Skip to content

Add length validation for D-Star network packets#878

Open
BeigeBox wants to merge 1 commit intog4klx:masterfrom
BeigeBox:fix/dstar-network-length
Open

Add length validation for D-Star network packets#878
BeigeBox wants to merge 1 commit intog4klx:masterfrom
BeigeBox:fix/dstar-network-length

Conversation

@BeigeBox
Copy link
Copy Markdown
Contributor

@BeigeBox BeigeBox commented Apr 6, 2026

Security: remotely exploitable out-of-bounds read

Incoming D-Star network UDP packets are accessed at fixed offsets after checking only the 4-byte DSRP header. A crafted short packet passes the header check but causes out-of-bounds reads. Since UDP source addresses are trivially spoofed, the existing source address check does not prevent exploitation.

An attacker who can send UDP packets to the D-Star gateway port can crash MMDVMHost or read adjacent memory contents.

Added minimum length checks for NETWORK_TEXT (34 bytes), NETWORK_HEADER (9 bytes), and NETWORK_DATA (10 bytes).

@g4klx
Copy link
Copy Markdown
Owner

g4klx commented Apr 6, 2026

Should this not also be applied to other modes, and also the gateways?

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.

2 participants