mirror of
https://github.com/curl/curl.git
synced 2026-08-25 02:33:31 +03:00
auth: Rename the various authentication clean up functions
For consistency and to a avoid confusion. Closes #3869
This commit is contained in:
parent
4d8461ae8a
commit
52dfab65d6
18 changed files with 54 additions and 53 deletions
|
|
@ -5,7 +5,7 @@
|
|||
* | (__| |_| | _ <| |___
|
||||
* \___|\___/|_| \_\_____|
|
||||
*
|
||||
* Copyright (C) 2014 - 2017, Steve Holme, <steve_holme@hotmail.com>.
|
||||
* Copyright (C) 2014 - 2019, Steve Holme, <steve_holme@hotmail.com>.
|
||||
* Copyright (C) 2015, Daniel Stenberg, <daniel@haxx.se>, et al.
|
||||
*
|
||||
* This software is licensed as described in the file COPYING, which
|
||||
|
|
@ -372,7 +372,7 @@ CURLcode Curl_auth_create_gssapi_security_message(struct Curl_easy *data,
|
|||
}
|
||||
|
||||
/*
|
||||
* Curl_auth_gssapi_cleanup()
|
||||
* Curl_auth_cleanup_gssapi()
|
||||
*
|
||||
* This is used to clean up the GSSAPI (Kerberos V5) specific data.
|
||||
*
|
||||
|
|
@ -381,7 +381,7 @@ CURLcode Curl_auth_create_gssapi_security_message(struct Curl_easy *data,
|
|||
* krb5 [in/out] - The Kerberos 5 data struct being cleaned up.
|
||||
*
|
||||
*/
|
||||
void Curl_auth_gssapi_cleanup(struct kerberos5data *krb5)
|
||||
void Curl_auth_cleanup_gssapi(struct kerberos5data *krb5)
|
||||
{
|
||||
OM_uint32 minor_status;
|
||||
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@
|
|||
* | (__| |_| | _ <| |___
|
||||
* \___|\___/|_| \_\_____|
|
||||
*
|
||||
* Copyright (C) 2014 - 2017, Steve Holme, <steve_holme@hotmail.com>.
|
||||
* Copyright (C) 2014 - 2019, Steve Holme, <steve_holme@hotmail.com>.
|
||||
*
|
||||
* This software is licensed as described in the file COPYING, which
|
||||
* you should have received as part of this distribution. The terms
|
||||
|
|
@ -474,7 +474,7 @@ CURLcode Curl_auth_create_gssapi_security_message(struct Curl_easy *data,
|
|||
}
|
||||
|
||||
/*
|
||||
* Curl_auth_gssapi_cleanup()
|
||||
* Curl_auth_cleanup_gssapi()
|
||||
*
|
||||
* This is used to clean up the GSSAPI (Kerberos V5) specific data.
|
||||
*
|
||||
|
|
@ -483,7 +483,7 @@ CURLcode Curl_auth_create_gssapi_security_message(struct Curl_easy *data,
|
|||
* krb5 [in/out] - The Kerberos 5 data struct being cleaned up.
|
||||
*
|
||||
*/
|
||||
void Curl_auth_gssapi_cleanup(struct kerberos5data *krb5)
|
||||
void Curl_auth_cleanup_gssapi(struct kerberos5data *krb5)
|
||||
{
|
||||
/* Free our security context */
|
||||
if(krb5->context) {
|
||||
|
|
|
|||
|
|
@ -403,7 +403,7 @@ CURLcode Curl_auth_create_ntlm_type1_message(struct Curl_easy *data,
|
|||
(void)hostname,
|
||||
|
||||
/* Clean up any former leftovers and initialise to defaults */
|
||||
Curl_auth_ntlm_cleanup(ntlm);
|
||||
Curl_auth_cleanup_ntlm(ntlm);
|
||||
|
||||
#if defined(USE_NTRESPONSES) && defined(USE_NTLM2SESSION)
|
||||
#define NTLM2FLAG NTLMFLAG_NEGOTIATE_NTLM2_KEY
|
||||
|
|
@ -844,13 +844,13 @@ CURLcode Curl_auth_create_ntlm_type3_message(struct Curl_easy *data,
|
|||
/* Return with binary blob encoded into base64 */
|
||||
result = Curl_base64_encode(data, (char *)ntlmbuf, size, outptr, outlen);
|
||||
|
||||
Curl_auth_ntlm_cleanup(ntlm);
|
||||
Curl_auth_cleanup_ntlm(ntlm);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
/*
|
||||
* Curl_auth_ntlm_cleanup()
|
||||
* Curl_auth_cleanup_ntlm()
|
||||
*
|
||||
* This is used to clean up the NTLM specific data.
|
||||
*
|
||||
|
|
@ -859,7 +859,7 @@ CURLcode Curl_auth_create_ntlm_type3_message(struct Curl_easy *data,
|
|||
* ntlm [in/out] - The NTLM data struct being cleaned up.
|
||||
*
|
||||
*/
|
||||
void Curl_auth_ntlm_cleanup(struct ntlmdata *ntlm)
|
||||
void Curl_auth_cleanup_ntlm(struct ntlmdata *ntlm)
|
||||
{
|
||||
/* Free the target info */
|
||||
Curl_safefree(ntlm->target_info);
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ CURLcode Curl_auth_create_ntlm_type1_message(struct Curl_easy *data,
|
|||
TimeStamp expiry; /* For Windows 9x compatibility of SSPI calls */
|
||||
|
||||
/* Clean up any former leftovers and initialise to defaults */
|
||||
Curl_auth_ntlm_cleanup(ntlm);
|
||||
Curl_auth_cleanup_ntlm(ntlm);
|
||||
|
||||
/* Query the security package for NTLM */
|
||||
status = s_pSecFn->QuerySecurityPackageInfo((TCHAR *) TEXT(SP_NAME_NTLM),
|
||||
|
|
@ -323,13 +323,13 @@ CURLcode Curl_auth_create_ntlm_type3_message(struct Curl_easy *data,
|
|||
result = Curl_base64_encode(data, (char *) ntlm->output_token,
|
||||
type_3_buf.cbBuffer, outptr, outlen);
|
||||
|
||||
Curl_auth_ntlm_cleanup(ntlm);
|
||||
Curl_auth_cleanup_ntlm(ntlm);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
/*
|
||||
* Curl_auth_ntlm_cleanup()
|
||||
* Curl_auth_cleanup_ntlm()
|
||||
*
|
||||
* This is used to clean up the NTLM specific data.
|
||||
*
|
||||
|
|
@ -338,7 +338,7 @@ CURLcode Curl_auth_create_ntlm_type3_message(struct Curl_easy *data,
|
|||
* ntlm [in/out] - The NTLM data struct being cleaned up.
|
||||
*
|
||||
*/
|
||||
void Curl_auth_ntlm_cleanup(struct ntlmdata *ntlm)
|
||||
void Curl_auth_cleanup_ntlm(struct ntlmdata *ntlm)
|
||||
{
|
||||
/* Free our security context */
|
||||
if(ntlm->context) {
|
||||
|
|
|
|||
|
|
@ -97,7 +97,7 @@ CURLcode Curl_auth_decode_spnego_message(struct Curl_easy *data,
|
|||
/* We finished successfully our part of authentication, but server
|
||||
* rejected it (since we're again here). Exit with an error since we
|
||||
* can't invent anything better */
|
||||
Curl_auth_spnego_cleanup(nego);
|
||||
Curl_auth_cleanup_spnego(nego);
|
||||
return CURLE_LOGIN_DENIED;
|
||||
}
|
||||
|
||||
|
|
@ -238,7 +238,7 @@ CURLcode Curl_auth_create_spnego_message(struct Curl_easy *data,
|
|||
}
|
||||
|
||||
/*
|
||||
* Curl_auth_spnego_cleanup()
|
||||
* Curl_auth_cleanup_spnego()
|
||||
*
|
||||
* This is used to clean up the SPNEGO (Negotiate) specific data.
|
||||
*
|
||||
|
|
@ -247,7 +247,7 @@ CURLcode Curl_auth_create_spnego_message(struct Curl_easy *data,
|
|||
* nego [in/out] - The Negotiate data struct being cleaned up.
|
||||
*
|
||||
*/
|
||||
void Curl_auth_spnego_cleanup(struct negotiatedata *nego)
|
||||
void Curl_auth_cleanup_spnego(struct negotiatedata *nego)
|
||||
{
|
||||
OM_uint32 minor_status;
|
||||
|
||||
|
|
|
|||
|
|
@ -107,7 +107,7 @@ CURLcode Curl_auth_decode_spnego_message(struct Curl_easy *data,
|
|||
/* We finished successfully our part of authentication, but server
|
||||
* rejected it (since we're again here). Exit with an error since we
|
||||
* can't invent anything better */
|
||||
Curl_auth_spnego_cleanup(nego);
|
||||
Curl_auth_cleanup_spnego(nego);
|
||||
return CURLE_LOGIN_DENIED;
|
||||
}
|
||||
|
||||
|
|
@ -307,7 +307,7 @@ CURLcode Curl_auth_create_spnego_message(struct Curl_easy *data,
|
|||
}
|
||||
|
||||
/*
|
||||
* Curl_auth_spnego_cleanup()
|
||||
* Curl_auth_cleanup_spnego()
|
||||
*
|
||||
* This is used to clean up the SPNEGO (Negotiate) specific data.
|
||||
*
|
||||
|
|
@ -316,7 +316,7 @@ CURLcode Curl_auth_create_spnego_message(struct Curl_easy *data,
|
|||
* nego [in/out] - The Negotiate data struct being cleaned up.
|
||||
*
|
||||
*/
|
||||
void Curl_auth_spnego_cleanup(struct negotiatedata *nego)
|
||||
void Curl_auth_cleanup_spnego(struct negotiatedata *nego)
|
||||
{
|
||||
/* Free our security context */
|
||||
if(nego->context) {
|
||||
|
|
|
|||
|
|
@ -142,7 +142,7 @@ CURLcode Curl_auth_create_ntlm_type3_message(struct Curl_easy *data,
|
|||
char **outptr, size_t *outlen);
|
||||
|
||||
/* This is used to clean up the NTLM specific data */
|
||||
void Curl_auth_ntlm_cleanup(struct ntlmdata *ntlm);
|
||||
void Curl_auth_cleanup_ntlm(struct ntlmdata *ntlm);
|
||||
#endif /* USE_NTLM */
|
||||
|
||||
/* This is used to generate a base64 encoded OAuth 2.0 message */
|
||||
|
|
@ -184,7 +184,7 @@ CURLcode Curl_auth_create_gssapi_security_message(struct Curl_easy *data,
|
|||
size_t *outlen);
|
||||
|
||||
/* This is used to clean up the GSSAPI specific data */
|
||||
void Curl_auth_gssapi_cleanup(struct kerberos5data *krb5);
|
||||
void Curl_auth_cleanup_gssapi(struct kerberos5data *krb5);
|
||||
#endif /* USE_KERBEROS5 */
|
||||
|
||||
#if defined(USE_SPNEGO)
|
||||
|
|
@ -208,7 +208,7 @@ CURLcode Curl_auth_create_spnego_message(struct Curl_easy *data,
|
|||
char **outptr, size_t *outlen);
|
||||
|
||||
/* This is used to clean up the SPNEGO specifiec data */
|
||||
void Curl_auth_spnego_cleanup(struct negotiatedata *nego);
|
||||
void Curl_auth_cleanup_spnego(struct negotiatedata *nego);
|
||||
|
||||
#endif /* USE_SPNEGO */
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue