Versions in this module Expand all Collapse all v1 v1.4.1 Mar 1, 2023 Changes in this version + const ATYPDomain + const ATYPIPv4 + const ATYPIPv6 + var ErrBadRequest = errors.New("bad Request") + var ErrVersion = errors.New("invalid Version") + func ParseAddress(address string) (a byte, addr []byte, port []byte, err error) + type Datagram struct + Atyp byte + Data []byte + DstAddr []byte + DstPort []byte + Frag byte + Rsv []byte + func NewDatagram(atyp byte, dstaddr []byte, dstport []byte, data []byte) *Datagram + func (d *Datagram) Address() string + func (d *Datagram) Bytes() []byte + type Reply struct + Atyp byte + BndAddr []byte + BndPort []byte + Rep byte + Rsv byte + Ver byte + func NewReply(rep byte, atyp byte, bndaddr []byte, bndport []byte) *Reply + func (r *Reply) WriteTo(w io.Writer) (int64, error) + type Request struct + Atyp byte + DstAddr []byte + DstPort []byte + Rsv byte + func NewRequestFrom(r io.Reader) (*Request, error) + func (r *Request) Address() string type Service + func (s *Service) CreateTun(config VpnConfig) (iface *water.Interface) + func (s *Service) NewVpnService(group string) http.Handler + func (s *Service) SetProxyGroup(group string) error + func (s *Service) SetVpnGroup(group string) error + func (s *Service) StartProxy(addr, natAddr, group string) + type UDPExchange struct + ClientAddr *net.UDPAddr + RemoteConn *net.UDPConn + type VpnConfig struct + CIDR string + CIDRv6 string + Group string + Listen string + MTU int + ServerIP string + ServerIPv6 string + type VpnService struct v1.2.6 Oct 21, 2022 v1.2.5 Sep 28, 2022 v1.2.4 Sep 11, 2022 v1.2.3 Sep 6, 2022 v1.2.2 Aug 24, 2022 v1.2.1 Aug 17, 2022 v1.2.0 Jul 28, 2022 v1.1.2 Jul 8, 2022 v1.1.1 Jul 4, 2022 v1.1.0 Jul 1, 2022 Changes in this version + type NetRelay interface + RelayHttpDo func(w http.ResponseWriter, r *http.Request, address boson.Address) + type Service struct + func New(streamer p2p.Streamer, logging logging.Logger, groups []model.ConfigNodeGroup, ...) *Service + func (s *Service) Protocol() p2p.ProtocolSpec + func (s *Service) RelayHttpDo(w http.ResponseWriter, r *http.Request, address boson.Address) + func (s *Service) SendHttp(ctx context.Context, address boson.Address, req pb.RelayHttpReq) (Response pb.RelayHttpResp, err error)