Skip to content

Commit

Permalink
readme: update rootless mode section
Browse files Browse the repository at this point in the history
  • Loading branch information
rkonfj committed Dec 28, 2024
1 parent 4ce25bb commit 5ed8a89
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ pgvpn --peers
### Rootless mode VPN

```sh
pgvpn -s wss://synf.in/pg -4 100.64.0.1/24 --forward tcp://127.0.0.1:80 --forward udp://8.8.8.8:53
pgvpn -s wss://synf.in/pg -4 100.64.0.1/24 --proxy-listen 127.0.0.1:4090 --forward tcp://127.0.0.1:80 --forward udp://8.8.8.8:53
```

### Uses pre-shared secret file instead of OIDC auth
Expand Down
4 changes: 2 additions & 2 deletions README_zh_CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,10 @@ ln -sf /usr/sbin/pgcli /usr/sbin/pgvpn
pgvpn --peers
```

### Rootless mode VPN
### 去 root 权限的 VPN

```sh
pgvpn -s wss://synf.in/pg -4 100.64.0.1/24 --forward tcp://127.0.0.1:80 --forward udp://8.8.8.8:53
pgvpn -s wss://synf.in/pg -4 100.64.0.1/24 --proxy-listen 127.0.0.1:4090 --forward tcp://127.0.0.1:80 --forward udp://8.8.8.8:53
```

### 使用预共享密钥文件代替 OIDC 认证
Expand Down
2 changes: 1 addition & 1 deletion cmd/pgcli/vpn/rootless/proxy.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ func (s *ProxyServer) Start(ctx context.Context, wg *sync.WaitGroup) error {
udpPacketConn.Close()
}()
s.udpListener = &N.UDPListener{PacketConn: udpPacketConn}
slog.Info("[Proxy] Server started", "listen", fmt.Sprintf("tcp+udp://%s", tcpListener.Addr().String()))
slog.Info("[Proxy] Server started", "listen", fmt.Sprintf("tcp+udp://%s", tcpListener.Addr().String()), "protocols", "socks5")
go s.run(tcpListener)
return nil
}
Expand Down

0 comments on commit 5ed8a89

Please sign in to comment.