mirror of
https://github.com/Armored-Dragon/overte.git
synced 2025-03-11 16:13:16 +01:00
Fallback for STUN packets
This commit is contained in:
parent
d620d3511f
commit
bffd87b331
1 changed files with 4 additions and 3 deletions
|
@ -167,9 +167,10 @@ local RFC_5389_MAGIC_COOKIE = 0x2112A442
|
|||
|
||||
function p_hfudt.dissector(buf, pinfo, tree)
|
||||
|
||||
-- make sure this isn't a STUN packet - those don't follow HFUDT format
|
||||
-- if pinfo.dst == Address.ip("stun.highfidelity.io") then return end
|
||||
if buf:len() >= 8 and buf(4, 4):uint() == RFC_5389_MAGIC_COOKIE then return end
|
||||
-- make sure this isn't a STUN packet - those don't follow HFUDT format
|
||||
if buf:len() >= 8 and buf(4, 4):uint() == RFC_5389_MAGIC_COOKIE then
|
||||
return 0
|
||||
end
|
||||
|
||||
-- validate that the packet length is at least the minimum control packet size
|
||||
if buf:len() < 4 then return end
|
||||
|
|
Loading…
Reference in a new issue