mirror of
https://github.com/XTLS/Xray-examples.git
synced 2025-06-28 13:16:06 +08:00
61 lines
2.2 KiB
JSON
61 lines
2.2 KiB
JSON
{
|
||
"inbounds": [
|
||
{
|
||
"listen": "0.0.0.0",
|
||
"port": 443, // 可根据实际情况更换端口
|
||
"protocol": "vless",
|
||
"settings": {
|
||
"clients": [
|
||
{
|
||
"id": "", // 长度为 1-30 字节的任意字符串,或执行 xray uuid 生成
|
||
"flow": ""
|
||
}
|
||
],
|
||
"decryption": "none"
|
||
},
|
||
"streamSettings": {
|
||
"network": "xhttp",
|
||
"xhttpSettings": {
|
||
"path": "/yourpath" // 自行设定路径
|
||
},
|
||
"security": "reality",
|
||
"realitySettings": {
|
||
// 此target字段原名为dest,从24.10.31版本开始开始使用新名称。
|
||
// 目标网站最低标准:国外网站,支持 TLSv1.3 与 H2,域名非跳转用(主域名可能被用于跳转到 www)。详见 https://github.com/XTLS/REALITY
|
||
"target": "example.com:443",
|
||
"serverNames": [
|
||
// 客户端可用的 serverName 列表,暂不支持 * 通配符
|
||
// 执行 xray tls ping 目标网站网址,填 "Allowed domains" 的值
|
||
],
|
||
"privateKey": "", // 执行 xray x25519 生成,填 "Private key" 的值
|
||
"shortIds": [ // 客户端可用的 shortId 列表,可用于区分不同的客户端
|
||
// "", // 若有此项,客户端 shortId 可为空
|
||
"00", // 0 到 f,长度为 2 的倍数,长度上限为 16
|
||
"01",
|
||
"02"
|
||
]
|
||
}
|
||
},
|
||
"sniffing": {
|
||
"enabled": true,
|
||
"destOverride": [
|
||
"http",
|
||
"tls",
|
||
"quic"
|
||
]
|
||
}
|
||
}
|
||
],
|
||
"outbounds": [
|
||
{
|
||
"protocol": "freedom",
|
||
"tag": "direct"
|
||
},
|
||
{
|
||
"protocol": "blackhole",
|
||
"tag": "block"
|
||
}
|
||
|
||
]
|
||
}
|