File: test902.lua

package info (click to toggle)
gopacket 1.1.19-6.2
  • links: PTS, VCS
  • area: main
  • in suites: experimental, forky, sid, trixie, trixie-proposed-updates
  • size: 4,692 kB
  • sloc: sh: 293; python: 75; makefile: 4
file content (30 lines) | stat: -rw-r--r-- 705 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
-- prevent wireshark loading this file as a plugin
if not _G['pcapng_test_gen'] then return end


local block = require "blocks"
local input = require "input"


local test = {
    category    = 'difficult',
    description = "idb with binary resolution",
}


local timestamp = UInt64(0x8c0dc032, 0x0000005a)

function test:compile()
    local idb0 = block.IDB(0, input.linktype.ETHERNET, 0, "eth0")
                    :addOption( block.OptionFormat ('if_tsresol', "B", 0x88) )

    self.blocks = {
        block.SHB("my computer", "linux", "pcap_writer.lua")
            :addOption('comment', self.testname),
        idb0,
        block.EPB( idb0, input:getData(1),  timestamp ),
    }
end


return test