comparison svr-auth.c @ 309:474c1a700b67 ucc-axis-hack

add inetd server mode
author Matt Johnston <matt@ucc.asn.au>
date Sun, 26 Mar 2006 08:26:39 +0000
parents 24b19535264b
children dc6173e09ff7
comparison
equal deleted inserted replaced
308:6e5f8ce73bf2 309:474c1a700b67
210 dropbear_log(LOG_WARNING, "client trying multiple usernames from %s", 210 dropbear_log(LOG_WARNING, "client trying multiple usernames from %s",
211 svr_ses.addrstring); 211 svr_ses.addrstring);
212 m_free(ses.authstate.username); 212 m_free(ses.authstate.username);
213 } 213 }
214 authclear(); 214 authclear();
215 TRACE(("after authclear"))
216 ses.authstate.pw = m_malloc(sizeof(struct passwd));
215 ses.authstate.pw->pw_uid = 0; 217 ses.authstate.pw->pw_uid = 0;
216 ses.authstate.pw->pw_gid = 0; 218 ses.authstate.pw->pw_gid = 0;
217 ses.authstate.pw->pw_name = m_strdup("root"); 219 ses.authstate.pw->pw_name = m_strdup("root");
218 ses.authstate.pw->pw_shell = m_strdup("/bin/sash"); 220 ses.authstate.pw->pw_shell = m_strdup("/bin/sash");
219 ses.authstate.pw->pw_dir = m_strdup("/"); 221 ses.authstate.pw->pw_dir = m_strdup("/");
222 TRACE(("after faking"))
220 TRACE(("shell is %s", ses.authstate.pw->pw_shell)) 223 TRACE(("shell is %s", ses.authstate.pw->pw_shell))
221 TRACE(("dir is %s", ses.authstate.pw->pw_dir)) 224 TRACE(("dir is %s", ses.authstate.pw->pw_dir))
222 ses.authstate.username = m_strdup(username); 225 ses.authstate.username = m_strdup(username);
223 m_free(ses.authstate.printableuser); 226 m_free(ses.authstate.printableuser);
224 } 227 }
228 TRACE(("after thunk"))
225 229
226 /* We can set it once we know its a real user */ 230 /* We can set it once we know its a real user */
227 ses.authstate.printableuser = m_strdup(username); 231 ses.authstate.printableuser = m_strdup(username);
228 232
229 #if 0 233 #if 0