immortalwrt / homeproxy

The modern ImmortalWrt proxy platform for ARM64/AMD64 (powered by sing-box)
GNU General Public License v2.0
532 stars 159 forks source link

suggestion on generator of tun inbound of `sing-box-c.json` #204

Closed evan0greenup closed 3 weeks ago

evan0greenup commented 3 weeks ago

Feature description

For inbound of type of tun, it would be nice to add key-value pair "strict_route": true, add change value of key "auto_route" from false to true.

For better performance, it would be nice set value of key "stack" from "system" to "mixed".

In addition, "inet4_address" key is deprecated, consider to replace it with key "address".

Please reference https://sing-box.sagernet.org/configuration/inbound/tun/

Expected behavior

With strict_route enabled, the issue of IP/DNS leak could be prevented (according to official document suggest).

Additional information

@1715173329 In my previous issue report https://github.com/immortalwrt/homeproxy/issues/202, you said that 3rd party IP leak testing website will report insecurity for promotion their own VPN product.

I understand your concern, However, the points is this website (a foreign website) can accurately tell my local ISP provider name, this is unexpected, and it can definitely indicate that my DNS query for foreign website have leaked to ISP provider.

muink commented 3 weeks ago
  1. leaks can be caused by a variety of activities, including dns, webrtc, stun..., you have to find the issue yourself, and describe the issue in detail.
  2. the value of stack can be manually selected by user. And the tun feature is optional but not required.
  3. address is a feature of SB 1.10, although I wrote part of it.
evan0greenup commented 3 weeks ago

@muink , Is it possible to modify sing-box-c.json and restart sing-box?

I have tried to modify the sing-box-c.json file before, but whenever I restart openwrt, it will reset the sing-box-c.json file. And all my modification disappeared.

How to keep my modification unchanged.

muink commented 3 weeks ago

sing-box-c.json is not operable it is dynamically generated. For additional customization please use bare core.

1715173329 commented 3 weeks ago

It would be nice if you can learn how everything works instead creating issues without understanding the configurations.