1CURLOPT_HSTSREADDATA(3)    curl_easy_setopt options    CURLOPT_HSTSREADDATA(3)
2
3
4

NAME

6       CURLOPT_HSTSREADDATA - pointer passed to the HSTS read callback
7

SYNOPSIS

9       #include <curl/curl.h>
10
11       CURLcode   curl_easy_setopt(CURL  *handle,  CURLOPT_HSTSREADDATA,  void
12       *pointer);
13

EXPERIMENTAL

15       Warning: this feature is early code and is marked as  experimental.  It
16       can only be enabled by explicitly telling configure with --enable-hsts.
17       You are advised to not ship this in production before the  experimental
18       label is removed.
19

DESCRIPTION

21       Data  pointer  to  pass  to the HSTS read function. If you use the CUR‐
22       LOPT_HSTSREADFUNCTION(3) option, this is the pointer you'll get as  in‐
23       put in the 3rd argument to the callback.
24
25       This  option  doesn't enable HSTS, you need to use CURLOPT_HSTS_CTRL(3)
26       to do that.
27

DEFAULT

29       NULL
30

PROTOCOLS

32       This feature is only used for HTTP(S) transfer.
33

EXAMPLE

35       CURL *curl = curl_easy_init();
36       struct MyData this;
37       if(curl) {
38         curl_easy_setopt(curl, CURLOPT_URL, "http://example.com");
39
40         /* pass pointer that gets passed in to the
41            CURLOPT_HSTSREADFUNCTION callback */
42         curl_easy_setopt(curl, CURLOPT_HSTSREADDATA, &this);
43
44         curl_easy_perform(curl);
45       }
46

AVAILABILITY

48       Added in 7.74.0
49

RETURN VALUE

51       This will return CURLE_OK.
52

SEE ALSO

54       CURLOPT_HSTSREADFUNCTION(3),       CURLOPT_HSTSWRITEDATA(3),       CUR‐
55       LOPT_HSTSWRITEFUNCTION(3),
56
57
58
59libcurl 7.76.1                 November 04, 2020       CURLOPT_HSTSREADDATA(3)
Impressum