summaryrefslogtreecommitdiff
path: root/sshd.c
diff options
context:
space:
mode:
Diffstat (limited to 'sshd.c')
-rw-r--r--sshd.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/sshd.c b/sshd.c
index d8faaebd5..64c564236 100644
--- a/sshd.c
+++ b/sshd.c
@@ -434,7 +434,8 @@ sshd_exchange_identification(int sock_in, int sock_out)
434 } 434 }
435 435
436 xasprintf(&server_version_string, "SSH-%d.%d-%.100s%s%s%s", 436 xasprintf(&server_version_string, "SSH-%d.%d-%.100s%s%s%s",
437 major, minor, SSH_VERSION, 437 major, minor,
438 options.debian_banner ? SSH_RELEASE : SSH_RELEASE_MINIMUM,
438 *options.version_addendum == '\0' ? "" : " ", 439 *options.version_addendum == '\0' ? "" : " ",
439 options.version_addendum, newline); 440 options.version_addendum, newline);
440 441
@@ -745,7 +746,7 @@ privsep_postauth(Authctxt *authctxt)
745 RAND_seed(rnd, sizeof(rnd)); 746 RAND_seed(rnd, sizeof(rnd));
746 747
747 /* Drop privileges */ 748 /* Drop privileges */
748 do_setusercontext(authctxt->pw); 749 do_setusercontext(authctxt->pw, authctxt->role);
749 750
750 skip: 751 skip:
751 /* It is safe now to apply the key state */ 752 /* It is safe now to apply the key state */
@@ -1631,6 +1632,11 @@ main(int ac, char **av)
1631 sensitive_data.host_keys[i] = NULL; 1632 sensitive_data.host_keys[i] = NULL;
1632 continue; 1633 continue;
1633 } 1634 }
1635 if (auth_key_is_revoked(key, 1)) {
1636 key_free(key);
1637 sensitive_data.host_keys[i] = NULL;
1638 continue;
1639 }
1634 switch (key->type) { 1640 switch (key->type) {
1635 case KEY_RSA1: 1641 case KEY_RSA1:
1636 sensitive_data.ssh1_host_key = key; 1642 sensitive_data.ssh1_host_key = key;