diff options
author | Steve Holme <steve_holme@hotmail.com> | 2019-04-17 23:47:51 +0100 |
---|---|---|
committer | Steve Holme <steve_holme@hotmail.com> | 2019-05-22 22:55:05 +0100 |
commit | a14d72ca2fec5d4eb5a043936e4f7ce08015c177 (patch) | |
tree | ad856028203028c20e1ba9c30bb3b74d64a7f41c /lib/setopt.c | |
parent | 081d374f4949b7fabfa76a0fb14daa02d47b5050 (diff) |
sasl: Implement SASL authorisation identity via CURLOPT_SASL_AUTHZID
Added the ability for the calling program to specify the authorisation
identity (authzid), the identity to act as, in addition to the
authentication identity (authcid) and password when using SASL PLAIN
authentication.
Fixed #3653
Closes #3790
Diffstat (limited to 'lib/setopt.c')
-rw-r--r-- | lib/setopt.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/setopt.c b/lib/setopt.c index 92cd5b271..ff68788e5 100644 --- a/lib/setopt.c +++ b/lib/setopt.c @@ -2400,6 +2400,12 @@ static CURLcode vsetopt(struct Curl_easy *data, CURLoption option, break; #endif + case CURLOPT_SASL_AUTHZID: + /* Authorisation identity (identity to act as) */ + result = Curl_setstropt(&data->set.str[STRING_SASL_AUTHZID], + va_arg(param, char *)); + break; + case CURLOPT_SASL_IR: /* Enable/disable SASL initial response */ data->set.sasl_ir = (0 != va_arg(param, long)) ? TRUE : FALSE; |