summaryrefslogtreecommitdiff
path: root/source3/winbindd/winbindd_pam.c
diff options
context:
space:
mode:
authorGünther Deschner <gd@samba.org>2008-02-05 17:25:07 +0100
committerGünther Deschner <gd@samba.org>2008-02-06 02:09:44 +0100
commit742fd39b7a9ecfe30b01e323a9ce1c2375c5d076 (patch)
tree627854d969d349f5cd5a8c82aaeabaa88b5473c6 /source3/winbindd/winbindd_pam.c
parent99bff2fc72319764269624d0bfbf2d8f1dbb4ba9 (diff)
downloadsamba-742fd39b7a9ecfe30b01e323a9ce1c2375c5d076.tar.gz
samba-742fd39b7a9ecfe30b01e323a9ce1c2375c5d076.tar.bz2
samba-742fd39b7a9ecfe30b01e323a9ce1c2375c5d076.zip
Use rpccli_samr_QueryDomainInfo() in winbindd.
Guenther (This used to be commit dd9fa33e968d4e641460fe1c6beb05dfe12fa918)
Diffstat (limited to 'source3/winbindd/winbindd_pam.c')
-rw-r--r--source3/winbindd/winbindd_pam.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/source3/winbindd/winbindd_pam.c b/source3/winbindd/winbindd_pam.c
index 9435a328dd..c1a277f9b5 100644
--- a/source3/winbindd/winbindd_pam.c
+++ b/source3/winbindd/winbindd_pam.c
@@ -370,7 +370,7 @@ static NTSTATUS fillup_password_policy(struct winbindd_domain *domain,
{
struct winbindd_methods *methods;
NTSTATUS status = NT_STATUS_UNSUCCESSFUL;
- SAM_UNK_INFO_1 password_policy;
+ struct samr_DomInfo1 password_policy;
if ( !winbindd_can_contact_domain( domain ) ) {
DEBUG(5,("fillup_password_policy: No inbound trust to "
@@ -386,28 +386,28 @@ static NTSTATUS fillup_password_policy(struct winbindd_domain *domain,
}
state->response.data.auth.policy.min_length_password =
- password_policy.min_length_password;
+ password_policy.min_password_length;
state->response.data.auth.policy.password_history =
- password_policy.password_history;
+ password_policy.password_history_length;
state->response.data.auth.policy.password_properties =
password_policy.password_properties;
state->response.data.auth.policy.expire =
- nt_time_to_unix_abs(&(password_policy.expire));
- state->response.data.auth.policy.min_passwordage =
- nt_time_to_unix_abs(&(password_policy.min_passwordage));
+ nt_time_to_unix_abs((NTTIME *)&(password_policy.max_password_age));
+ state->response.data.auth.policy.min_passwordage =
+ nt_time_to_unix_abs((NTTIME *)&(password_policy.min_password_age));
return NT_STATUS_OK;
}
static NTSTATUS get_max_bad_attempts_from_lockout_policy(struct winbindd_domain *domain,
TALLOC_CTX *mem_ctx,
- uint16 *max_allowed_bad_attempts)
+ uint16 *lockout_threshold)
{
struct winbindd_methods *methods;
NTSTATUS status = NT_STATUS_UNSUCCESSFUL;
- SAM_UNK_INFO_12 lockout_policy;
+ struct samr_DomInfo12 lockout_policy;
- *max_allowed_bad_attempts = 0;
+ *lockout_threshold = 0;
methods = domain->methods;
@@ -416,7 +416,7 @@ static NTSTATUS get_max_bad_attempts_from_lockout_policy(struct winbindd_domain
return status;
}
- *max_allowed_bad_attempts = lockout_policy.bad_attempt_lockout;
+ *lockout_threshold = lockout_policy.lockout_threshold;
return NT_STATUS_OK;
}
@@ -427,7 +427,7 @@ static NTSTATUS get_pwd_properties(struct winbindd_domain *domain,
{
struct winbindd_methods *methods;
NTSTATUS status = NT_STATUS_UNSUCCESSFUL;
- SAM_UNK_INFO_1 password_policy;
+ struct samr_DomInfo1 password_policy;
*password_properties = 0;