]> git.ipfire.org Git - thirdparty/openssh-portable.git/commitdiff
upstream: test for first-match-wins in authorized_keys environment=
authordjm@openbsd.org <djm@openbsd.org>
Sat, 24 Jul 2021 01:54:23 +0000 (01:54 +0000)
committerDamien Miller <djm@mindrot.org>
Sat, 24 Jul 2021 02:31:05 +0000 (12:31 +1000)
options

OpenBSD-Regress-ID: 1517c90276fe84b5dc5821c59f88877fcc34c0e8

regress/unittests/authopt/tests.c

index 8c51b3802aa6d0789b4a60453577c15ab20fdabc..4e5526a0b44d5675ce38c45a68268f09574e2a2a 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: tests.c,v 1.1 2018/03/03 03:16:17 djm Exp $ */
+/*     $OpenBSD: tests.c,v 1.2 2021/07/24 01:54:23 djm Exp $ */
 
 /*
  * Regress test for keys options functions.
@@ -270,6 +270,8 @@ test_authkeys_parse(void)
        } while (0)
        ARRAY_TEST("environment", "environment=\"foo=1\",environment=\"bar=2\"",
            env, nenv, "foo=1,bar=2");
+       ARRAY_TEST("environment", "environment=\"foo=1\",environment=\"foo=2\"",
+           env, nenv, "foo=1");
        ARRAY_TEST("permitopen", "permitopen=\"foo:123\",permitopen=\"bar:*\"",
            permitopen, npermitopen, "foo:123,bar:*");
 #undef ARRAY_TEST