View | Details | Raw Unified | Return to bug 2012 | Differences between
and this patch

Collapse All | Expand All

(-)a/misc.c (+7 lines)
Lines 205-211 pwcopy(struct passwd *pw) Link Here
205
	struct passwd *copy = xcalloc(1, sizeof(*copy));
205
	struct passwd *copy = xcalloc(1, sizeof(*copy));
206
206
207
	copy->pw_name = xstrdup(pw->pw_name);
207
	copy->pw_name = xstrdup(pw->pw_name);
208
#if defined(__ANDROID__)
209
	/* FIXME: password is NULL on Android */
210
	copy->pw_passwd = xstrdup(pw->pw_passwd ? pw->pw_passwd :
211
	/* fake password from auth.c */
212
	"$2a$06$r3.juUaHZDlIbQaO2dS9FuYxL1W9M81R1Tc92PoSNmzvpEqLkLGrK");
213
#else
208
	copy->pw_passwd = xstrdup(pw->pw_passwd);
214
	copy->pw_passwd = xstrdup(pw->pw_passwd);
215
#endif
209
#ifdef HAVE_STRUCT_PASSWD_PW_GECOS
216
#ifdef HAVE_STRUCT_PASSWD_PW_GECOS
210
	copy->pw_gecos = xstrdup(pw->pw_gecos);
217
	copy->pw_gecos = xstrdup(pw->pw_gecos);
211
#endif
218
#endif
(-)a/openbsd-compat/xcrypt.c (-1 / +11 lines)
Lines 53-58 Link Here
53
#  include <pwdadj.h>
53
#  include <pwdadj.h>
54
# endif
54
# endif
55
55
56
# if defined(__ANDROID__)
57
#  include <sys/limits.h>
58
#  if _XOPEN_CRYPT == -1
59
    /* FIXME: to update configure script */
60
#   undef HAVE_MD5_PASSWORDS
61
#  endif
62
# endif
63
56
# if defined(HAVE_MD5_PASSWORDS) && !defined(HAVE_MD5_CRYPT)
64
# if defined(HAVE_MD5_PASSWORDS) && !defined(HAVE_MD5_CRYPT)
57
#  include "md5crypt.h"
65
#  include "md5crypt.h"
58
# endif 
66
# endif 
Lines 74-79 xcrypt(const char *password, const char *salt) Link Here
74
                crypted = crypt(password, salt);
82
                crypted = crypt(password, salt);
75
# elif defined(HAVE_SECUREWARE)
83
# elif defined(HAVE_SECUREWARE)
76
        crypted = bigcrypt(password, salt);
84
        crypted = bigcrypt(password, salt);
85
# elif defined(__ANDROID__)
86
	/* FIXME: password is NULL on Android */
87
	crypted = NULL;
77
# else
88
# else
78
        crypted = crypt(password, salt);
89
        crypted = crypt(password, salt);
79
# endif 
90
# endif 
80
- 

Return to bug 2012