tool_cfgable.h
Go to the documentation of this file.
1 #ifndef HEADER_CURL_TOOL_CFGABLE_H
2 #define HEADER_CURL_TOOL_CFGABLE_H
3 /***************************************************************************
4  * _ _ ____ _
5  * Project ___| | | | _ \| |
6  * / __| | | | |_) | |
7  * | (__| |_| | _ <| |___
8  * \___|\___/|_| \_\_____|
9  *
10  * Copyright (C) 1998 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al.
11  *
12  * This software is licensed as described in the file COPYING, which
13  * you should have received as part of this distribution. The terms
14  * are also available at https://curl.haxx.se/docs/copyright.html.
15  *
16  * You may opt to use, copy, modify, merge, publish, distribute and/or sell
17  * copies of the Software, and permit persons to whom the Software is
18  * furnished to do so, under the terms of the COPYING file.
19  *
20  * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
21  * KIND, either express or implied.
22  *
23  ***************************************************************************/
24 #include "tool_setup.h"
25 
26 #include "tool_sdecls.h"
27 
28 #include "tool_metalink.h"
29 
30 typedef enum {
32  ERR_BINARY_TERMINAL = 1, /* binary to terminal detected */
34 } curl_error;
35 
36 struct GlobalConfig;
37 
39  CURL *easy; /* A copy of the handle from GlobalConfig */
41  char *random_file;
42  char *egd_file;
43  char *useragent;
44  char *cookie; /* single line with specified cookies */
45  char *cookiejar; /* write to this file */
46  char *cookiefile; /* read from this file */
47  bool cookiesession; /* new session? */
48  bool encoding; /* Accept-Encoding please */
49  bool tr_encoding; /* Transfer-Encoding please */
50  unsigned long authtype; /* auth bitmask */
51  bool use_resume;
55  bool ftp_pret;
56  long proto;
62  char *postfields;
64  char *referer;
65  double timeout;
67  long maxredirs;
69  char *headerfile;
70  char *ftpport;
71  char *iface;
72  int localport;
74  unsigned short porttouse;
75  char *range;
78  char *dns_servers; /* dot notation: 1.1.1.1;2.2.2.2 */
79  char *dns_interface; /* interface name */
80  char *dns_ipv4_addr; /* dot notation */
81  char *dns_ipv6_addr; /* dot notation */
82  char *userpwd;
84  char *tls_username;
85  char *tls_password;
86  char *tls_authtype;
90  char *proxyuserpwd;
91  char *proxy;
92  int proxyver; /* set to CURLPROXY_HTTP* define */
93  char *noproxy;
94  char *mail_from;
96  char *mail_auth;
97  bool sasl_ir; /* Enable/disable SASL initial response */
99  bool ftp_append; /* APPE on ftp */
100  bool use_ascii; /* select ascii or text transfer */
101  bool autoreferer; /* automatically set referer */
102  bool failonerror; /* fail on (HTTP) errors */
103  bool include_headers; /* send headers to data output */
104  bool no_body; /* don't get the body */
105  bool dirlistonly; /* only get the FTP dir list */
106  bool followlocation; /* follow http redirects */
107  bool unrestricted_auth; /* Continue to send authentication (user+password)
108  when following ocations, even when hostname
109  changed */
110  bool netrc_opt;
111  bool netrc;
112  char *netrc_file;
113  struct getout *url_list; /* point to the first node */
114  struct getout *url_last; /* point to the last/current node */
115  struct getout *url_get; /* point to the node to fill in URL */
116  struct getout *url_out; /* point to the node to fill in outfile */
117  char *cipher_list;
119  char *cert;
120  char *proxy_cert;
121  char *cert_type;
123  char *cacert;
125  char *capath;
127  char *crlfile;
130  char *key;
131  char *proxy_key;
132  char *key_type;
134  char *key_passwd;
136  char *pubkey;
137  char *hostpubmd5;
138  char *engine;
139  bool crlf;
141  char *krblevel;
144  bool nobuffer;
145  bool readbusy; /* set when reading input returns EAGAIN */
146  bool globoff;
148  bool insecure_ok; /* set TRUE to allow insecure SSL connects */
149  bool proxy_insecure_ok; /* set TRUE to allow insecure SSL connects
150  for proxy */
157  bool proxyntlm;
161  char *writeout; /* %-styled format string to output */
162  struct curl_slist *quote;
170  time_t condtime;
179 
180  /* for bandwidth limiting features: */
181  curl_off_t sendpersecond; /* send to peer */
182  curl_off_t recvpersecond; /* receive from peer */
183 
184  bool ftp_ssl;
189  char *preproxy;
190  int socks5_gssapi_nec; /* The NEC reference server does not protect the
191  encryption type exchange */
192  unsigned long socks5_auth;/* auth bitmask for socks5 proxies */
193  char *proxy_service_name; /* set authentication service name for HTTP and
194  SOCKS5 proxies */
195  char *service_name; /* set authentication service name for DIGEST-MD5,
196  Kerberos 5 and SPNEGO */
197 
200  long req_retry; /* number of retries */
201  bool retry_connrefused; /* set connection refused as a transient error */
202  long retry_delay; /* delay between retries (in seconds) */
203  long retry_maxtime; /* maximum time to keep retrying */
204 
205  char *ftp_account; /* for ACCT */
206  char *ftp_alternative_to_user; /* send command if USER/PASS fails */
208  long tftp_blksize; /* TFTP BLKSIZE option */
209  bool tftp_no_options; /* do not send TFTP options requests */
210  bool ignorecl; /* --ignore-content-length */
212 
213  bool raw;
214  bool post301;
215  bool post302;
216  bool post303;
217  bool nokeepalive; /* for keepalive needs */
218  long alivetime;
219  bool content_disposition; /* use Content-disposition filename */
220 
221  int default_node_flags; /* default flags to search for each 'node', which
222  is basically each given URL to transfer */
223 
224  bool xattr; /* store metadata in extended attributes */
226  bool ssl_allow_beast; /* allow this SSL vulnerability */
227  bool proxy_ssl_allow_beast; /* allow this SSL vulnerability for proxy*/
228 
229  bool ssl_no_revoke; /* disable SSL certificate revocation checks */
230  /*bool proxy_ssl_no_revoke; */
231 
232  bool use_metalink; /* process given URLs as metalink XML file */
233  metalinkfile *metalinkfile_list; /* point to the first node */
234  metalinkfile *metalinkfile_last; /* point to the last/current node */
235 #ifdef CURLDEBUG
236  bool test_event_based;
237 #endif
238  char *oauth_bearer; /* OAuth 2.0 bearer token */
239  bool nonpn; /* enable/disable TLS NPN extension */
240  bool noalpn; /* enable/disable TLS ALPN extension */
241  char *unix_socket_path; /* path to Unix domain socket */
242  bool abstract_unix_socket; /* path to an abstract Unix domain socket */
246  bool suppress_connect_headers; /* suppress proxy CONNECT response headers
247  from user callbacks */
248  curl_error synthetic_error; /* if non-zero, it overrides any libcurl
249  error */
250  bool ssh_compression; /* enable/disable SSH compression */
253  struct OperationConfig *next; /* Always last in the struct */
254 };
255 
256 struct GlobalConfig {
257  CURL *easy; /* Once we have one, we keep it here */
258  int showerror; /* -1 == unset, default => show errors
259  0 => -s is used to NOT show errors
260  1 => -S has been used to show errors */
261  bool mute; /* don't show messages, --silent given */
262  bool noprogress; /* don't show progress bar --silent given */
263  bool isatty; /* Updated internally if output is a tty */
264  FILE *errors; /* Error stream, defaults to stderr */
265  bool errors_fopened; /* Whether error stream isn't stderr */
266  char *trace_dump; /* file to dump the network trace to */
270  bool tracetime; /* include timestamp? */
271  int progressmode; /* CURL_PROGRESS_BAR / CURL_PROGRESS_STATS */
272  char *libcurl; /* Output libcurl code to this file name */
273  bool fail_early; /* exit on first transfer error */
276  struct OperationConfig *last; /* Always last in the struct */
277 };
278 
279 void config_init(struct OperationConfig *config);
280 void config_free(struct OperationConfig *config);
281 
282 #endif /* HEADER_CURL_TOOL_CFGABLE_H */
curl_off_t max_filesize
Definition: tool_cfgable.h:68
curl_off_t postfieldsize
Definition: tool_cfgable.h:63
struct curl_slist * quote
Definition: tool_cfgable.h:162
double expect100timeout
Definition: tool_cfgable.h:245
struct OperationConfig * prev
Definition: tool_cfgable.h:252
metalinkfile * metalinkfile_last
Definition: tool_cfgable.h:234
Definition: ws_ssl.c:25
char * proxyuserpwd
Definition: tool_cfgable.h:90
struct getout * url_last
Definition: tool_cfgable.h:114
struct curl_slist * telnet_options
Definition: tool_cfgable.h:175
unsigned long authtype
Definition: tool_cfgable.h:50
HttpReq
Definition: tool_sdecls.h:134
char * dns_ipv6_addr
Definition: tool_cfgable.h:81
char * proxy_service_name
Definition: tool_cfgable.h:193
struct curl_slist * headers
Definition: tool_cfgable.h:171
struct OperationConfig * last
Definition: tool_cfgable.h:276
struct curl_slist * prequote
Definition: tool_cfgable.h:164
char * customrequest
Definition: tool_cfgable.h:140
bool trace_fopened
Definition: tool_cfgable.h:268
curl_error
Definition: tool_cfgable.h:30
void config_free(struct OperationConfig *config)
Definition: tool_cfgable.c:161
struct curl_slist * connect_to
Definition: tool_cfgable.h:177
struct GlobalConfig * global
Definition: tool_cfgable.h:251
metalinkfile * metalinkfile_list
Definition: tool_cfgable.h:233
char * dns_servers
Definition: tool_cfgable.h:78
char * unix_socket_path
Definition: tool_cfgable.h:241
char * ftp_alternative_to_user
Definition: tool_cfgable.h:206
FILE * trace_stream
Definition: tool_cfgable.h:267
curl_error synthetic_error
Definition: tool_cfgable.h:248
trace
Definition: tool_sdecls.h:122
struct curl_slist * resolve
Definition: tool_cfgable.h:176
struct getout * url_get
Definition: tool_cfgable.h:115
char * proxy_tls_password
Definition: tool_cfgable.h:88
struct OperationConfig * current
Definition: tool_cfgable.h:275
bool abstract_unix_socket
Definition: tool_cfgable.h:242
curl_TimeCond
Definition: curl.h:1955
struct getout * url_out
Definition: tool_cfgable.h:116
char * proxy_crlfile
Definition: tool_cfgable.h:128
unsigned short porttouse
Definition: tool_cfgable.h:74
char * dns_interface
Definition: tool_cfgable.h:79
curl_mime * mimecurrent
Definition: tool_cfgable.h:174
CURL_TYPEOF_CURL_OFF_T curl_off_t
Definition: system.h:420
char * libcurl
Definition: tool_cfgable.h:272
bool content_disposition
Definition: tool_cfgable.h:219
struct OperationConfig * next
Definition: tool_cfgable.h:253
char * login_options
Definition: tool_cfgable.h:83
curl_mime * mimepost
Definition: tool_cfgable.h:173
bool proto_redir_present
Definition: tool_cfgable.h:59
bool proxy_ssl_allow_beast
Definition: tool_cfgable.h:227
struct curl_slist * postquote
Definition: tool_cfgable.h:163
char * tls_authtype
Definition: tool_cfgable.h:86
char * proxy_tls_authtype
Definition: tool_cfgable.h:89
struct getout * url_list
Definition: tool_cfgable.h:113
char * proxy_cert_type
Definition: tool_cfgable.h:122
void config_init(struct OperationConfig *config)
Definition: tool_cfgable.c:29
curl_off_t recvpersecond
Definition: tool_cfgable.h:182
struct curl_slist * proxyheaders
Definition: tool_cfgable.h:172
char * dns_ipv4_addr
Definition: tool_cfgable.h:80
curl_TimeCond timecond
Definition: tool_cfgable.h:169
unsigned long socks5_auth
Definition: tool_cfgable.h:192
char * proxy_key_type
Definition: tool_cfgable.h:133
void CURL
Definition: curl.h:102
char * trace_dump
Definition: tool_cfgable.h:266
curl_off_t resume_from
Definition: tool_cfgable.h:61
char * tls_username
Definition: tool_cfgable.h:84
curl_off_t sendpersecond
Definition: tool_cfgable.h:181
char * proto_default
Definition: tool_cfgable.h:60
char * request_target
Definition: tool_cfgable.h:142
bool resume_from_current
Definition: tool_cfgable.h:52
bool errors_fopened
Definition: tool_cfgable.h:265
char * proxy_cipher_list
Definition: tool_cfgable.h:118
char * proxy_key_passwd
Definition: tool_cfgable.h:135
char * tls_password
Definition: tool_cfgable.h:85
bool suppress_connect_headers
Definition: tool_cfgable.h:246
struct OperationConfig * first
Definition: tool_cfgable.h:274
char * random_file
Definition: tool_cfgable.h:41
double connecttimeout
Definition: tool_cfgable.h:66
char * proxy_tls_username
Definition: tool_cfgable.h:87
struct curl_slist * mail_rcpt
Definition: tool_cfgable.h:95


rc_tagdetect_client
Author(s): Monika Florek-Jasinska , Raphael Schaller
autogenerated on Sat Feb 13 2021 03:42:16