1、Go语言驱动:基于纯Go语言开发,使用了quic-go库; 2、兼容性;client包(Go)基于net/http标准库抽象实现; 3、负载均衡:可以在同一个隧道运行多个服务实例; 4、高性能:基于QUIC和HTTP/3实现其功能;
客户端
go get go.flipt.io/reverst/client
go install ./client/...
服务器端
go install ./cmd/...
测试
dagger call test --source=.
1、QUCI隧道监听127.0.0.1:7171; 2、HTTP服务监听127.0.0.1:8181; 3、日志记录设置为debug级别;
go run ./cmd/reverst/... -l debug
-n flipt.dev.local
-g examples/simple/group.yml
-k examples/simple/server.key
-c examples/simple/server.crt
go run ./examples/simple/main.go --username user --password pass
curl -H 'Host: flipt.dev.local' 127.0.0.1:8181/fo
命令行参数选项与环境变量
reverst -h
COMMAND
reverst
USAGE
reverst [FLAGS]
FLAGS
-l, --log LEVEL debug、info、warn或error (默认: INFO)
-a, --tunnel-address STRING 接收隧道QUIC连接的地址 (默认: 127.0.0.1:7171)
-s, --http-address STRING 处理HTTP请求的地址 (默认: 0.0.0.0:8181)
-n, --server-name STRING 通过TLS识别隧道的服务器名称 (必须)
-k, --private-key-path STRING path to TLS private key PEM file (必须)
-c, --certificate-path STRING TLS证书PEM文件路径 (必须)
-g, --tunnel-groups STRING k8s配置映射标识符或文件路径 (默认: groups.yml)
-w, --watch-groups 监控隧道组源以获取更新
--management-address STRING 管理API的HTTP地址
--max-idle-timeout DURATION 连接可以空闲的最长时间 (默认: 1ms)
--keep-alive-period DURATION keep-alive事件间隔时间(默认: 30s)
隧道组配置
reverst -g path/to/configuration.yml
// alternatively:
reverst -g file:///path/to/configuration.yml
reverst -g k8s://configmap/default/tunnelconfig/groups.yml
配置多个身份验证策略
groups:"group-name":hosts:- "some.host.address.dev" # Host for routing inbound HTTP requests to tunnel groupauthentication:basic:username: "user"password: "pass"bearer:token: "some-token"external:scheme: "JWT"endpoint: "http://some-external-endpoint/auth/ext"
原文始发于微信公众号(FreeBuf):Reverst:基于QUIC协议和HTTP3的反向隧道工具
免责声明:文章中涉及的程序(方法)可能带有攻击性,仅供安全研究与教学之用,读者将其信息做其他用途,由读者承担全部法律及连带责任,本站不承担任何法律及连带责任;如有问题可邮件联系(建议使用企业邮箱或有效邮箱,避免邮件被拦截,联系方式见首页),望知悉。
- 左青龙
- 微信扫一扫
-
- 右白虎
- 微信扫一扫
-
评论