New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
Nyr's Auto Installer for OpenVPN Question
https://github.com/Nyr/openvpn-install
Anyone know how to assign a user a static internal IP (10.x.x.x) so that I can open certain ports for that user.
-A PREROUTING -p tcp -m tcp --dport 13021 -j DNAT --to-destination 10.8.0.14:13021
This is an example of iptables for port forwarding on one of my other openvpn setups. I assign a user the internal ip of 10.8.0.14.
But since Nyr's uses certificate base and not user-pass based I'm not sure how to do it for Nyr's one.
Comments
Generally, I get static IPs for my profiles (10.8.0.2, 10.8.0.3, etc).
Connect the client, get the internal IP and put it in your iptables rule.
Use the commonName of the certificate. See https://community.openvpn.net/openvpn/wiki/Concepts-Addressing#StaticAddressAssignment for configuration instructions.