libcli/security: tests for conditional ACE integer base persistence
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>
Wed, 13 Dec 2023 22:56:19 +0000 (11:56 +1300)
committerAndrew Bartlett <abartlet@samba.org>
Thu, 14 Dec 2023 03:31:37 +0000 (03:31 +0000)
Credit to OSS-Fuzz.

REF: https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=62929

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
libcli/security/tests/test_sddl_conditional_ace.c
selftest/knownfail.d/sddl-conditional-ace [new file with mode: 0644]

index 38e852f17b1124847c6ba6dfa3adaf3f7c90ed66..3ea9e23b2b81f02f218b4fe215b7c09d997c9462 100644 (file)
@@ -617,6 +617,14 @@ static void test_round_trips(void **state)
                "( x == SID(BA))",
                "((x) == SID(BA))",
                "(OctetStringType==#1#2#3###))",
+               "(@user.x == 00)",
+               "(@user.x == 01)",
+               "(@user.x == -00)",
+               "(@user.x == -01)",
+               "(@user.x == 0x0)",
+               "(@user.x == 0x1)",
+               "(@user.x == -0x0)",
+               "(@user.x == -0x1)",
        };
        size_t i, length;
        TALLOC_CTX *mem_ctx = talloc_new(NULL);
diff --git a/selftest/knownfail.d/sddl-conditional-ace b/selftest/knownfail.d/sddl-conditional-ace
new file mode 100644 (file)
index 0000000..6d3a861
--- /dev/null
@@ -0,0 +1 @@
+amba.unittests.sddl_conditional_ace.test_round_trips