Skip to content

Add json_file output format (uses json-c)#10

Merged
zakird merged 7 commits intozmap:masterfrom
hdm:feature/add-json-output
Aug 30, 2013
Merged

Add json_file output format (uses json-c)#10
zakird merged 7 commits intozmap:masterfrom
hdm:feature/add-json-output

Conversation

@hdm
Copy link

@hdm hdm commented Aug 17, 2013

Example output for syn-scan:

{ "type": "result", "response-type": "rst", "saddr": "10.222.49.19", "daddr": "192.168.0.4", "proto": "tcp", "sport": 80, "dport": 59284, "seq": 0, "ack": 3135547661, "in_cooldown": 0, "is_repeat": 0, "t": "2013-08-17 14:01:08", "ts": 1376766068, "tm": 472 }

@hdm
Copy link
Author

hdm commented Aug 17, 2013

Merged with master to pick up the UDP probe module and included some output examples below. Currently this decodes both success and failure replies. For the sake of space, it may make sense to expose a configuration parameter that disables failed response output. It seems like the right way to do this is output-module-args, but it would mean defining a format for setting this. Any preference for how output-module-args should be defined or parsed?

Header (first JSON line):

{ "type": "header", "log_level": 3, "target_port": 137, "source_port_first": 32768, "source_port_last": 61000, "max_targets": -1, "max_runtime": 0, "max_results": 0, "iface": "bond0", "rate": 1000, "bandwidth": 0, "cooldown_secs": 8, "senders": 1, "use_seed": 0, "seed": 0, "generator": 0, "packet_streams": 1, "probe_module": "udp", "output_module": "json_file", "probe_args": "file:../examples/udp-probes/netbios_137.pkt", "gw_mac": "00:54:f5:f1:f4:34", "source_ip_first": "192.168.0.4", "source_ip_last": "192.168.0.4", "output_filename": "-", "dryrun": 0, "summary": 0, "quiet": 0, "recv_ready": 0 }

ICMP Unreachable:
{ "type": "result", "response-type": "port-unreach", "saddr": "10.0.0.214", "daddr": "192.168.0.4", "proto": "icmp", "icmp_type": 3, "icmp_code": 13, "in_cooldown": 0, "is_repeat": 0, "t": "2013-08-17 14:55:05", "ts": 1376769305, "tm": 972, "data": "78acc03de0020024a5f1043208004500003800000000f2014e46c1fbf7d6c0a80004030d32a0000000004500004ed4310000f311e1b7c0a80004b32d9ddbc98f0089003a0000", "length": 70 }

UDP Reply:
{ "type": "result", "response-type": "data", "saddr": "192.168.29.151", "daddr": "192.168.0.4", "proto": "udp", "sport": 137, "dport": 42201, "in_cooldown": 0, "is_repeat": 0, "t": "2013-08-17 14:56:58", "ts": 1376769418, "tm": 128, "data": "e5d88400000000010000000020434b41414141414141414141414141414141414141414141414141414141414100002100010000000000650341524e4f4c442020202020202020200004004d53484f4d4520202020202020202000840041524e4f4c44202020202020202020200400001320dd29a400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", "length": 175 }

@zakird zakird merged commit c455d99 into zmap:master Aug 30, 2013
zakird pushed a commit that referenced this pull request Feb 14, 2024
* fist pass at a debian workflow

* Refactored debian workflow into a common bsd/linux yml. Edited Dockerfile

* attempt #2

* attempt #3

* attempt #4

* attempt #5

* attempt #6

* attempt #7

* attempt #8

* attempt #9

* attempt #10, at least we're getting into the debian dockerfile

* Looks like its working, causing a compile error in get_gateway_linux to see if check fails

* Confirmed, debian workflow is working!

* Removed debugging ls in .yml

* testing arch build

* Added fedora test

* testing Gentoo test

* phillip/773: refactored all the github compile actions to be in a single .yml file

* phillip/773: added arch and gentoo Install instructions

* phillip/773: removed extra space in arch.Dockerfile

* phillip/773: apparently the free-bsd vm is picky about having the run being on the same line
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.

2 participants