Artifactspublic-v0

curl

master
ply4 git calls218 ms290 KiB2 cachedprotocol v2
238 lines6.7 KiBRaw

NAME

libcurl-env-dbg - environment variables libcurl DEBUGBUILD understands

DESCRIPTION

This is a set of variables only recognized and used if libcurl was built "debug enabled", which should never be true for a library used in production. These variables are intended for internal use only, subject to change and have many effects on the behavior of libcurl. Refer to the source code to determine how exactly they are being used.

CURL_ALTSVC_HTTP

Bypass the AltSvc HTTPS protocol restriction if this variable exists.

CURL_DBG_SOCK_RBLOCK

The percentage of recv() calls that should be answered with an EAGAIN at random. For TCP/UNIX sockets.

CURL_DBG_SOCK_RMAX

The maximum data that shall be received from the network in one recv() call. For TCP/UNIX sockets. This is applied to every recv.

Example: CURL_DBG_SOCK_RMAX=400 means recv buffer size is limited to a maximum of 400 bytes.

CURL_DBG_SOCK_WBLOCK

The percentage of send() calls that should be answered with an EAGAIN at random. For TCP/UNIX sockets.

CURL_DBG_SOCK_WPARTIAL

The percentage of data that shall be written to the network. For TCP/UNIX sockets. This is applied to every send.

Example: CURL_DBG_SOCK_WPARTIAL=80 means a send with 1000 bytes would only send 800.

CURL_DBG_SOCK_CONNECT_WAIT_MS

Wait this many milliseconds after first connect() on a socket.

CURL_DBG_QUIC_WBLOCK

The percentage of send() calls that should be answered with EAGAIN at random. QUIC only.

CURL_DBG_SOCK_FAIL_IPV6

Fail opening of sockets for the IPv6 address family.

CURL_DEBUG

Trace logging behavior as an alternative to calling curl_global_trace(3).

Example: CURL_DEBUG=http/2 means trace details about HTTP/2 handling.

In the curl command line tool, built with --enable-debug, this environment variable adds to arguments like --verbose, -vvv. At least a single -v is needed to make the run emit trace output, but when it does, the contents of CURL_DEBUG are added and can override existing options.

Example: CURL_DEBUG=tcp,-http/2 curl -vv url means trace protocol details, triggered by -vv, add tracing of TCP in addition and remove tracing of HTTP/2.

CURL_DEBUG_SIZE

Fake the size returned by CURLINFO_HEADER_SIZE and CURLINFO_REQUEST_SIZE.

CURL_DNS_SERVER

When built with c-ares for name resolving, setting this environment variable to [IP:port] makes libcurl use that DNS server instead of the system default. This is used by the curl test suite.

CURL_FTP_PWD_STOP

When set, the first transfer - when using ftp: - returns before sending the PWD command and stop any further progress. This is used to test an edge case

CURL_GETHOSTNAME

Fake the local machine's unqualified hostname for SMTP.

CURL_HSTS_HTTP

Bypass the HSTS HTTPS protocol restriction if this variable exists.

CURL_FORCETIME

A time of 0 is used for AWS signatures if this variable exists.

CURL_ENTROPY

A fixed faked value to use instead of a proper random number so that functions in libcurl that are otherwise getting random outputs can be tested for what they generate.

CURL_SIGPIPE_DEBUG

When present, curl does not set SIGPIPE to ignore. This allows verification that libcurl does not cause SIGPIPE to be raised.

CURL_SMALLREQSEND

An alternative size of HTTP data to be sent at a time only if smaller than the current.

CURL_SMALLSENDS

An alternative size of socket data to be sent at a time only if smaller than the current.

CURL_TIME

Fake Unix timestamp to use for AltSvc, HSTS and CURLINFO variables that are time related.

This variable can also be used to fake the data returned by some CURLINFO variables that are not time-related (such as CURLINFO_LOCAL_PORT), and in that case the value is not a timestamp.

CURL_TRACE

LDAP tracing is enabled if this variable exists and its value is 1 or greater.

OpenLDAP tracing is separate. Refer to CURL_OPENLDAP_TRACE.

CURL_OPENLDAP_TRACE

OpenLDAP tracing is enabled if this variable exists and its value is 1 or greater. There is a number of debug levels, refer to openldap.c comments.

CURL_WS_CHUNK_SIZE

Used to influence the buffer chunk size used for WebSocket encoding and decoding.

CURL_WS_CHUNK_EAGAIN

Used to simulate blocking sends after this chunk size for WebSocket connections.

