]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
upstream: add a regress test for configurations > 256KB
authordjm@openbsd.org <djm@openbsd.org>
Fri, 4 Jul 2025 07:52:17 +0000 (07:52 +0000)
committerDamien Miller <djm@mindrot.org>
Fri, 4 Jul 2025 07:53:41 +0000 (17:53 +1000)
mostly by Dmitry Belyavskiy

OpenBSD-Regress-ID: fcedb249e4cf2447e078a839877f99730ee79024

regress/Makefile
regress/connect-bigconf.sh [new file with mode: 0644]

index b8787205a15f3caa09daf09d402d816ad04b4190..ece093a2ba87532ee4727a05e0bbc9730a11fb5a 100644 (file)
@@ -1,4 +1,4 @@
-#      $OpenBSD: Makefile,v 1.139 2025/06/28 13:34:08 dtucker Exp $
+#      $OpenBSD: Makefile,v 1.140 2025/07/04 07:52:17 djm Exp $
 
 tests:         prep file-tests t-exec unit
 
@@ -113,7 +113,8 @@ LTESTS=     connect \
                agent-pkcs11-restrict \
                agent-pkcs11-cert \
                penalty \
-               penalty-expire
+               penalty-expire \
+               connect-bigconf
 
 INTEROP_TESTS= putty-transfer putty-ciphers putty-kex conch-ciphers
 INTEROP_TESTS+=        dropbear-ciphers dropbear-kex dropbear-server
diff --git a/regress/connect-bigconf.sh b/regress/connect-bigconf.sh
new file mode 100644 (file)
index 0000000..56cf0ea
--- /dev/null
@@ -0,0 +1,17 @@
+#       $OpenBSD: connect-bigconf.sh,v 1.1 2025/07/04 07:52:17 djm Exp $
+#       Placed in the Public Domain.
+
+tid="simple connect"
+
+for x in `jot 10000 1` ; do
+       echo "Match group NONEXIST" >> $OBJ/sshd_config
+       echo "ChrootDirectory /some/path/for/group/NONEXIST" >> $OBJ/sshd_config
+done
+#cat $OBJ/sshd_config
+start_sshd
+
+trace "direct connect with large sshd_config"
+${SSH} -F $OBJ/ssh_config somehost true
+if [ $? -ne 0 ]; then
+        fail "ssh direct connect with large sshd_config failed"
+fi