/client

sock5 netty proxy client

Primary LanguageJavaMIT LicenseMIT

client

sock5 netty proxy client TCP

introduction

This is a cross firewall tool based on sock5 protocol and aes encryption,based on TCP.
This is client and should use with server, which is in my repo.

why I create it

1 Socks5 proxy mostly written in python for historical reason.And I feel tired of python
2 It's a good way to totally understand netty and sock5.
3 I try make the code easy to understand. And you can write your own sock5 proxy if you like
4 The massive use of one tool will make network easy to detect by machine learning. You can customize your own way of transfer data in Encrypt and Descrypt handler.

how it works

The client receives data from browser and data will be encrpted by client.
And then client sends the encrypted data to server.
When server receive the encrypted data, the server will descrypt it and get the real information and transfer the data to its destination.
When server receives the response from destination, it will encrypt the response and transfer it to client.
At last, client descrypts response and send it to browser.

how to use it

1 get client project and server project source code

2 enter the client project,and compile it with maven, usinng command:
maven clean compile

3 find class SecretKeyGenerator in client project,run it. And then SecretKeyGenerator wil print a unique key in the last line. This key is generated for encryption and descryption. The client and server should use th same key.
Copy the key generated by SecretKeyGenerator, and put this key in the right place of config.properties both in client and server project.

4 config other item in config.properties both in client and server projecct .

5 compile both client and server project.
mvn clean compile package

6 find the jar whose name has "jar-with-depenencies".

7 deploy client jar in client computer which usually the pc now we are working on ,use command:
nohup java -jar client-0.0.1-SNAPSHOT-jar-with-dependencies.jar &

8 deploy server jar in server computer which usually a vps outside the firewall,use commmand:
nohup java -jar server-0.0.1-SNAPSHOT-jar-with-dependencies.jar &

9 download SwitchyOmega or other sock5 chrome plugins, and add it to your browser.

10 If you do not want to use it,just find the pid of program,in linux you can use netstat -tlnp,and match the port,and kill it.

##todo 1 add udp support
2 add more encryption methods
3 reduce running memory size (After lonng time running, the memory it uses will increase and may cause memory leak. Much Appreciated if anyone can tell me how to solve it).

thanks

bouncycastle
xtuhcy/socks5-netty
and other open source project.

communication

dadui518@outlook.com