The Traffic WatermarkingFramework

An adaptable, scalable and effective framework for active watermarking.

Adaptable

A broad API designed to allow various workflows enables implementing watermarking schemes of all kinds.

User-friendly

Simple configuration with YAML and easy scripting using Lua; Waterfall is designed to make implementation a breeze.

Scalable

Every instance of Waterfall acts as an independent node on the network, allowing for significant scalability.

Write the watermark.Waterfall runs the experiment.

Waterfall separates traffic-watermarking logic from the infrastructure around it. Describe when a scheme should run in YAML, implement its embedder and detector as Lua capsules, and let the runtime handle flow discovery, packet monitoring, traffic actions, timing, peer communication, keys, and correlation.

When matching traffic satisfies a policy trigger, Waterfall starts a dedicated capsule for that flow. Capsules can bind related flows, coordinate across nodes, and submit extracted keys or measurements as structured JSON.

See the configuration model
Configuration
YAML policies and manifests
Execution
Per-flow Lua capsules
Output
Structured JSON correlation

Capsules follow the traffic

Every scheme uses the same flow-aware runtime while exposing the operations appropriate to its role.

Embedding capsule

Shape matching traffic

Load key material and change packet handling under Lua control to encode the watermark a scheme requires.

  • Accept, drop, delay, reinject, or modify packets
  • Schedule actions against the watermark clock
  • Broadcast keys and structured data to peers
Embedding API

Detection capsule

Recover the signal

Observe matching traffic, derive a key or measurement, and send the result to Waterfall's correlation service.

  • Monitor packets, counts, throughput, and RTT
  • Detect burst and silent traffic intervals
  • Submit extracted keys or arbitrary result data
Detection API
detection.luaWaterfall / Lua
local wf = require("waterfall")  -- import waterfall module

local seconds = wf.get_parameter("timeout_s")  -- retrieve parameter defined in policy
local timeout = seconds * wf.SECOND            -- provided constants can be used to create time values

local previous = nil  -- time of last packet
local ipds = {}       -- inter-packet delays

wf.on_packet("measure", "DataFlow", function()  -- runs for each packet
    local now = wf.get_watermark_time()         -- get the current time (relative to watermark start)
    if previous then
        table.insert(ipds, now - previous)      -- save inter-packet delay
    end
    previous = now                              -- update time of last packet
end)

wf.on_timeout("stop", timeout, function ()         -- schedules the timeout
    wf.submit_data("exampleScheme", "ipds", ipds)  -- submit ipds to correlation service
    wf.stop()                                      -- stop the capsule
end)

A focused API for live traffic

Capsule scripts import one module. Configuration and manifests provide experiment values without rebuilding the runtime, while the API exposes the operations schemes need.

Observe
Packets, counters, throughput, intervals, and RTT.
Act
Flow-scoped packet actions for embedding capsules.
Coordinate
Watermark clocks, timers, and peer messaging.
Compose
Bind additional embedding or detection flows.
Compare
Exchange keys and submit structured results.
Browse the complete Lua API

Turn a scheme into a repeatable experiment.

Start with a manifest, a policy, and a Lua file. Keep the API reference beside you as the scheme grows.