Skip to content

Commit

Permalink
s3:winbindd: Improve logic so it is easier to understand
Browse files Browse the repository at this point in the history
BUG: https://bugzilla.samba.org/show_bug.cgi?id=13209

Signed-off-by: Andreas Schneider <[email protected]>
Reviewed-by: Ralph Boehme <[email protected]>
  • Loading branch information
cryptomilk committed Jan 15, 2018
1 parent 0d62579 commit 264249d
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions source3/winbindd/winbindd_pam.c
Original file line number Diff line number Diff line change
Expand Up @@ -1683,22 +1683,24 @@ static NTSTATUS winbindd_dual_pam_auth_samlogon(
true, /* interactive */
&authoritative,
&info3);
if (NT_STATUS_IS_OK(result)) {
result = map_info3_to_validation(mem_ctx,
info3,
&validation_level,
&validation);
TALLOC_FREE(info3);
if (!NT_STATUS_IS_OK(result)) {
goto done;
}
}

/*
* We need to try the remote NETLOGON server if this is
* not authoritative (for example on the RODC).
*/
if (authoritative != 0) {
if (NT_STATUS_IS_OK(result)) {
result = map_info3_to_validation(
mem_ctx,
info3,
&validation_level,
&validation);
TALLOC_FREE(info3);
if (!NT_STATUS_IS_OK(result)) {
goto done;
}
}

goto done;
}
}
Expand Down

0 comments on commit 264249d

Please sign in to comment.