1CURLOPT_TLSAUTH_PASSWORD(3)curl_easy_setopt optionsCURLOPT_TLSAUTH_PASSWORD(3)
2
3
4

NAME

6       CURLOPT_TLSAUTH_PASSWORD - password to use for TLS authentication
7

SYNOPSIS

9       #include <curl/curl.h>
10
11       CURLcode curl_easy_setopt(CURL *handle, CURLOPT_TLSAUTH_PASSWORD, char *pwd);
12

DESCRIPTION

14       Pass  a  char * as parameter, which should point to the null-terminated
15       password to use for the TLS authentication method  specified  with  the
16       CURLOPT_TLSAUTH_TYPE(3) option. Requires that the CURLOPT_TLSAUTH_USER‐
17       NAME(3) option also be set.
18
19       The application does not have to keep the string around  after  setting
20       this option.
21
22       This feature relies in TLS SRP which does not work with TLS 1.3.
23

DEFAULT

25       NULL
26

PROTOCOLS

28       All TLS-based protocols
29

EXAMPLE

31       CURL *curl = curl_easy_init();
32       if(curl) {
33         curl_easy_setopt(curl, CURLOPT_URL, "https://example.com/");
34         curl_easy_setopt(curl, CURLOPT_TLSAUTH_TYPE, "SRP");
35         curl_easy_setopt(curl, CURLOPT_TLSAUTH_USERNAME, "user");
36         curl_easy_setopt(curl, CURLOPT_TLSAUTH_PASSWORD, "secret");
37         ret = curl_easy_perform(curl);
38         curl_easy_cleanup(curl);
39       }
40

AVAILABILITY

42       Added in 7.21.4, with the OpenSSL and GnuTLS backends only
43

RETURN VALUE

45       Returns  CURLE_OK  if  the option is supported, CURLE_UNKNOWN_OPTION if
46       not, or CURLE_OUT_OF_MEMORY if there was insufficient heap space.
47

SEE ALSO

49       CURLOPT_TLSAUTH_TYPE(3), CURLOPT_TLSAUTH_USERNAME(3),
50
51
52
53libcurl 7.85.0                   May 17, 2022      CURLOPT_TLSAUTH_PASSWORD(3)
Impressum