You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Verify atomic close-on-exec for Redis writer connections #1317
swss-common currently sets FD_CLOEXEC after hiredis connects and before sending AUTH. That leaves a window between socket creation and fcntl(). A concurrent fork in that window can give a child a copy of the descriptor without the flag. Setting it in the parent afterward cannot change the child's copy.
Debian Trixie's hiredis 1.2.0-6 creates Unix and TCP sockets without SOCK_CLOEXEC. The buildimage draft adds the flag at socket creation for Trixie while keeping the existing hiredis ABI. Upstream hiredis added opt-in close-on-exec after the 1.2.0 release. A follow-up PR addresses a collision between the close-on-exec and address-reuse flags.
swss-common follow-up
Once the patched package is available, verify that protected writer connections already have FD_CLOEXEC before AUTH. Coordinate the check with package delivery so existing callers on stock packages keep their current behavior. Cover new connections, copies, worker connections, and reconnects. Confirm on the installed image that the socket is closed across child exec.
Activity