Skip to content

the simple script for install and running the open connect and make tunnel between two servers

Notifications You must be signed in to change notification settings

mahdiniknejad/open-connect-tunnel

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

A Stable Tunneling Protocol With OpenConnect And Stunnel

** you need two vps for Using the tunnels.
the first vps will be used by the client called mediator server
(your mobile, laptop, or every device in which you can install 
OpenConnect or Cisco Any Connect) and the second one called host will be 
connect to the client server (you have to install OpenConnect in that)

VPS

  • you need 2 virtual private servers with low config as far as one core cpu and 1GB mem is enough for your config
  • your servers need ubuntu 20.04 > version (20.04 is highly recommended)
  • all the server ports should be opened

Usage, First Config the Host server and then config the Mediator server

Host server

  1. (A) set a valid domain (x.x.com) to the ip of the host server ip (cloud flare is highly recommended ,but you have to turn the proxy option off)
  2. you need check that domain is connected correctly (you can do it with simple ping command "ping x.x.com")
  3. switch to the root user
  4. clone the repo on the server
  5. follow the steps
$> cd Host/
$> chmod +x host-install.sh
$> ./host-install.sh
$> Your Valid Domain : x.x.com
$> Your Email Address : [email protected]
$> How Many Connection Each User should Have (number between 1 and 8) ?  : 4
# you need to use chosen port in the mediator server in the next step
$> What is your approprate input port (hint: you will use this from mediator server) : 8888
# you can add a new user with running this script
$> chmod +x new_user.sh
$> ./new_user.sh
$> Username : user1
$> Password : myPassword

Mediator server

  1. (‌B) change the domain dns (x.x.com) to the ip of the mediator server ip (you have to turn the proxy option off or cdn)
  2. you need check that domain is connected correctly (you can do it with simple ping command "ping x.x.com")
  3. switch to the root user
  4. clone the repo on the server
  5. follow the steps
$> cd Mediator/
$> chmod +x mediator-install.sh
$> ./mediator-install.sh
$> What is your host server ip : my.host.ip.address
$> What is your host server input port (you have added this in host config) : 8888

Usage

host: x.x.com
username: user1
password: myPassword

About

the simple script for install and running the open connect and make tunnel between two servers

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages