CVE-2019-3824 ldb: wildcard_match check tree operation
authorGary Lockyer <gary@catalyst.net.nz>
Mon, 18 Feb 2019 21:26:25 +0000 (10:26 +1300)
committerStefan Metzmacher <metze@samba.org>
Tue, 26 Feb 2019 06:50:16 +0000 (07:50 +0100)
commit73187de71382e48c7eba595aad2fa69dca020a7d
treea5501741f8519522c50010ded56290118de62566
parent754bc1a76e91c265fc1cd69264d013ea60d25392
CVE-2019-3824 ldb: wildcard_match check tree operation

Check the operation type of the passed parse tree, and return
LDB_INAPPROPRIATE_MATCH if the operation is not LDB_OP_SUBSTRING.

A query of "attribute=*" gets parsed as LDB_OP_PRESENT, checking the
operation and failing ldb_wildcard_match should help prevent confusion
writing tests.

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

Signed-off-by: Gary Lockyer <gary@catalyst.net.nz>
lib/ldb/common/ldb_match.c