1CURLOPT_DOH_SSL_VERIFYSTATUSc(u3r)l_easy_setopt optiCoUnRsLOPT_DOH_SSL_VERIFYSTATUS(3)
2
3
4

NAME

6       CURLOPT_DOH_SSL_VERIFYSTATUS - verify the DoH SSL certificate's status
7

SYNOPSIS

9       #include <curl/curl.h>
10
11       CURLcode curl_easy_setopt(CURL *handle, CURLOPT_DOH_SSL_VERIFYSTATUS,
12                                 long verify);
13

DESCRIPTION

15       Pass a long as parameter set to 1 to enable or 0 to disable.
16
17       This  option  determines whether libcurl verifies the status of the DoH
18       (DNS-over-HTTPS) server cert using the "Certificate Status Request" TLS
19       extension (aka. OCSP stapling).
20
21       This  option  is  the DoH equivalent of CURLOPT_SSL_VERIFYSTATUS(3) and
22       only affects requests to the DoH server.
23
24       Note that if this option is enabled but the server does not support the
25       TLS extension, the verification will fail.
26

DEFAULT

28       0
29

PROTOCOLS

31       DoH
32

EXAMPLE

34       CURL *curl = curl_easy_init();
35       if(curl) {
36         curl_easy_setopt(curl, CURLOPT_URL, "https://example.com");
37
38         curl_easy_setopt(curl, CURLOPT_DOH_URL, "https://cloudflare-dns.com/dns-query");
39
40         /* Ask for OCSP stapling when verifying the DoH server */
41         curl_easy_setopt(curl, CURLOPT_DOH_SSL_VERIFYSTATUS, 1L);
42
43         curl_easy_perform(curl);
44       }
45

AVAILABILITY

47       Added  in  7.76.0.  This  option  is  currently  only  supported by the
48       OpenSSL, GnuTLS and NSS TLS backends.
49

RETURN VALUE

51       Returns CURLE_OK if OCSP stapling is supported by the SSL backend, oth‐
52       erwise returns CURLE_NOT_BUILT_IN.
53

SEE ALSO

55       CURLOPT_DOH_SSL_VERIFYHOST(3),    CURLOPT_DOH_SSL_VERIFYPEER(3),   CUR‐
56       LOPT_SSL_VERIFYSTATUS(3),
57
58
59
60libcurl 8.0.1                  January 02, 2023CURLOPT_DOH_SSL_VERIFYSTATUS(3)
Impressum