-
-
Notifications
You must be signed in to change notification settings - Fork 532
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[client] Add stateful userspace firewall and remove egress filters #3093
base: main
Are you sure you want to change the base?
Conversation
809d63f
to
8216ab6
Compare
Quality Gate failedFailed conditions See analysis details on SonarQube Cloud Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE |
|
||
// TrackOutbound processes an outbound TCP packet and updates connection state | ||
func (t *TCPTracker) TrackOutbound(srcIP net.IP, dstIP net.IP, srcPort uint16, dstPort uint16, flags uint8) { | ||
t.mutex.Lock() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can apply the locks later, right before touch the map.
// TCPTracker manages TCP connection states | ||
type TCPTracker struct { | ||
connections map[TCPConnKey]*TCPConnTrack | ||
mutex sync.RWMutex |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is RWMutex but it has been used without RW feature
Describe your changes
Issue ticket number and link
Checklist