openresty / openresty

High Performance Web Platform Based on Nginx and LuaJIT

Home Page:https://openresty.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

最新版openresty HTTP/3编译成功,要怎么启用配置,网上找的教程都不成功,是有bug吗?怎么配置都还是启用不了HTTP3协议访问

zhiduopc opened this issue · comments

最新版openresty HTTP/3编译成功,要怎么启用配置,网上找的教程都不成功,是有bug吗?怎么配置都还是启用不了HTTP3协议访问

HTTP/3 has no problem in openresty, please refer to https://nginx.org/en/docs/quic.html
I use Debian12 on linode and the test is normal
nginx version: openresty/1.25.3.1rc1
built by gcc 12.2.0 (Debian 12.2.0-14)
built with OpenSSL 1.1.1 (compatible; BoringSSL) (running with BoringSSL)
TLS SNI support enabled
configure arguments: --prefix=/usr/local/openresty/nginx --with-debug --with-cc-opt='-DNGX_LUA_USE_ASSERT -DNGX_LUA_ABORT_AT_PANIC -O2 -I /root/boringssl/include' --add-module=../ngx_devel_kit-0.3.3 --add-module=../echo-nginx-module-0.63 --add-module=../xss-nginx-module-0.06 --add-module=../ngx_coolkit-0.2 --add-module=../set-misc-nginx-module-0.33 --add-module=../form-input-nginx-module-0.12 --add-module=../encrypted-session-nginx-module-0.09 --add-module=../srcache-nginx-module-0.33 --add-module=../ngx_lua-0.10.26rc2 --add-module=../ngx_lua_upstream-0.07 --add-module=../headers-more-nginx-module-0.37rc1 --add-module=../array-var-nginx-module-0.06 --add-module=../memc-nginx-module-0.20rc1 --add-module=../redis2-nginx-module-0.15 --add-module=../redis-nginx-module-0.3.9 --add-module=../rds-json-nginx-module-0.16 --add-module=../rds-csv-nginx-module-0.09 --add-module=../ngx_stream_lua-0.0.14rc1 --with-ld-opt='-Wl,-rpath,/usr/local/openresty/luajit/lib -ljemalloc -Wl,-u,pcre_version -L /root/boringssl/build/ssl -L /root/boringssl/build/crypto' --user=www --group=www --with-http_stub_status_module --with-http_sub_module --with-http_v2_module --with-http_ssl_module --with-http_gzip_static_module --with-http_realip_module --with-http_mp4_module --with-http_v3_module --with-pcre-jit --with-file-aio --with-threads --with-pcre --with-stream --without-pcre2 --with-stream_ssl_module --with-stream_ssl_preread_module
curl --http3 -v https://x.x.x.x/ -k

  • Trying x.x.x.x:443...
  • QUIC cipher selection: TLS_AES_128_GCM_SHA256:TLS_AES_256_GCM_SHA384:TLS_CHACHA20_POLY1305_SHA256:TLS_AES_128_CCM_SHA256
  • Trying x.x.x.x:443...
  • Skipped certificate verification
  • Connected to x.x.x.x (x.x.x.x) port 443
  • using HTTP/3
  • [HTTP/3] [0] OPENED stream for https://x.x.x.x/
  • [HTTP/3] [0] [:method: GET]
  • [HTTP/3] [0] [:scheme: https]
  • [HTTP/3] [0] [:authority: x.x.x.x]
  • [HTTP/3] [0] [:path: /]
  • [HTTP/3] [0] [user-agent: curl/8.5.0]
  • [HTTP/3] [0] [accept: /]

GET / HTTP/3
Host: x.x.x.x
User-Agent: curl/8.5.0
Accept: /

< HTTP/3 200
< server: nginx
< date: Fri, 22 Dec 2023 21:48:54 GMT
< content-type: text/html
< content-length: 116028
< last-modified: Fri, 22 Dec 2023 21:16:26 GMT
< vary: accept-encoding
< etag: "6585fcaa-1c53c"
< alt-svc: h3=":443"; ma=86400
< accept-ranges: bytes

please add --with-http_v3_module option when compiling openresty.