Project description

# openpynA python3 script to easily connect to and switch between, OpenVPN servers hosted by NordVPN. Quickly Connect to the least busy servers (using current data from Nordvpn's website) with lowest latency from you. Find servers in a specific country or even a city. It Tunnels DNS traffic through the VPN which normally (when using OpenVPN with NordVPN) goes through your ISP's DNS (still unencrypted, even if you use a third party) and completely compromises Privacy!

## Features* Automatically connect to least busy, low latency servers in a given country.* Find and connect to servers in a specific city or state.* Uses NordVPN's DNS servers and tunnels DNS queries through the VPN Tunnel.* Use Iptables rules to prevent IP leakage if tunnel breaks (Experimental).* Quickly Connect to any specific server. i.e au10 or us20.* Downloads and Updates (modifications) the latest config files from NordVPN.* Option to run the script in background (openvpn daemon mode).* Options to fine-tune server selection based on "Server Load" or "Ping Latency".* Auto excludes the servers if ping to them fails or if they don't support OpenVPN \ (TCP or UDP depending upon which one you are trying to use).* Finds and displays nord vpn servers (with extra info) in a given country.* Now list and connect to servers with "Peer To Peer" --p2p, "Dedicated IP" --dedicated, "Tor Over VPN" --tor, \"Double VPN" --double, "Anti DDos" --anti-ddos support.* Desktop notification are shown when VPN connects and disconnects. (needs to run without sudo)* Auto retry if [soft,auth-failure] received, auto failover to next best server if connection dies. (not in daemon mode)

## Basic Usage* At minimum, you only need to specify the country-code, default port is TCP-443, If you want to useUDP-1194 instead, use "-u" switch.``` bashopenpyn us -u```* Now, you can also specify a city or state, useful when companies (like Google) lock youraccount if you try to login from an IP that resides in a different physical location.``` bashopenpyn us -a nyopenpyn us --area "new york"```* To enforce Firewall rules to prevent dns leakage, also from ip leakage if tunnel breaks.``` bashopenpyn us -f # (Highly Experimental!) Warning, clears IPtables rules! # (changes are non persistent, simply reboot if having networking issues)```* When using "-f", To allow custom ports (from internal ip ranges, i.e 192.168 or 10.) through the firewall.``` bashsudo openpyn us -f --allow 22 #only accessible from local network```* To quickly connect to a specific server.``` bashopenpyn -s au10```* To list all the Countries and their Country Codes where NordVPN hosts servers.``` bashopenpyn -l```* To find detailed information about the available servers in a given country.``` bashopenpyn -l uk```* To find servers with features like "peer-to-peer", "dedicated ip", "tor over vpn", "double vpn" in all countries or a given country.``` bashopenpyn -l uk --p2popenpyn --list uk --dedicatedopenpyn -l --tor # tor over vpn in all countries```* To find the least loaded 10 NordVPN servers in US that support "peer-to-peer", out of them, connect to one of the top 2 servers that have the lowest latency from you.``` bashopenpyn us -t 10 -T 2 --p2p```* To run the script in background.``` bashopenpyn us -d```* To kill a running openvpn connection.``` bashsudo openpyn -k```* To Flush the iptables and kill any running openvpn connections.``` bashsudo openpyn -x #optionally --allow 22 if using as ssh server```* To Download/Update the latest vpn config files from NordVPN by:``` bashopenpyn --update```