diff options
author | Colin Watson <cjwatson@debian.org> | 2020-02-21 11:57:14 +0000 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2020-02-21 14:27:02 +0000 |
commit | 886e47e745586c34e81cfd5c5fb9b5dbc8e84d04 (patch) | |
tree | dd6c3b4dc64a17c520af7aaf213163f8a0a63e56 /auth.c | |
parent | ac2b4c0697fcac554041ab95f81736887eadf6ec (diff) | |
parent | a2dabf35ce0228c86a288d11cc847a9d9801604f (diff) |
New upstream release (8.2p1)
Diffstat (limited to 'auth.c')
-rw-r--r-- | auth.c | 14 |
1 files changed, 8 insertions, 6 deletions
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: auth.c,v 1.141 2019/10/02 00:42:30 djm Exp $ */ | 1 | /* $OpenBSD: auth.c,v 1.146 2020/01/31 22:42:45 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2000 Markus Friedl. All rights reserved. | 3 | * Copyright (c) 2000 Markus Friedl. All rights reserved. |
4 | * | 4 | * |
@@ -79,6 +79,7 @@ | |||
79 | 79 | ||
80 | /* import */ | 80 | /* import */ |
81 | extern ServerOptions options; | 81 | extern ServerOptions options; |
82 | extern struct include_list includes; | ||
82 | extern int use_privsep; | 83 | extern int use_privsep; |
83 | extern struct sshbuf *loginmsg; | 84 | extern struct sshbuf *loginmsg; |
84 | extern struct passwd *privsep_pw; | 85 | extern struct passwd *privsep_pw; |
@@ -489,7 +490,7 @@ check_key_in_hostfiles(struct passwd *pw, struct sshkey *key, const char *host, | |||
489 | host_status = check_key_in_hostkeys(hostkeys, key, &found); | 490 | host_status = check_key_in_hostkeys(hostkeys, key, &found); |
490 | if (host_status == HOST_REVOKED) | 491 | if (host_status == HOST_REVOKED) |
491 | error("WARNING: revoked key for %s attempted authentication", | 492 | error("WARNING: revoked key for %s attempted authentication", |
492 | found->host); | 493 | host); |
493 | else if (host_status == HOST_OK) | 494 | else if (host_status == HOST_OK) |
494 | debug("%s: key for %s found at %s:%ld", __func__, | 495 | debug("%s: key for %s found at %s:%ld", __func__, |
495 | found->host, found->file, found->line); | 496 | found->host, found->file, found->line); |
@@ -571,7 +572,7 @@ getpwnamallow(struct ssh *ssh, const char *user) | |||
571 | 572 | ||
572 | ci = get_connection_info(ssh, 1, options.use_dns); | 573 | ci = get_connection_info(ssh, 1, options.use_dns); |
573 | ci->user = user; | 574 | ci->user = user; |
574 | parse_server_match_config(&options, ci); | 575 | parse_server_match_config(&options, &includes, ci); |
575 | log_change_level(options.log_level); | 576 | log_change_level(options.log_level); |
576 | process_permitopen(ssh, &options); | 577 | process_permitopen(ssh, &options); |
577 | 578 | ||
@@ -828,7 +829,7 @@ subprocess(const char *tag, struct passwd *pw, const char *command, | |||
828 | child_set_env(&child_env, &envsize, "LANG", cp); | 829 | child_set_env(&child_env, &envsize, "LANG", cp); |
829 | 830 | ||
830 | for (i = 0; i < NSIG; i++) | 831 | for (i = 0; i < NSIG; i++) |
831 | signal(i, SIG_DFL); | 832 | ssh_signal(i, SIG_DFL); |
832 | 833 | ||
833 | if ((devnull = open(_PATH_DEVNULL, O_RDWR)) == -1) { | 834 | if ((devnull = open(_PATH_DEVNULL, O_RDWR)) == -1) { |
834 | error("%s: open %s: %s", tag, _PATH_DEVNULL, | 835 | error("%s: open %s: %s", tag, _PATH_DEVNULL, |
@@ -912,7 +913,7 @@ auth_log_authopts(const char *loc, const struct sshauthopt *opts, int do_remote) | |||
912 | 913 | ||
913 | snprintf(buf, sizeof(buf), "%d", opts->force_tun_device); | 914 | snprintf(buf, sizeof(buf), "%d", opts->force_tun_device); |
914 | /* Try to keep this alphabetically sorted */ | 915 | /* Try to keep this alphabetically sorted */ |
915 | snprintf(msg, sizeof(msg), "key options:%s%s%s%s%s%s%s%s%s%s%s%s%s", | 916 | snprintf(msg, sizeof(msg), "key options:%s%s%s%s%s%s%s%s%s%s%s%s%s%s", |
916 | opts->permit_agent_forwarding_flag ? " agent-forwarding" : "", | 917 | opts->permit_agent_forwarding_flag ? " agent-forwarding" : "", |
917 | opts->force_command == NULL ? "" : " command", | 918 | opts->force_command == NULL ? "" : " command", |
918 | do_env ? " environment" : "", | 919 | do_env ? " environment" : "", |
@@ -925,7 +926,8 @@ auth_log_authopts(const char *loc, const struct sshauthopt *opts, int do_remote) | |||
925 | opts->force_tun_device == -1 ? "" : " tun=", | 926 | opts->force_tun_device == -1 ? "" : " tun=", |
926 | opts->force_tun_device == -1 ? "" : buf, | 927 | opts->force_tun_device == -1 ? "" : buf, |
927 | opts->permit_user_rc ? " user-rc" : "", | 928 | opts->permit_user_rc ? " user-rc" : "", |
928 | opts->permit_x11_forwarding_flag ? " x11-forwarding" : ""); | 929 | opts->permit_x11_forwarding_flag ? " x11-forwarding" : "", |
930 | opts->no_require_user_presence ? " no-touch-required" : ""); | ||
929 | 931 | ||
930 | debug("%s: %s", loc, msg); | 932 | debug("%s: %s", loc, msg); |
931 | if (do_remote) | 933 | if (do_remote) |