summaryrefslogtreecommitdiff
path: root/source3/auth/auth_rhosts.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2001-08-12 11:19:57 +0000
committerAndrew Bartlett <abartlet@samba.org>2001-08-12 11:19:57 +0000
commit6ad80352dd2523c310258de3211a2af0f1763d2a (patch)
tree7058ea9d3faf2c4f72a9b7edcca6d4ac856108b9 /source3/auth/auth_rhosts.c
parent9644bf74bd90ef5b9c016434408be1acaa311978 (diff)
downloadsamba-6ad80352dd2523c310258de3211a2af0f1763d2a.tar.gz
samba-6ad80352dd2523c310258de3211a2af0f1763d2a.tar.bz2
samba-6ad80352dd2523c310258de3211a2af0f1763d2a.zip
This patch does a number of things, mostly smaller than they look :-)
In particuar, it moves the domain_client_validate stuff out of auth_domain.c to somwhere where they (I hope) they can be shared with winbind better. (This may need some work) The main purpose of this patch was however to improve some of the internal documentation and to correctly place become_root()/unbecome_root() calls within the code. Finally this patch moves some more of auth.c into other files, auth_unix.c in this case. Andrew Bartlett (This used to be commit ea1c547ac880def29f150de2172c95213509350e)
Diffstat (limited to 'source3/auth/auth_rhosts.c')
-rw-r--r--source3/auth/auth_rhosts.c21
1 files changed, 21 insertions, 0 deletions
diff --git a/source3/auth/auth_rhosts.c b/source3/auth/auth_rhosts.c
index c1bee6247c..f11f9cf777 100644
--- a/source3/auth/auth_rhosts.c
+++ b/source3/auth/auth_rhosts.c
@@ -163,3 +163,24 @@ BOOL check_hosts_equiv(char *user)
return(False);
}
+
+/****************************************************************************
+ Check for a valid .rhosts/hosts.equiv entry for this user
+****************************************************************************/
+
+uint32 check_rhosts_security(const auth_usersupplied_info *user_info,
+ auth_serversupplied_info *server_info)
+{
+ uint32 nt_status = NT_STATUS_LOGON_FAILURE;
+
+ become_root();
+ if (check_hosts_equiv(user_info->smb_username.str)) {
+ nt_status = NT_STATUS_NOPROBLEMO;
+ }
+ unbecome_root();
+
+ return nt_status;
+}
+
+
+