CURL_WS_FORCE_ZERO_MASK

Used to set the bitmask of all sent WebSocket frames to zero. The value of the environment variable does not matter.

CURL_FORBID_REUSE

Used to set the CURLOPT_FORBID_REUSE flag on each transfer initiated by the curl command line tool. The value of the environment variable does not matter.

CURL_GRACEFUL_SHUTDOWN

Make a blocking, graceful shutdown of all remaining connections when a multi handle is destroyed. This implicitly triggers for easy handles that are run via easy_perform. The value of the environment variable gives the shutdown timeout in milliseconds.

CURL_DBG_HE_AAAA_AWAIT_MS

Overrides the time delaying a connect for AAAA resolve results to arrive before continuing with Happy Eyeballing.

CURL_DBG_RESOLV_MAX_THREADS

Overrides the maximum number of threads for resolver.

CURL_DBG_RESOLV_DELAY

Makes ever threaded resolve experience an initial delay in milliseconds.

CURL_DBG_RESOLV_FAIL_DELAY

With a threaded resolver, delay each lookup by the given milliseconds and fail it, as if a transient resolver failure happened.

CURL_DBG_RESOLV_FAIL_NEGATIVE

With a threaded resolver, make a lookup failing via CURL_DBG_RESOLV_FAIL_DELAY count as an authoritative negative answer, eligible for negative DNS caching, instead of a transient failure.

CURL_DBG_RESOLV_FAIL_IPV6

Make libcurl fail a resolve for IPv6 only.

CURL_DBG_THRDPOOL_FAIL_STARTS

Fail this many thread starts in a thread pool, as if the system refused to spawn more threads. Read when the pool is created.

CURL_QUICK_EXIT

Make curl use the quick exit option, even when built in debug mode.

CURL_DBG_AWAIT_HTTPSRR

When happy eyeballing for https: wait for the HTTPS-RR resolve answer to arrive before starting any connect attempt.

CURL_DBG_NO_USE_SSL_ON_FIRST

When passing --ssl-reqd, clear it for the first URL in a curl command. This allows testing of connection reuse in mixed STARTTLS needs.

CURL_DBG_SUPPRESS_CONNECT_HDS

Existence of this variable suppresses the collection of CONNECT headers.

CURL_DBG_MAX_TOTAL_CONNECTIONS

Set the max_total_connections for a multi handle.

CURL_DBG_FTP_WILDCARD

Simulate CURLOPT_WILDCARDMATCH being set.

