Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add tunnel name to config and update masquerade to use tunnel name for custom cli #1646

Open
frankozland opened this issue Aug 20, 2024 · 1 comment

Comments

@frankozland
Copy link

Is your feature request related to a problem?

in config/vpn-providers.json, would it make sense to add a field for the tunnel name?

And then on up set the masquerade to match that cli field?
ie

            "id": 3,
            "name": "NordVPN",
            "bin_path": "/usr/bin/nordvpn",
            "tun_device":"nordlynx",
            "install_page": "https://nordvpn.com/download/linux/",
            "account_page": "https://my.nordaccount.com/dashboard/",
            "cmd_overrides": {
                "log": "status"
            },

so on masquerade step, just pass $tun_device?

iptables -t nat -A POSTROUTING -o $tun_device -j MASQUERADE

This may also be useful for monitoring - if $tun_device disappears from "ip a" the tunnel is dead.

Describe the solution you'd like

masquerade to use the correct tunnel name

Describe alternatives you've considered

manually apply iptables - undesired

Additional context

users are having issues when using cli - masquerade is not forwarding packets thru vpn tunnel

#1562

This may be a very easy/simple win, esp as new vpn tech comes along?

it might make sense to also include wireguard (wg0) and openvpn (tun0) for consistency sake and 1 place to maintain without any other code change. A nice to have would be a place to add additional field to run a user cli command on connect thru raspap, and a place to run a different command on disconnect thru raspap.

Copy link

This issue is stale because it has been open for 30 days with no activity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants