From 46dee7219da466e292c865fa7e24bc8634197875 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Sun, 18 Dec 2005 13:54:53 +0000 Subject: r12311: Reformatting (This used to be commit 23f5be1dcbb9e5a1e7f24813c67009056b07d59c) --- source3/smbd/password.c | 38 +++++++++++++++++++++++--------------- 1 file changed, 23 insertions(+), 15 deletions(-) (limited to 'source3/smbd') diff --git a/source3/smbd/password.c b/source3/smbd/password.c index e4516be32b..764fbe8a2e 100644 --- a/source3/smbd/password.c +++ b/source3/smbd/password.c @@ -521,19 +521,21 @@ BOOL authorise_login(int snum, fstring user, DATA_BLOB password, BOOL ok = False; #ifdef DEBUG_PASSWORD - DEBUG(100,("authorise_login: checking authorisation on user=%s pass=%s\n", - user,password.data)); + DEBUG(100,("authorise_login: checking authorisation on " + "user=%s pass=%s\n", user,password.data)); #endif *guest = False; /* there are several possibilities: 1) login as the given user with given password - 2) login as a previously registered username with the given password + 2) login as a previously registered username with the given + password 3) login as a session list username with the given password 4) login as a previously validated user/password pair 5) login as the "user =" user with given password - 6) login as the "user =" user with no password (guest connection) + 6) login as the "user =" user with no password + (guest connection) 7) login as guest user with no password if the service is guest_only then steps 1 to 5 are skipped @@ -562,11 +564,12 @@ BOOL authorise_login(int snum, fstring user, DATA_BLOB password, if (password_ok(user2,password)) { ok = True; fstrcpy(user,user2); - DEBUG(3,("authorise_login: ACCEPTED: session list username (%s) \ -and given password ok\n", user)); + DEBUG(3,("authorise_login: ACCEPTED: session " + "list username (%s) and given " + "password ok\n", user)); } } - + SAFE_FREE(user_list); } @@ -585,17 +588,21 @@ and given password ok\n", user)); if (auser) { ok = True; fstrcpy(user,auser); - DEBUG(3,("authorise_login: ACCEPTED: group username \ -and given password ok (%s)\n", user)); + DEBUG(3,("authorise_login: ACCEPTED: " + "group username and given " + "password ok (%s)\n", user)); } } else { fstring user2; fstrcpy(user2,auser); - if (user_ok(user2,snum, NULL, 0) && password_ok(user2,password)) { + if (user_ok(user2,snum, NULL, 0) && + password_ok(user2,password)) { ok = True; fstrcpy(user,user2); - DEBUG(3,("authorise_login: ACCEPTED: user list username \ -and given password ok (%s)\n", user)); + DEBUG(3,("authorise_login: ACCEPTED: " + "user list username and " + "given password ok (%s)\n", + user)); } } } @@ -608,10 +615,11 @@ and given password ok (%s)\n", user)); if (Get_Pwnam(guestname)) { fstrcpy(user,guestname); ok = True; - DEBUG(3,("authorise_login: ACCEPTED: guest account and guest ok (%s)\n", - user)); + DEBUG(3,("authorise_login: ACCEPTED: guest account " + "and guest ok (%s)\n", user)); } else { - DEBUG(0,("authorise_login: Invalid guest account %s??\n",guestname)); + DEBUG(0,("authorise_login: Invalid guest account " + "%s??\n",guestname)); } *guest = True; } -- cgit