summaryrefslogtreecommitdiff
path: root/src/tool_getparam.c
Commit message (Collapse)AuthorAgeFilesLines
* Revert all SASL authzid (new feature) commitsJay Satiro2019-05-251-5/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Revert all commits related to the SASL authzid feature since the next release will be a patch release, 7.65.1. Prior to this change CURLOPT_SASL_AUTHZID / --sasl-authzid was destined for the next release, assuming it would be a feature release 7.66.0. However instead the next release will be a patch release, 7.65.1 and will not contain any new features. After the patch release after the reverted commits can be restored by using cherry-pick: git cherry-pick a14d72c a9499ff 8c1cc36 c2a8d52 0edf690 Details for all reverted commits: Revert "os400: take care of CURLOPT_SASL_AUTHZID in curl_easy_setopt_ccsid()." This reverts commit 0edf6907ae37e2020722e6f61229d8ec64095b0a. Revert "tests: Fix the line endings for the SASL alt-auth tests" This reverts commit c2a8d52a1356a722ff9f4aeb983cd4eaf80ef221. Revert "examples: Added SASL PLAIN authorisation identity (authzid) examples" This reverts commit 8c1cc369d0c7163c6dcc91fd38edfea1f509ae75. Revert "curl: --sasl-authzid added to support CURLOPT_SASL_AUTHZID from the tool" This reverts commit a9499ff136d89987af885e2d7dff0a066a3e5817. Revert "sasl: Implement SASL authorisation identity via CURLOPT_SASL_AUTHZID" This reverts commit a14d72ca2fec5d4eb5a043936e4f7ce08015c177.
* curl: --sasl-authzid added to support CURLOPT_SASL_AUTHZID from the toolSteve Holme2019-05-221-1/+5
|
* curl: report error for "--no-" on non-boolean optionsDaniel Stenberg2019-05-201-0/+5
| | | | | | Reported-by: Olen Andoni Fixes #3906 Closes #3907
* alt-svc: the curl command line bitsDaniel Stenberg2019-03-031-9/+16
|
* cli tool: fix mime post with --disable-libcurl-option configure optionPatrick Monnerat2019-02-191-2/+2
| | | | | | Reported-by: Marcel Raad Fixes #3576 Closes #3583
* http: added options for allowing HTTP/0.9 responsesDaniel Stenberg2018-12-211-0/+5
| | | | | | | | | | | | Added CURLOPT_HTTP09_ALLOWED and --http0.9 for this purpose. For now, both the tool and library allow HTTP/0.9 by default. docs/DEPRECATE.md lays out the plan for when to reverse that default: 6 months after the 7.64.0 release. The options are added already now so that applications/scripts can start using them already now. Fixes #2873 Closes #3383
* curl: fix memory leak reading --writeout from fileDaniel Stenberg2018-11-301-0/+1
| | | | | | | | | If another string had been set first, the writout function for reading the syntax from file would leak the previously allocated memory. Reported-by: Brian Carpenter Fixes #3322 Closes #3330
* snprintf: renamed and we now only use msnprintf()Daniel Stenberg2018-11-231-2/+2
| | | | | | | | | | | The function does not return the same value as snprintf() normally does, so readers may be mislead into thinking the code works differently than it actually does. A different function name makes this easier to detect. Reported-by: Tomas Hoger Assisted-by: Daniel Gustafsson Fixes #3296 Closes #3297
* curl: --local-port range was not "including"Daniel Stenberg2018-11-091-1/+1
| | | | | | | | | The end port number in a given range was not included in the range used, as it is documented to be. Reported-by: infinnovation-dev on github Fixes #3251 Closes #3255
* curl: --local-port fix followupDaniel Stenberg2018-11-081-1/+1
| | | | | | | | Regression by 52db54869e6. Reported-by: infinnovation-dev on github Fixes #3248 Closes #3249
* curl: fix --local-port integer overflowDaniel Stenberg2018-11-071-9/+22
| | | | | | | | | | The tool's local port command line range parser didn't check for integer overflows and could pass "weird" data to libcurl for this option. libcurl however, has a strict range check for the values so it rejects anything outside of the accepted range. Reported-by: Brian Carpenter Closes #3242
* tool_getparam: fix some commentsMichael Kaufmann2018-11-031-13/+5
|
* curl: --doh-url addedDaniel Stenberg2018-09-061-0/+4
|
* curl-compilers: enable -Wimplicit-fallthrough=4 for GCCMarcel Raad2018-08-211-1/+1
| | | | | | | | This enables level 4 instead of the default level 3, which of the currently used comments only allows /* FALLTHROUGH */ to silence the warning. Closes https://github.com/curl/curl/pull/2747
* curl: warn the user if a given file name looks like an optionDaniel Stenberg2018-08-151-23/+31
| | | | | | | | | | ... simply because this is usually a sign of the user having omitted the file name and the next option is instead "eaten" by the parser as a file name. Add test1268 to verify Closes #2885
* ssl: set engine implicitly when a PKCS#11 URI is providedAnderson Toshiyuki Sasaki2018-08-081-1/+1
| | | | | | | | | | | This allows the use of PKCS#11 URI for certificates and keys without setting the corresponding type as "ENG" and the engine as "pkcs11" explicitly. If a PKCS#11 URI is provided for certificate, key, proxy_certificate or proxy_key, the corresponding type is set as "ENG" if not provided and the engine is set to "pkcs11" if not provided. Acked-by: Nikos Mavrogiannopoulos Closes #2333
* curl: Fix segfault when -H @headerfile is emptyTobias Blomberg2018-07-281-1/+1
| | | | | | | The curl binary would crash if the -H command line option was given a filename to read using the @filename syntax but that file was empty. Closes #2797
* cppcheck: fix warningsMarian Klymov2018-06-111-4/+2
| | | | | | | | | | | | | - Get rid of variable that was generating false positive warning (unitialized) - Fix issues in tests - Reduce scope of several variables all over etc Closes #2631
* option: disallow username in URLBjörn Stenberg2018-05-311-0/+4
| | | | | | | Adds CURLOPT_DISALLOW_USERNAME_IN_URL and --disallow-username-in-url. Makes libcurl reject URLs with a username in them. Closes #2340
* setopt: add TLS 1.3 ciphersuitesDaniel Stenberg2018-05-291-0/+8
| | | | | | | | | | Adds CURLOPT_TLS13_CIPHERS and CURLOPT_PROXY_TLS13_CIPHERS. curl: added --tls13-ciphers and --proxy-tls13-ciphers Fixes #2435 Reported-by: zzq1015 on github Closes #2607
* httpauth: add support for Bearer tokensLinus Lewandowski2018-05-241-0/+1
| | | | Closes #2102
* curl: added --styled-outputDaniel Stenberg2018-05-211-2/+5
| | | | | | | It is enabled by default, so --no-styled-output will switch off the detection/use of bold headers. Closes #2538
* curl: show headers in boldDaniel Stenberg2018-05-211-7/+5
| | | | | | | | | | | | | | | | | | The feature is only enabled if the output is believed to be a tty. -J: There's some minor differences and improvements in -J handling, as now J should work with -i and it actually creates a file first using the initial name and then *renames* that to the one found in Content-Disposition (if any). -i: only shows headers for HTTP transfers now (as documented). Previously it would also show for pieces of the transfer that were HTTP (for example when doing FTP over a HTTP proxy). -i: now shows trailers as well. Previously they were not shown at all. --libcurl: the CURLOPT_HEADER is no longer set, as the header output is now done in the header callback.
* CURLOPT_HAPROXYPROTOCOL: support the HAProxy PROXY protocolLawrence Matthews2018-03-171-0/+4
| | | | | | Add --haproxy-protocol for the command line tool Closes #2162
* curl tool: accept --compressed also if Brotli is enabled and zlib is not.Patrick Monnerat2018-03-081-2/+3
|
* url: Add option CURLOPT_HAPPY_EYEBALLS_TIMEOUTAnders Bakken2018-02-201-0/+7
| | | | | | | | | | | | | | - Add new option CURLOPT_HAPPY_EYEBALLS_TIMEOUT to set libcurl's happy eyeball timeout value. - Add new optval macro CURL_HET_DEFAULT to represent the default happy eyeballs timeout value (currently 200 ms). - Add new tool option --happy-eyeballs-timeout-ms to expose CURLOPT_HAPPY_EYEBALLS_TIMEOUT. The -ms suffix is used because the other -timeout options in the tool expect seconds not milliseconds. Closes https://github.com/curl/curl/pull/2260
* time-cond: fix reading the file modification time on WindowsMichael Kaufmann2018-02-051-8/+9
| | | | | | | | On Windows, stat() may adjust the unix file time by a daylight saving time offset. Avoid this by calling GetFileTime() instead. Fixes #2164 Closes #2204
* curl: add --proxy-pinnedpubkeyDaniel Stenberg2018-01-301-0/+5
| | | | | | | To verify a proxy's public key. For when using HTTPS proxies. Fixes #2192 Closes #2268
* tool_getparam: Support size modifiers for --max-filesizeGisle Vanem2017-12-261-35/+64
| | | | | | | | | | | | | - Move the size modifier detection code from limit-rate to its own function so that it can also be used with max-filesize. Size modifiers are the suffixes such as G (gigabyte), M (megabyte) etc. For example --max-filesize 1G Ref: https://curl.haxx.se/mail/archive-2017-12/0000.html Closes https://github.com/curl/curl/pull/2179
* curl: speed up handling of many URLsDaniel Stenberg2017-11-041-10/+10
| | | | | | | | | | | | | | By properly keeping track of the last entry in the list of URLs/uploads to handle, curl now avoids many meaningless traverses of the list which speeds up many-URL handling *MASSIVELY* (several magnitudes on 100K URLs). Added test 1291, to verify that it doesn't take ages - but we don't have any detection of "too slow" command in the test suite. Reported-by: arainchik on github Fixes #1959 Closes #2052
* code style: use spaces around plusesDaniel Stenberg2017-09-111-5/+5
|
* code style: use spaces around equals signsDaniel Stenberg2017-09-111-4/+4
|
* mime: use in curl cli tool instead of form API.Patrick Monnerat2017-09-021-3/+3
| | | | | | Extended -F option syntax to support multipart mail messages. -F keyword headers= added to include custom headers in parts. Documentation upgraded.
* ssh: add the ability to enable compression (for SCP/SFTP)Viktor Szakats2017-08-171-0/+4
| | | | | | | | | | | | | | | | | | The required low-level logic was already available as part of `libssh2` (via `LIBSSH2_FLAG_COMPRESS` `libssh2_session_flag()`[1] option.) This patch adds the new `libcurl` option `CURLOPT_SSH_COMPRESSION` (boolean) and the new `curl` command-line option `--compressed-ssh` to request this `libssh2` feature. To have compression enabled, it is required that the SSH server supports a (zlib) compatible compression method and that `libssh2` was built with `zlib` support enabled. [1] https://www.libssh2.org/libssh2_session_flag.html Ref: https://github.com/curl/curl/issues/1732 Closes https://github.com/curl/curl/pull/1735
* strtoofft: reduce integer overflow risks globallyDaniel Stenberg2017-08-141-2/+9
| | | | | | | ... make sure we bail out on overflows. Reported-by: Brian Carpenter Closes #1758
* curl: detect and bail out early on parameter integer overflowsDaniel Stenberg2017-08-071-3/+4
| | | | | | | | | Make the number parser aware of the maximum limit curl accepts for a value and return an error immediately if larger, instead of running an integer overflow later. Fixes #1730 Closes #1736
* getparameter: avoid returning uninitialized 'usedarg'Daniel Stenberg2017-08-051-1/+1
| | | | Fixes #1728
* tool_getparam: fix potentially uninitialized errJay Satiro2017-07-091-1/+2
|
* curl --socks5-{basic,gssapi}: control socks5 authKamil Dudka2017-06-281-0/+18
| | | | Closes https://github.com/curl/curl/pull/1454
* tool_getparam: fix memory leak on test 1147 OOM (torture tests)Jay Satiro2017-06-261-1/+3
| | | | | Bug: https://github.com/curl/curl/pull/1486#issuecomment-310926872 Reported-by: Dan Fandrich
* --request-target: instead of --strip-path-slashDaniel Stenberg2017-06-211-3/+3
| | | | | | | | | | | | | | ... and CURLOPT_REQUEST_TARGET instead of CURLOPT_STRIP_PATH_SLASH. This option instead provides the full "alternative" target to use in the request, instead of extracting the path from the URL. Test 1298 and 1299 updated accordingly. Idea-by: Evert Pot Suggestion: https://daniel.haxx.se/blog/2017/06/19/options-with-curl/comment-page-1/#comment-18373 Closes #1593
* http: add --strip-path-slash and CURLOPT_STRIP_PATH_SLASHDaniel Stenberg2017-06-191-1/+6
| | | | | | | | | | | ... to enable sending "OPTIONS *" which wasn't possible previously. This option currently only works for HTTP. Added test cases 1298 + 1299 to verify Fixes #1280 Closes #1462
* curl: prevent binary output spewed to terminalDaniel Stenberg2017-06-161-1/+1
| | | | | | | | | ... unless "--output -" is used. Binary detection is done by simply checking for a binary zero in early data. Added test 1425 1426 to verify. Closes #1512
* curl: allow --header and --proxy-header read from fileDaniel Stenberg2017-06-151-6/+36
| | | | | | | | So many headers can be provided as @filename. Suggested-by: Timothe Litt Closes #1486
* tool: fix remaining -Wcast-qual warningsMarcel Raad2017-05-091-5/+5
| | | | Avoid casting away low-level const.
* curl: remove tool_writeenv.[ch]Daniel Stenberg2017-05-061-8/+0
| | | | | | | | | ... and USE_ENVIRONMENT and --environment. It was once added for RISC OS support and its platform specific behavior has been annoying ever since. Added in commit c3c8bbd3b2688da8e, mostly unchanged since then. Most probably not actually used for years. Closes #1463
* curl: fix warning "comma at end of enumerator list"Daniel Stenberg2017-05-041-1/+1
|
* curl: non-boolean command line args reject --no- prefixesDaniel Stenberg2017-05-021-219/+225
| | | | | | | | ... and instead properly respond with an error message to the user instead of silently ignoring. Fixes #1453 Closes #1458
* tool: Fix missing prototype warnings for CURL_DOES_CONVERSIONSJay Satiro2017-05-011-0/+1
| | | | | | | - Include tool_convert.h where needed. Bug: https://github.com/curl/curl/issues/1460 Reported-by: Gisle Vanem
* Improve code readbilitySylvestre Ledru2017-03-131-25/+22
| | | | | | ... by removing the else branch after a return, break or continue. Closes #1310