Lines Matching +full:- +full:- +full:with +full:- +full:nghttp2
1 <!--
4 SPDX-License-Identifier: curl
5 -->
11 [HTTP/3 Explained](https://http3-explained.haxx.se/en/) - the online free
14 [quicwg.org](https://quicwg.org/) - home of the official protocol drafts
22 [quiche](https://github.com/cloudflare/quiche) - **EXPERIMENTAL**
24 [OpenSSL 3.2+ QUIC](https://github.com/openssl/openssl) - **EXPERIMENTAL**
26 [msh3](https://github.com/nibanks/msh3) (with [msquic](https://github.com/microsoft/msquic)) - **EX…
35 master branch using pull-requests, just like ordinary changes.
39 - the used QUIC library needs to consider itself non-beta
40 - it is fine to "leave" individual backends as experimental if necessary
44 Building curl with ngtcp2 involves 3 components: `ngtcp2` itself, `nghttp3` and a QUIC supporting T…
49 ## Build with quictls
52 to use a TLS library that has such APIs and that works with *ngtcp2*.
56 % git clone --depth 1 -b openssl-3.1.4+quic https://github.com/quictls/openssl
58 % ./config enable-tls1_3 --prefix=<somewhere1>
65 % git clone -b v1.1.0 https://github.com/ngtcp2/nghttp3
67 % git submodule update --init
68 % autoreconf -fi
69 % ./configure --prefix=<somewhere2> --enable-lib-only
76 % git clone -b v1.2.0 https://github.com/ngtcp2/ngtcp2
78 % autoreconf -fi
79 …gconfig:<somewhere2>/lib/pkgconfig LDFLAGS="-Wl,-rpath,<somewhere1>/lib" --prefix=<somewhere3> --e…
88 % autoreconf -fi
89 …% LDFLAGS="-Wl,-rpath,<somewhere1>/lib" ./configure --with-openssl=<somewhere1> --with-nghttp3=<so…
93 …r later builds on Linux for x86_64 architecture, substitute all occurrences of "/lib" with "/lib64"
95 ## Build with GnuTLS
99 % git clone --depth 1 https://gitlab.com/gnutls/gnutls.git
102 % ./configure --prefix=<somewhere1>
109 % git clone -b v1.1.0 https://github.com/ngtcp2/nghttp3
111 % git submodule update --init
112 % autoreconf -fi
113 % ./configure --prefix=<somewhere2> --enable-lib-only
120 % git clone -b v1.2.0 https://github.com/ngtcp2/ngtcp2
122 % autoreconf -fi
123 …g:<somewhere2>/lib/pkgconfig LDFLAGS="-Wl,-rpath,<somewhere1>/lib" --prefix=<somewhere3> --enable-…
132 % autoreconf -fi
133 % ./configure --with-gnutls=<somewhere1> --with-nghttp3=<somewhere2> --with-ngtcp2=<somewhere3>
137 ## Build with wolfSSL
143 % autoreconf -fi
144 …% ./configure --prefix=<somewhere1> --enable-quic --enable-session-ticket --enable-earlydata --ena…
151 % git clone -b v1.1.0 https://github.com/ngtcp2/nghttp3
153 % git submodule update --init
154 % autoreconf -fi
155 % ./configure --prefix=<somewhere2> --enable-lib-only
162 % git clone -b v1.2.0 https://github.com/ngtcp2/ngtcp2
164 % autoreconf -fi
165 …g:<somewhere2>/lib/pkgconfig LDFLAGS="-Wl,-rpath,<somewhere1>/lib" --prefix=<somewhere3> --enable-…
174 % autoreconf -fi
175 … % ./configure --with-wolfssl=<somewhere1> --with-nghttp3=<somewhere2> --with-ngtcp2=<somewhere3>
189 % git clone --recursive -b 0.22.0 https://github.com/cloudflare/quiche
191 % cargo build --package quiche --release --features ffi,pkg-config-meta,qlog
192 % ln -s libquiche.so target/release/libquiche.so.0
194 …% ln -vnf $(find target/release -name libcrypto.a -o -name libssl.a) quiche/deps/boringssl/src/lib/
201 % autoreconf -fi
202 …% ./configure LDFLAGS="-Wl,-rpath,$PWD/../quiche/target/release" --with-openssl=$PWD/../quiche/qui…
207 it with `sudo`.
216 % git clone -b openssl-3.3.1 https://github.com/openssl/openssl
218 % ./config enable-tls1_3 --prefix=<somewhere> --libdir=lib
225 % git clone -b v1.1.0 https://github.com/ngtcp2/nghttp3
227 % git submodule update --init
228 % autoreconf -fi
229 % ./configure --prefix=<somewhere2> --enable-lib-only
238 % autoreconf -fi
239 …% LDFLAGS="-Wl,-rpath,<somewhere>/lib" ./configure --with-openssl=<somewhere> --with-openssl-quic …
243 You can build curl with cmake:
248 % cmake . -B bld -DCURL_USE_OPENSSL=ON -DUSE_OPENSSL_QUIC=ON
249 % cmake --build bld
250 % cmake --install bld
253 it with `sudo`.
263 ## Build Linux (with quictls fork of OpenSSL)
267 % git clone -b v0.6.0 --depth 1 --recursive https://github.com/nibanks/msh3
269 % cmake -G 'Unix Makefiles' -DCMAKE_BUILD_TYPE=RelWithDebInfo ..
270 % cmake --build .
271 % cmake --install .
277 % autoreconf -fi
278 % ./configure LDFLAGS="-Wl,-rpath,/usr/local/lib" --with-msh3=/usr/local --with-openssl
288 % git clone -b v0.6.0 --depth 1 --recursive https://github.com/nibanks/msh3
290 % cmake -G 'Visual Studio 17 2022' -DCMAKE_BUILD_TYPE=RelWithDebInfo ..
291 % cmake --build . --config Release
292 % cmake --install . --config Release
294 **Note** - On Windows, Schannel is used for TLS support by default. If you
295 with to use (the quictls fork of) OpenSSL, specify the `-DQUIC_TLS=openssl`
296 option to the generate command above. Also note that OpenSSL brings with it an
300 prompt](../winbuild/README.md#open-a-command-prompt)):
310 …\Program Files\msh3\lib> F:\curl\builds\libcurl-vc-x64-release-dll-ipv6-sspi-schannel-msh3\bin\cur…
312 # `--http3`
316 % curl --http3-only https://example.org:4433/
318 Use HTTP/3 with fallback to HTTP/2 or HTTP/1.1 (see "HTTPS eyeballing" below):
320 % curl --http3 https://example.org:4433/
322 Upgrade via Alt-Svc:
324 % curl --alt-svc altsvc.cache https://curl.se/
326 See this [list of public HTTP/3 servers](https://bagder.github.io/HTTP3-test/)
330 With option `--http3` curl attempts earlier HTTP versions as well should the
336 `--happy-eyeballs-timeout-ms value`. Since HTTP/3 is still relatively new, we
337 decided to use this timeout also for the HTTP eyeballing - with a slight
340 The `happy-eyeballs-timeout-ms` value is the **hard** timeout, meaning after
342 or HTTP/1.1. At half of that value - currently - is the **soft** timeout. The
362 those until one succeeds - just as with all other protocols. If those IP
378 ones. You can easily create huge local files like `truncate -s=8G 8GB` - they
383 document root in `/var/www/html`. Download the 8GB file from apache with `curl
384 localhost/8GB -o dev/null`
386 In this description we setup and run an HTTP/3 reverse-proxy in front of the
398 Get, build and install nghttp2:
400 % git clone https://github.com/nghttp2/nghttp2.git
401 % cd nghttp2
402 % autoreconf -fi
403 …-quictls/lib/pkgconfig:/home/daniel/build-nghttp3/lib/pkgconfig:/home/daniel/build-ngtcp2/lib/pkgc…
411 % $HOME/bin/nghttpx $CERT $CERT --backend=localhost,80 \
412 --frontend="localhost,9443;quic"
419 Create a `Caddyfile` with the following content:
432 You can change the hard-coded response to something more useful by replacing `respond`
433 with `reverse_proxy` or `file_server`, for example: `reverse_proxy localhost:80`