Asterisk4Magisk / Xray4Magisk

Xray core with service scripts for Android
386 stars 44 forks source link

软件似乎无法连接上代理 #90

Closed Hypesnocore closed 5 months ago

Hypesnocore commented 1 year ago

按照教程设置完成以后,使用浏览器打开网页,无论是国内还是国外都提示dns错误,但是log里完全没有dns的访问记录。 以下是log记录

Xray 1.8.4 (Xray, Penetrates Everything.) Custom (go1.21.0 android/arm64)
A unified platform for anti-censorship.
2023/10/04 07:55:51 Using confdir from arg: /data/adb/xray/confs/
2023/10/04 07:55:51 [Info] infra/conf/serial: Reading config: /data/adb/xray/confs/base.json
2023/10/04 07:55:51 [Info] infra/conf/serial: Reading config: /data/adb/xray/confs/dns.json
2023/10/04 07:55:51 [Info] infra/conf/serial: Reading config: /data/adb/xray/confs/policy.json
2023/10/04 07:55:51 [Info] infra/conf/serial: Reading config: /data/adb/xray/confs/proxy.json
2023/10/04 07:55:51 [Info] infra/conf/serial: Reading config: /data/adb/xray/confs/routing.json
2023/10/04 07:55:51 [Debug] app/log: Logger started
2023/10/04 07:55:51 [Info] app/dns: DNS: created UDP client initialized for 223.5.5.5:53
2023/10/04 07:55:51 [Info] app/dns: DNS: created Remote DOH client for https://1.1.1.1/dns-query
2023/10/04 07:55:51 [Debug] app/router: MphDomainMatcher is enabled for 20324 domain rule(s)
2023/10/04 07:55:51 [Debug] app/router: MphDomainMatcher is enabled for 65373 domain rule(s)
2023/10/04 07:55:51 [Debug] app/proxyman/inbound: creating stream worker on 0.0.0.0:65535
2023/10/04 07:55:51 [Debug] app/proxyman/inbound: creating stream worker on 127.0.0.1:65534
2023/10/04 07:55:51 [Info] transport/internet/tcp: listening TCP on 0.0.0.0:65535
2023/10/04 07:55:51 [Info] transport/internet/udp: listening UDP on 0.0.0.0:65535
2023/10/04 07:55:51 [Info] transport/internet/tcp: listening TCP on 127.0.0.1:65534
2023/10/04 07:55:51 [Info] transport/internet/udp: listening UDP on 127.0.0.1:65534
2023/10/04 07:55:51 [Warning] core: Xray 1.8.4 started

以下是xrayhelper.yml配置

xrayHelper:
    coreType: xray
    corePath: /data/adb/xray/bin/xray
    coreConfig: /data/adb/xray/confs/
    dataDir: /data/adb/xray/data/
    runDir: /data/adb/xray/run/
    proxyTag: proxy
proxy:
    method: tproxy
    tproxyPort: 65535
    socksPort: 65534
    tunDevice: xtun
    enableIPv6: false
    autoDNSStrategy: true
    mode: whitelist
    pkgList:
        - com.mi.globalbrowser
    apList:
        - wlan+
        - rndis+
clash:
    dnsPort: 65533
    template: /data/adb/xray/clashconfs/template.yaml

以下是base.json

{
    "log": {
        "access": "/data/adb/xray/run/access.log",
        "loglevel": "debug",
        "dnsLog": true
    },
    "inbounds": [
        {
            "tag": "proxy-in",
            "port": 65535,
            "protocol": "dokodemo-door",
            "settings": {
                "network": "udp,tcp",
                "followRedirect": true
            },
            "streamSettings": {
                "sockopt": {
                    "tproxy": "tproxy"
                }
            },
            "sniffing": {
                "enabled": true,
                "destOverride": [
                    "http",
                    "tls",
                    "quic"
                ],
                "metadataOnly": false,
                "routeOnly": true
            }
        },
        {
            "tag": "socks-in",
            "listen": "127.0.0.1",
            "port": 65534,
            "protocol": "socks",
            "settings": {
                "udp": true
            },
            "sniffing": {
                "enabled": true,
                "destOverride": [
                    "http",
                    "tls",
                    "quic"
                ],
                "metadataOnly": false,
                "routeOnly": true
            }
        }
    ]
}