mirror of
https://github.com/Armored-Dragon/overte.git
synced 2025-03-11 16:13:16 +01:00
Merge pull request #15687 from SimonWalton-HiFi/dissectors-message-limits
Dissectors: Limit message number & position values
This commit is contained in:
commit
6394d14f2a
1 changed files with 11 additions and 2 deletions
|
@ -158,7 +158,13 @@ local packet_types = {
|
|||
}
|
||||
|
||||
local unsourced_packet_types = {
|
||||
["DomainList"] = true
|
||||
["DomainList"] = true,
|
||||
["DomainConnectRequest"] = true,
|
||||
["ICEPing"] = true,
|
||||
["ICEPingReply"] = true,
|
||||
["DomainServerConnectionToken"] = true,
|
||||
["DomainSettingsRequest"] = true,
|
||||
["ICEServerHeartbeatACK"] = true
|
||||
}
|
||||
|
||||
local fragments = {}
|
||||
|
@ -307,7 +313,10 @@ function p_hfudt.dissector(buf, pinfo, tree)
|
|||
|
||||
-- check if we have part of a message that we need to re-assemble
|
||||
-- before it can be dissected
|
||||
if message_bit == 1 and message_position ~= 0 then
|
||||
-- limit array indices to prevent lock-up with arbitrary data
|
||||
if message_bit == 1 and message_position ~= 0 and message_number < 100
|
||||
and message_part_number < 100 then
|
||||
|
||||
if fragments[message_number] == nil then
|
||||
fragments[message_number] = {}
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue