Displaying 1 result from an estimated 1 matches for "prng_seed_saved".
2001 Jan 16
1
ssh drops privs when it can't find ~/.ssh/prng_seed
..., using rhosts authentication, entropy.c drops the privs in
prng_write_seedfile() at the setuid(original_uid) line (line 550,
approx):
void
prng_write_seedfile(void) {
int fd;
char seed[1024];
char filename[1024];
struct passwd *pw;
/* Don't bother if we have already saved a seed */
if (prng_seed_saved)
return;
setuid(original_uid);
/* ^^^^^^^^^^^^^^^^^^^^ ***HERE*** */
prng_seed_saved = 1;
pw = getpwuid(original_uid);
if (pw == NULL)
fatal("Couldn't get password entry for current user (%i): %s",
original_uid, strerror(errno));
/* Try to ensure that t...