diff options
author | des <des@FreeBSD.org> | 2011-10-05 22:08:17 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2011-10-05 22:08:17 +0000 |
commit | 038442ad80c21a07c19532a176030e2ca51fdd9d (patch) | |
tree | 654e40360db9b6bb67928b3a5c1b5dbd84925000 /crypto/openssh/auth.c | |
parent | 2276ee273397e0ccd5c7911848e3de9bd91fb1c2 (diff) | |
parent | a9c7316f0b012b7e85d1a1c4d8b6ce36b9fd9604 (diff) | |
download | FreeBSD-src-038442ad80c21a07c19532a176030e2ca51fdd9d.zip FreeBSD-src-038442ad80c21a07c19532a176030e2ca51fdd9d.tar.gz |
Upgrade to OpenSSH 5.9p1.
MFC after: 3 months
Diffstat (limited to 'crypto/openssh/auth.c')
-rw-r--r-- | crypto/openssh/auth.c | 23 |
1 files changed, 4 insertions, 19 deletions
diff --git a/crypto/openssh/auth.c b/crypto/openssh/auth.c index 23c39e5..893dc7b 100644 --- a/crypto/openssh/auth.c +++ b/crypto/openssh/auth.c @@ -1,4 +1,4 @@ -/* $OpenBSD: auth.c,v 1.91 2010/11/29 23:45:51 djm Exp $ */ +/* $OpenBSD: auth.c,v 1.94 2011/05/23 03:33:38 djm Exp $ */ /* * Copyright (c) 2000 Markus Friedl. All rights reserved. * @@ -332,7 +332,7 @@ auth_root_allowed(char *method) * * This returns a buffer allocated by xmalloc. */ -static char * +char * expand_authorized_keys(const char *filename, struct passwd *pw) { char *file, ret[MAXPATHLEN]; @@ -356,18 +356,6 @@ expand_authorized_keys(const char *filename, struct passwd *pw) } char * -authorized_keys_file(struct passwd *pw) -{ - return expand_authorized_keys(options.authorized_keys_file, pw); -} - -char * -authorized_keys_file2(struct passwd *pw) -{ - return expand_authorized_keys(options.authorized_keys_file2, pw); -} - -char * authorized_principals_file(struct passwd *pw) { if (options.authorized_principals_file == NULL) @@ -469,7 +457,6 @@ secure_filename(FILE *f, const char *file, struct passwd *pw, } strlcpy(buf, cp, sizeof(buf)); - debug3("secure_filename: checking '%s'", buf); if (stat(buf, &st) < 0 || (st.st_uid != 0 && st.st_uid != uid) || (st.st_mode & 022) != 0) { @@ -479,11 +466,9 @@ secure_filename(FILE *f, const char *file, struct passwd *pw, } /* If are past the homedir then we can stop */ - if (comparehome && strcmp(homedir, buf) == 0) { - debug3("secure_filename: terminating check at '%s'", - buf); + if (comparehome && strcmp(homedir, buf) == 0) break; - } + /* * dirname should always complete with a "/" path, * but we can be paranoid and check for "." too |