Coder Social home page Coder Social logo

cns's Introduction

CuteBi Network Server

网络代理服务端, 支持 IPV6,tcpFastOpen,UDP_Over_HttpTunnel(需要配合专门的客户端)

  1. 普通的 CONNECT 代理服务器(暂时不考虑添加普通 http 支持)
  2. 实现与 114DNS 以及腾讯的 dnsPod 一样的 httpDNS 服务端
  3. 配合专门的客户端可以实现 TCP/UDP 全局代理, 目前只有: https://github.com/mmmdbybyd/CLNC

服务端

1. 普通的CONNECT代理服务器(暂时不考虑添加普通http支持)
2. 实现与114DNS以及腾讯的dnsPod一样的httpDNS服务端
3. 支持服务多个端口(通过config.cfg文件中的`listenAddr`指定)

服务端+客户端

1. 使用自己的加密协议加密流量
2. 可伪装为各种HTTP流量
3. 支持UDP_Over_HttpTunnel
4. 使用配置文件替换了命令行参数

BUG 修复

1. 修复了两处在长时连接状态下会自动关闭连接的 BUG

配置文件(config.cfg)

必选参数:
proxyKey                    代理头域, 如: 'Meng'
udpFlag                     udp请求标识, 如: 'httpUDP'
listenAddr                  监听端口, 如: ':80',多个端口如:':80,:443,:520'
udpTimeout                  udp超时时间, 默认: 30s
enableHttpDNS               httpDNS开关, #t则开,#f则关
enableTFO                   tcpFastOpen开关, #t则开,#f则关
可选参数:
password                    加密密码, 没有则不加密
pidPath                     pid文件路径, 没有则不保存

命令行选项

-config-file                指定新的`config.cfg`的文件路径
-daemon                     开启后台运行, 默认开启
-h, --help                  显示帮助

编译

编译前准备:
  • 若您使用的是 windows 系统,则应该将目录中的isNotWin.go文件删除,否则应该将isWin.go文件删除

若 go 版本低于 1.11,请使用命令:

go build -o cns

若 go 版本等于或高于 1.11,请使用命令:

go mod init cns/m
go mod tidy
go build -o cns

使用方法

  1. 非 root 用户:
sudo ./cns
  1. root 用户
./cns

cns's People

Contributors

davidquan111 avatar

Stargazers

 avatar

Watchers

 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.