Conghao97's picture tcftrees's picture
ProgramGen release
d086025
|
Raw History Blame Contribute Delete
4.27 kB

Output Formats

Human-readable output (default)

  scanme.nmap.org  scanning top 1000 ports

  2 open tcp ports  1 filtered port  997 closed

  open
    22/tcp
    80/tcp

  filtered
    25/tcp

  svc
    22/tcp  ssh OpenSSH 6.6.1p1 Ubuntu 2ubuntu2.13
    80/tcp  http Apache httpd 2.4.7

  os
    Linux, Ubuntu  (85%)

  ◆ critical  80/tcp  http Apache httpd 2.4.7  17 exploits
    1. Apache + PHP < 5.3.12 / < 5.4.2 - cgi-bin Remote Code Execution
       /opt/homebrew/opt/exploitdb/share/exploitdb/exploits/php/remote/29290.c
    ...
    17 exploits total

Sections, in order:

  1. Header — <target> scanning top <N> ports, where N is the selected port count (all when scanning all 65535 ports) and the protocol matches the scan mode: scanning top 1000 UDP ports with --udp; --both prints one header per protocol (TCP first, then UDP).
  2. Summary counts — open / filtered / closed port totals per protocol.
  3. open — open ports as <port>/<proto> (/tcp or /udp).
  4. filtered — filtered ports, same notation.
  5. svc — detected service per port: <port>/<proto> <service> <version banner>.
  6. os — inferred operating system plus a confidence percentage.
  7. Findings — one block per risky service, prefixed with a risk marker: ◆ critical, ▲ high, ● medium, ○ low, followed by the port, protocol, service and exploit count; then numbered exploit entries as <title> and the local Exploit-DB file path. At most 10 exploits are listed per service, followed by an N exploits total line. When NSE scripts were requested (--script), script results are printed before the exploit findings.

If nothing is open, the scan ends with a WARNING No open ports found line. Progress updates are printed while scanning; they are suppressed by --json.

JSON output (--json)

A pretty-printed JSON object with three top-level keys:

Key Contents
services Array, one entry per open port: port (number), protocol ("tcp" / "udp"), service, product, version (empty strings when undetected)
os null, or { "name", "distro", "confidence", "source" }; confidence is a number out of 100, source records how the guess was obtained
exploits Array, one entry per port with exploit hits: { "port": <service object>, "exploits": [ … ], "risk_score": <number> }; each exploit record is { "title", "url", "cvss", "path" }, cvss possibly null
{
  "services": [
    { "port": 22, "protocol": "tcp", "service": "ssh", "product": "OpenSSH",
      "version": "6.6.1p1 Ubuntu 2ubuntu2.13" },
    { "port": 80, "protocol": "tcp", "service": "http", "product": "Apache httpd",
      "version": "2.4.7" }
  ],
  "os": { "name": "Linux", "distro": "Ubuntu", "confidence": 85.0, "source": "banner" },
  "exploits": [
    {
      "port": { "port": 80, "protocol": "tcp", "service": "http",
                "product": "Apache httpd", "version": "2.4.7" },
      "exploits": [
        { "title": "Apache + PHP < 5.3.12 / < 5.4.2 - cgi-bin Remote Code Execution",
          "url": "https://www.exploit-db.com/exploits/29290/",
          "cvss": null,
          "path": "/opt/homebrew/opt/exploitdb/share/exploitdb/exploits/php/remote/29290.c" }
      ],
      "risk_score": 52.0
    }
  ]
}

Typical queries:

oxscan 192.168.1.1 --json | jq '.services[] | select(.service != "") | .port'
oxscan target.example --json | jq '.exploits[].exploits[].path'
oxscan target.example --json | jq '.os.distro'

With --json, stdout carries only the JSON document: the banner line, the open/filtered/closed summary and the coloured findings blocks are suppressed, so read counts and risk from services and exploits[].risk_score.

Notes

  • Service and version detection runs concurrently per port, so results appear as ports are probed; --threads controls the concurrency.
  • OS information is derived from service banners, with an Nmap OS-detection fallback; the percentage shown is a confidence value, not a certainty.
  • Exploit rows only appear when searchsploit and a local Exploit-DB copy are installed; missing tools are reported as errors instead of findings.