Coder Social home page Coder Social logo

int2ecall / toht-proxy Goto Github PK

View Code? Open in Web Editor NEW

This project forked from 1lann/toht-proxy

0.0 0.0 0.0 168 KB

TCP over HTTP proxy. Tunnels TCP traffic over the HTTP protocol to bypass corporate/school firewalls. To be used with SSH or OpenVPN to form a tunnel for all your traffic.

License: MIT License

Go 100.00%

toht-proxy's Introduction

TOHT-Proxy

TCP over HTTP proxy. Tunnels TCP traffic over the HTTP protocol to bypass corporate/school firewalls. To be used with SSH or OpenVPN to form a tunnel for all your traffic.

Proudly written in Go (It's cross platform!)

What makes this tunnel unique?

It disguises your TCP traffic as HTTP (in a very hacky manner). This is to circumvent firewalls which strictly only allow valid HTTP that is negotiated by the firewall. This can also be used as a proxy. You have the client running on your computer behind the firewall, and the server running on the server hosting the VPN/SSH services (setting up a loopback), or any other web server that can then proxy it to your server hosting the services.

Ok that was probably a bad explanation, here's an (irl) example for clarity:

  • I can't access my personal server because the whitelisting firewall at my school is blocking it.
  • I can however access Heroku servers.
  • I can set up the server software on Heroku.
  • This will form a tunnel from my computer, to Heroku, then to my personal server.

How do I use it?

  1. Install go on your client machine and server
  2. On your client, download client.go and modify these lines near the top of the file
const proxyDomain = "127.0.0.1:9002"
const port = "8080"

to the domain and port of the server that will be running server.go, and the port you would like to use as the tunnel on the client.

  1. On your server, download server.go and modify these lines near the top of the file
const port = "9002"
const target = "123.44.32.45:22"

to the port the tunnel will be running on (must match proxyDomain port specified in the client), and the target server's IP and port that you would like to channel TCP traffic to. Can be a lookback like 127.0.0.1:22. This will usually be your IP:SSH port or OpenVPN port. Note that this proxy only supports connections to a single port, which is why you should use SSH or OpenVPN to tunnel all of your traffic. 4. Run client.go, and server.go 5. When setting up OpenVPN, change the TCP IP to 127.0.0.1:PORT or when setting up SSH, use ssh [email protected] -p PORT (PORT being defined under client.go's const port)

Limitations

  • Can only tunnel to 1 port on a remote server.
  • Can be quite unreliable as there are many points of failure and connections drop somewhat frequently.
  • Can be very slow to tunnel through multiple servers.

If you are staff member from my school

I intend no harm and I will not mention this to other students. I just wanted to work on a fun challenge and learn more about how networking works.

toht-proxy's People

Contributors

1lann avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.