mirror of
https://gitlab.com/openconnect/ocserv.git
synced 2026-08-09 09:51:49 +08:00
main read cookie.data[0] (to select sec_mod_instance_index) before validating the cookie's length. A worker sending an empty cookie unpacks with cookie.data == NULL (protobuf-c "required bytes" semantics), so the read crashed the root main process, tearing down every connected client. Validate cookie.data/len immediately after unpacking, before the first byte is read. handle_auth_cookie_req()'s own later check remains as defense-in-depth. Adds REQ-IPC-018. Signed-off-by: Nikos Mavrogiannopoulos <n.mavrogiannopoulos@gmail.com>