1---
2c: Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
3SPDX-License-Identifier: curl
4Title: libcurl-env-dbg
5Section: 3
6Source: libcurl
7See-also:
8 - libcurl-env (3)
9Protocol:
10 - All
11Added-in: n/a
12---
14# NAME
16libcurl-env-dbg - environment variables libcurl DEBUGBUILD understands
18# DESCRIPTION
20This is a set of variables only recognized and used if libcurl was built
21"debug enabled", which should never be true for a library used in production.
22These variables are intended for internal use only, subject to change and have
23many effects on the behavior of libcurl. Refer to the source code to determine
24how exactly they are being used.
26## `CURL_ALTSVC_HTTP`
28Bypass the AltSvc HTTPS protocol restriction if this variable exists.
30## `CURL_DBG_SOCK_RBLOCK`
32The percentage of recv() calls that should be answered with an EAGAIN at
33random. For TCP/UNIX sockets.
35## `CURL_DBG_SOCK_RMAX`
37The maximum data that shall be received from the network in one recv() call.
38For TCP/UNIX sockets. This is applied to every recv.
40Example: **CURL_DBG_SOCK_RMAX=400** means recv buffer size is limited to a
41maximum of 400 bytes.
43## `CURL_DBG_SOCK_WBLOCK`
45The percentage of send() calls that should be answered with an EAGAIN at
46random. For TCP/UNIX sockets.
48## `CURL_DBG_SOCK_WPARTIAL`
50The percentage of data that shall be written to the network. For TCP/UNIX
51sockets. This is applied to every send.
53Example: **CURL_DBG_SOCK_WPARTIAL=80** means a send with 1000 bytes would
54only send 800.
56## `CURL_DBG_SOCK_CONNECT_WAIT_MS`
58Wait this many milliseconds after first `connect()` on a socket.
60## `CURL_DBG_QUIC_WBLOCK`
62The percentage of send() calls that should be answered with EAGAIN at random.
63QUIC only.
65## `CURL_DBG_SOCK_FAIL_IPV6`
67Fail opening of sockets for the IPv6 address family.
69## `CURL_DEBUG`
71Trace logging behavior as an alternative to calling curl_global_trace(3).
73Example: **CURL_DEBUG=http/2** means trace details about HTTP/2 handling.
75In the curl command line tool, built with `--enable-debug`, this environment
76variable adds to arguments like `--verbose`, `-vvv`. At least a single `-v`
77is needed to make the run emit trace output, but when it does, the contents
78of `CURL_DEBUG` are added and can override existing options.
80Example: **CURL_DEBUG=tcp,-http/2 curl -vv url** means trace protocol details,
81triggered by `-vv`, add tracing of TCP in addition and remove tracing of
82HTTP/2.
84## `CURL_DEBUG_SIZE`
86Fake the size returned by CURLINFO_HEADER_SIZE and CURLINFO_REQUEST_SIZE.
88## `CURL_DNS_SERVER`
90When built with c-ares for name resolving, setting this environment variable
91to `[IP:port]` makes libcurl use that DNS server instead of the system
92default. This is used by the curl test suite.
94## `CURL_FTP_PWD_STOP`
96When set, the first transfer - when using ftp: - returns before sending
97the `PWD` command and stop any further progress. This is used to test
98an edge case
100## `CURL_GETHOSTNAME`
102Fake the local machine's unqualified hostname for SMTP.
104## `CURL_HSTS_HTTP`
106Bypass the HSTS HTTPS protocol restriction if this variable exists.
108## `CURL_FORCETIME`
110A time of 0 is used for AWS signatures if this variable exists.
112## `CURL_ENTROPY`
114A fixed faked value to use instead of a proper random number so that functions
115in libcurl that are otherwise getting random outputs can be tested for what
116they generate.
118## `CURL_SIGPIPE_DEBUG`
120When present, `curl` does not set `SIGPIPE` to ignore. This allows
121verification that `libcurl` does not cause `SIGPIPE` to be raised.
123## `CURL_SMALLREQSEND`
125An alternative size of HTTP data to be sent at a time only if smaller than the
126current.
128## `CURL_SMALLSENDS`
130An alternative size of socket data to be sent at a time only if smaller than
131the current.
133## `CURL_TIME`
135Fake Unix timestamp to use for AltSvc, HSTS and CURLINFO variables that are
136time related.
138This variable can also be used to fake the data returned by some CURLINFO
139variables that are not time-related (such as CURLINFO_LOCAL_PORT), and in that
140case the value is not a timestamp.
142## `CURL_TRACE`
144LDAP tracing is enabled if this variable exists and its value is 1 or greater.
146OpenLDAP tracing is separate. Refer to CURL_OPENLDAP_TRACE.
148## `CURL_OPENLDAP_TRACE`
150OpenLDAP tracing is enabled if this variable exists and its value is 1 or
151greater. There is a number of debug levels, refer to *openldap.c* comments.
153## `CURL_WS_CHUNK_SIZE`
155Used to influence the buffer chunk size used for WebSocket encoding and
156decoding.
158## `CURL_WS_CHUNK_EAGAIN`
160Used to simulate blocking sends after this chunk size for WebSocket
161connections.
163## `CURL_WS_FORCE_ZERO_MASK`
165Used to set the bitmask of all sent WebSocket frames to zero. The value of the
166environment variable does not matter.
168## `CURL_FORBID_REUSE`
170Used to set the CURLOPT_FORBID_REUSE flag on each transfer initiated
171by the curl command line tool. The value of the environment variable
172does not matter.
174## `CURL_GRACEFUL_SHUTDOWN`
176Make a blocking, graceful shutdown of all remaining connections when
177a multi handle is destroyed. This implicitly triggers for easy handles
178that are run via easy_perform. The value of the environment variable
179gives the shutdown timeout in milliseconds.
181## `CURL_DBG_HE_AAAA_AWAIT_MS`
183Overrides the time delaying a connect for AAAA resolve results to arrive
184before continuing with Happy Eyeballing.
186## `CURL_DBG_RESOLV_MAX_THREADS`
188Overrides the maximum number of threads for resolver.
190## `CURL_DBG_RESOLV_DELAY`
192Makes ever threaded resolve experience an initial delay in milliseconds.
194## `CURL_DBG_RESOLV_FAIL_DELAY`
196With a threaded resolver, delay each lookup by the given milliseconds
197and fail it, as if a transient resolver failure happened.
199## `CURL_DBG_RESOLV_FAIL_NEGATIVE`
201With a threaded resolver, make a lookup failing via
202`CURL_DBG_RESOLV_FAIL_DELAY` count as an authoritative negative answer,
203eligible for negative DNS caching, instead of a transient failure.
205## `CURL_DBG_RESOLV_FAIL_IPV6`
207Make libcurl fail a resolve for IPv6 only.
209## `CURL_DBG_THRDPOOL_FAIL_STARTS`
211Fail this many thread starts in a thread pool, as if the system
212refused to spawn more threads. Read when the pool is created.
214## `CURL_QUICK_EXIT`
216Make `curl` use the quick exit option, even when built in debug mode.
218## `CURL_DBG_AWAIT_HTTPSRR`
220When happy eyeballing for https: wait for the HTTPS-RR resolve
221answer to arrive before starting any connect attempt.
223## `CURL_DBG_NO_USE_SSL_ON_FIRST`
225When passing `--ssl-reqd`, clear it for the first URL in a curl command.
226This allows testing of connection reuse in mixed `STARTTLS` needs.
228## `CURL_DBG_SUPPRESS_CONNECT_HDS`
230Existence of this variable suppresses the collection of CONNECT headers.
232## `CURL_DBG_MAX_TOTAL_CONNECTIONS`
234Set the `max_total_connections` for a `multi` handle.
236## `CURL_DBG_FTP_WILDCARD`
238Simulate CURLOPT_WILDCARDMATCH being set.
Diagnostics4 git calls · 218 ms
CallStatusSizeTime0218 ms
discover200152 B3 ms
git.upload-pack discover
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=2
git.response.bytes=152
git.server.agent=gitty/1.0
git.server.object_format=sha1
git.server.caps=agent ls-refs fetch object-format
git.server.fetch=shallow filter sideband-all
git.protocol.version=2
git.pkt.frames=8
git.pkt.data=6
git.pkt.flush=2
git.pkt.delim=0
git.pkt.bytes=152
git.pkt.payload.max=34
ls-refs200149 B · hit2 ms
git.upload-pack ls-refs
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=ls-refs
git.upstream.dur_ms=2
git.response.bytes=149
git.response.cache=HIT
git.response.duration_ms=2
git.protocol.version=2
git.pkt.frames=3
git.pkt.data=2
git.pkt.flush=1
git.pkt.delim=0
git.pkt.bytes=149
git.pkt.payload.max=78
git.ls_refs.count=2
git.ls_refs.head=refs/heads/master
fetchblob:none · deepen 10200287 KiB · hit2 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=212
git.response.bytes=293470
git.response.cache=HIT
git.response.duration_ms=2
git.fetch.filter=blob:none
git.fetch.filter.requested=tree:0
git.fetch.filter.fallback=blob:none
git.fetch.filter.learned=false
git.fetch.wants=31c911efe5652725e930f4d2e60c9060e5f6646d
git.fetch.haves.count=0
git.fetch.deepen=10
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=10
git.pkt.data=8
git.pkt.flush=1
git.pkt.delim=1
git.pkt.bytes=293470
git.pkt.payload.max=65516
git.sideband.band1.bytes=293354
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0
git.pack.objects=87
git.pack.bytes=293354
git.pack.ofs_delta=0
git.pack.ref_delta=1
git.pack.chain.max=1
git.pack.trailer=6a646bcda6740bab42e321b51998b52ea15146c0
git.pack.full=86
Open pack map
fetch2003.0 KiB213 ms
git.upload-pack fetch
http.response.status_code=200
git.response.bytes=3034
git.response.cache=MISS
git.response.duration_ms=213
git.fetch.wants=3af0972946034639084aec581acd6e723534688d
git.fetch.haves.count=0
git.fetch.deepen=0
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=3
git.pkt.data=2
git.pkt.flush=1
git.pkt.delim=0
git.pkt.bytes=3034
git.pkt.payload.max=3013
git.sideband.band1.bytes=3012
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0

Each row is one HTTP round trip ply made to the git server for this page, on one timeline. discover asks what the server speaks, ls-refs lists branch tips, fetch brings objects by id. A hit was served by Workers Cache. Tap a row for its wire details.

Remote
https://5ad2236b39de4c8bd8f6270ea63f3ea9.artifacts.cloudflare.net/git/public-v0/curl.git
Ref
refs/heads/master
Commit
31c911efe5652725e930f4d2e60c9060e5f6646d
cf-ray
a5e1791558892a7e
Request
56d37868…
Protocol
v2 · sha1
Agent
gitty/1.0
Filter
advertised
Fetch
shallow filter sideband-all
Capabilities
agent ls-refs fetch object-format