MCPcopy Create free account
hub / github.com/PierreGode/Ragnar / test_feed_drops_binary_garbage

Function test_feed_drops_binary_garbage

tests/test_irc_dpi.py:111–116  ·  view source on GitHub ↗
(parser)

Source from the content-addressed store, hash-verified

109
110
111def test_feed_drops_binary_garbage(parser):
112 bot_ip, c2_ip = '10.0.0.1', '10.0.0.2'
113 # Binary control chars at the start of a 'line' -> not IRC
114 payload = b'\x00\x01\x02\x03lots of garbage\n'
115 msgs = parser.feed_payload(bot_ip, c2_ip, 1234, 6667, 1.0, payload)
116 assert msgs == []
117
118
119def test_buffer_size_cap_prevents_runaway_growth(parser):

Callers

nothing calls this directly

Calls 1

feed_payloadMethod · 0.80

Tested by

no test coverage detected