Skip to content

Fix UDP receive for binary SIP bodies#132

Merged
yeoleobun merged 1 commit into
mainfrom
codex/udp-binary-body
Jul 6, 2026
Merged

Fix UDP receive for binary SIP bodies#132
yeoleobun merged 1 commit into
mainfrom
codex/udp-binary-body

Conversation

@yeoleobun

Copy link
Copy Markdown
Collaborator

Summary

  • Parse incoming UDP datagrams as SIP message bytes instead of requiring the entire datagram to be valid UTF-8.
  • Keep debug logging readable with lossy UTF-8 rendering.
  • Add a UDP regression test for a SIP MESSAGE carrying a binary application/isup body.

Root cause

UDP receive decoded &buf[..len] with std::str::from_utf8 before parsing. SIP headers are text, but the body is opaque bytes, so valid SIP messages with binary bodies were dropped before reaching the parser.

Validation

  • cargo test transport::tests::test_udp

Fixes #131

@yeoleobun yeoleobun marked this pull request as ready for review July 6, 2026 02:06
@yeoleobun yeoleobun merged commit f0c8575 into main Jul 6, 2026
3 checks passed
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.

UDP transport drops incoming messages with non-UTF-8 (binary) bodies

1 participant