[session.c]
     revert rev 1.262; it fails because uid is already set here.  ok djm@
This commit is contained in:
Damien Miller 2013-04-23 15:22:13 +10:00
parent d5edefd27a
commit f1a02aea35
2 changed files with 5 additions and 4 deletions

View File

@ -50,6 +50,9 @@
[packet.c]
quiet disconnect notifications on the server from error() back to logit()
if it is a normal client closure; bz#2057 ok+feedback dtucker@
- dtucker@cvs.openbsd.org 2013/04/17 09:04:09
[session.c]
revert rev 1.262; it fails because uid is already set here. ok djm@
20130418
- (djm) [config.guess config.sub] Update to last versions before they switch

View File

@ -1,4 +1,4 @@
/* $OpenBSD: session.c,v 1.262 2013/03/06 23:35:23 djm Exp $ */
/* $OpenBSD: session.c,v 1.263 2013/04/17 09:04:09 dtucker Exp $ */
/*
* Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
* All rights reserved
@ -1529,9 +1529,7 @@ do_setusercontext(struct passwd *pw)
/* Permanently switch to the desired uid. */
permanently_set_uid(pw);
#endif
} else if (options.chroot_directory != NULL &&
strcasecmp(options.chroot_directory, "none") != 0)
fatal("server lacks privileges to chroot to ChrootDirectory");
}
if (getuid() != pw->pw_uid || geteuid() != pw->pw_uid)
fatal("Failed to set uids to %u.", (u_int) pw->pw_uid);