-/* $OpenBSD: sshd-auth.c,v 1.2 2024/12/03 22:30:03 jsg Exp $ */
+/* $OpenBSD: sshd-auth.c,v 1.3 2025/01/16 06:37:10 dtucker Exp $ */
/*
* SSH2 implementation:
* Privilege Separation:
exit(1);
}
- debug("sshd version %s, %s", SSH_VERSION, SSH_OPENSSL_VERSION);
-
/* Connection passed by stdin/out */
if (inetd_flag) {
/*
fill_default_server_options(&options);
options.timing_secret = timing_secret; /* XXX eliminate from unpriv */
+ /* Reinit logging in case config set Level, Facility or Verbose. */
+ log_init(__progname, options.log_level, options.log_facility, 1);
+
+ debug("sshd-auth version %s, %s", SSH_VERSION, SSH_OPENSSL_VERSION);
+
/* Store privilege separation user for later use if required. */
privsep_chroot = (getuid() == 0 || geteuid() == 0);
if ((privsep_pw = getpwnam(SSH_PRIVSEP_USER)) == NULL) {
-/* $OpenBSD: sshd-session.c,v 1.9 2024/09/09 02:39:57 djm Exp $ */
+/* $OpenBSD: sshd-session.c,v 1.11 2025/01/16 06:37:10 dtucker Exp $ */
/*
* SSH2 implementation:
* Privilege Separation:
exit(1);
}
- debug("sshd version %s, %s", SSH_VERSION, SSH_OPENSSL_VERSION);
-
if (!rexeced_flag)
fatal("sshd-session should not be executed directly");
SYSLOG_FACILITY_AUTH : options.log_facility,
log_stderr || !inetd_flag || debug_flag);
- debug("sshd version %s, %s", SSH_VERSION, SSH_OPENSSL_VERSION);
-
/* Fetch our configuration */
if ((cfg = sshbuf_new()) == NULL)
fatal("sshbuf_new config buf failed");
fill_default_server_options(&options);
options.timing_secret = timing_secret;
+ /* Reinit logging in case config set Level, Facility or Verbose. */
+ log_init(__progname, options.log_level, options.log_facility,
+ log_stderr || !inetd_flag || debug_flag);
+
+ debug("sshd-session version %s, %s", SSH_VERSION, SSH_OPENSSL_VERSION);
+
/* Store privilege separation user for later use if required. */
privsep_chroot = (getuid() == 0 || geteuid() == 0);
if ((privsep_pw = getpwnam(SSH_PRIVSEP_USER)) == NULL) {