Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

bacnet - fuzz

Send malformed BACnet/IP payloads to a device and report anomalous responses.

Usage

iottack bacnet fuzz --host <HOST> [OPTIONS]

Description

Sends a suite of crafted malformed BACnet/IP packets to the target device and classifies each response as a normal Error/Reject/Abort PDU, an anomalous PDU type or a potential crash indicator. A liveness check runs before and after the payload set. if the device stops responding, a Critical DoS finding is raised.

Based on the mutation strategy from BACteria fuzzer.py.

Payload categories

CategoryDescription
Truncated APDUEmpty, 1-byte, 2-byte Confirmed-Request frames
ReadProperty mutationsMax instance (0x3FFFFF), invalid object type (1023), property ID 0xFFFF, invoke-id 0xFF
Segmentation flagsSEG bit set without segmentation headers, MOR bit set
WritePropertyAttempts to overwrite Device Object Name and AnalogInput:0 Present Value
DeviceCommunicationControlTries to permanently disable device communications
ReinitializeDeviceAttempts cold-start and warm-start restarts
ReadPropertyMultiple ALLRequests all properties in one APDU
Who-Is extremesUnrestricted Who-Is broadcast
BVLC anomaliesWrong function code, length mismatch, broadcast function to unicast, garbage prefix
Boundary APDUs64/256/1024/1025 zero-bytes, all 0xFF

Response classification

Each response is decoded into a descriptive string before pattern matching:

Response typeDescription shown
Simple-ACKbacnet-simple-ack
Complex-ACKbacnet-complex-ack
Error PDUbacnet-error class=N code=N
Reject PDUbacnet-reject reason=N (label)
Abort PDUbacnet-abort reason=N (label)
Malformed BVLCinvalid-bvlc-response
No APDU foundno-apdu-in-response

Patterns flagged as interesting: bacnet-reject, bacnet-abort, overflow (buffer-overflow abort reason), bacnet-unknown, invalid-bvlc, no-apdu, plus any --pattern overrides.

Severity mapping

FindingSeverity
No anomalous responsesInfo
Reject/Abort PDU receivedMedium
Buffer-overflow abort reasonCritical
Device unresponsive after fuzzing (DoS)Critical

Options

FlagShortDefaultDescription
--host <HOST>-H(required)Target BACnet/IP device
--port <PORT>-p47808BACnet/IP UDP port
--timeout-ms <MS>-1000Per-packet response timeout
--iterations <N>-1Times to repeat the full payload set
--delay-ms <MS>-d50Inter-packet delay in ms
--wordlist <PATH>-w-File of additional APDU payloads (one hex or binary line each)
--pattern <STR>--Extra response pattern to flag as interesting
--output <FILE>-o-Save result to a file
--format <FORMAT>-ftexttext or json
--verbose-v-Increase log verbosity

Example

$ iottack bacnet fuzz --host 192.168.1.50 --delay-ms 100

Plugin name:    bacnet/fuzz
Execution time: 42.10 s
Status:         fail
Date:           2025-10-14 00:00:00 UTC

Interesting response to 'reinitialize-coldstart' payload
  192.168.1.50:47808 responded with patterns [bacnet-reject] after receiving the 'reinitialize-coldstart' payload.
  bacnet-reject reason=9 (unrecognized-service)

Interesting response to 'device-comm-control-disable' payload
  192.168.1.50:47808 responded with patterns [bacnet-reject] after receiving the 'device-comm-control-disable' payload.
  bacnet-reject reason=9 (unrecognized-service)

Interesting response to 'apdu-1025-zeros' payload
  192.168.1.50:47808 responded with patterns [bacnet-abort, overflow] after receiving the 'apdu-1025-zeros' payload.
  bacnet-abort reason=1 (buffer-overflow overflow)

Notes

  • Rate limiting: use --delay-ms to avoid overwhelming devices with slow BACnet stacks.
  • DoS risk: reinitialize-coldstart and device-comm-control-disable payloads may disrupt live devices.
  • Wordlist format: each line is treated as raw APDU bytes if the line starts with 0x81 (full packet), otherwise wrapped in a valid BVLC/NPDU unicast frame.