summaryrefslogtreecommitdiff
path: root/auth.c
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2006-07-12 22:34:17 +1000
committerDarren Tucker <dtucker@zip.com.au>2006-07-12 22:34:17 +1000
commit4515047e47f26377a46f480ed5929e8ccfa18720 (patch)
treea7485f1794bcab3a46c5f3efcf2a3ba630021be9 /auth.c
parentba724050263c0bca0a7dffa26462d046c4df7e01 (diff)
- dtucker@cvs.openbsd.org 2006/07/12 11:34:58
[sshd.c servconf.h servconf.c sshd_config.5 auth.c] Add support for conditional directives to sshd_config via a "Match" keyword, which works similarly to the "Host" directive in ssh_config. Lines after a Match line override the default set in the main section if the condition on the Match line is true, eg AllowTcpForwarding yes Match User anoncvs AllowTcpForwarding no will allow port forwarding by all users except "anoncvs". Currently only a very small subset of directives are supported. ok djm@
Diffstat (limited to 'auth.c')
-rw-r--r--auth.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/auth.c b/auth.c
index e5ddc79da..3bca8dc21 100644
--- a/auth.c
+++ b/auth.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: auth.c,v 1.70 2006/07/11 20:07:25 stevesk Exp $ */ 1/* $OpenBSD: auth.c,v 1.71 2006/07/12 11:34:58 dtucker Exp $ */
2/* 2/*
3 * Copyright (c) 2000 Markus Friedl. All rights reserved. 3 * Copyright (c) 2000 Markus Friedl. All rights reserved.
4 * 4 *
@@ -467,6 +467,9 @@ getpwnamallow(const char *user)
467#endif 467#endif
468 struct passwd *pw; 468 struct passwd *pw;
469 469
470 parse_server_match_config(&options, user,
471 get_canonical_hostname(options.use_dns), get_remote_ipaddr());
472
470 pw = getpwnam(user); 473 pw = getpwnam(user);
471 if (pw == NULL) { 474 if (pw == NULL) {
472 logit("Invalid user %.100s from %.100s", 475 logit("Invalid user %.100s from %.100s",