CVE-2019-3824 ldb: Add tests for ldb_wildcard_match
authorGary Lockyer <gary@catalyst.net.nz>
Mon, 18 Feb 2019 21:24:38 +0000 (10:24 +1300)
committerGary Lockyer <gary@samba.org>
Mon, 25 Feb 2019 20:26:12 +0000 (21:26 +0100)
commit45b75db50f5c1a7c8c38af59a62fccee5401c845
treebc40ed5a10752e5e10226c58e30348556591dede
parent42f0f57eb819ce6b68a8c5b3b53123b83ec917e3
CVE-2019-3824 ldb: Add tests for ldb_wildcard_match

Add cmocka tests for ldb_wildcard_match.

Running test_wildcard_match under valgrind reproduces
 CVE-2019-3824 out of bounds read in wildcard compare (bug 13773)

 valgrind --suppressions=lib/ldb/tests/ldb_match_test.valgrind\
          bin/ldb_match_test

BUG: https://bugzilla.samba.org/show_bug.cgi?id=13773

Signed-off-by: Gary Lockyer <gary@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
lib/ldb/tests/ldb_match_test.c [new file with mode: 0644]
lib/ldb/tests/ldb_match_test.valgrind [new file with mode: 0644]
lib/ldb/wscript