Lines Matching refs:nextarg
483 GetFileAndPassword(char *nextarg, char **file, char **password) in GetFileAndPassword() argument
486 if(nextarg) { in GetFileAndPassword()
487 parse_cert_parameter(nextarg, &certname, &passphrase); in GetFileAndPassword()
569 char *nextarg, in data_urlencode() argument
580 const char *p = strchr(nextarg, '='); in data_urlencode()
587 p = strchr(nextarg, '@'); in data_urlencode()
589 nlen = p - nextarg; /* length of the name part */ in data_urlencode()
596 p = nextarg; in data_urlencode()
644 if(curlx_dyn_addn(&dyn, nextarg, nlen) || in data_urlencode()
810 static ParameterError url_query(char *nextarg, in url_query() argument
820 if(*nextarg == '+') { in url_query()
822 query = strdup(&nextarg[1]); in url_query()
827 err = data_urlencode(global, nextarg, &query, &size); in url_query()
847 char *nextarg, in set_data() argument
857 err = data_urlencode(global, nextarg, &postdata, &size); in set_data()
861 else if('@' == *nextarg && (cmd != C_DATA_RAW)) { in set_data()
864 nextarg++; /* pass the @ */ in set_data()
866 if(!strcmp("-", nextarg)) { in set_data()
872 file = fopen(nextarg, "rb"); in set_data()
874 errorf(global, "Failed to open %s", nextarg); in set_data()
903 err = getstr(&postdata, nextarg, ALLOW_BLANK); in set_data()
928 char *nextarg) in set_rate() argument
939 char *div = strchr(nextarg, '/'); in set_rate()
943 size_t numlen = div ? (size_t)(div - nextarg) : strlen(nextarg); in set_rate()
947 memcpy(number, nextarg, numlen); in set_rate()
1020 const char *nextarg) in parse_url() argument
1048 err = getstr(&url->url, nextarg, DENY_BLANK); in parse_url()
1060 char *nextarg) in parse_localport() argument
1063 char *p = nextarg; in parse_localport()
1079 if(str2unummax(&config->localport, nextarg, 65535)) in parse_localport()
1095 const char *nextarg) in parse_continue_at() argument
1113 if(strcmp(nextarg, "-")) { in parse_continue_at()
1114 err = str2offset(&config->resume_from, nextarg); in parse_continue_at()
1127 const char *nextarg) in parse_ech() argument
1132 else if(strlen(nextarg) > 4 && strncasecompare("pn:", nextarg, 3)) { in parse_ech()
1134 nextarg += 3; in parse_ech()
1135 err = getstr(&config->ech_public, nextarg, DENY_BLANK); in parse_ech()
1137 else if(strlen(nextarg) > 5 && strncasecompare("ecl:", nextarg, 4)) { in parse_ech()
1139 nextarg += 4; in parse_ech()
1140 if('@' != *nextarg) { in parse_ech()
1141 err = getstr(&config->ech_config, nextarg, DENY_BLANK); in parse_ech()
1148 nextarg++; /* skip over '@' */ in parse_ech()
1149 if(!strcmp("-", nextarg)) { in parse_ech()
1153 file = fopen(nextarg, FOPEN_READTEXT); in parse_ech()
1159 nextarg); in parse_ech()
1175 err = getstr(&config->ech, nextarg, DENY_BLANK); in parse_ech()
1183 const char *nextarg) in parse_header() argument
1188 if(nextarg[0] == '@') { in parse_header()
1192 bool use_stdin = !strcmp(&nextarg[1], "-"); in parse_header()
1193 FILE *file = use_stdin ? stdin : fopen(&nextarg[1], FOPEN_READTEXT); in parse_header()
1195 errorf(global, "Failed to open %s", &nextarg[1]); in parse_header()
1221 err = add2list(&config->proxyheaders, nextarg); in parse_header()
1223 err = add2list(&config->headers, nextarg); in parse_header()
1229 const char *nextarg) in parse_output() argument
1258 err = getstr(&url->outfile, nextarg, DENY_BLANK); in parse_output()
1306 const char *nextarg) in parse_quote() argument
1311 switch(nextarg[0]) { in parse_quote()
1314 nextarg++; in parse_quote()
1315 err = add2list(&config->postquote, nextarg); in parse_quote()
1319 nextarg++; in parse_quote()
1320 err = add2list(&config->prequote, nextarg); in parse_quote()
1323 err = add2list(&config->quote, nextarg); in parse_quote()
1331 const char *nextarg) in parse_range() argument
1343 if(ISDIGIT(*nextarg) && !strchr(nextarg, '-')) { in parse_range()
1346 if(curlx_strtoofft(nextarg, NULL, 10, &value)) { in parse_range()
1364 const char *tmp_range = nextarg; in parse_range()
1375 err = getstr(&config->range, nextarg, DENY_BLANK); in parse_range()
1381 const char *nextarg) in parse_upload_file() argument
1409 if(!*nextarg) in parse_upload_file()
1413 err = getstr(&url->infile, nextarg, DENY_BLANK); in parse_upload_file()
1479 const char *nextarg) in parse_writeout() argument
1484 if('@' == *nextarg) { in parse_writeout()
1489 nextarg++; /* pass the @ */ in parse_writeout()
1490 if(!strcmp("-", nextarg)) { in parse_writeout()
1495 fname = nextarg; in parse_writeout()
1512 err = getstr(&config->writeout, nextarg, ALLOW_BLANK); in parse_writeout()
1519 const char *nextarg) in parse_time_cond() argument
1523 switch(*nextarg) { in parse_time_cond()
1525 nextarg++; in parse_time_cond()
1534 nextarg++; in parse_time_cond()
1539 nextarg++; in parse_time_cond()
1542 config->condtime = (curl_off_t)curl_getdate(nextarg, NULL); in parse_time_cond()
1546 int rc = getfiletime(nextarg, global, &value); in parse_time_cond()
1563 char *nextarg, /* NULL if unset */ in getparameter() argument
1626 else if(expand && nextarg) { in getparameter()
1636 err = varexpand(global, nextarg, &nbuf, &replaced); in getparameter()
1642 nextarg = curlx_dyn_ptr(&nbuf); in getparameter()
1667 nextarg = (char *)&parse[1]; /* this is the actual extra parameter */ in getparameter()
1670 else if(!nextarg) { in getparameter()
1682 (nextarg[0] == '-') && nextarg[1]) { in getparameter()
1685 nextarg); in getparameter()
1687 else if(!strncmp("\xe2\x80\x9c", nextarg, 3)) { in getparameter()
1690 nextarg); in getparameter()
1698 if(!nextarg) in getparameter()
1703 nextarg = (char *)""; in getparameter()
1717 err = getstr(&config->dns_ipv4_addr, nextarg, DENY_BLANK); in getparameter()
1724 err = getstr(&config->dns_ipv6_addr, nextarg, DENY_BLANK); in getparameter()
1727 err = getstr(&config->oauth_bearer, nextarg, DENY_BLANK); in getparameter()
1734 err = secs2ms(&config->connecttimeout_ms, nextarg); in getparameter()
1737 err = getstr(&config->doh_url, nextarg, ALLOW_BLANK); in getparameter()
1743 err = getstr(&config->cipher_list, nextarg, DENY_BLANK); in getparameter()
1750 err = getstr(&config->dns_interface, nextarg, DENY_BLANK); in getparameter()
1766 err = getstr(&config->dns_servers, nextarg, DENY_BLANK); in getparameter()
1769 err = getstr(&global->trace_dump, nextarg, DENY_BLANK); in getparameter()
1780 err = getstr(&global->trace_dump, nextarg, DENY_BLANK); in getparameter()
1792 err = GetSizeParameter(global, nextarg, "rate", &value); in getparameter()
1799 err = set_rate(global, nextarg); in getparameter()
1855 err = oct2nummax(&config->create_file_mode, nextarg, 0777); in getparameter()
1860 err = str2num(&config->maxredirs, nextarg); in getparameter()
1866 err = getstr(&config->ipfs_gateway, nextarg, DENY_BLANK); in getparameter()
1881 err = getstr(&config->aws_sigv4, nextarg, DENY_BLANK); in getparameter()
1884 tool_set_stderr_file(global, nextarg); in getparameter()
1888 err = getstr(&config->iface, nextarg, DENY_BLANK); in getparameter()
1895 err = getstr(&config->krblevel, nextarg, DENY_BLANK); in getparameter()
1901 err = getstr(&config->haproxy_clientip, nextarg, DENY_BLANK); in getparameter()
1904 err = GetSizeParameter(global, nextarg, "max-filesize", &value); in getparameter()
1918 err = parse_url(global, config, nextarg); in getparameter()
1938 err = getstr(&config->proxy, nextarg, DENY_BLANK); in getparameter()
1942 err = getstr(&config->proxy, nextarg, DENY_BLANK); in getparameter()
1946 err = getstr(&config->proxy, nextarg, DENY_BLANK); in getparameter()
1950 err = getstr(&config->proxy, nextarg, DENY_BLANK); in getparameter()
1959 find.name = nextarg; in getparameter()
1966 err = str2unummax(&config->ip_tos, nextarg, 0xFF); in getparameter()
1970 err = str2unummax(&config->vlan_priority, nextarg, 7); in getparameter()
1979 err = str2unum(&config->req_retry, nextarg); in getparameter()
1985 err = str2unummax(&config->retry_delay, nextarg, LONG_MAX/1000); in getparameter()
1988 err = str2unummax(&config->retry_maxtime, nextarg, LONG_MAX/1000); in getparameter()
2005 err = getstr(&config->ftp_account, nextarg, DENY_BLANK); in getparameter()
2020 config->ftp_filemethod = ftpfilemethod(config, nextarg); in getparameter()
2023 err = parse_localport(config, nextarg); in getparameter()
2026 err = getstr(&config->ftp_alternative_to_user, nextarg, DENY_BLANK); in getparameter()
2052 config->ftp_ssl_ccc_mode = ftpcccmethod(config, nextarg); in getparameter()
2060 err = getstr(&global->libcurl, nextarg, DENY_BLANK); in getparameter()
2070 err = str2unum(&config->alivetime, nextarg); in getparameter()
2073 err = str2unum(&config->alivecnt, nextarg); in getparameter()
2086 err = getstr(&config->noproxy, nextarg, ALLOW_BLANK); in getparameter()
2093 err = getstr(&config->proxy, nextarg, DENY_BLANK); in getparameter()
2097 err = str2unum(&config->tftp_blksize, nextarg); in getparameter()
2100 err = getstr(&config->mail_from, nextarg, DENY_BLANK); in getparameter()
2104 err = add2list(&config->mail_rcpt, nextarg); in getparameter()
2111 err = proto2num(config, built_in_protos, &config->proto_str, nextarg); in getparameter()
2116 nextarg)) in getparameter()
2120 err = add2list(&config->resolve, nextarg); in getparameter()
2123 config->gssapi_delegation = delegation(config, nextarg); in getparameter()
2126 err = getstr(&config->mail_auth, nextarg, DENY_BLANK); in getparameter()
2133 err = getstr(&config->sasl_authzid, nextarg, DENY_BLANK); in getparameter()
2148 err = getstr(&config->unix_socket_path, nextarg, DENY_BLANK); in getparameter()
2154 err = getstr(&config->proxy_service_name, nextarg, DENY_BLANK); in getparameter()
2157 err = getstr(&config->service_name, nextarg, DENY_BLANK); in getparameter()
2160 err = getstr(&config->proto_default, nextarg, DENY_BLANK); in getparameter()
2165 err = secs2ms(&config->expect100timeout_ms, nextarg); in getparameter()
2171 err = add2list(&config->connect_to, nextarg); in getparameter()
2175 err = getstr(&config->unix_socket_path, nextarg, DENY_BLANK); in getparameter()
2182 err = str2tls_max(&config->ssl_version_max, nextarg); in getparameter()
2191 err = str2unum(&config->happy_eyeballs_timeout_ms, nextarg); in getparameter()
2198 if(set_trace_config(global, nextarg)) in getparameter()
2208 err = setvariable(global, nextarg); in getparameter()
2273 err = getstr(&config->cipher13_list, nextarg, DENY_BLANK); in getparameter()
2276 err = getstr(&config->proxy_cipher13_list, nextarg, DENY_BLANK); in getparameter()
2295 err = getstr(&config->useragent, nextarg, ALLOW_BLANK); in getparameter()
2301 err = getstr(&config->altsvc, nextarg, ALLOW_BLANK); in getparameter()
2307 err = getstr(&config->hsts, nextarg, ALLOW_BLANK); in getparameter()
2310 if(strchr(nextarg, '=')) { in getparameter()
2312 err = add2list(&config->cookies, nextarg); in getparameter()
2317 err = add2list(&config->cookiefiles, nextarg); in getparameter()
2324 err = getstr(&config->cookiejar, nextarg, DENY_BLANK); in getparameter()
2327 err = parse_continue_at(global, config, nextarg); in getparameter()
2335 err = set_data(cmd, nextarg, global, config); in getparameter()
2338 err = url_query(nextarg, global, config); in getparameter()
2344 err = getstr(&config->headerfile, nextarg, DENY_BLANK); in getparameter()
2347 char *ptr = strstr(nextarg, ";auto"); in getparameter()
2356 ptr = *nextarg ? nextarg : NULL; in getparameter()
2362 GetFileAndPassword(nextarg, &config->cert, &config->key_passwd); in getparameter()
2365 err = getstr(&config->cacert, nextarg, DENY_BLANK); in getparameter()
2374 err = getstr(&config->cert_type, nextarg, DENY_BLANK); in getparameter()
2377 err = getstr(&config->key, nextarg, DENY_BLANK); in getparameter()
2380 err = getstr(&config->key_type, nextarg, DENY_BLANK); in getparameter()
2383 err = getstr(&config->key_passwd, nextarg, DENY_BLANK); in getparameter()
2387 err = getstr(&config->engine, nextarg, DENY_BLANK); in getparameter()
2394 err = parse_ech(global, config, nextarg); in getparameter()
2397 err = getstr(&config->capath, nextarg, DENY_BLANK); in getparameter()
2400 err = getstr(&config->pubkey, nextarg, DENY_BLANK); in getparameter()
2403 err = getstr(&config->hostpubmd5, nextarg, DENY_BLANK); in getparameter()
2410 err = getstr(&config->hostpubsha256, nextarg, DENY_BLANK); in getparameter()
2413 err = getstr(&config->crlfile, nextarg, DENY_BLANK); in getparameter()
2419 err = getstr(&config->tls_username, nextarg, DENY_BLANK); in getparameter()
2426 err = getstr(&config->tls_password, nextarg, ALLOW_BLANK); in getparameter()
2433 err = getstr(&config->tls_authtype, nextarg, DENY_BLANK); in getparameter()
2451 err = getstr(&config->pinnedpubkey, nextarg, DENY_BLANK); in getparameter()
2454 err = getstr(&config->proxy_pinnedpubkey, nextarg, DENY_BLANK); in getparameter()
2481 err = getstr(&config->proxy_tls_username, nextarg, ALLOW_BLANK); in getparameter()
2488 err = getstr(&config->proxy_tls_password, nextarg, DENY_BLANK); in getparameter()
2494 err = getstr(&config->proxy_tls_authtype, nextarg, DENY_BLANK); in getparameter()
2501 GetFileAndPassword(nextarg, &config->proxy_cert, in getparameter()
2505 err = getstr(&config->proxy_cert_type, nextarg, DENY_BLANK); in getparameter()
2508 err = getstr(&config->proxy_key, nextarg, ALLOW_BLANK); in getparameter()
2511 err = getstr(&config->proxy_key_type, nextarg, DENY_BLANK); in getparameter()
2514 err = getstr(&config->proxy_key_passwd, nextarg, ALLOW_BLANK); in getparameter()
2518 err = getstr(&config->proxy_cipher_list, nextarg, DENY_BLANK); in getparameter()
2521 err = getstr(&config->proxy_crlfile, nextarg, DENY_BLANK); in getparameter()
2528 err = getstr(&config->login_options, nextarg, ALLOW_BLANK); in getparameter()
2531 err = getstr(&config->proxy_cacert, nextarg, DENY_BLANK); in getparameter()
2534 err = getstr(&config->proxy_capath, nextarg, DENY_BLANK); in getparameter()
2561 err = getstr(&config->etag_save_file, nextarg, DENY_BLANK); in getparameter()
2569 err = getstr(&config->etag_compare_file, nextarg, DENY_BLANK); in getparameter()
2572 err = getstr(&config->ssl_ec_curves, nextarg, DENY_BLANK); in getparameter()
2612 nextarg, in getparameter()
2627 err = getstr(&config->request_target, nextarg, DENY_BLANK); in getparameter()
2631 if(*nextarg) { in getparameter()
2632 global->help_category = strdup(nextarg); in getparameter()
2644 err = parse_header(global, config, cmd, nextarg); in getparameter()
2671 if(parseconfig(nextarg, global)) { in getparameter()
2672 errorf(global, "cannot read config from '%s'", nextarg); in getparameter()
2689 err = secs2ms(&config->timeout_ms, nextarg); in getparameter()
2704 err = getstr(&config->netrc_file, nextarg, DENY_BLANK); in getparameter()
2720 err = getstr(&config->output_dir, nextarg, DENY_BLANK); in getparameter()
2731 err = parse_output(config, nextarg); in getparameter()
2742 err = getstr(&config->ftpport, nextarg, DENY_BLANK); in getparameter()
2754 err = parse_quote(config, nextarg); in getparameter()
2757 err = parse_range(global, config, nextarg); in getparameter()
2774 err = add2list(&config->telnet_options, nextarg); in getparameter()
2777 err = parse_upload_file(config, nextarg); in getparameter()
2781 err = getstr(&config->userpwd, nextarg, ALLOW_BLANK); in getparameter()
2786 err = getstr(&config->proxyuserpwd, nextarg, ALLOW_BLANK); in getparameter()
2797 err = parse_writeout(global, config, nextarg); in getparameter()
2800 err = getstr(&config->preproxy, nextarg, DENY_BLANK); in getparameter()
2804 err = getstr(&config->proxy, nextarg, ALLOW_BLANK); in getparameter()
2810 err = getstr(&config->customrequest, nextarg, DENY_BLANK); in getparameter()
2814 err = str2unum(&config->low_speed_time, nextarg); in getparameter()
2820 err = str2unum(&config->low_speed_limit, nextarg); in getparameter()
2829 err = str2unum(&val, nextarg); in getparameter()
2844 err = parse_time_cond(global, config, nextarg); in getparameter()
2859 free(nextarg); in getparameter()
2885 char *nextarg = NULL; in parse_args() local
2887 nextarg = curlx_convert_tchar_to_UTF8(argv[i + 1]); in parse_args()
2888 if(!nextarg) { in parse_args()
2894 result = getparameter(orig_opt, nextarg, argv[i + 1], &passarg, in parse_args()
2897 curlx_unicodefree(nextarg); in parse_args()