REDHAT-BUG-2577435: Integer Overflow
A flaw was found in corosync. The membership commit token handler in exec/totemsrp.c copies a received membcommittoken into a fixed-size heap buffer (committokenstorage[40000]) using the full received message length (msglen). checkmembcommittokensanity() only validates lower bounds (minimum header size and space for addrentries) and caps addrentries at PROCESSORCOUNTMAX; it does not reject messages larger than committokenstorage. A crafted commit token with a valid small address list and trailing padding above 40000 bytes can therefore overflow the heap-allocated totemsrpinstance when a node is in MEMBSTATEGATHER and the token matches membership and ring-sequence gates. Over knet, messages can be up to the default 64 KiB netmtu, allowing roughly 24 KiB of attacker-controlled out-of-bounds write. This is distinct from CVE-2026-35091 (incorrect success return on truncated messages) and CVE-2026-81666 (32-bit integer overflow in requiredlen). Impact is heap memory corruption and denial of service of the Corosync daemon; code execution was not demonstrated. Reported via PSIRTSUPT-30664 by Adam Bedard. Upstream maintainer Jan Friesse confirmed the issue and provided a proposed fix that adds an upper-bound length check and moves alloca after the sanity check.
Affected Software
Remediation
Recommended actions to resolve this vulnerability, in priority order.
- Compensating control
In Corosync's exec/totemsrp.c membership commit-token handler, reject messages larger than the 40000-byte commit_token_storage buffer before copying, and move the alloca after the sanity check.