3.2 KiB
icon
| icon |
|---|
| material/new-box |
!!! question "Since sing-box 1.14.0"
Structure
A string or an object.
When string, the tag of a shared HTTP Client defined in top-level http_clients.
When object:
{
"engine": "",
"version": 0,
"disable_version_fallback": false,
"headers": {},
... // HTTP2 Fields
"tls": {},
... // Dial Fields
}
Fields
engine
HTTP engine to use.
Values:
go(default)applecronet
apple uses NSURLSession, only available on Apple platforms.
!!! warning ""
Experimental only: due to the high memory overhead of both CGO and Network.framework,
do not use in hot paths on iOS and tvOS.
Supported fields:
headerstls.server_name(must match request host)tls.insecuretls.min_version/tls.max_versiontls.certificate/tls.certificate_pathtls.certificate_public_key_sha256- Dial Fields
Unsupported fields:
versiondisable_version_fallback- HTTP2 Fields
- QUIC Fields
tls.enginetls.alpntls.disable_snitls.cipher_suitestls.curve_preferencestls.client_certificate/tls.client_certificate_path/tls.client_key/tls.client_key_pathtls.fragment/tls.record_fragmenttls.kernel_tx/tls.kernel_rxtls.echtls.utlstls.reality
cronet uses Cronet, only available when sing-box is built with the with_naive_outbound tag.
Supported fields:
versiondisable_version_fallback(version = 3only)headerstls.server_name(must match request host)tls.certificate/tls.certificate_pathtls.certificate_public_key_sha256tls.ech.config/tls.ech.config_path/tls.ech.query_server_namehttp2.stream_receive_window/http2.connection_receive_windowquic.stream_receive_window/quic.connection_receive_windowquic.idle_timeout- Dial Fields
Unsupported fields:
tls.enginetls.disable_snitls.insecuretls.alpntls.min_version/tls.max_versiontls.cipher_suitestls.curve_preferencestls.client_certificate/tls.client_certificate_path/tls.client_key/tls.client_key_pathtls.fragment/tls.record_fragmenttls.kernel_tx/tls.kernel_rxtls.handshake_timeouttls.utlstls.realityhttp2.idle_timeouthttp2.keep_alive_periodhttp2.max_concurrent_streamsquic.keep_alive_periodquic.initial_packet_sizequic.disable_path_mtu_discoveryquic.max_concurrent_streams
version
HTTP version.
Available values: 1, 2, 3.
2 is used by default.
When 3, HTTP2 Fields are replaced by QUIC Fields.
disable_version_fallback
Disable automatic fallback to lower HTTP version.
headers
Custom HTTP headers.
Host header is used as request host.
HTTP2 Fields
When version is 2 (default).
See HTTP2 Fields for details.
QUIC Fields
When version is 3.
See QUIC Fields for details.
TLS Fields
See TLS for details.
Dial Fields
See Dial Fields for details.