mirror of
https://github.com/samba-team/samba.git
synced 2025-01-08 21:18:16 +03:00
CVE-2020-25722 s4/dsdb/samldb: samldb_get_single_valued_attr() check all values
using dsdb_get_expected_new_values(). BUG: https://bugzilla.samba.org/show_bug.cgi?id=14876 Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
14d3ce2557
commit
74b549b951
@ -174,11 +174,19 @@ static int samldb_get_single_valued_attr(struct ldb_context *ldb,
|
||||
* attribute.
|
||||
*/
|
||||
struct ldb_message_element *el = NULL;
|
||||
int ret;
|
||||
|
||||
*value = NULL;
|
||||
|
||||
el = dsdb_get_single_valued_attr(ac->msg, attr,
|
||||
ac->req->operation);
|
||||
ret = dsdb_get_expected_new_values(ac,
|
||||
ac->msg,
|
||||
attr,
|
||||
&el,
|
||||
ac->req->operation);
|
||||
|
||||
if (ret != LDB_SUCCESS) {
|
||||
return ret;
|
||||
}
|
||||
if (el == NULL) {
|
||||
/* we are not affected */
|
||||
return LDB_SUCCESS;
|
||||
|
Loading…
Reference in New Issue
Block a user