diff options
author | Colin Watson <cjwatson@debian.org> | 2008-05-25 23:24:33 +0000 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2008-05-25 23:24:33 +0000 |
commit | d61c655626e74e65dba34e4e9d5aa6616cc72f93 (patch) | |
tree | 039e0946fb19b073b13605142e5737875107dba9 /auth2-pubkey.c | |
parent | fe3af0a26497234bbae83a25fadf81a78cf2cf66 (diff) |
Log IP addresses of hosts attempting to use blacklisted keys (closes:
#481721).
Diffstat (limited to 'auth2-pubkey.c')
-rw-r--r-- | auth2-pubkey.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/auth2-pubkey.c b/auth2-pubkey.c index 4976a5a8a..0870d64f6 100644 --- a/auth2-pubkey.c +++ b/auth2-pubkey.c | |||
@@ -277,11 +277,13 @@ user_key_allowed(struct passwd *pw, Key *key) | |||
277 | if (blacklisted_key(key) == 1) { | 277 | if (blacklisted_key(key) == 1) { |
278 | fp = key_fingerprint(key, SSH_FP_MD5, SSH_FP_HEX); | 278 | fp = key_fingerprint(key, SSH_FP_MD5, SSH_FP_HEX); |
279 | if (options.permit_blacklisted_keys) | 279 | if (options.permit_blacklisted_keys) |
280 | logit("Public key %s blacklisted (see " | 280 | logit("Public key %s from %s blacklisted (see " |
281 | "ssh-vulnkey(1)); continuing anyway", fp); | 281 | "ssh-vulnkey(1)); continuing anyway", |
282 | fp, get_remote_ipaddr()); | ||
282 | else | 283 | else |
283 | logit("Public key %s blacklisted (see " | 284 | logit("Public key %s from %s blacklisted (see " |
284 | "ssh-vulnkey(1))", fp); | 285 | "ssh-vulnkey(1))", |
286 | fp, get_remote_ipaddr()); | ||
285 | xfree(fp); | 287 | xfree(fp); |
286 | if (!options.permit_blacklisted_keys) | 288 | if (!options.permit_blacklisted_keys) |
287 | return 0; | 289 | return 0; |