diff options
author | Matt Johnston <matt@ucc.asn.au> | 2004-06-23 07:14:16 +0000 |
---|---|---|
committer | Matt Johnston <matt@ucc.asn.au> | 2004-06-23 07:14:16 +0000 |
commit | 09b50641ff656b22cf1f24e43d8504a1a7f3afec (patch) | |
tree | 287484eb2d40c1dd174f1073a16dd959952ac25a /svr-auth.c | |
parent | 8977fbbd97d30ed5a064e2f514abfeb22b7f05dd (diff) | |
parent | 18bfb4dd4812ab1e30bb4b2ecb6674ea2d368322 (diff) |
merge of abac2150ee4f4031a98016241fbd136d24fed127
and ffa047425729e478a5b49b1ab0f8ec71c08a1421
--HG--
extra : convert_revision : e9b7d4eda64d70aff736f48cc8dea680b153139b
Diffstat (limited to 'svr-auth.c')
-rw-r--r-- | svr-auth.c | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -52,7 +52,7 @@ void authinitialise() { * on initialisation */ static void authclear() { - svr_ses.authstate.authdone = 0; + ses.authdone = 0; svr_ses.authstate.pw = NULL; svr_ses.authstate.username = NULL; svr_ses.authstate.printableuser = NULL; @@ -102,7 +102,7 @@ void recv_msg_userauth_request() { TRACE(("enter recv_msg_userauth_request")); /* ignore packets if auth is already done */ - if (svr_ses.authstate.authdone == 1) { + if (ses.authdone == 1) { return; } @@ -339,7 +339,11 @@ void send_msg_userauth_success() { buf_putbyte(ses.writepayload, SSH_MSG_USERAUTH_SUCCESS); encrypt_packet(); - svr_ses.authstate.authdone = 1; + ses.authdone = 1; + + if (svr_ses.authstate.pw->pw_uid == 0) { + ses.allowprivport = 1; + } /* Remove from the list of pre-auth sockets. Should be m_close(), since if * we fail, we might end up leaking connection slots, and disallow new |