Move code focus

This commit is contained in:
Fangliding
2026-05-25 18:39:42 +08:00
parent 6e044d091c
commit 525969079b
99 changed files with 99 additions and 99 deletions
+1 -1
View File
@@ -29,8 +29,8 @@ Use the following environment variables in Linux to enable a global HTTP proxy f
{
// ...
"protocol": "http",
// [!code focus:10]
"settings": {
// [!code focus:8]
"users": [
{
"user": "my-username",
+1 -1
View File
@@ -14,8 +14,8 @@ The `hysteria protocol` itself has no authentication; `users` only take effect w
{
// ...
"protocol": "hysteria",
// [!code focus:10]
"settings": {
// [!code focus:8]
"version": 2,
"users": [
{
+1 -1
View File
@@ -37,8 +37,8 @@ Under the "none" encryption method, traffic will be transmitted in plain text. T
{
// ...
"protocol": "shadowsocks",
// [!code focus:13]
"settings": {
// [!code focus:11]
"network": "tcp,udp",
"method": "aes-256-gcm",
"password": "114514",
+1 -1
View File
@@ -18,8 +18,8 @@ A more meaningful usage of `Socks` inbound is to listen within a LAN or on the l
{
// ...
"protocol": "socks",
// [!code focus:12]
"settings": {
// [!code focus:10]
"auth": "noauth",
"users": [
{
+1 -1
View File
@@ -16,8 +16,8 @@ Trojan is designed to work over correctly configured encrypted TLS tunnels.
{
// ...
"protocol": "trojan",
// [!code focus:14]
"settings": {
// [!code focus:12]
"users": [
{
"password": "password",
+1 -1
View File
@@ -14,8 +14,8 @@ On Android, the TUN FD must be passed in from an external app, which uses VPN Se
{
// ...
"protocol": "tun",
// [!code focus:9]
"settings": {
// [!code focus:7]
"name": "xray0",
"mtu": 1500,
"gateway": ["10.0.0.1/16", "fc00::1/64"],
+1 -1
View File
@@ -12,8 +12,8 @@ Tunnel, formerly known as dokodemo-door (Arbitrary Door), can listen on multiple
{
// ...
"protocol": "tunnel",
// [!code focus:12]
"settings": {
// [!code focus:10]
"allowedNetwork": "tcp",
"rewriteAddress": "8.8.8.8",
"rewritePort": 53,
+1 -1
View File
@@ -14,8 +14,8 @@ Unlike [VMess](./vmess.md), VLESS does not depend on system time. The authentica
{
// ...
"protocol": "vless",
// [!code focus:17]
"settings": {
// [!code focus:15]
"users": [
{
"id": "5783a3e7-e373-51cd-8642-c83782b807c5",
+1 -1
View File
@@ -16,8 +16,8 @@ VMess depends on system time. Please ensure that the system UTC time of the devi
{
// ...
"protocol": "vmess",
// [!code focus:12]
"settings": {
// [!code focus:10]
"users": [
{
"id": "5783a3e7-e373-51cd-8642-c83782b807c5",
+1 -1
View File
@@ -16,8 +16,8 @@ User-space WireGuard protocol implementation.
{
// ...
"protocol": "wireguard",
// [!code focus:10]
"settings": {
// [!code focus:8]
"secretKey": "PRIVATE_KEY",
"peers": [
{
+1 -1
View File
@@ -12,8 +12,8 @@ Blackhole is an outbound data protocol that blocks all outbound data. When used
{
// ...
"protocol": "blackhole",
// [!code focus:5]
"settings": {
// [!code focus:3]
"response": {
"type": "none"
}
+1 -1
View File
@@ -16,8 +16,8 @@ It can allow queries to the target DNS server, `hijack` them to the built-in [DN
{
// ...
"protocol": "dns",
// [!code focus:17]
"settings": {
// [!code focus:15]
"rewriteNetwork": "udp",
"rewriteAddress": "1.1.1.1",
"rewritePort": 53,
+1 -1
View File
@@ -16,8 +16,8 @@ This outbound has a default safety policy in server-side and reverse-proxy scena
{
// ...
"protocol": "freedom",
// [!code focus:29]
"settings": {
// [!code focus:27]
"domainStrategy": "AsIs",
"redirect": "127.0.0.1:3366",
"userLevel": 0,
+1 -1
View File
@@ -20,8 +20,8 @@ HTTP protocol.
{
// ...
"protocol": "http",
// [!code focus:12]
"settings": {
// [!code focus:10]
"address": "192.168.108.1",
"port": 3128,
"user": "my-username",
+1 -1
View File
@@ -18,8 +18,8 @@ The `hysteria protocol` itself has no authentication. When using with a non `hys
{
// ...
"protocol": "hysteria",
// [!code focus:5]
"settings": {
// [!code focus:3]
"version": 2,
"address": "192.168.108.1",
"port": 3128
+1 -1
View File
@@ -12,8 +12,8 @@ Loopback is an outbound data protocol. Its function is to re-inject data sent th
{
// ...
"protocol": "loopback",
// [!code focus:3]
"settings": {
// [!code focus:1]
"inboundTag": "TagUseAsInbound"
}
}
+1 -1
View File
@@ -37,8 +37,8 @@ Under the "none" encryption method, traffic will be transmitted in plain text. T
{
// ...
"protocol": "shadowsocks",
// [!code focus:10]
"settings": {
// [!code focus:8]
"email": "love@xray.com",
"address": "127.0.0.1",
"port": 1234,
+1 -1
View File
@@ -16,8 +16,8 @@ Standard Socks protocol implementation, compatible with Socks 5.
{
// ...
"protocol": "socks",
// [!code focus:8]
"settings": {
// [!code focus:6]
"address": "127.0.0.1",
"port": 1234,
"user": "test user",
+1 -1
View File
@@ -16,8 +16,8 @@ Trojan is designed to work over a correctly configured encrypted TLS tunnel.
{
// ...
"protocol": "trojan",
// [!code focus:7]
"settings": {
// [!code focus:5]
"address": "127.0.0.1",
"port": 1234,
"password": "password",
+1 -1
View File
@@ -14,8 +14,8 @@ Unlike [VMess](./vmess.md), VLESS does not depend on system time. The authentica
{
// ...
"protocol": "vless",
// [!code focus:9]
"settings": {
// [!code focus:7]
"address": "example.com",
"port": 443,
"id": "5783a3e7-e373-51cd-8642-c83782b807c5",
+1 -1
View File
@@ -16,8 +16,8 @@ VMess depends on system time. Please ensure that the UTC time of the system runn
{
// ...
"protocol": "vmess",
// [!code focus:8]
"settings": {
// [!code focus:6]
"address": "127.0.0.1",
"port": 37192,
"id": "5783a3e7-e373-51cd-8642-c83782b807c5",
+1 -1
View File
@@ -16,8 +16,8 @@ Standard Wireguard protocol implementation.
{
// ...
"protocol": "wireguard",
// [!code focus:20]
"settings": {
// [!code focus:18]
"secretKey": "PRIVATE_KEY",
"address": [
// optional, default ["10.0.0.1", "fd59:7153:2388:b5fd:0000:0000:0000:0001"]
+1 -1
View File
@@ -24,8 +24,8 @@ For direct outbounds such as [Freedom](./outbounds/freedom.md), the peer is usua
"outbounds": [
{
// ...
// [!code focus:18]
"streamSettings": {
// [!code focus:16]
// Transport methods
"network": "raw",
"rawSettings": {},
+1 -1
View File
@@ -15,8 +15,8 @@ It can be used for multiple kinds of TCP and UDP camouflage, as well as QUIC-rel
{
// ...
"streamSettings": {
// [!code focus:33]
"finalmask": {
// [!code focus:31]
"tcp": [
{
"type": "",
+1 -1
View File
@@ -45,8 +45,8 @@ If you are using fallback, please note the following:
// ...
"streamSettings": {
"network": "grpc",
// [!code focus:10]
"grpcSettings": {
// [!code focus:8]
"authority": "grpc.example.com",
"serviceName": "name",
"multiMode": false,
+1 -1
View File
@@ -19,8 +19,8 @@ Its design is not recommended for standalone use; instead, it is intended to wor
// ...
"streamSettings": {
"network": "httpupgrade",
// [!code focus:8]
"httpupgradeSettings": {
// [!code focus:6]
"acceptProxyProtocol": false,
"path": "/",
"host": "xray.com",
+1 -1
View File
@@ -14,8 +14,8 @@ Xray implementation of the underlying QUIC transport for Hysteria2, typically us
// ...
"streamSettings": {
"network": "hysteria",
// [!code focus:17]
"hysteriaSettings": {
// [!code focus:15]
"version": 2,
"auth": "password",
"udpIdleTimeout": 60,
+1 -1
View File
@@ -20,8 +20,8 @@ Please ensure that the firewall configuration on the host is correct.
// ...
"streamSettings": {
"network": "mkcp",
// [!code focus:9]
"kcpSettings": {
// [!code focus:7]
"mtu": 1350,
"tti": 20,
"uplinkCapacity": 5,
+1 -1
View File
@@ -16,8 +16,8 @@ It can be combined with various protocols in multiple modes.
// ...
"streamSettings": {
"network": "raw",
// [!code focus:6]
"rawSettings": {
// [!code focus:4]
"acceptProxyProtocol": false,
"header": {
"type": "none"
+1 -1
View File
@@ -26,8 +26,8 @@ For more information, see the [REALITY project](https://github.com/XTLS/REALITY)
// ...
"streamSettings": {
"security": "reality",
// [!code focus:30]
"realitySettings": {
// [!code focus:28]
// Inbound (server-side) settings
"show": false,
"target": "example.com:443",
+1 -1
View File
@@ -15,8 +15,8 @@ It can be used to tune transparent proxying, DNS resolution strategy, and many o
{
// ...
"streamSettings": {
// [!code focus:21]
"sockopt": {
// [!code focus:19]
"mark": 0,
"tcpMaxSeg": 1440,
"tcpFastOpen": false,
+1 -1
View File
@@ -18,8 +18,8 @@ It supports use with the `RAW`, `XHTTP`, `mKCP`, `gRPC`, `WebSocket`, `HTTPUpgra
// ...
"streamSettings": {
"security": "tls",
// [!code focus:20]
"tlsSettings": {
// [!code focus:18]
"serverName": "xray.com",
"verifyPeerCertByName": "",
"rejectUnknownSni": false,
+1 -1
View File
@@ -24,8 +24,8 @@ WebSocket will recognize the `X-Forwarded-For` header in HTTP requests to overwr
// ...
"streamSettings": {
"network": "websocket",
// [!code focus:9]
"wsSettings": {
// [!code focus:7]
"acceptProxyProtocol": false,
"path": "/",
"host": "xray.com",