From nobody Mon Nov 11 02:39:59 2024 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Xmv0H5RLhz5cf4K; Mon, 11 Nov 2024 02:39:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R10" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Xmv0H4W0yz465K; Mon, 11 Nov 2024 02:39:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1731292799; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=myNij7saG7FCjfmU17k1X3LJNrPU8ZNlRQoKN1BnEfI=; b=qPdVCMt9f8pzpERMnzVDB0ou7EZ9DRASwda9qJwLD4zaRgqFzcitlpjn26Qit2LZfY+Org Kp/7Bdnrnbk5lzv8TFCUDsiy3Bx6L8zEhycBtnQ2viUsue68U53mnom72yhVFjE0kXv5A4 FaMo8arU5Wcf22QBULVY+iBxh6gLnZnSVe+2Uxp5Hm9Xfck/lNu7FqZ/q5xEECbMo1hlDa 4ZeiGG2EOkzuWR9Yd6MqGpcIZN1oL5wb9kFfTmEchWDDMvhvBxM52GyH3L3AhGIhSSgE+f V1TR6Zf1S5tiz1Bh8dUVxNV8HAjMyYYjBgZB/nmHM2zVZ5mHJ1sl5OVXuneq4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1731292799; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=myNij7saG7FCjfmU17k1X3LJNrPU8ZNlRQoKN1BnEfI=; b=xhqvUxzPdqUQV2YMif/6CmaR3Wsz02eUxSYl96BA7gdJH/F2cfNFycBw04CoeAWSm6UcdP aVBAghQlyyLX5nHfUAJZ6CeS0xEImKG7FU2XJKOvXYigNJTRjS2XUWevMWOHWlLjM177Pl GV8kMejAl3qtWXmWXsjyN8275CeNsPw56qQgsLbzMJn02K5b/uAK0TDjdgrliwSFwCm34o k938mESXOd+DA9sXmzy3F2kh21nQHGwIhhkrXLVo6Ai8Ho8OOkVNG4Fmfn7c1T1tVaP+7X 5W1A8P0c5seHoStcbzONeSw63jDt0dyhQz7uNsu/4erMUO5Bdt09GFzL0HHyOg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1731292799; a=rsa-sha256; cv=none; b=qQ9XlyGAHVU+3KVd3QsQIQWoj4d+mvtda56Ene7RaSPT+VZcBxldDY6GCrsZQKAqkvTCVx sdnfPt1THc3mrzaSmB3bdMxgHMv5dKBtLyNEHGhSxSsTVtlOR2ULBsOvnHNrmauIgZ9mOX rO1oDHDakclA3qCtxPgoS3Y47WcRheBzbOF0MrUcx5aHTrMHmstsOZ1uSz6IBDcmoBPwt8 Euul+7PZ+M5svHdafg4Em+Zm8p87L3nKMfLLMwKIZ6LF5Mr19YMyxFvaIRi0OAKagThmLS UYjVEsGhQvZQmaXf10T59l1liSD5Pdhr4jlQX4d4B4TdMAT7u8v9xw+3uQmaNg== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Xmv0H2lqsz17Cw; Mon, 11 Nov 2024 02:39:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 4AB2dx35007883; Mon, 11 Nov 2024 02:39:59 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 4AB2dxS5007880; Mon, 11 Nov 2024 02:39:59 GMT (envelope-from git) Date: Mon, 11 Nov 2024 02:39:59 GMT Message-Id: <202411110239.4AB2dxS5007880@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Bryan Drewery Subject: git: 96dd1bc15cbb - main - security/openssh-portable: Include ssh[d]_config.d/*.conf List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-ports-main@freebsd.org Sender: owner-dev-commits-ports-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bdrewery X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 96dd1bc15cbb8e743f761b19aaa8e88558c8d924 Auto-Submitted: auto-generated The branch main has been updated by bdrewery: URL: https://cgit.FreeBSD.org/ports/commit/?id=96dd1bc15cbb8e743f761b19aaa8e88558c8d924 commit 96dd1bc15cbb8e743f761b19aaa8e88558c8d924 Author: Bryan Drewery AuthorDate: 2024-11-09 20:26:36 +0000 Commit: Bryan Drewery CommitDate: 2024-11-11 02:39:32 +0000 security/openssh-portable: Include ssh[d]_config.d/*.conf --- security/openssh-portable/Makefile | 4 +++- security/openssh-portable/files/patch-ssh_config | 11 +++++++++++ security/openssh-portable/files/patch-sshd_config | 15 +++++++-------- security/openssh-portable/files/patch-sshd_config.5 | 8 +++++--- security/openssh-portable/pkg-plist | 2 ++ 5 files changed, 28 insertions(+), 12 deletions(-) diff --git a/security/openssh-portable/Makefile b/security/openssh-portable/Makefile index 69edba17e8cc..676c1b750027 100644 --- a/security/openssh-portable/Makefile +++ b/security/openssh-portable/Makefile @@ -1,6 +1,6 @@ PORTNAME= openssh DISTVERSION= 9.9p1 -PORTREVISION= 0 +PORTREVISION= 1 PORTEPOCH= 1 CATEGORIES= security MASTER_SITES= OPENBSD/OpenSSH/portable @@ -223,6 +223,8 @@ post-install: ${STAGEDIR}${ETCDIR}/ssh_config.sample ${MV} ${STAGEDIR}${ETCDIR}/sshd_config \ ${STAGEDIR}${ETCDIR}/sshd_config.sample + ${MKDIR} ${STAGEDIR}${ETCDIR}/ssh_config.d \ + ${STAGEDIR}${ETCDIR}/sshd_config.d .if ${PORT_OPTIONS:MHPN} || ${PORT_OPTIONS:MNONECIPHER} ${MKDIR} ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/HPN-README ${STAGEDIR}${DOCSDIR} diff --git a/security/openssh-portable/files/patch-ssh_config b/security/openssh-portable/files/patch-ssh_config new file mode 100644 index 000000000000..ea5fafad4d30 --- /dev/null +++ b/security/openssh-portable/files/patch-ssh_config @@ -0,0 +1,11 @@ +--- ssh_config.orig 2024-09-19 15:20:48.000000000 -0700 ++++ ssh_config 2024-11-09 12:23:47.263548000 -0800 +@@ -17,6 +17,8 @@ + # list of available options, their meanings and defaults, please see the + # ssh_config(5) man page. + ++Include ssh_config.d/*.conf ++ + # Host * + # ForwardAgent no + # ForwardX11 no diff --git a/security/openssh-portable/files/patch-sshd_config b/security/openssh-portable/files/patch-sshd_config index c19496486f4f..7b6bc14977c7 100644 --- a/security/openssh-portable/files/patch-sshd_config +++ b/security/openssh-portable/files/patch-sshd_config @@ -1,19 +1,18 @@ -!!! -!!! Note files/extra-patch-pam-sshd_config contains more changes for default PAM option. -!!! ---- sshd_config.orig 2022-02-11 18:49:55.062881000 +0000 -+++ sshd_config 2022-02-11 18:52:31.639435000 +0000 -@@ -10,6 +10,9 @@ +--- sshd_config.orig 2024-11-09 12:22:03.414050000 -0800 ++++ sshd_config 2024-11-09 12:25:59.964286000 -0800 +@@ -10,6 +10,11 @@ # possible, but leave them commented. Uncommented options override the # default value. +# Note that some of FreeBSD's defaults differ from OpenBSD's, and +# FreeBSD has a few additional options. ++ ++Include sshd_config.d/*.conf + #Port 22 #AddressFamily any #ListenAddress 0.0.0.0 -@@ -37,8 +40,7 @@ +@@ -37,8 +42,7 @@ #PubkeyAuthentication yes # The default is to check both .ssh/authorized_keys and .ssh/authorized_keys2 @@ -23,7 +22,7 @@ #AuthorizedPrincipalsFile none -@@ -84,7 +86,7 @@ +@@ -84,7 +88,7 @@ AuthorizedKeysFile .ssh/authorized_keys #AllowAgentForwarding yes #AllowTcpForwarding yes #GatewayPorts no diff --git a/security/openssh-portable/files/patch-sshd_config.5 b/security/openssh-portable/files/patch-sshd_config.5 index 15d3ff7bf9d8..f5297c2a42c2 100644 --- a/security/openssh-portable/files/patch-sshd_config.5 +++ b/security/openssh-portable/files/patch-sshd_config.5 @@ -11,7 +11,7 @@ with successful public key client host authentication is allowed (host-based authentication). The default is -@@ -1416,6 +1434,13 @@ +@@ -1416,6 +1434,15 @@ .Cm ethernet . The default is .Cm no . @@ -21,11 +21,13 @@ +.Cm yes , +the root user may be allowed in with its password even if +.Cm PermitRootLogin is set to ++.Cm prohibit-password ++or +.Cm without-password . .Pp Independent of this setting, the permissions of the selected .Xr tun 4 -@@ -1774,12 +1799,19 @@ +@@ -1774,12 +1801,19 @@ .Xr sshd 8 as a non-root user. The default is @@ -46,7 +48,7 @@ .It Cm X11DisplayOffset Specifies the first display number available for .Xr sshd 8 Ns 's -@@ -1793,7 +1825,7 @@ +@@ -1793,7 +1827,7 @@ or .Cm no . The default is diff --git a/security/openssh-portable/pkg-plist b/security/openssh-portable/pkg-plist index 276fd4a7590d..09c4267cc7ca 100644 --- a/security/openssh-portable/pkg-plist +++ b/security/openssh-portable/pkg-plist @@ -8,6 +8,8 @@ bin/ssh-keyscan @sample %%ETCDIR%%/moduli.sample @sample %%ETCDIR%%/ssh_config.sample @sample %%ETCDIR%%/sshd_config.sample +@dir %%ETCDIR%%/ssh_config.d +@dir %%ETCDIR%%/sshd_config.d @postexec if [ -f %D/%%ETCDIR%%/ssh_host_ecdsa_key ] && grep -q DSA %D/%%ETCDIR%%/ssh_host_ecdsa_key; then echo; echo "\!/ Warning \!/"; echo; echo "Your %D/%%ETCDIR%%/ssh_host_ecdsa_key is not a valid ECDSA key. It is incorrectly"; echo "a DSA key due to a bug fixed in 2012 in the security/openssh-portable port."; echo; echo "Regenerate a proper one with: rm -f %D/%%ETCDIR%%/ssh_host_ecdsa_key*; service openssh restart"; echo; echo "Clients should not see any key change warning since the ECDSA was not valid and was not actually"; echo "used by the server."; echo; echo "\!/ Warning \!/"; fi sbin/sshd libexec/sftp-server