spwd
extern struct spwd* getspent(void);
extern int getspent_r(struct spwd* spwd, char* buffer, size_t bufferSize,
struct spwd** _result);
extern struct spwd* getspnam(const char* name);
extern int getspnam_r(const char* name, struct spwd* spwd, char* buffer,
size_t bufferSize, struct spwd** _result);
extern struct spwd* sgetspent(const char* line);
extern int sgetspent_r(const char* line, struct spwd *spwd, char *buffer,
size_t bufferSize, struct spwd** _result);
extern struct spwd* fgetspent(FILE* file);
extern int fgetspent_r(FILE* file, struct spwd* spwd, char* buffer,
size_t bufferSize, struct spwd** _result);
int flags, spwd* entry, char* buffer, size_t bufferSize);
status_t copy_shadow_pwd_to_buffer(const spwd* from, spwd* entry,
struct spwd* spwd = getspnam(user);
bool ok = verify_password(passwd, spwd, password);
requiredPassword = spwd->sp_pwdp;
authenticate_user(const char* prompt, passwd* passwd, spwd* spwd, int maxTries,
if (verify_password(passwd, spwd, ""))
bool ok = verify_password(passwd, spwd, plainPassword);
spwd** _spwd, int maxTries, bool useStdio)
struct spwd* spwd = getspnam(user);
status_t error = authenticate_user(prompt, passwd, spwd, maxTries,
*_spwd = spwd;
verify_password(passwd* passwd, spwd* spwd, const char* plainPassword)
if (spwd == NULL) {
bool verify_password(passwd* passwd, spwd* spwd, const char* plainPassword);
status_t authenticate_user(const char* prompt, passwd* passwd, spwd* spwd,
passwd** _passwd, spwd** _spwd, int maxTries, bool useStdio);
struct spwd *sp = NULL;
struct spwd *shadowpwd = getspnam(username);
spwd* WriteFlatShadowPwd(FlatStore& store) const
struct spwd spwd;
spwd.sp_namp = store.AppendString(fName);
spwd.sp_pwdp = store.AppendString(fShadowPassword);
spwd.sp_lstchg = fLastChanged;
spwd.sp_min = fMin;
spwd.sp_max = fMax;
spwd.sp_warn = fWarn;
spwd.sp_inact = fInactive;
spwd.sp_expire = fExpiration;
spwd.sp_flag = fFlags;
return store.AppendData(spwd);
size_t entriesSpace = sizeof(spwd*) * count;
spwd** entries = new spwd*[count];
ArrayDeleter<spwd*> _(entries);
sShadowPwdEntries[sIterationIndex], spwd, buffer, bufferSize);
*_result = spwd;
struct spwd *
struct spwd* result = NULL;
getspnam_r(const char *name, struct spwd *spwd, char *buffer,
size_t bufferSize, struct spwd **_result)
min, max, warn, inactive, expiration, flags, spwd, buffer, bufferSize);
*_result = spwd;
struct spwd*
struct spwd* result = NULL;
sgetspent_r(const char* _line, struct spwd *spwd, char *buffer,
size_t bufferSize, struct spwd** _result)
min, max, warn, inactive, expiration, flags, spwd, buffer, bufferSize);
*_result = spwd;
struct spwd*
struct spwd* result = NULL;
fgetspent_r(FILE* file, struct spwd* spwd, char* buffer, size_t bufferSize,
struct spwd** _result)
return sgetspent_r(line, spwd, buffer, bufferSize, _result);
static spwd** sShadowPwdEntries = NULL;
static struct spwd sShadowPwdBuffer;
spwd** entries;
spwd* entry = relocate_pointer(baseAddress, entries[i]);
struct spwd*
struct spwd* result = NULL;
getspent_r(struct spwd* spwd, char* buffer, size_t bufferSize,
struct spwd** _result)
int flags, spwd* entry, char* buffer, size_t bufferSize)
BPrivate::copy_shadow_pwd_to_buffer(const spwd* from, spwd* entry,