summaryrefslogtreecommitdiff
path: root/packages/OS400
Commit message (Collapse)AuthorAgeFilesLines
* OS400: provide ILE/RPG usage examplesPatrick Monnerat2023-04-187-0/+919
| | | | Closes https://github.com/curl/curl/pull/10994
* OS400: improve vararg emulationPatrick Monnerat2023-04-184-0/+76
| | | | | | | | | | | | - Use V7R4 RPG procedure overloading to improve vararg emulation. From OS400 V7R4 and above, ILE/RPG implements a limited procedure overloading feature that can be used to improve curl's typed implementation of varargs procedures. This commit applies it to curl_easy_setopt(), curl_multi_setopt(), curl_share_setopt() and curl_easy_getinfo(). Closes https://github.com/curl/curl/pull/10994
* OS400: fix and complete ILE/RPG bindingPatrick Monnerat2023-04-182-24/+264
| | | | | | | | | | | | | | | | - Fix wrong definitions of CURL_ZERO_TERNINATED, curl_mime_data() and curl_mime_data_ccsid(). - Add recent definitions, in particular blob, header API and WebSockets API. - Support for CURLVERSION_ELEVENTH. - New functions for EBCDIC support. Reflect these changes in README.OS400. Closes https://github.com/curl/curl/pull/10994
* OS400: implement EBCDIC support for recent featuresPatrick Monnerat2023-04-184-94/+163
| | | | | | | | | | | | | | | | | | | - Support CURLVERSION_ELEVENTH. - New function curl_url_strerror_ccsid(). - curl_easy_setopt_ccsid() supports blobs and 3 recent string options. - New function curl_easy_header_ccsid(). - New generic latin1<-->ccsid conversion functions curl_from_ccsid() and curl_to_ccsid() for user convenience. - README.OS400 updated accordingly. - Removed a leftover QsoSSL support identifier. Closes https://github.com/curl/curl/pull/10994
* OS400: rework build scriptsPatrick Monnerat2023-04-185-81/+37
| | | | | | | | | | | | | | | | | - Rename shell function "system" to "CLcommand" to avoid confusion with built-in command. - Reformat scripts. Fix some indentations. Avoid lines > 80 characters where possible. - Support ASCII runtime development files in a user-defined directory path. - FIX SONAME detection. - Drop form API test program compilation (does not exist anymore). Closes https://github.com/curl/curl/pull/10994
* os400: correct Curl_os400_sendto()jonrumsey2023-02-171-1/+1
| | | | | | | | | | Add const qualifier to 5th argument of Curl_os400_sendto() Make OS400 wrapper for sendto match the normal prototype of sendto() with a const qualifier. Fixes #10539 Closes #10548
* os400: fixes to make-lib.sh and initscript.shjonrumsey2023-01-102-7/+18
| | | | | | | | | | | | | Adjust how exports list is generated from header files to account for declarations across multiple lines and CURL_DEPRECATED(...) tags. Update initscript.sh Specify qadrt_use_inline to prevent unistd.h in ASCII runtime defining close(a) -> close_a(a) Fixes #10266 Closes #10267
* scripts: set file mode +x on all perl and shell scriptsJay Satiro2023-01-056-0/+0
| | | | | | | | | | | | | - Set all scripts +x, ie 644 => 755. Prior to this change some scripts were not executable and therefore could not be called directly. ~~~ git ls-files -s \*.{sh,pl,py} | grep -v 100755 ~~~ Closes https://github.com/curl/curl/pull/10219
* copyright: update all copyright lines and remove year rangesDaniel Stenberg2023-01-0312-13/+13
| | | | | | | | | | | | - they are mostly pointless in all major jurisdictions - many big corporations and projects already don't use them - saves us from pointless churn - git keeps history for us - the year range is kept in COPYING checksrc is updated to allow non-year using copyright statements Closes #10205
* lib: fix some type mismatches and remove unneeded typecastsRose2022-11-082-5/+5
| | | | | | | | | Many of these castings are unneeded if we change the variables to work better with each other. Ref: https://github.com/curl/curl/pull/9823 Closes https://github.com/curl/curl/pull/9835
* os400: use platform socklen_t in Curl_getnameinfo_ajonrumsey2022-10-271-3/+3
| | | | | | | | | | | | Curl_getnameinfo_a() is prototyped before including curl.h as an ASCII'fied wrapper for getnameinfo(), which itself is prototyped with socklen_t arguments, so this should use the platform socklen_t and not curl_socklen_t too. Update setup-os400.h Fixes #9811 Closes #9812
* tidy-up: delete parallel/unused feature flagsViktor Szakats2022-10-062-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Detecting headers and lib separately makes sense when headers come in variations or with extra ones, but this wasn't the case here. These were duplicate/parallel macros that we had to keep in sync with each other for a working build. This patch leaves a single macro for each of these dependencies: - Rely on `HAVE_LIBZ`, delete parallel `HAVE_ZLIB_H`. Also delete CMake logic making sure these two were in sync, along with a toggle to turn off that logic, called `CURL_SPECIAL_LIBZ`. Also delete stray `HAVE_ZLIB` defines. There is also a `USE_ZLIB` variant in `lib/config-dos.h`. This patch retains it for compatibility and deprecates it. - Rely on `USE_LIBSSH2`, delete parallel `HAVE_LIBSSH2_H`. Also delete `LIBSSH2_WIN32`, `LIBSSH2_LIBRARY` from `winbuild/MakefileBuild.vc`, these have a role when building libssh2 itself. And `CURL_USE_LIBSSH`, which had no use at all. Also delete stray `HAVE_LIBSSH2` defines. - Rely on `USE_LIBSSH`, delete parallel `HAVE_LIBSSH_LIBSSH_H`. Also delete `LIBSSH_WIN32`, `LIBSSH_LIBRARY` and `HAVE_LIBSSH` from `winbuild/MakefileBuild.vc`, these were the result of copy-pasting the libssh2 line, and were not having any use. - Delete unused `HAVE_LIBPSL_H` and `HAVE_LIBPSL`. Reviewed-by: Daniel Stenberg Closes #9652
* CURLOPT_SERVER_RESPONSE_TIMEOUT: the new nameDaniel Stenberg2022-07-051-1/+1
| | | | | | | | | | | Starting now, CURLOPT_FTP_RESPONSE_TIMEOUT is the alias instead of the other way around. Since 7.20.0, CURLOPT_SERVER_RESPONSE_TIMEOUT has existed as an alias but since the option is for more protocols than FTP the more "correct" version of the option is the "server" one so now we switch. Closes #9104
* version: rename threadsafe-init to threadsafeViktor Szakats2022-06-131-1/+1
| | | | | | | | | | | | | | | | | | | | Referring to Daniel's article [1], making the init function thread-safe was the last bit to make libcurl thread-safe as a whole. So the name of the feature may as well be the more concise 'threadsafe', also telling the story that libcurl is now fully thread-safe, not just its init function. Chances are high that libcurl wants to remain so in the future, so there is little likelihood of ever needing any other distinct `threadsafe-<name>` feature flags. For consistency we also shorten `CURL_VERSION_THREADSAFE_INIT` to `CURL_VERSION_THREADSAFE`, update its description and reference libcurl's thread safety documentation. [1]: https://daniel.haxx.se/blog/2022/06/08/making-libcurl-init-more-thread-safe/ Reviewed-by: Daniel Stenberg Reviewed-by: Jay Satiro Closes #8989
* copyright: make repository REUSE compliantmax.mehl2022-06-1312-9/+33
| | | | | | | | | | | Add licensing and copyright information for all files in this repository. This either happens in the file itself as a comment header or in the file `.reuse/dep5`. This commit also adds a Github workflow to check pull requests and adapts copyright.pl to the changes. Closes #8869
* curl_version_info: add CURL_VERSION_THREADSAFE_INITThomas Guillem2022-06-071-0/+2
| | | | | | | | | | This flag can be used to make sure that curl_global_init() is thread-safe. This can be useful for libraries that can't control what other dependencies are doing with Curl. Closes #8680
* English: use American spelling consistentlyDaniel Stenberg2022-04-052-2/+2
| | | | | | Authorization, Initialization, Organization etc. Closes #8673
* OS400/README: clarify compilation stepsRob Boeckermann2022-02-221-2/+2
| | | | Closes #8494
* OS400: fix typos in rpg include fileRob Boeckermann2022-02-221-5/+5
| | | | | | | This resolves issues compiling rpg code that includes the curl header file. Closes #8494
* os400: Add link to QADRT devkit to README.OS400Kevin Adler2022-02-171-0/+2
| | | | Closes #8455
* os400: Add function wrapper for system commandKevin Adler2022-02-172-2/+8
| | | | | | | | | | The wrapper will exit if the system command failed instead of blindly continuing on. In addition, only copy docs which exist, since now the copy failure will cause the build to stop. Closes #8455
* os400: Default build to target current releaseKevin Adler2022-02-171-1/+1
| | | | | | | | | V6R1M0 is not available as a target release since IBM i 7.2. To keep from having to keep this up to date in git, default to the current release. Users can configure this to whatever release they want to actually build for. Closes #8455
* mime: use percent-escaping for multipart form field and file namesPatrick Monnerat2021-11-151-0/+5
| | | | | | | | | | | | | | | | | | Until now, form field and file names where escaped using the backslash-escaping algorithm defined for multipart mails. This commit replaces this with the percent-escaping method for URLs. As this may introduce incompatibilities with server-side applications, a new libcurl option CURLOPT_MIME_OPTIONS with bitmask CURLMIMEOPT_FORMESCAPE is introduced to revert to legacy use of backslash-escaping. This is controlled by new cli tool option --form-escape. New tests and documentation are provided for this feature. Reported by: Ryan Sleevi Fixes #7789 Closes #7805
* CURLOPT_MAXLIFETIME_CONN: maximum allowed lifetime for conn reuseJeffrey Tolar2021-10-061-0/+2
| | | | | | | | | ... and close connections that are too old instead of reusing them. By default, this behavior is disabled. Bug: https://curl.se/mail/lib-2021-09/0058.html Closes #7751
* urlapi: add curl_url_strerror()i-ky2021-09-271-0/+4
| | | | | | | | | | Add curl_url_strerror() to convert CURLUcode into readable string and facilitate easier troubleshooting in programs using URL API. Extend CURLUcode with CURLU_LAST for iteration in unit tests. Update man pages with a mention of new function. Update example code and tests with new functionality where it fits. Closes #7605
* ccsidcurl: fix the compile errorsjonrumsey2021-05-261-3/+3
| | | | | | | | Looks like the declaration of cpp shoule be const char ** and return null if convert_version_info_string fails. Fixes #7134 Closes #7135
* SSL: support in-memory CA certs for some backendsGilles Vollant2021-05-051-0/+4
| | | | | | | | | | | | | | | | | - New options CURLOPT_CAINFO_BLOB and CURLOPT_PROXY_CAINFO_BLOB to specify in-memory PEM certificates for OpenSSL, Schannel (Windows) and Secure Transport (Apple) SSL backends. Prior to this change PEM certificates could only be imported from a file and not from memory. Co-authored-by: moparisthebest@users.noreply.github.com Ref: https://github.com/curl/curl/pull/4679 Ref: https://github.com/curl/curl/pull/5677 Ref: https://github.com/curl/curl/pull/6109 Closes https://github.com/curl/curl/pull/6662
* version: add gsasl_version to curl_version_info_dataMartin Halle2021-04-222-3/+8
| | | | | | | | - Add gsasl_version string and bump to CURLVERSION_TENTH. Ref: https://curl.se/mail/lib-2021-04/0003.html Closes https://github.com/curl/curl/pull/6843
* schannel: Disable auto credentials; add an option to enable itJay Satiro2021-04-221-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Disable auto credentials by default. This is a breaking change for clients that are using it, wittingly or not. - New libcurl ssl option value CURLSSLOPT_AUTO_CLIENT_CERT tells libcurl to automatically locate and use a client certificate for authentication, when requested by the server. - New curl tool options --ssl-auto-client-cert and --proxy-ssl-auto-client-cert map to CURLSSLOPT_AUTO_CLIENT_CERT. This option is only supported for Schannel (the native Windows SSL library). Prior to this change Schannel would, with no notification to the client, attempt to locate a client certificate and send it to the server, when requested by the server. Since the server can request any certificate that supports client authentication in the OS certificate store it could be a privacy violation and unexpected. Fixes https://github.com/curl/curl/issues/2262 Reported-by: Jeroen Ooms Assisted-by: Wes Hinsley Assisted-by: Rich FitzJohn Ref: https://curl.se/mail/lib-2021-02/0066.html Reported-by: Morten Minde Neergaard Closes https://github.com/curl/curl/pull/6673
* OS400: fix typoJay Satiro2021-04-221-1/+1
| | | | CURLVERSION_HEIGHTH -> CURLVERSION_EIGHTH
* os400: additional support for options metadataPatrick Monnerat2021-04-224-68/+321
| | | | | | | | | | | | | | New functions curl_easy_option_by_name_ccsid() and curl_easy_option_get_name_ccsid() allows accessing metadata in alternate character encoding. This commit also updates curl_version_info_ccsid() to handle info version 9 and adds recent definitions to the ILE/RPG include file. Documentation updated accordingly. Reviewed-by: Jon Rumsey Closes #6574
* http: add support to read and store the referrer headerViktor Szakats2021-02-192-0/+3
| | | | | | | | | - add CURLINFO_REFERER libcurl option - add --write-out '%{referer}' command-line option - extend --xattr command-line option to fill user.xdg.referrer.url extended attribute with the referrer (if there was any) Closes #6591
* doh: add options to disable ssl verificationJay Satiro2021-02-141-0/+6
| | | | | | | | | | | | | | | | | | | | | | - New libcurl options CURLOPT_DOH_SSL_VERIFYHOST, CURLOPT_DOH_SSL_VERIFYPEER and CURLOPT_DOH_SSL_VERIFYSTATUS do the same as their respective counterparts. - New curl tool options --doh-insecure and --doh-cert-status do the same as their respective counterparts. Prior to this change DOH SSL certificate verification settings for verifyhost and verifypeer were supposed to be inherited respectively from CURLOPT_SSL_VERIFYHOST and CURLOPT_SSL_VERIFYPEER, but due to a bug were not. As a result DOH verification remained at the default, ie enabled, and it was not possible to disable. This commit changes behavior so that the DOH verification settings are independent and not inherited. Ref: https://github.com/curl/curl/pull/4579#issuecomment-554723676 Fixes https://github.com/curl/curl/issues/4578 Closes https://github.com/curl/curl/pull/6597
* OS400: update for CURLOPT_AWS_SIGV4jonrumsey2021-02-043-4/+7
| | | | | | | | chkstrings fails because a new string option that could require codepage conversion has been added. Closes #6561 Fixes #6560
* OS400: update ccsidcurl.cJon Rumsey2020-12-101-2/+2
| | | | | | | | Add 'struct' to cast and declaration of cfcdata to fix compilation error. Fixes #6292 Closes #6297
* curl.se: new homeDaniel Stenberg2020-11-0412-12/+12
| | | | Closes #6172
* packages/OS400: make the source code-style compliantDaniel Stenberg2020-10-174-341/+219
| | | | | | | ... and make sure 'make checksrc' in the root dir also verifies the packages/OS400 sources. Closes https://github.com/curl/curl/pull/6085
* os400: Sync libcurl API optionsJay Satiro2020-10-173-2/+29
| | | | | | | | | | | This fixes the OS400 build and also an incorrect entry for CURLINFO_APPCONNECT_TIME_T where it was treated as CURLINFO_STARTTRANSFER_TIME_T. Reported-by: Jon Rumsey Fixes https://github.com/curl/curl/issues/6083 Closes https://github.com/curl/curl/pull/6084
* windows: add unicode to feature listViktor Szakats2020-07-141-0/+2
| | | | | | | Reviewed-by: Marcel Raad Reviewed-by: Marc Hörsken Closes #5491
* doc: Rename VERSIONS to VERSIONS.md as it already has Markdown syntaxEmil Engler2020-05-021-1/+1
| | | | Closes #5325
* copyright: fix out-of-date copyright ranges and missing headersDaniel Stenberg2020-03-248-2/+128
| | | | | | | | | Reported by the new script 'scripts/copyright.pl'. The script has a regex whitelist for the files that don't need copyright headers. Removed three (mostly usesless) README files from docs/ Closes #5141
* OS400: Update strings for ccsid-ifierCalvin Buckley2020-03-232-6/+9
| | | | | | Fixes build. Closes #5132
* schannel: add "best effort" revocation check optionJohannes Schindelin2020-03-181-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Implement new option CURLSSLOPT_REVOKE_BEST_EFFORT and --ssl-revoke-best-effort to allow a "best effort" revocation check. A best effort revocation check ignores errors that the revocation check was unable to take place. The reasoning is described in detail below and discussed further in the PR. --- When running e.g. with Fiddler, the schannel backend fails with an unhelpful error message: Unknown error (0x80092012) - The revocation function was unable to check revocation for the certificate. Sadly, many enterprise users who are stuck behind MITM proxies suffer the very same problem. This has been discussed in plenty of issues: https://github.com/curl/curl/issues/3727, https://github.com/curl/curl/issues/264, for example. In the latter, a Microsoft Edge developer even made the case that the common behavior is to ignore issues when a certificate has no recorded distribution point for revocation lists, or when the server is offline. This is also known as "best effort" strategy and addresses the Fiddler issue. Unfortunately, this strategy was not chosen as the default for schannel (and is therefore a backend-specific behavior: OpenSSL seems to happily ignore the offline servers and missing distribution points). To maintain backward-compatibility, we therefore add a new flag (`CURLSSLOPT_REVOKE_BEST_EFFORT`) and a new option (`--ssl-revoke-best-effort`) to select the new behavior. Due to the many related issues Git for Windows and GitHub Desktop, the plan is to make this behavior the default in these software packages. The test 2070 was added to verify this behavior, adapted from 310. Based-on-work-by: georgeok <giorgos.n.oikonomou@gmail.com> Co-authored-by: Markus Olsson <j.markus.olsson@gmail.com> Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Closes https://github.com/curl/curl/pull/4981
* urldata: do string enums without #ifdefs for build scriptsJon Rumsey2020-01-273-16/+82
| | | | | | | ... and check for inconsistencies for OS400 at build time with the new chkstrings tool. Closes #4822
* ngtcp2: Add an error code for QUIC connection errorsEmil Engler2020-01-111-0/+2
| | | | | | | | | | - Add new error code CURLE_QUIC_CONNECT_ERROR for QUIC connection errors. Prior to this change CURLE_FAILED_INIT was used, but that was not correct. Closes https://github.com/curl/curl/pull/4754
* multi: Change curl_multi_wait/poll to error on negative timeoutJay Satiro2020-01-111-1/+3
| | | | | | | | | | | | | | - Add new error CURLM_BAD_FUNCTION_ARGUMENT and return that error when curl_multi_wait/poll is passed timeout param < 0. Prior to this change passing a negative value to curl_multi_wait/poll such as -1 could cause the function to wait forever. Reported-by: hamstergene@users.noreply.github.com Fixes https://github.com/curl/curl/issues/4763 Closes https://github.com/curl/curl/pull/4765
* os400: Add missing CURLE error constantsJay Satiro2019-12-261-0/+6
| | | | | Bug: https://github.com/curl/curl/pull/4754#issuecomment-569126922 Reported-by: Emil Engler
* lib: fix some loose ends for recently added CURLSSLOPT_NO_PARTIALCHAINJay Satiro2019-12-051-0/+2
| | | | | | | | | | | | | Add support for CURLSSLOPT_NO_PARTIALCHAIN in CURLOPT_PROXY_SSL_OPTIONS and OS400 package spec. Also I added the option to the NameValue list in the tool even though it isn't exposed as a command-line option (...yet?). (NameValue stringizes the option name for the curl cmd -> libcurl source generator) Follow-up to 564d88a which added CURLSSLOPT_NO_PARTIALCHAIN. Ref: https://github.com/curl/curl/pull/4655
* multi: add curl_multi_wakeup()Gergely Nagy2019-11-251-1/+5
| | | | | | | | | | | | This commit adds curl_multi_wakeup() which was previously in the TODO list under the curl_multi_unblock name. On some platforms and with some configurations this feature might not be available or can fail, in these cases a new error code (CURLM_WAKEUP_FAILURE) is returned from curl_multi_wakeup(). Fixes #4418 Closes #4608
* CURLMOPT_MAX_CONCURRENT_STREAMS: new setoptKunal Ekawde2019-10-021-0/+2
| | | | Closes #4410