Raw Config

“Raw Config” supports Xray-core and Hysteria 2.

Please note: The functions on this page require you to be proficient in Xray-core and Hysteria 2. Please use it after reading the relevant documents.

Xray-core Config Reference

Hysteria 2 Full Client Config

Xray-core #

It is recommended that you directly copy the “Xray config File” generated by the App for modification.

You can find the “Xray config File” by following the operation path:

Setting ➡️ Log ➡️ Xray config File.

Inbound #

You must write an inbound, which must meet the following conditions.

  1. listen must be [::1]. Other addresses will cause traffic to not be processed correctly.
  2. port must be a single-digit string format, such as "11024", and cannot be other formats. Other formats will cause read errors. Support setting to "0".
  3. protocol must be socks. Other protocols are not supported.
  4. auth must be noauth.
  5. udp must be true. Setting it to false or not setting it will cause DNS resolution failure.
  6. tag must be socksIn. The app will use protocol and tag to determine whether there is an inbound that meets the conditions.
  7. sniffing is recommended to be turned on, otherwise the diversion function may not work properly.

It is recommended that you use the following template directly.

{
    "inbounds": [
        {
            "listen": "[::1]",
            "port": "11024",
            "protocol": "socks",
            "settings": {
                "auth": "noauth",
                "udp": true
            },
            "tag": "socksIn",
            "sniffing": {
                "enabled": true,
                "destOverride": [
                    "http",
                    "tls",
                    "quic"
                ],
                "domainsExcluded": [
                    "courier.push.apple.com"
                ]
            }
        }
    ]
}

Metrics #

If you need to use the metrics function, please meet the following settings.

{
    "policy": {
        "system": {
        "statsInboundUplink": true,
        "statsInboundDownlink": true,
        "statsOutboundUplink": true,
        "statsOutboundDownlink": true
        }
    },
    "stats": {},
    "metrics": {
        "tag": "metrics",
        "listen": "[::1]:11026"
    }
}

listen supports setting to [::1]:0.

Log #

The access and error fields in log cannot be customized. They will be rewritten to a fixed path when generating the Xray config file.

Routing #

The following two routing rules are used to ensure the normal operation of DNS. Please set them as the first two routing rules.

{
    "routing": {
        "rules": [
            {
                "domainMatcher": "hybrid",
                "inboundTag": [
                    "dnsQuery"
                ],
                "outboundTag": "proxy",
                "ruleTag": "dnsQuery"
            },
            {
                "domainMatcher": "hybrid",
                "port": "53",
                "outboundTag": "dnsOut",
                "ruleTag": "dnsOut"
            }
        ]
    }
}

Extension Fields #

{
    "name": "RawXrayConfig",
    "type": "raw"
}

name, the name of the configuration, used to display in the list.

type, the type of configuration, fixed here as raw. Note that type can be omitted, even if the configuration is wrong, it does not matter, there is no impact.

Hysteria 2 #

It is recommended that you directly copy the “Hysteria 2 config File” generated by the App for modification.

You can find the “Hysteria 2 config File” by following the operation path:

Setting ➡️ Log ➡️ Hysteria 2 config File.

Inbound #

You must write an inbound that meets the following conditions.

  1. listen must be "[::1]:11024". Other addresses will cause traffic to not be processed correctly. Note: The quotation marks here cannot be omitted, otherwise the configuration file cannot be parsed.

It is recommended that you use the following template directly.

socks5:
  listen: "[::1]:11024"

lazy #

It is recommended to enable the lazy ​​mode. Disabling it may cause the VPN to fail to start.

Extension Fields #

name: rawHysteria2Config
type: raw

name, the name of the configuration, used to display in the list.

type, the type of configuration, fixed here as raw. Note that type can be omitted, even if the configuration is wrong, it does not matter, there is no impact.