diff options
author | Andrew Bartlett <abartlet@samba.org> | 2009-04-14 12:43:34 +1000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2009-04-14 12:54:12 +1000 |
commit | 97af7f1ed14bcd00b7606ba6e0379589064cd233 (patch) | |
tree | a5ab5fb8d4f2dbd54af13e54d859b8c43772d216 | |
parent | 3b3e21bd9ba701a97e752205263a7903619541c7 (diff) | |
download | samba-97af7f1ed14bcd00b7606ba6e0379589064cd233.tar.gz samba-97af7f1ed14bcd00b7606ba6e0379589064cd233.tar.bz2 samba-97af7f1ed14bcd00b7606ba6e0379589064cd233.zip |
Add some harmless use of talloc_tos() in ntlm_auth
-rw-r--r-- | source3/utils/ntlm_auth.c | 4 | ||||
-rw-r--r-- | source3/utils/ntlm_auth_diagnostics.c | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/source3/utils/ntlm_auth.c b/source3/utils/ntlm_auth.c index 7899bd0d07..e8bd9fbd2b 100644 --- a/source3/utils/ntlm_auth.c +++ b/source3/utils/ntlm_auth.c @@ -2275,7 +2275,7 @@ static bool check_auth_crap(void) if (request_lm_key && (memcmp(zeros, lm_key, sizeof(lm_key)) != 0)) { - hex_lm_key = hex_encode_talloc(NULL, (const unsigned char *)lm_key, + hex_lm_key = hex_encode_talloc(talloc_tos(), (const unsigned char *)lm_key, sizeof(lm_key)); x_fprintf(x_stdout, "LM_KEY: %s\n", hex_lm_key); TALLOC_FREE(hex_lm_key); @@ -2283,7 +2283,7 @@ static bool check_auth_crap(void) if (request_user_session_key && (memcmp(zeros, user_session_key, sizeof(user_session_key)) != 0)) { - hex_user_session_key = hex_encode_talloc(NULL, (const unsigned char *)user_session_key, + hex_user_session_key = hex_encode_talloc(talloc_tos(), (const unsigned char *)user_session_key, sizeof(user_session_key)); x_fprintf(x_stdout, "NT_KEY: %s\n", hex_user_session_key); TALLOC_FREE(hex_user_session_key); diff --git a/source3/utils/ntlm_auth_diagnostics.c b/source3/utils/ntlm_auth_diagnostics.c index 17801b2a80..cea4b084f7 100644 --- a/source3/utils/ntlm_auth_diagnostics.c +++ b/source3/utils/ntlm_auth_diagnostics.c @@ -458,7 +458,7 @@ static bool test_plaintext(enum ntlm_break break_which) flags |= WBFLAG_PAM_LMKEY; flags |= WBFLAG_PAM_USER_SESSION_KEY; - if (!push_ucs2_talloc(NULL, &nt_response_ucs2, opt_password, + if (!push_ucs2_talloc(talloc_tos(), &nt_response_ucs2, opt_password, &converted_size)) { DEBUG(0, ("push_ucs2_talloc failed!\n")); @@ -468,12 +468,12 @@ static bool test_plaintext(enum ntlm_break break_which) nt_response.data = (unsigned char *)nt_response_ucs2; nt_response.length = strlen_w(nt_response_ucs2)*sizeof(smb_ucs2_t); - if ((password = strupper_talloc(NULL, opt_password)) == NULL) { + if ((password = strupper_talloc(talloc_tos(), opt_password)) == NULL) { DEBUG(0, ("strupper_talloc() failed!\n")); exit(1); } - if (!convert_string_talloc(NULL, CH_UNIX, + if (!convert_string_talloc(talloc_tos(), CH_UNIX, CH_DOS, password, strlen(password)+1, &lm_response.data, |