All Projects → mgrybyk → Node Tunnel

mgrybyk / Node Tunnel

Port forwarding (tunneling) on node.js. Connect to host without public ip easily!

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to Node Tunnel

PSnmap
Svendsen Tech's PowerShell nmap-like port scanner accepting IPv4 CIDR notation
Stars: ✭ 37 (-22.92%)
Mutual labels:  tcp, port
Powershell ipv4portscanner
Powerful asynchronus IPv4 port scanner for PowerShell
Stars: ✭ 117 (+143.75%)
Mutual labels:  tcp, port
knockonports
A port knocking client for Android
Stars: ✭ 25 (-47.92%)
Mutual labels:  tcp, port
Netscanner
netscanner - TCP/UDP scanner to find open or closed ports
Stars: ✭ 191 (+297.92%)
Mutual labels:  tcp, port
Tcptunnel
A simple TCP port forwarder.
Stars: ✭ 259 (+439.58%)
Mutual labels:  tcp, port
Hev Socks5 Server
A simple, lightweight socks5 server for Unix (Linux/BSD/macOS)
Stars: ✭ 33 (-31.25%)
Mutual labels:  tcp
Rf24gateway
TCP/IP (RF24Ethernet) and RF24Network Gateway
Stars: ✭ 36 (-25%)
Mutual labels:  tcp
Wait4x
Wait4X is a cli tool to wait for everything! It can be wait for a port to open or enter to rquested state.
Stars: ✭ 30 (-37.5%)
Mutual labels:  tcp
Phoenix tcp
TCP transport layer for Phoenix
Stars: ✭ 29 (-39.58%)
Mutual labels:  tcp
Media Tutorial
流处理,TCP和UDP,WebRTC和Blob
Stars: ✭ 47 (-2.08%)
Mutual labels:  tcp
Veza
IPC/TCP Networking Utility to connect several processes with great concurrency.
Stars: ✭ 45 (-6.25%)
Mutual labels:  tcp
Cocoaasyncsocket demo
基于AsyncSocket搭建即时通讯体系 . 包含TCP连接 , 消息发送 , 消息接收 , 心跳处理 ,断网重连 , 消息超时 , 消息分发 , 数据库结构设计 , 消息丢失等 . 以及UI设计, 文本表情消息/语音消息/图片消息/视频消息/文件消息/撤回消息/提示语消息的实现思路讲解
Stars: ✭ 981 (+1943.75%)
Mutual labels:  tcp
Mts
Project of Multi-protocol Test Tool opensourced by Ericsson
Stars: ✭ 34 (-29.17%)
Mutual labels:  tcp
Objecttransport
Send and Receive objects over TCP or UDP
Stars: ✭ 39 (-18.75%)
Mutual labels:  tcp
Gensio
A library to abstract stream I/O like serial port, TCP, telnet, UDP, SSL, IPMI SOL, etc.
Stars: ✭ 30 (-37.5%)
Mutual labels:  tcp
Dnsforwarder
Just a DNS utility.
Stars: ✭ 1,029 (+2043.75%)
Mutual labels:  tcp
Emodbus
Modbus library for both RTU and TCP protocols. Primarily developed on and for ESP32 MCUs.
Stars: ✭ 29 (-39.58%)
Mutual labels:  tcp
Anette
Simple haxe network library
Stars: ✭ 35 (-27.08%)
Mutual labels:  tcp
Sundog
A port of the Atari ST game SunDog: Frozen Legacy (1984) by FTL software
Stars: ✭ 42 (-12.5%)
Mutual labels:  port
Godsharp.socket
An easy-to-use .NET socket server and client.
Stars: ✭ 35 (-27.08%)
Mutual labels:  tcp

node-tunnel

NodeJS port forwarding implementation

Allows you to open to forward any custom port (rdp, ssh, proxies, whatever) from machine in some private network (with no public ip) to another machine anywhere else through some server with public ip.

  1. have latest nodejs (8+) and npm
  2. clone repo
  3. npm i

WARN: data is NOT encrypted at the moment, except service messages!

server

install server on machine with public ip create your own configuration in .env file, example:

N_T_SERVER_PORT=32121
N_T_SERVER_PORTS_FROM=32131
N_T_SERVER_PORTS_TO=32141

NOTE: ports specified should be accessible from internet

agent

install agent on machine you want to connect to create your own configuration in .env file, example:

N_T_SERVER_HOST=server-with-public-ip
N_T_SERVER_PORT=32121

N_T_AGENT_NAME=test-rdp
N_T_AGENT_DATA_HOST=localhost
N_T_AGENT_DATA_PORT=3389

or

N_T_SERVER_HOST=server-with-public-ip
N_T_SERVER_PORT=32121

N_T_AGENT_NAME=test-ssh
N_T_AGENT_DATA_HOST=some-machine
N_T_AGENT_DATA_PORT=22

It is better to use long client/agent names for security reasons!

client

install client on your local machine create your own configuration in .env file, example:

N_T_SERVER_HOST=server-with-public-ip
N_T_SERVER_PORT=32121

N_T_CLIENT_NAME=test-rdp
N_T_CLIENT_PORT=1111

or

N_T_SERVER_HOST=server-with-public-ip
N_T_SERVER_PORT=32121

N_T_CLIENT_NAME=test-ssh
N_T_CLIENT_PORT=1112

It is better to use long client/agent names for security reasons!

Finally, to open rdp/ssh connection to machine where agent is installed, connect to localhost:1111 / localhost:1112 with your rdp/ssh client correspondingly

Client port (N_T_CLIENT_PORT) should not be accessible from outside because everyone will access data port opened by agent! If you still want/need it - feel free.

set service messages crypt key (not data!)

All service messages are encrypted with default key using aes128. To change override default key edit .env. file:

N_T_CRYPT_KEY=YOUR_ENCRYPTION_KEY

N_T_CRYPT_KEY should be the same for server, all agents and clients.

data encryption (not implemented yet)

TODO. Currently having problems with buffer length. Once message is encrypted its length increases and single socket message splits to two (or more?) messages. Can't find out the way to join them back properly :(

one more img example :)


NOTE:

you can combine as you want server, agent, client instances. Example: you can have server and client on same machine with public ip.

Client port (N_T_CLIENT_PORT) should not be accessible from outside because everyone will access data port opened by agent! If you still want/need it - feel free.


FAQ

Q: I have public IP according to my provider config, but agent can't connect to server.

A: Multiple issues possible, like: firewalls, your host is connected to router and no virtual server is configured for server ports, etc.

Q: I have no server with public IP, what should I do?

A: You can create any instance where it is possible to run Node.js and open at least two ports, example: https://aws.amazon.com/free/

Q: I have multiple messages on client/agent side "Connection to server established."

A: You have to set same N_T_CRYPT_KEY (IV/ALG) for server and all agents/clients.

Q: Next plans?

A: none at this point...

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].