mirror of
https://github.com/curl/curl.git
synced 2026-08-25 15:13:41 +03:00
TLS: add CURLOPT_SSL_SIGNATURE_ALGORITHMS and --sigalgs
Fixes #12982 Closes #16964
This commit is contained in:
parent
f9daa75a3b
commit
a638828c88
23 changed files with 194 additions and 11 deletions
|
|
@ -135,6 +135,7 @@ struct OperationConfig {
|
|||
char *etag_compare_file;
|
||||
char *customrequest;
|
||||
char *ssl_ec_curves;
|
||||
char *ssl_signature_algorithms;
|
||||
char *krblevel;
|
||||
char *request_target;
|
||||
char *writeout; /* %-styled format string to output */
|
||||
|
|
|
|||
|
|
@ -305,6 +305,8 @@ static const struct LongShort aliases[]= {
|
|||
{"sessionid", ARG_BOOL|ARG_NO, ' ', C_SESSIONID},
|
||||
{"show-error", ARG_BOOL, 'S', C_SHOW_ERROR},
|
||||
{"show-headers", ARG_BOOL, 'i', C_SHOW_HEADERS},
|
||||
{"sigalgs", ARG_STRG|ARG_TLS, ' ',
|
||||
C_SIGNATURE_ALGORITHMS},
|
||||
{"silent", ARG_BOOL, 's', C_SILENT},
|
||||
{"skip-existing", ARG_BOOL, ' ', C_SKIP_EXISTING},
|
||||
{"socks4", ARG_STRG, ' ', C_SOCKS4},
|
||||
|
|
@ -2692,6 +2694,9 @@ ParameterError getparameter(const char *flag, /* f or -long-flag */
|
|||
case C_CURVES: /* --curves */
|
||||
err = getstr(&config->ssl_ec_curves, nextarg, DENY_BLANK);
|
||||
break;
|
||||
case C_SIGNATURE_ALGORITHMS: /* --sigalgs */
|
||||
err = getstr(&config->ssl_signature_algorithms, nextarg, DENY_BLANK);
|
||||
break;
|
||||
case C_FAIL_EARLY: /* --fail-early */
|
||||
global->fail_early = toggle;
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -242,6 +242,7 @@ typedef enum {
|
|||
C_SHOW_ERROR,
|
||||
C_SHOW_HEADERS,
|
||||
C_SILENT,
|
||||
C_SIGNATURE_ALGORITHMS,
|
||||
C_SKIP_EXISTING,
|
||||
C_SOCKS4,
|
||||
C_SOCKS4A,
|
||||
|
|
|
|||
|
|
@ -659,6 +659,9 @@ const struct helptxt helptext[] = {
|
|||
{"-i, --show-headers",
|
||||
"Show response headers in output",
|
||||
CURLHELP_IMPORTANT | CURLHELP_VERBOSE | CURLHELP_OUTPUT},
|
||||
{" --sigalgs <list>",
|
||||
"TLS signature algorithms to use",
|
||||
CURLHELP_TLS},
|
||||
{"-s, --silent",
|
||||
"Silent mode",
|
||||
CURLHELP_IMPORTANT | CURLHELP_VERBOSE},
|
||||
|
|
|
|||
|
|
@ -1263,6 +1263,10 @@ static CURLcode config2setopts(struct GlobalConfig *global,
|
|||
if(config->ssl_ec_curves)
|
||||
my_setopt_str(curl, CURLOPT_SSL_EC_CURVES, config->ssl_ec_curves);
|
||||
|
||||
if(config->ssl_signature_algorithms)
|
||||
my_setopt_str(curl, CURLOPT_SSL_SIGNATURE_ALGORITHMS,
|
||||
config->ssl_signature_algorithms);
|
||||
|
||||
if(config->writeout)
|
||||
my_setopt_long(curl, CURLOPT_CERTINFO, 1);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue