1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-03 01:18:10 +03:00
samba-mirror/lib
Joseph Sutton 9447c4e81e CVE-2023-0614 ldb: Prevent disclosure of confidential attributes
Add a hook, acl_redact_msg_for_filter(), in the aclread module, that
marks inaccessible any message elements used by an LDAP search filter
that the user has no right to access. Make the various ldb_match_*()
functions check whether message elements are accessible, and refuse to
match any that are not. Remaining message elements, not mentioned in the
search filter, are checked in aclread_callback(), and any inaccessible
elements are removed at this point.

Certain attributes, namely objectClass, distinguishedName, name, and
objectGUID, are always present, and hence the presence of said
attributes is always allowed to be checked in a search filter. This
corresponds with the behaviour of Windows.

Further, we unconditionally allow the attributes isDeleted and
isRecycled in a check for presence or equality. Windows is not known to
make this special exception, but it seems mostly harmless, and should
mitigate the performance impact on searches made by the show_deleted
module.

As a result of all these changes, our behaviour regarding confidential
attributes happens to match Windows more closely. For the test in
confidential_attr.py, we can now model our attribute handling with
DC_MODE_RETURN_ALL, which corresponds to the behaviour exhibited by
Windows.

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

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>

Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz>
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

[abartlet@samba.org adapted due to Samba 4.17 and lower
 not having the patches for CVE-2020-25720 and 4.16 and lower
 not having the patches for CVE-2022-32743 ]
2023-03-20 10:03:38 +01:00
..
addns build: Consolidate --with-dnsupdate with --with-ads (which implied HAVE_KRB5) 2021-03-26 04:06:41 +00:00
afs s3:param: make "servicename" a substituted option 2019-11-27 10:25:37 +00:00
async_req lib: Use FIONREAD in wait_for_read_send/recv 2021-03-16 17:09:31 +00:00
audit_logging audit_logging.c: fix compilation on macOS 2021-10-13 01:42:35 +00:00
cmdline cmdline_s4: re-initialise logging once loadparm is ready 2022-06-18 08:47:17 +00:00
compression lzxpress: avoid technically undefined shift 2020-08-31 22:31:13 +00:00
crypto CVE-2021-20251 lib:crypto: Add md4_hash_blob() for hashing data with MD4 2022-09-18 16:46:09 +00:00
dbwrap lib/dbwrap: reset deleted record to tdb_null 2021-11-04 19:49:47 +00:00
fuzzing s3:rpc_server: Activate samba-dcerpcd 2021-12-10 14:02:30 +00:00
krb5_wrap CVE-2022-37966 lib/krb5_wrap: no longer reference des encryption types 2022-12-14 10:28:16 +00:00
ldb CVE-2023-0614 ldb: Prevent disclosure of confidential attributes 2023-03-20 10:03:38 +01:00
ldb-samba CVE-2023-0614 ldb: Prevent disclosure of confidential attributes 2023-03-20 10:03:38 +01:00
messaging messaging: Fix receiving file descriptors 2021-03-19 08:18:26 +00:00
mscat lib;smbd: Fix the -Os build by initializing variables 2021-08-06 17:22:30 +00:00
param CVE-2022-37966 param: Add support for new option "kdc supported enctypes" 2022-12-14 10:28:17 +00:00
printer_driver printing: Align integer types 2021-04-01 19:32:36 +00:00
pthreadpool build: Do not build selftest binaries for builds without --enable-selftest 2019-11-22 11:48:59 +00:00
replace lib/replace - add extra check to bsd_attr_list 2023-01-23 10:59:28 +00:00
smbconf waf: add library dependency for sendfile on Solaris 2019-02-17 13:33:15 +01:00
socket lib/socket: autodetect RSS using ETHTOOL_GRXRINGS 2020-05-07 14:44:40 +00:00
talloc nsswitch: reduce dependecies to private libraries and link static/builtin if possible 2021-11-30 15:53:34 +00:00
tdb tdb: version 1.4.6 2022-01-24 11:21:32 +00:00
tdb_wrap lib: Open tdb files with O_CLOEXEC 2021-06-04 16:47:34 +00:00
tdr lib: Fix 1354521 Unchecked return value 2016-03-01 21:49:44 +01:00
tevent Fix Python docstrings 2021-09-04 00:55:32 +00:00
texpect texpect: don't ignore unknown options 2021-09-10 15:10:30 +00:00
torture lib/torture: fix subunit names of nested suites 2020-07-07 10:30:40 +00:00
tsocket lib/tsocket: avoid endless cpu-spinning in tstream_bsd_fde_handler() 2022-10-31 14:30:09 +00:00
util lib:util: Check memset_s() error code in talloc_keep_secret_destructor() 2022-09-18 16:46:09 +00:00
README various: Remove references to about to be deleted thirdparty/dnspython 2018-12-11 20:07:18 +01:00
wscript_build Remove 'external' python module support code - use the third_party directory instead. 2015-03-06 04:41:48 +01:00

compression - Various compression algorithms (MSZIP, lzxpress)
popt - Command-line option parsing library
replace - Provides replacements for standard (POSIX, C99) functions 
          not provided by the host platform.
subunit - Utilities and bindings for working with the Subunit test result 
          reporting protocol.
talloc - Hierarchical pool based memory allocator 
tdb - Simple but fast key/value database library, supporting multiple writers
torture - Simple unit testing helper library