summaryrefslogtreecommitdiff
path: root/auth.c
diff options
context:
space:
mode:
authordjm <djm>2012-04-22 01:21:43 +0000
committerdjm <djm>2012-04-22 01:21:43 +0000
commit5af5b1085c4f9e1542ae7a7f74a6d5aa201f17d0 (patch)
tree93209970d332e409a499ab5acefc448c4486e0ca /auth.c
parent84cfdc9f5776f096938d977bb4675adfff287a2f (diff)
downloadopenssh-5af5b1085c4f9e1542ae7a7f74a6d5aa201f17d0.tar.gz
- djm@cvs.openbsd.org 2012/04/11 13:17:54
[auth.c] Support "none" as an argument for AuthorizedPrincipalsFile to indicate no file should be read.
Diffstat (limited to 'auth.c')
-rw-r--r--auth.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/auth.c b/auth.c
index cd95da93..97693288 100644
--- a/auth.c
+++ b/auth.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: auth.c,v 1.94 2011/05/23 03:33:38 djm Exp $ */
+/* $OpenBSD: auth.c,v 1.95 2012/04/11 13:17:54 djm Exp $ */
/*
* Copyright (c) 2000 Markus Friedl. All rights reserved.
*
@@ -357,7 +357,8 @@ expand_authorized_keys(const char *filename, struct passwd *pw)
char *
authorized_principals_file(struct passwd *pw)
{
- if (options.authorized_principals_file == NULL)
+ if (options.authorized_principals_file == NULL ||
+ strcasecmp(options.authorized_principals_file, "none") == 0)
return NULL;
return expand_authorized_keys(options.authorized_principals_file, pw);
}