summaryrefslogtreecommitdiff
path: root/lib/curl_sasl.c
diff options
context:
space:
mode:
authorSteve Holme <steve_holme@hotmail.com>2019-04-18 21:54:35 +0100
committerSteve Holme <steve_holme@hotmail.com>2019-04-22 12:29:49 +0100
commiteb84ca3ea8f793ecbedf7865c41a8d1b9f59efb7 (patch)
treebd8b0144d60fb1eb1634591428ff20f1a9824e21 /lib/curl_sasl.c
parentb21701c54ba050145246e89c5137015479c65f7e (diff)
downloadcurl-eb84ca3ea8f793ecbedf7865c41a8d1b9f59efb7.tar.gz
sasl: Don't send authcid as authzid for the PLAIN mechanism as per RFC 4616
RFC 4616 specifies the authzid is optional in the client authentication message and that the server will derive the authorisation identity (authzid) from the authentication identity (authcid) when not specified by the client.
Diffstat (limited to 'lib/curl_sasl.c')
-rw-r--r--lib/curl_sasl.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/curl_sasl.c b/lib/curl_sasl.c
index 94b51e541..c609b1ded 100644
--- a/lib/curl_sasl.c
+++ b/lib/curl_sasl.c
@@ -367,7 +367,7 @@ CURLcode Curl_sasl_start(struct SASL *sasl, struct connectdata *conn,
sasl->authused = SASL_MECH_PLAIN;
if(force_ir || data->set.sasl_ir)
- result = Curl_auth_create_plain_message(data, conn->user, conn->user,
+ result = Curl_auth_create_plain_message(data, NULL, conn->user,
conn->passwd, &resp, &len);
}
else if(enabledmechs & SASL_MECH_LOGIN) {
@@ -450,7 +450,7 @@ CURLcode Curl_sasl_continue(struct SASL *sasl, struct connectdata *conn,
*progress = SASL_DONE;
return result;
case SASL_PLAIN:
- result = Curl_auth_create_plain_message(data, conn->user, conn->user,
+ result = Curl_auth_create_plain_message(data, NULL, conn->user,
conn->passwd, &resp, &len);
break;
case SASL_LOGIN: