全球灰产交流论坛

 找回密码
 立即注册

QQ登录

只需一步,快速开始

全球云38元起免备案V2EX搬瓦工灰产
SEO查询超级PING网站测速
Virmach特价鸡乌云漏洞吾爱破解
查看: 82|回复: 4

大佬们 lnmp中如何开启http/3

[复制链接]

4

主题

18

回帖

74

积分

注册会员

Rank: 2

积分
74
发表于 2024-10-11 10:25:19 | 显示全部楼层 |阅读模式
20230417
听闻http/3性能优异,lnmp一键包好像说是已经支持http/3了,
那么如何在lnmp中使用http/3
hostloc邀请码购买+tg:@Sendtoae86bot
回复

使用道具 举报

69

主题

3371

回帖

8317

积分

论坛元老

Rank: 8Rank: 8

积分
8317
发表于 2024-10-11 10:27:04 | 显示全部楼层
啊,投毒还没投够嘛?
hostloc邀请码购买+tg:@Sendtoae86bot
回复 支持 反对

使用道具 举报

29

主题

398

回帖

1399

积分

金牌会员

Rank: 6Rank: 6

积分
1399
发表于 2024-10-11 10:27:14 | 显示全部楼层
站点的server块内加入以下内容开启quic
  1. server {
  2.     ...
  3.         listen 443 ssl;
  4.         listen [::]:443 ssl;
  5.         listen 443 quic reuseport;
  6.         listen [::]:443 quic reuseport;
  7.         http2 on;
  8.         add_header Alt-Svc 'h3=":443"; ma=86400';
  9.         quic_retry on;
  10.         ssl_early_data on;
  11.     ...
  12. }
复制代码
hostloc邀请码购买+tg:@Sendtoae86bot
回复 支持 反对

使用道具 举报

4

主题

18

回帖

74

积分

注册会员

Rank: 2

积分
74
 楼主| 发表于 2024-10-11 10:29:33 | 显示全部楼层
小白鸡 发表于 2024-10-11 10:27
啊,投毒还没投够嘛?

啥投毒啊   
hostloc邀请码购买+tg:@Sendtoae86bot
回复 支持 反对

使用道具 举报

9

主题

836

回帖

2151

积分

金牌会员

Rank: 6Rank: 6

积分
2151
发表于 2024-10-11 10:27:00 | 显示全部楼层
first 检查
  1. root@hetzner-fsn1-002:~# nginx -V
  2. nginx version: nginx/1.26.2
  3. built by gcc 13.2.0 (Ubuntu 13.2.0-23ubuntu4)
  4. built with OpenSSL 1.1.1w  11 Sep 2023
  5. TLS SNI support enabled
  6. configure arguments: --user=www --group=www --prefix=/usr/local/nginx --with-http_stub_status_module --with-http_ssl_module --with-http_v2_module --with-http_v3_module --with-http_gzip_static_module --with-http_sub_module --with-stream --with-stream_ssl_module --with-stream_ssl_preread_module --with-http_realip_module --with-openssl=/root/lnmp/src/openssl-1.1.1w --with-openssl-opt=enable-weak-ssl-ciphers --add-module=/root/lnmp/src/ngx-fancyindex-0.5.2
复制代码


然后 conf 设置

  1. server
  2.     {
  3.        #listen 443 ssl http2;
  4.        #listen [::]:443 ssl http2;
  5.         listen 443 ssl;
  6.         listen 443 quic reuseport;
  7.         listen [::]:443 ssl;
  8.         listen [::]:443 quic reuseport;
  9.         server_name yoursite.dev ;
  10.         index index.html index.htm index.php default.html default.htm default.php;
  11.         root  /home/wwwroot/yoursite.dev;
复制代码
hostloc邀请码购买+tg:@Sendtoae86bot
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

展开

QQ|Archiver|手机版|小黑屋|全球灰产交流论坛

GMT+8, 2024-10-26 22:22 , Processed in 0.043467 second(s), 26 queries , Gzip On.

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表