From 9292e5b74310632e1f0b4b2b76a9ef4ccae6874e Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Fri, 1 Feb 2013 13:14:05 +0100 Subject: s3: use generate_random_password() instead of generate_random_str() Signed-off-by: Stefan Metzmacher Reviewed-by: Michael Adam --- source3/libads/util.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'source3/libads') diff --git a/source3/libads/util.c b/source3/libads/util.c index 6a6b42afc4..2e22bca02e 100644 --- a/source3/libads/util.c +++ b/source3/libads/util.c @@ -35,8 +35,10 @@ ADS_STATUS ads_change_trust_account_password(ADS_STRUCT *ads, char *host_princip return ADS_ERROR_SYSTEM(ENOENT); } - new_password = generate_random_str(talloc_tos(), DEFAULT_TRUST_ACCOUNT_PASSWORD_LENGTH); - + new_password = generate_random_password(talloc_tos(), + DEFAULT_TRUST_ACCOUNT_PASSWORD_LENGTH, + DEFAULT_TRUST_ACCOUNT_PASSWORD_LENGTH); + ret = kerberos_set_password(ads->auth.kdc_server, host_principal, password, host_principal, new_password, ads->auth.time_offset); if (!ADS_ERR_OK(ret)) { -- cgit