Skip to content

Commit

Permalink
ipn/wg: m rename var
Browse files Browse the repository at this point in the history
  • Loading branch information
ignoramous committed Nov 5, 2024
1 parent 8081c0e commit 823a91e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions intra/ipn/wg/wgconn.go
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ import (

const maxbindtries = 50
const wgtimeout = 60 * time.Second
const useBepassTrick = false // don't seem to work as of now
const useWarpClientID = true

// github.com/WireGuard/wireguard-go/blob/19ac233cc6/wireguard/device/send.go#L96
var (
Expand Down Expand Up @@ -122,7 +122,7 @@ func NewEndpoint(id string, d connector, ep *multihost.MH, f rwlistener, rb [3]b
connect: d,
mh: ep,
listener: f,
reserved: rb[:3],
reserved: rb[:3], // github.com/bepass-org/warp-plus/blob/19ac233cc6/wiresocks/config.go#L184
floodBa: core.NewKeyedBarrier[int, netip.AddrPort](minFloodInterval),
}
}
Expand Down Expand Up @@ -507,7 +507,7 @@ func (s *StdNetBind) overwriteReserved() bool {
}

func isReservedOverwitten(b []byte) bool {
return useBepassTrick && len(b) > 3 &&
return useWarpClientID && len(b) > 3 &&
(b[1] != 0 || b[2] != 0 || b[3] != 0)
}

Expand Down

1 comment on commit 823a91e

@ignoramous
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.