Skip to content

Commit

Permalink
CVE-2021-20251 auth4: Return only the result message and free the sur…
Browse files Browse the repository at this point in the history
…rounding result

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

Signed-off-by: Andrew Bartlett <[email protected]>
Reviewed-by: Joseph Sutton <[email protected]>
Reviewed-by: Andreas Schneider <[email protected]>
  • Loading branch information
GaryWL authored and abartlet committed Sep 12, 2022
1 parent 4a9e0fd commit b954acf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
1 change: 0 additions & 1 deletion selftest/knownfail.d/auth-sam
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
^samba.unittests.auth.sam.test_reread_account_not_locked.none
^samba.unittests.auth.sam.test_success_accounting_add_control_failed.none
^samba.unittests.auth.sam.test_success_accounting_build_mod_req_failed.none
^samba.unittests.auth.sam.test_success_accounting_commit_failed.none
Expand Down
3 changes: 2 additions & 1 deletion source4/auth/sam.c
Original file line number Diff line number Diff line change
Expand Up @@ -885,7 +885,8 @@ NTSTATUS authsam_reread_user_logon_data(
TALLOC_FREE(res);
return NT_STATUS_ACCOUNT_LOCKED_OUT;
}
*current = res->msgs[0];
*current = talloc_steal(mem_ctx, res->msgs[0]);
TALLOC_FREE(res);
return NT_STATUS_OK;
}

Expand Down

0 comments on commit b954acf

Please sign in to comment.