mirror of
https://github.com/tailscale/tailscale.git
synced 2025-05-06 07:37:38 +00:00
control/controlhttp: set forceNoise443 on Plan 9
Updates #5794 Change-Id: Idc67082f5d367e03540e1a5310db5b466ee03666 Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
parent
7dbb21cae8
commit
4c9b37fa2e
@ -270,6 +270,15 @@ var forceNoise443 = envknob.RegisterBool("TS_FORCE_NOISE_443")
|
||||
// use HTTPS connections as its underlay connection (double crypto). This can
|
||||
// be necessary when networks or middle boxes are messing with port 80.
|
||||
func (d *Dialer) forceNoise443() bool {
|
||||
if runtime.GOOS == "plan9" {
|
||||
// For running demos of Plan 9 in a browser with network relays,
|
||||
// we want to minimize the number of connections we're making.
|
||||
// The main reason to use port 80 is to avoid double crypto
|
||||
// costs server-side but the costs are tiny and number of Plan 9
|
||||
// users doesn't make it worth it. Just disable this and always use
|
||||
// HTTPS for Plan 9. That also reduces some log spam.
|
||||
return true
|
||||
}
|
||||
if forceNoise443() {
|
||||
return true
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user