diff options
author | Jim McDonough <jmcd@samba.org> | 2006-03-15 02:31:11 +0000 |
---|---|---|
committer | Jim McDonough <jmcd@samba.org> | 2006-03-15 02:31:11 +0000 |
commit | 9c41e82b4aa18c3972516ecc288387f5ed08b54b (patch) | |
tree | 3f9129c09480eece599ff09c5d830f477be3a6e5 /source/libmsrpc | |
parent | a48e68b1272a53b031aaf7b9812b4c5b7c1532c7 (diff) | |
download | samba-9c41e82b4aa18c3972516ecc288387f5ed08b54b.tar.gz samba-9c41e82b4aa18c3972516ecc288387f5ed08b54b.tar.xz samba-9c41e82b4aa18c3972516ecc288387f5ed08b54b.zip |
r14408: More on fix for coverity #36. The previous fix would cause us to
marshall a buffer based on an unknown size. Zero out the sec_desc
buffer to prevent this. This is still not getting proper results for
a registry security descriptor (everything gets ACCESS DENIED), but
at least we aren't blowing out memory now...
Diffstat (limited to 'source/libmsrpc')
-rw-r--r-- | source/libmsrpc/cac_winreg.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/libmsrpc/cac_winreg.c b/source/libmsrpc/cac_winreg.c index aa847602cc3..acd83f40760 100644 --- a/source/libmsrpc/cac_winreg.c +++ b/source/libmsrpc/cac_winreg.c @@ -831,6 +831,8 @@ int cac_RegGetKeySecurity(CacServerHandle *hnd, TALLOC_CTX *mem_ctx, struct RegG uint32 buf_size; SEC_DESC_BUF buf; + ZERO_STRUCT(buf); + if(!hnd) return CAC_FAILURE; |