diff --git a/funcs/func_curl.c b/funcs/func_curl.c index b4b98206c4..ba14e3f7f3 100644 --- a/funcs/func_curl.c +++ b/funcs/func_curl.c @@ -173,6 +173,46 @@ Whether to verify the server certificate against a list of known root certificate authorities (boolean). + + Whether to verify the host in the server's TLS certificate. + Set to 2 to verify the host, 0 to ignore the host. + + + Path to a file holding one or more certificates to verify + the peer's certificate with. Only used when ssl_verifypeer + is enabled. + + + Path to a directory holding multiple CA certificates to + verify the peer's certificate with. Only used when ssl_verifypeer + is enabled. + + + Path to a file containing a client certificate. Default format + is PEM, and can be changed with ssl_certtype. + + + The format of the ssl_cert file. + + + + + + + Path to a file containing a client private key. Default format + is PEM, and can be changed with ssl_keytype + + + The format of the ssl_key file. + + + + + + + + The passphrase to use the ssl_key file. + Assuming the responses will be in key1=value1&key2=value2 format, reformat the response such that it can be used @@ -320,6 +360,30 @@ static int parse_curlopt_key(const char *name, CURLoption *key, enum optiontype } else if (!strcasecmp(name, "ssl_verifypeer")) { *key = CURLOPT_SSL_VERIFYPEER; *ot = OT_BOOLEAN; + } else if (!strcasecmp(name, "ssl_verifyhost")) { + *key = CURLOPT_SSL_VERIFYHOST; + *ot = OT_INTEGER; + } else if (!strcasecmp(name, "ssl_cainfo")) { + *key = CURLOPT_CAINFO; + *ot = OT_STRING; + } else if (!strcasecmp(name, "ssl_capath")) { + *key = CURLOPT_CAPATH; + *ot = OT_STRING; + } else if (!strcasecmp(name, "ssl_cert")) { + *key = CURLOPT_SSLCERT; + *ot = OT_STRING; + } else if (!strcasecmp(name, "ssl_certtype")) { + *key = CURLOPT_SSLCERTTYPE; + *ot = OT_STRING; + } else if (!strcasecmp(name, "ssl_key")) { + *key = CURLOPT_SSLKEY; + *ot = OT_STRING; + } else if (!strcasecmp(name, "ssl_keytype")) { + *key = CURLOPT_SSLKEYTYPE; + *ot = OT_STRING; + } else if (!strcasecmp(name, "ssl_keypasswd")) { + *key = CURLOPT_KEYPASSWD; + *ot = OT_STRING; } else if (!strcasecmp(name, "hashcompat")) { *key = CURLOPT_SPECIAL_HASHCOMPAT; *ot = OT_ENUM;