Skip to content

[BUG] Fixed OOB read in ACK payload parsing#3325

Open
mszatmary-netflix wants to merge 1 commit into
Haivision:masterfrom
mszatmary-netflix:fix/ack-oob-read
Open

[BUG] Fixed OOB read in ACK payload parsing#3325
mszatmary-netflix wants to merge 1 commit into
Haivision:masterfrom
mszatmary-netflix:fix/ack-oob-read

Conversation

@mszatmary-netflix
Copy link
Copy Markdown
Contributor

CUDT::processCtrlAckreads twoint32_t` fields out of the control packet
payload without validating its length:

  • ackdata[ACKD_RCVLASTACK] (index 0) is dereferenced up front, OOB for
    0–3 byte payloads.
  • ackdata[ACKD_BUFFERLEFT] (index 3) is dereferenced on the non-lite path,
    OOB for 5–15 byte payloads.

A peer can send an ACK control packet with an arbitrary intermediate
payload length and cause the receiver to read up to 15 bytes past the
allocated packet buffer. The value at index 3 is then assigned into
m_iFlowWindowSize, so the leaked memory directly perturbs send-side
flow control.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant