Libcurl: Difference between revisions
No edit summary |
|||
| (2 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
This page documents the libcurl package used by official sw. This is statically linked in the main-codebin, on old versions (~v2.x) this was a subsdk NSO. This page does not apply to the libcurl build included in the browser OSS NRO. | This page documents the libcurl package used by official sw. This is statically linked in the main-codebin, on old versions (~v2.x) this was a subsdk NSO. This page does not apply to the libcurl build included in the browser OSS NRO. | ||
Starting with sdkver 10.x, this is built with support for NGHTTP2 with the relevant [[SSL_services|Alpn]] cmds being used for this. | |||
The changes to libcurl compared to the original libcurl are documented below, etc. | The changes to libcurl compared to the original libcurl are documented below, etc. | ||
| Line 46: | Line 46: | ||
== SSL_CTX_FUNCTION == | == SSL_CTX_FUNCTION == | ||
This funcptr is called with the same params as normal, with the context ptr being {sdknso container object for [[SSL_services#ISslContext|ISslContext]]}. | This funcptr is called with the same params as normal, with the context ptr being {sdknso container object for [[SSL_services#ISslContext|ISslContext]]}. If this funcptr returns non-zero, the CURLcode is set to CURLE_ABORTED_BY_CALLBACK. | ||
This is only used if [[#UNK502]] is not set, in which case an error is thrown if this funcptr is not set. An error is also thrown afterwards if the context wasn't created. | This is only used if [[#UNK502]] is not set, in which case an error is thrown if this funcptr is not set. An error is also thrown afterwards if the context wasn't created. | ||
The user must create the [[SSL_services#ISslContext|ISslContext]] using this funcptr, with all required ISslContext initialization - no cmds are used by the caller with ISslContext besides [[SSL_services#CreateConnection|CreateConnection]]. | The user must create the [[SSL_services#ISslContext|ISslContext]] using this funcptr, with all required ISslContext initialization - no cmds are used by the caller with ISslContext besides [[SSL_services#CreateConnection|CreateConnection]] (the caller doesn't use [[SSL_services#CreateContext|CreateContext]], the user must). | ||
== PROXYAUTOCONFIG == | == PROXYAUTOCONFIG == | ||
| Line 57: | Line 57: | ||
A warning is printed if this option is set when CURLOPT_PROXY is already set - in which case CURLOPT_PROXY is freed. | A warning is printed if this option is set when CURLOPT_PROXY is already set - in which case CURLOPT_PROXY is freed. | ||
This option controls whether to load the system proxy from [[Network_Interface_services#GetCurrentNetworkProfile|nifm]]. The code handling this option was added to the start of the inlined create_conn_helper_init_proxy func. | This option controls whether to load the system proxy from [[Network_Interface_services#GetCurrentNetworkProfile|nifm]]. The code handling this option was added to the start of the inlined create_conn_helper_init_proxy func. The loaded proxy info is written to the CURLOPT PROXY* options as needed. | ||
== UNK501 == | == UNK501 == | ||
| Line 113: | Line 113: | ||
This is used during Curl_resolver_getaddrinfo. See also [[#URL]]. | This is used during Curl_resolver_getaddrinfo. See also [[#URL]]. | ||
= CURLcode = | |||
This section documents the custom CURLcode values. | |||
{| class="wikitable" border="1" | |||
|- | |||
! Value | |||
! Description | |||
|- | |||
| 95 || {sdknso container object for [[SSL_services#ISslContext|ISslContext]]} isn't initialized. | |||
|- | |||
| 96 || nnsslContextGetContextId failed. | |||
|- | |||
| 98 || Ptr is NULL. | |||
|} | |||