vless+xhttp+caddy简单配置 #5500
wangziyao318
started this conversation in
Show and tell
Replies: 1 comment 1 reply
-
|
两个问题, 另外我查看官方给出的配置,vless-H2C的配置跟你这个版本很像。参考https://github.com/XTLS/Xray-examples/tree/main/VLESS-HTTP-Caddy/VLESS-H2C-Caddy |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
发现caddy比nginx简单很多,就贴一个基于caddy反代的简单配置,优点是不用管tls证书比较省事,另外客户端可以随便切h2h3,tcp丢包多的线路可以试试udp。不过感觉跟naiveproxy差不多,不知道目前哪种特征更少。
加了个header认证,防止别人主动探测https://example.com/your-xray-path*。
因为用的tls,需要有一个域名,并配置好dns解析指向vps ip。
Caddyfile配置
xray服务端入站
{ "inbounds": [ { "listen": "/dev/shm/xray.sock,0666", "protocol": "vless", "settings": { "clients": [ { "id": "your-uuid" } ], "decryption": "none" }, "streamSettings": { "network": "xhttp", "xhttpSettings": { "host": "", "path": "/your-xray-path", "mode": "auto" } } } ] }xray客户端出站
{ "outbounds": [ { "protocol": "vless", "settings": { "address": "your-vps-ip", "port": 443, "id": "your-uuid", "encryption": "none" } "streamSettings": { "network": "xhttp", "security": "tls", "tlsSettings": { "serverName": "example.com", "alpn": [ "h2" ], "fingerprint": "chrome" }, "xhttpSettings": { "host": "", "path": "/your-xray-path", "mode": "auto", "extra": { "headers": { "x-access-token": "your-auth-token" } } } } } }Beta Was this translation helpful? Give feedback.
All reactions