Libcurl

From Nintendo Switch Brew
Jump to navigation Jump to search

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.

With sdkver 10.x, this is built with support for NGHTTP2 with the relevant Alpn cmds being used for this.

The changes to libcurl compared to the original libcurl are documented below, etc.

CURLOPT

The 50X options are custom, the default values for some of these are set in Curl_init_userdefined.

CINIT name CINIT type CINIT number CURLoption value Default value
#PROXYAUTOCONFIG LONG 500 500 1
#UNK501 LONG 501 501 0
502
503
504
505
#UNK506 LONG 506 506 0
#UNK507 LONG 507 507

PROXYAUTOCONFIG

This option is handled as a bool.

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 nifm. The code handling this option was added to the start of the inlined create_conn_helper_init_proxy func.

UNK501

This option is handled as a bool.

This controls the value of the DataCheck VerifyOption bit.

UNK506

This option is handled as a bool.

This is used during Curl_resolver_getaddrinfo.

UNK507

This option is handled as a bool.

This controls the value of the SkipDefaultVerify option flag.