CVE-2019-3880 s3: rpc: winreg: Remove implementations of SaveKey/RestoreKey.
authorJeremy Allison <jra@samba.org>
Thu, 21 Mar 2019 21:51:30 +0000 (14:51 -0700)
committerKarolin Seeger <kseeger@samba.org>
Fri, 5 Apr 2019 07:48:18 +0000 (09:48 +0200)
commitd53121af8028bb39c1d61e0f5c26ae1d30ab6351
treeb1a5cd393689d1758d0fc1f8e8db5cd999855d57
parentc92ac5ada094a2f3f10f15b65d6ba5c771261acd
CVE-2019-3880 s3: rpc: winreg: Remove implementations of SaveKey/RestoreKey.

The were not using VFS backend calls and could only work
locally, and were unsafe against symlink races and other
security issues.

If the incoming handle is valid, return WERR_BAD_PATHNAME.

[MS-RRP] states "The format of the file name is implementation-specific"
so ensure we don't allow this.

As reported by Michael Hanselmann.

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

Signed-off-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
source3/rpc_server/winreg/srv_winreg_nt.c