Closed
Description
We are starting to test http3 in our proxies and I found curl doesn't have the same behaviour when printing http_version variable.
When we do it with http/1.1:
$ docker run -it --rm --network test_network $curl curl -sk https://usvc-ingress:1443/nginx_status -o/dev/null -w '%{http_version}\n'
1.1
If we do the same with http/3, it's empty:
$ docker run -it --rm --network test_network $curl curl -sk --http3 https://usvc-ingress:1443/nginx_status -o/dev/null -w '%{http_version}\n'
The request is working fine with http/3:
$ docker run -it --rm --network test_network $curl curl -sk --http3 https://usvc-ingress:1443/nginx_status -i
HTTP/3 200
server: nginx
date: Mon, 29 Nov 2021 15:17:31 GMT
content-type: text/plain
content-length: 97
vary: accept-encoding
alt-svc: h3=":1443"
quic-status: quic
Active connections: 2
server accepts handled requests
9 9 9
Reading: 0 Writing: 1 Waiting: 0
I compiled curl from sources using the versions:
ARG CURL_VERSION=curl-7_80_0
ARG QUICHE_VERSION=0.10.0
From curl -V:
$ docker run -it --rm --network test_network $curl curl -V
curl 7.80.0-DEV (x86_64-pc-linux-gnu) libcurl/7.80.0-DEV BoringSSL nghttp2/1.40.0 quiche/0.10.0
Release-Date: [unreleased]
Protocols: dict file ftp ftps gopher gophers http https imap imaps mqtt pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: alt-svc AsynchDNS HSTS HTTP2 HTTP3 HTTPS-proxy IPv6 Largefile NTLM NTLM_WB SSL UnixSockets