summaryrefslogtreecommitdiff
path: root/monitor.c
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2013-07-18 16:10:09 +1000
committerDamien Miller <djm@mindrot.org>2013-07-18 16:10:09 +1000
commit20bdcd72365e8b3d51261993928cc47c5f0d7c8a (patch)
treedb4f44ba0f86b271a9493ce0d866941f0ac5a953 /monitor.c
parent3071070b39e6d1722151c754cdc2b26640eaf45e (diff)
- djm@cvs.openbsd.org 2013/06/21 00:34:49
[auth-rsa.c auth.h auth2-hostbased.c auth2-pubkey.c monitor.c] for hostbased authentication, print the client host and user on the auth success/failure line; bz#2064, ok dtucker@
Diffstat (limited to 'monitor.c')
-rw-r--r--monitor.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/monitor.c b/monitor.c
index 7286126f5..0516f60a2 100644
--- a/monitor.c
+++ b/monitor.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: monitor.c,v 1.125 2013/05/19 02:42:42 djm Exp $ */ 1/* $OpenBSD: monitor.c,v 1.126 2013/06/21 00:34:49 djm Exp $ */
2/* 2/*
3 * Copyright 2002 Niels Provos <provos@citi.umich.edu> 3 * Copyright 2002 Niels Provos <provos@citi.umich.edu>
4 * Copyright 2002 Markus Friedl <markus@openbsd.org> 4 * Copyright 2002 Markus Friedl <markus@openbsd.org>
@@ -1165,7 +1165,7 @@ mm_answer_keyallowed(int sock, Buffer *m)
1165 case MM_USERKEY: 1165 case MM_USERKEY:
1166 allowed = options.pubkey_authentication && 1166 allowed = options.pubkey_authentication &&
1167 user_key_allowed(authctxt->pw, key); 1167 user_key_allowed(authctxt->pw, key);
1168 pubkey_auth_info(authctxt, key); 1168 pubkey_auth_info(authctxt, key, NULL);
1169 auth_method = "publickey"; 1169 auth_method = "publickey";
1170 if (options.pubkey_authentication && allowed != 1) 1170 if (options.pubkey_authentication && allowed != 1)
1171 auth_clear_options(); 1171 auth_clear_options();
@@ -1174,6 +1174,9 @@ mm_answer_keyallowed(int sock, Buffer *m)
1174 allowed = options.hostbased_authentication && 1174 allowed = options.hostbased_authentication &&
1175 hostbased_key_allowed(authctxt->pw, 1175 hostbased_key_allowed(authctxt->pw,
1176 cuser, chost, key); 1176 cuser, chost, key);
1177 pubkey_auth_info(authctxt, key,
1178 "client user \"%.100s\", client host \"%.100s\"",
1179 cuser, chost);
1177 auth_method = "hostbased"; 1180 auth_method = "hostbased";
1178 break; 1181 break;
1179 case MM_RSAHOSTKEY: 1182 case MM_RSAHOSTKEY: