mirror of
https://github.com/curl/curl.git
synced 2026-08-25 16:33:38 +03:00
tool_getparam: add --knownhosts
To allow users to specify a known hosts file that is not the default one: ~/.ssh/known_hosts URL: https://github.com/curl/curl/discussions/18784 Closes #18859
This commit is contained in:
parent
762ce8801b
commit
aae18c4bdc
11 changed files with 48 additions and 14 deletions
|
|
@ -196,6 +196,7 @@ static const struct LongShort aliases[]= {
|
|||
{"keepalive-time", ARG_STRG, ' ', C_KEEPALIVE_TIME},
|
||||
{"key", ARG_FILE, ' ', C_KEY},
|
||||
{"key-type", ARG_STRG|ARG_TLS, ' ', C_KEY_TYPE},
|
||||
{"knownhosts", ARG_FILE, ' ', C_KNOWNHOSTS},
|
||||
{"krb", ARG_STRG|ARG_DEPR, ' ', C_KRB},
|
||||
{"krb4", ARG_STRG|ARG_DEPR, ' ', C_KRB4},
|
||||
{"libcurl", ARG_STRG, ' ', C_LIBCURL},
|
||||
|
|
@ -2224,6 +2225,9 @@ static ParameterError opt_file(struct OperationConfig *config,
|
|||
case C_KEY: /* --key */
|
||||
err = getstr(&config->key, nextarg, DENY_BLANK);
|
||||
break;
|
||||
case C_KNOWNHOSTS: /* --knownhosts */
|
||||
err = getstr(&config->knownhosts, nextarg, DENY_BLANK);
|
||||
break;
|
||||
case C_NETRC_FILE: /* --netrc-file */
|
||||
err = getstr(&config->netrc_file, nextarg, DENY_BLANK);
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue