CVE-2023-34967: mdssvc: add type checking to dalloc_value_for_key()
authorRalph Boehme <slow@samba.org>
Fri, 26 May 2023 13:06:38 +0000 (15:06 +0200)
committerJule Anger <janger@samba.org>
Fri, 14 Jul 2023 13:16:26 +0000 (15:16 +0200)
commit5b4353cc60b75610f0aa12b1cced36d35a4d04d4
treed2ca992bdd1a57dbf9f7eee863a323e18897ba84
parent92d014bc44b32478aa597f38bf11687f1fc95ff1
CVE-2023-34967: mdssvc: add type checking to dalloc_value_for_key()

Change the dalloc_value_for_key() function to require an additional final
argument which denotes the expected type of the value associated with a key. If
the types don't match, return NULL.

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

Signed-off-by: Ralph Boehme <slow@samba.org>
source3/rpc_server/mdssvc/dalloc.c
source3/rpc_server/mdssvc/mdssvc.c