2023-02-22 16:29:12 +03:00
# Pingtunnel
[<img src="https://img.shields.io/github/license/esrrhs/pingtunnel"> ](https://github.com/esrrhs/pingtunnel )
[<img src="https://img.shields.io/github/languages/top/esrrhs/pingtunnel"> ](https://github.com/esrrhs/pingtunnel )
[![Go Report Card ](https://goreportcard.com/badge/github.com/esrrhs/pingtunnel )](https://goreportcard.com/report/github.com/esrrhs/pingtunnel)
2023-02-22 16:42:13 +03:00
[<img src="https://img.shields.io/github/v/release/esrrhs/pingtunnel"> ](https://github.com/esrrhs/pingtunnel/releases )
2023-02-22 16:36:00 +03:00
[<img src="https://img.shields.io/github/downloads/esrrhs/pingtunnel/total"> ](https://github.com/esrrhs/pingtunnel/releases )
[<img src="https://img.shields.io/docker/pulls/esrrhs/pingtunnel"> ](https://hub.docker.com/repository/docker/esrrhs/pingtunnel )
[<img src="https://img.shields.io/github/actions/workflow/status/esrrhs/pingtunnel/go.yml?branch=master"> ](https://github.com/esrrhs/pingtunnel/actions )
2023-02-22 16:29:12 +03:00
Pingtunnel is a tool that send TCP/UDP traffic over ICMP.
## Note: This tool is only to be used for study and research, do not use it for illegal purposes
![image ](network.jpg )
## Usage
### Install server
- First prepare a server with a public IP, such as EC2 on AWS, assuming the domain name or public IP is www.yourserver.com
- Download the corresponding installation package from [releases ](https://github.com/esrrhs/pingtunnel/releases ), such as pingtunnel_linux64.zip, then decompress and execute with **root** privileges
2023-03-31 08:53:43 +03:00
- “-key” parameter is **int** type, only supports numbers between 0-2147483647
2023-02-22 16:29:12 +03:00
```
sudo wget (link of latest release)
sudo unzip pingtunnel_linux64.zip
sudo ./pingtunnel -type server
```
- (Optional) Disable system default ping
```
echo 1 > /proc/sys/net/ipv4/icmp_echo_ignore_all
```
### Install the client
- Download the corresponding installation package from [releases ](https://github.com/esrrhs/pingtunnel/releases ), such as pingtunnel_windows64.zip, and decompress it
- Then run with **administrator** privileges. The commands corresponding to different forwarding functions are as follows.
- If you see a log of ping pong, the connection is normal
2023-03-31 08:53:43 +03:00
- “-key” parameter is **int** type, only supports numbers between 0-2147483647
2023-02-22 16:29:12 +03:00
#### Forward sock5
```
2023-03-31 08:38:40 +03:00
pingtunnel.exe -type client -l :4455 -s www.yourserver.com -sock5 1
2023-02-22 16:29:12 +03:00
```
#### Forward tcp
```
2023-03-31 08:38:40 +03:00
pingtunnel.exe -type client -l :4455 -s www.yourserver.com -t www.yourserver.com:4455 -tcp 1
2023-02-22 16:29:12 +03:00
```
#### Forward udp
```
2023-03-31 08:38:40 +03:00
pingtunnel.exe -type client -l :4455 -s www.yourserver.com -t www.yourserver.com:4455
2023-02-22 16:29:12 +03:00
```
### Use Docker
It can also be started directly with docker, which is more convenient. Same parameters as above
- server:
```
docker run --name pingtunnel-server -d --privileged --network host --restart=always esrrhs/pingtunnel ./pingtunnel -type server -key 123456
```
- client:
```
2023-04-01 10:48:50 +03:00
docker run --name pingtunnel-client -d --restart=always -p 1080:1080 esrrhs/pingtunnel ./pingtunnel -type client -l :1080 -s www.yourserver.com -sock5 1 -key 123456
2023-02-22 16:29:12 +03:00
```
## Thanks for free JetBrains Open Source license
< img src = "https://resources.jetbrains.com/storage/products/company/brand/logos/GoLand.png" height = "200" / > < / a >