Skip to content

Conversation

@JoTurk
Copy link
Member

@JoTurk JoTurk commented Jan 31, 2026

Description

AV1 RTP packets shouldn't not include obu_size [1], When i rewrote the av1 depacketizer i added validation so if we receive packets with obu_size we would try to validate that this obu_size matches the actual size to reject invalid packets fast, but I guess some clients are so broken that they send obu_size in rtp and also that obu_size is incorrect (someone reported this in Discord), this fix isn't part of any spec packets shouldn't have obu_size anyway, this is more of trying to follow RFC-9413

Be strict when sending and tolerant when receiving.

The AV1 specification allows OBUs to have an optional size field called obu_size (also leb128 encoded), signaled by the obu_has_size_field flag in the OBU header. To minimize overhead, the obu_has_size_field flag SHOULD be set to zero in all OBUs.

@codecov
Copy link

codecov bot commented Jan 31, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 82.59%. Comparing base (438d7da) to head (5a7ea12).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #353      +/-   ##
==========================================
+ Coverage   82.58%   82.59%   +0.01%     
==========================================
  Files          28       28              
  Lines        3428     3430       +2     
==========================================
+ Hits         2831     2833       +2     
  Misses        427      427              
  Partials      170      170              
Flag Coverage Δ
go 82.59% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@JoTurk JoTurk force-pushed the dont-validate-non-spec-obu-size branch 2 times, most recently from 3012431 to 1dd2e53 Compare January 31, 2026 15:30
@JoTurk JoTurk requested a review from FrantaBOT January 31, 2026 15:34
@JoTurk JoTurk force-pushed the dont-validate-non-spec-obu-size branch from 1dd2e53 to 74f0cff Compare January 31, 2026 15:41
@JoTurk JoTurk force-pushed the dont-validate-non-spec-obu-size branch from 74f0cff to 5a7ea12 Compare January 31, 2026 15:47
@JoTurk JoTurk merged commit 5a7ea12 into master Jan 31, 2026
19 checks passed
@JoTurk JoTurk deleted the dont-validate-non-spec-obu-size branch January 31, 2026 15:49
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.

3 participants