diff options
-rw-r--r-- | ChangeLog | 2 | ||||
-rw-r--r-- | platform.c | 8 | ||||
-rw-r--r-- | session.c | 5 |
3 files changed, 8 insertions, 7 deletions
@@ -5,6 +5,8 @@ | |||
5 | -ftrapv (it seems to work but fails when trying to link ssh). ok djm@ | 5 | -ftrapv (it seems to work but fails when trying to link ssh). ok djm@ |
6 | - (dtucker) [aclocal.m4] Differentiate between compile-time and link-time | 6 | - (dtucker) [aclocal.m4] Differentiate between compile-time and link-time |
7 | tests in the configure output. ok djm. | 7 | tests in the configure output. ok djm. |
8 | - (tim) [platform.c session.c] Fix bug affecting SVR5 platforms introduced | ||
9 | with sftp chroot support. Move set_id call after chroot. | ||
8 | 10 | ||
9 | 20140120 | 11 | 20140120 |
10 | - (dtucker) [gss-serv-krb5.c] Fall back to krb5_cc_gen_new if the Kerberos | 12 | - (dtucker) [gss-serv-krb5.c] Fall back to krb5_cc_gen_new if the Kerberos |
diff --git a/platform.c b/platform.c index 6d896c229..30fc60909 100644 --- a/platform.c +++ b/platform.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $Id: platform.c,v 1.20 2013/09/22 09:02:40 dtucker Exp $ */ | 1 | /* $Id: platform.c,v 1.21 2014/01/21 01:59:29 tim Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * Copyright (c) 2006 Darren Tucker. All rights reserved. | 4 | * Copyright (c) 2006 Darren Tucker. All rights reserved. |
@@ -164,12 +164,6 @@ platform_setusercontext_post_groups(struct passwd *pw) | |||
164 | aix_usrinfo(pw); | 164 | aix_usrinfo(pw); |
165 | #endif /* _AIX */ | 165 | #endif /* _AIX */ |
166 | 166 | ||
167 | #if !defined(HAVE_LOGIN_CAP) && defined(USE_LIBIAF) | ||
168 | if (set_id(pw->pw_name) != 0) { | ||
169 | exit(1); | ||
170 | } | ||
171 | # endif /* USE_LIBIAF */ | ||
172 | |||
173 | #ifdef HAVE_SETPCRED | 167 | #ifdef HAVE_SETPCRED |
174 | /* | 168 | /* |
175 | * If we have a chroot directory, we set all creds except real | 169 | * If we have a chroot directory, we set all creds except real |
@@ -1552,6 +1552,11 @@ do_setusercontext(struct passwd *pw) | |||
1552 | */ | 1552 | */ |
1553 | (void) setusercontext(lc, pw, pw->pw_uid, LOGIN_SETUMASK); | 1553 | (void) setusercontext(lc, pw, pw->pw_uid, LOGIN_SETUMASK); |
1554 | #else | 1554 | #else |
1555 | # ifdef USE_LIBIAF | ||
1556 | if (set_id(pw->pw_name) != 0) { | ||
1557 | exit(1); | ||
1558 | } | ||
1559 | # endif /* USE_LIBIAF */ | ||
1555 | /* Permanently switch to the desired uid. */ | 1560 | /* Permanently switch to the desired uid. */ |
1556 | permanently_set_uid(pw); | 1561 | permanently_set_uid(pw); |
1557 | #endif | 1562 | #endif |