Primary Purpose:
Go-p2ptunnel is a TCP tunnel tool that leverages libp2p for establishing encrypted connections without supporting UDP. It ensures secure communication through multi-protocol support.
Key Features:
Multi-Protocol Support: Facilitates communication using QUIC, TCP, WebSocket, and WebTransport.
Encryption: Utilizes the Noise protocol for robust data protection.
NAT Traversal: Enables connections across different network addresses.
Node ID Connectivity: Allows connection without a public IP via node IDs.
Multi-Layer Tunneling: Supports complex tunnel configurations for enhanced security.
Automatic Key Management: Regenerates keys upon deletion, ensuring seamless operation.
Audience & Benefit:
Ideal for developers, system administrators, and security professionals seeking secure TCP communication. It eliminates reliance on central servers, enhancing autonomy and security in network setups.
Installation:
Available via winget, go-p2ptunnel simplifies setup, allowing users to focus on establishing secure connections efficiently.
This description adheres to a professional tone, avoiding any promotional language while clearly outlining the software's capabilities and benefits.
Use libp2p to establish a tcp tunnel (does not support udp), the underlying transmission can be realized using quic, tcp, websocket, webtransport, use the noise protocol to encrypt the transmission, comes with nat, and can be used in multi-layer combinations.
If there is no public network ip, you can use the node id to connect. If there is a situation, directly specify the ip and communication protocol to connect.
The node private key file is in the current directory, the suffix of the file name is .key , the default is user.key , and restarting the program after deletion will automatically create a new node id.
Parameter Description
Field
Type
Description
l
Address
The listening or forwarding address. If the id is not set, the address is forwarded. If it is set, the remote port is mapped to the local address. The default value is 127.0.0.1:10086
id
multiaddr format
connection remote service id
p2p_port
ip port
The port used by p2p is also the port that listens for other nodes to connect. The default is 4001, and it will automatically perform nat, but you may need to perform port mapping.If 0, a random port will be chosen
nodisc
bool
Prohibit broadcasting to improve performance, connecting nodes must use links with ip and port
user
string
specify which local key file to use
update
bool
Update the latest version from GitHub, it will verify the upgrade package signature, sha512
auto_update
bool
auto update
max_peers
int
Maximum number of connections, default 500
socks5
ip
socks5 listens to ip, for example 127.0.0.1:10086, if the l field is empty, use this field
build
go build -trimpath -ldflags="-w -s"
upgrade
./go-p2ptunnel -update
After v0.0.6, the program will automatically update the latest version from GitHub, and verify the sha512 and gpg signature of the file. The gpg signature id is
If using RSA key E1346252ED662364CA37F716189BE79683369DA3 appears, the verification is successful
Service publishing and sharing(todo)
You can publish your service, and after other nodes search for the service name, they can connect and use it. Must be a tcp-based service, udp is not supported yet.
Service naming Protocol of this application + / + Protocol of the service name, if it is not a standard well-known protocol, it is recommended to use a form similar to the package name to avoid service conflicts.
Precautions
Although this application uses end-to-end encryption, it does not guarantee the security of the transmitted data. Please do not use this application to transmit important data.
Since it is a p2p tunnel, this program will connect multiple ip, if you mind, please use frp.
If there are multiple client connections, please increase the maximum number of files on the server, otherwise the number of connections may not be enough.