bia-pain-bache / BPB-Worker-Panel

A GUI Panel providing Worker subscriptions for VLESS, Trojan and Warp configs alongside chain proxies, offering full DNS, clean IP, Fragment, Warp, Warp pro and routing settings for cross-platform clients using Sing-box, Clash/Mihomo and Xray cores.
GNU General Public License v3.0
5.74k stars 29.68k forks source link

Direct connection to domains, or their proxying [sing-box configuration] #316

Closed X-49 closed 1 month ago

X-49 commented 2 months ago

Attention | توجه

What Happened? | چه اتفاقی افتاده؟

Hello, could you add “Bypass Russia” for Russian users? I did it myself by changing the if (bypassChina) variable with parameters that are appropriate for Russia from meta-rules-dat, but I think it would be useful to have such functionality out of the box.

But more importantly, I have not been able to make a direct connection to certain domains or proxy them with Bypass China (Russia) selected. How can this be realized for sing-box configuration?

I tried to add

if (bypassChina) {
        rules.push({
            rule_set: [“geosite-cn”, “geoip-cn”],
            outbound: “direct”
        },
        {
            domain_suffix: “discord.com”,
            outbound: “direct”
        });

but this trick didn't work, discord.com is still proxied, and I need a direct connection

Please help me to figure this out 🥺🙏

Minimal Reproducible Example | چه پروسه‌ای برای مشاهده این مشکل طی کرده‌اید؟

No response

Relevant log output | لاگ برنامه یا پنل

none
bia-pain-bache commented 1 month ago

Hello, could you add “Bypass Russia” for Russian users? I did it myself by changing the if (bypassChina) variable with parameters that are appropriate for Russia from [meta-rules-dat](https://github.com/MetaCubeX/meta-rules-dat/tree/sing), but I think it would be useful to have such functionality out of the box.

Hi, Maybe in future releases, didn't come to my mind repository has russian users that much ;)

But more importantly, I have not been able to make a direct connection to certain domains or proxy them with Bypass China (Russia) selected. How can this be realized for sing-box configuration?

Please try domain_keyword instead of domain_suffix and let me know if it works, for better configuration it needs to be configured in DNS also. Sing-box > 1.9.0 shoud catch (domain|.+.domain) for domain_suffix, but I don't know why it's not doing the trick.