diff options
author | Damien Miller <djm@mindrot.org> | 2013-04-23 14:25:52 +1000 |
---|---|---|
committer | Damien Miller <djm@mindrot.org> | 2013-04-23 14:25:52 +1000 |
commit | 6332da2ae88db623d7da8070dd807efa26d9dfe8 (patch) | |
tree | 1d8fd6ce793ce93282d2ae80a6cee8324b283f31 /auth.c | |
parent | ce1c9574fcfaf753a062276867335c1e237f725c (diff) |
- (djm) [auth.c configure.ac misc.c monitor.c monitor_wrap.c] Support
platforms, such as Android, that lack struct passwd.pw_gecos. Report
and initial patch from Nathan Osman bz#2086; feedback tim@ ok dtucker@
Diffstat (limited to 'auth.c')
-rw-r--r-- | auth.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -721,10 +721,12 @@ fakepw(void) | |||
721 | fake.pw_name = "NOUSER"; | 721 | fake.pw_name = "NOUSER"; |
722 | fake.pw_passwd = | 722 | fake.pw_passwd = |
723 | "$2a$06$r3.juUaHZDlIbQaO2dS9FuYxL1W9M81R1Tc92PoSNmzvpEqLkLGrK"; | 723 | "$2a$06$r3.juUaHZDlIbQaO2dS9FuYxL1W9M81R1Tc92PoSNmzvpEqLkLGrK"; |
724 | #ifdef HAVE_STRUCT_PASSWD_PW_GECOS | ||
724 | fake.pw_gecos = "NOUSER"; | 725 | fake.pw_gecos = "NOUSER"; |
726 | #endif | ||
725 | fake.pw_uid = privsep_pw == NULL ? (uid_t)-1 : privsep_pw->pw_uid; | 727 | fake.pw_uid = privsep_pw == NULL ? (uid_t)-1 : privsep_pw->pw_uid; |
726 | fake.pw_gid = privsep_pw == NULL ? (gid_t)-1 : privsep_pw->pw_gid; | 728 | fake.pw_gid = privsep_pw == NULL ? (gid_t)-1 : privsep_pw->pw_gid; |
727 | #ifdef HAVE_PW_CLASS_IN_PASSWD | 729 | #ifdef HAVE_STRUCT_PASSWD_PW_CLASS |
728 | fake.pw_class = ""; | 730 | fake.pw_class = ""; |
729 | #endif | 731 | #endif |
730 | fake.pw_dir = "/nonexist"; | 732 | fake.pw_dir = "/nonexist"; |