Artifactspublic-v0

curl

master
ply4 git calls47 ms289 KiB3 cachedprotocol v2
98 lines3.8 KiBRaw

SSL problems

First, let's establish that we often refer to TLS and SSL interchangeably as SSL here. The current protocol is called TLS, it was called SSL a long time ago.

There are several known reasons why a connection that involves SSL might fail. This is a document that attempts to detail the most common ones and how to mitigate them.

CA certs

CA certs are used to digitally verify the server's certificate. You need a "ca bundle" for this. See lots of more details on this in the SSLCERTS document.

CA bundle missing intermediate certificates

When using said CA bundle to verify a server cert, you may experience problems if your CA store does not contain the certificates for the intermediates if the server does not provide them.

The TLS protocol mandates that the intermediate certificates are sent in the handshake, but as browsers have ways to survive or work around such omissions, missing intermediates in TLS handshakes still happen that browser users do not notice.

Browsers work around this problem in two ways: they cache intermediate certificates from previous transfers and some implement the TLS "AIA" extension that lets the client explicitly download such certificates on demand.

Protocol version

Some broken servers fail to support the protocol negotiation properly that SSL servers are supposed to handle. This may cause the connection to fail completely. Sometimes you may need to explicitly select an SSL version to use when connecting to make the connection succeed.

An additional complication can be that modern SSL libraries sometimes are built with support for older SSL and TLS versions disabled.

All versions of SSL and the TLS versions before 1.2 are considered insecure and should be avoided. Use TLS 1.2 or later.

Ciphers

Clients give servers a list of ciphers to select from. If the list does not include any ciphers the server wants/can use, the connection handshake fails.

curl has recently disabled the user of a whole bunch of seriously insecure ciphers from its default set (slightly depending on SSL backend in use).

You may have to explicitly provide an alternative list of ciphers for curl to use to allow the server to use a weak cipher for you.

Note that these weak ciphers are identified as flawed. For example, this includes symmetric ciphers with less than 128-bit keys and RC4.

Schannel in earlier Windows versions may be unable to connect to servers that no longer support the legacy handshakes and algorithms used by those versions. If you are using curl in such Windows versions you should choose another SSL backend such as OpenSSL.

Reference: Prohibiting RC4 Cipher Suites

Allow BEAST

BEAST is the name of a TLS 1.0 attack that surfaced 2011. When adding means to mitigate this attack, it turned out that some broken servers out there in the wild did not work properly with the BEAST mitigation in place.

To make such broken servers work, the --ssl-allow-beast option was introduced. Exactly as it sounds, it re-introduces the BEAST vulnerability but on the other hand it allows curl to connect to that kind of strange servers.

Disabling certificate revocation checks

Some SSL backends may do certificate revocation checks (CRL, OCSP, etc) depending on the OS or build configuration. The --ssl-no-revoke option was introduced in 7.44.0 to disable revocation checking but currently is only supported for Schannel (the native Windows SSL library), with an exception in the case of Windows' Untrusted Publishers block list which it seems cannot be bypassed. This option may have broader support to accommodate other SSL backends in the future.

References:

https://curl.se/docs/ssl-compared.html

1<!--
2Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
4SPDX-License-Identifier: curl
5-->
7# SSL problems
9First, let's establish that we often refer to TLS and SSL interchangeably as
10SSL here. The current protocol is called TLS, it was called SSL a long time
11ago.
13There are several known reasons why a connection that involves SSL might
14fail. This is a document that attempts to detail the most common ones and
15how to mitigate them.
17## CA certs
19CA certs are used to digitally verify the server's certificate. You need a
20"ca bundle" for this. See lots of more details on this in the `SSLCERTS`
21document.
23## CA bundle missing intermediate certificates
25When using said CA bundle to verify a server cert, you may experience
26problems if your CA store does not contain the certificates for the
27intermediates if the server does not provide them.
29The TLS protocol mandates that the intermediate certificates are sent in the
30handshake, but as browsers have ways to survive or work around such
31omissions, missing intermediates in TLS handshakes still happen that browser
32users do not notice.
34Browsers work around this problem in two ways: they cache intermediate
35certificates from previous transfers and some implement the TLS "AIA"
36extension that lets the client explicitly download such certificates on
37demand.
39## Protocol version
41Some broken servers fail to support the protocol negotiation properly that
42SSL servers are supposed to handle. This may cause the connection to fail
43completely. Sometimes you may need to explicitly select an SSL version to
44use when connecting to make the connection succeed.
46An additional complication can be that modern SSL libraries sometimes are
47built with support for older SSL and TLS versions disabled.
49All versions of SSL and the TLS versions before 1.2 are considered insecure
50and should be avoided. Use TLS 1.2 or later.
52## Ciphers
54Clients give servers a list of ciphers to select from. If the list does not
55include any ciphers the server wants/can use, the connection handshake
56fails.
58curl has recently disabled the user of a whole bunch of seriously insecure
59ciphers from its default set (slightly depending on SSL backend in use).
61You may have to explicitly provide an alternative list of ciphers for curl
62to use to allow the server to use a weak cipher for you.
64Note that these weak ciphers are identified as flawed. For example, this
65includes symmetric ciphers with less than 128-bit keys and RC4.
67Schannel in earlier Windows versions may be unable to connect to servers that
68no longer support the legacy handshakes and algorithms used by those versions.
69If you are using curl in such Windows versions you should choose another SSL
70backend such as OpenSSL.
72Reference: [Prohibiting RC4 Cipher
73Suites](https://datatracker.ietf.org/doc/html/draft-popov-tls-prohibiting-rc4-01)
75## Allow BEAST
77BEAST is the name of a TLS 1.0 attack that surfaced 2011. When adding means
78to mitigate this attack, it turned out that some broken servers out there in
79the wild did not work properly with the BEAST mitigation in place.
81To make such broken servers work, the --ssl-allow-beast option was
82introduced. Exactly as it sounds, it re-introduces the BEAST vulnerability
83but on the other hand it allows curl to connect to that kind of strange
84servers.
86## Disabling certificate revocation checks
88Some SSL backends may do certificate revocation checks (CRL, OCSP, etc)
89depending on the OS or build configuration. The --ssl-no-revoke option was
90introduced in 7.44.0 to disable revocation checking but currently is only
91supported for Schannel (the native Windows SSL library), with an exception
92in the case of Windows' Untrusted Publishers block list which it seems cannot
93be bypassed. This option may have broader support to accommodate other SSL
94backends in the future.
96References:
98https://curl.se/docs/ssl-compared.html
Diagnostics4 git calls · 47 ms
CallStatusSizeTime047 ms
discover200152 B2 ms
git.upload-pack discover
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=ls-refs
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 · hit23 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=3
git.response.bytes=293470
git.response.cache=HIT
git.response.duration_ms=23
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
fetch2001.9 KiB · hit22 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=22
git.response.bytes=1917
git.response.cache=HIT
git.response.duration_ms=22
git.fetch.wants=62f30b4e7bdc09662ae8ea2970a7c30f6f6c7671
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=1917
git.pkt.payload.max=1896
git.sideband.band1.bytes=1895
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
a5e24399bec0cf56
Request
3791a65b…
Protocol
v2 · sha1
Agent
gitty/1.0
Filter
advertised
Fetch
shallow filter sideband-all
Capabilities
agent ls-refs fetch object-format