tailscale/util
Irbe Krumina 9bd158cc09
cmd/containerboot,util/linuxfw: create a SNAT rule for dst/src only once, clean up if needed (#13658)
The AddSNATRuleForDst rule was adding a new rule each time it was called including:
- if a rule already existed
- if a rule matching the destination, but with different desired source already existed

This was causing issues especially for the in-progress egress HA proxies work,
where the rules are now refreshed more frequently, so more redundant rules
were being created.

This change:
- only creates the rule if it doesn't already exist
- if a rule for the same dst, but different source is found, delete it
- also ensures that egress proxies refresh firewall rules
if the node's tailnet IP changes

Updates tailscale/tailscale#13406

Signed-off-by: Irbe Krumina <irbe@tailscale.com>
2024-10-03 20:15:00 +01:00
..
cache
cibuild
clientmetric
cloudenv
cmpver
codegen cmd/cloner, cmd/viewer, util/codegen: add support for aliases of cloneable types 2024-08-23 15:43:40 -05:00
cstruct
ctxkey
deephash
dirwalk
dnsname
execqueue
expvarx
fastuuid
goroutines
groupmember
hashx
httphdr
httpm
jsonutil
limiter
lineread
linuxfw cmd/containerboot,util/linuxfw: create a SNAT rule for dst/src only once, clean up if needed (#13658) 2024-10-03 20:15:00 +01:00
lru
mak
multierr
must
nocasemaps
osdiag
osshare
osuser
pidowner
pool
precompress
progresstracking
quarantine
race
racebuild
rands
reload
ringbuffer
set
singleflight
slicesx util/slicesx: add FirstElementEqual and LastElementEqual 2024-09-11 18:36:00 -07:00
syspolicy control/controlclient,posture,util/syspolicy: use predefined syspolicy keys instead of string literals 2024-09-04 15:25:19 -05:00
sysresources
systemd
testenv
topk
truncate
uniq
usermetric util/usermetrics: make usermetrics non-global 2024-09-25 15:57:00 +02:00
vizerror
winutil util/winutil: add GetRegUserString/SetRegUserString accessors for storage and retrieval of string values in HKEY_CURRENT_USER 2024-08-20 08:07:57 -06:00
zstdframe