Behavioral detectors

Sigma answers "does this event match a known pattern". The behavioral layer answers a different question: "is this entity behaving like itself". The fourteen plugins run in imclassify, a C input module. That module has one runInput thread. It is not a stage of the line. mmclassify is the per-message action, after mmwake, for plugins whose delay is 0. None are registered, and the shipped ruleset does not call that action. mmwake writes one entity file per source. imclassify reads those files on its own clock.

Fourteen plugins are registered. Twelve poll every 60 seconds. attack_chain and sequence poll every 300 seconds. A finding deposits on the entity's pheromone slot. That deposit is added to threat_level on a later line, as mesh_bonus (confidence divided by 20000, capped at 0.30). It does not set wake.alert. The host does not write behavioral_signals.

How they run

execution model imclassify.c
  mmwake                 writes /var/log/wake/<source>.entities
       |
       v
  imclassify             one input thread. Not the message path.
       60s               first_seen, temporal, velocity, icmp_tunneling,
                         cross_category, credential_pivot, slow_scan,
                         destination, lateral_movement, data_staging,
                         dns_tunneling, geo_travel
       300s              attack_chain, sequence
                         (they read signals already stored)
       |
       v
  pheromone slot         mesh_bonus on threat_level, cap 0.30
                         wake.alert is not set here

  not in the fourteen    profile (compiled, must not deposit)
                         role_incongruence (a promotion, not a plugin)
                         beaconing (an mmsigma correlation)
One list, two periods. attack_chain and sequence are in the fourteen. They poll stored signals. They are not a second engine after the line is scored.

The fourteen

Registered in g_cyclic_plugins. A missing section in classifiers.toml leaves the detector enabled. The only switch every detector reads is enabled. Quoted strings. Six detectors read no other key. The names below are the plugin names.

DetectorPeriodWhat it detectsKeys, or the compiled testMITRE
first_seen60sA new entity, or one returning after a long absence.return_days=7TA0043, or TA0001 on a return
temporal60sActivity in a historically quiet hour.quiet_ratio=0.10, min_days=3TA0005
velocity60sA counter above mean + k sigma on recent 1h buckets.k=3.0, min_windows=6depends on the counter
icmp_tunneling60sICMP (proto 2), at least 10 messages, average size above 200 or out/in above 2.enabled onlyTA0010, T1095, T1048.003
cross_category60sAt least two categories among auth, network, and app. Then auth failures of at least 5 with any app event (high once the failures reach 20, otherwise medium), network denies of at least 10 with an app success (high), or auth failures of at least 5 with network allows of at least 10 (medium). Reaching 20 failures raises the first pattern from medium to high. 50 is only the confidence divisor on the deny pattern. Neither number is an emit gate.enabled onlyTA0006, TA0005, or TA0008
credential_pivot60sA success on the current record and at least 10 auth failures inside 6 hours.enabled only. The 6 hours and the count of 10 are compiled.TA0006, T1110, T1078
slow_scan60sUnique destinations accumulating while each window stays quiet.dst_threshold=50, min_days=3, max_rate=5.0TA0043, T1046, T1595
destination60sOver 24 hours, a destination with any failure counter and at least three visitors emits shared_target. Fewer than two visitors returns early. The handoff finding cannot fire: failure and success are the whole visitor set or empty, never a split.enabled only. The visitor counts and the 24 hours are compiled.TA0006, T1110
lateral_movement60sFan-out to new destinations, and the brute-force then success then spread shape.fanout_threshold=5TA0007, TA0008, T1021, T1046, T1078
data_staging60sRising egress, egress concentrated on one destination, or a normally inbound entity reversing direction.growth_factor=2.0, trend_ratio=0.65, min_windows=6TA0010, T1041, T1048
dns_tunneling60sOversized queries or an inverted out/in ratio on port 53 or 853. DoT is a separate signal, dot_tunneling.dns_tunnel_whitelist. Average query size 200 is compiled.TA0010, T1071.004, T1048.003
geo_travel60sOne entity in two places too far apart for the elapsed time.max_speed_kmh=900TA0001, T1078
attack_chain300sSeveral MITRE tactics already stored for one entity. Order does not matter. The correlator window is 4 hours, compiled.enabled onlythe finding carries no tactic of its own
sequence300sOrdered steps, a learned cadence that stopped, or a handoff to another entity. Lookback is 6 hours. The handoff window is 1 hour. Both are compiled.enabled onlythe pattern's tactic: TA0010, TA0011, TA0008, TA0005

Why slow-scan needs its own detector

Velocity is a per-window test. An attacker who stays under it every single window is invisible to it, however long they keep going. The two detectors read the same traffic and disagree, which is the point.

slow scan vs per-window rate same traffic, two tests
A slow scan staying under the per-window velocity threshold while accumulating unique destinations Fourteen hourly windows. In the top chart every window's message rate stays well under the velocity threshold, so the velocity detector never fires. In the bottom chart the count of unique destinations accumulates across the same windows and crosses the slow-scan threshold of 50, firing that detector instead. per-window test velocity msgs / window velocity threshold: mean + 3σ Never fires. Every window is under the line. cumulative test slow-scan unique destinations dst_threshold = 50 crosses at window 12 slow scan detected
The rate never moves; only the accumulation does. This is why max_rate=5.0 is an upper bound rather than a floor: a genuinely slow scan is defined partly by being quiet. Illustrative, representative shape.

Not one of the fourteen

profile
Compiled and tested, and not registered in g_cyclic_plugins. It must not deposit. The plugin handle is read-only, so it cannot write entity_profiles. A profile is a prior, not a detector.
role_incongruence
A promotion inside the suppress path, not a plugin. When an entity_profiles row names a class, a signal in that class's profile_forbidden set is promoted. The hot path does not write entity_profiles today, so the promotion matches nothing until a row exists. The host-compromise synthesis (shellcode_on_host, edr_alert) is compiled off.
beaconing
An mmsigma correlation, at line rate, not a plugin. It fires only where a Sigma base rule feeds that correlation. An edge without one has no beacon coverage.
sequence is the detector that can fire because a learned cadence stopped. The other thirteen fire on something that happened.

Known gaps

DoH payload is not this detector
dns_tunneling scores flows on port 53 and port 853. DNS over HTTPS on 443 is ordinary HTTPS at that layer. A beaconing correlation can still see a client that repeats on a cadence. That is not a look inside the HTTPS body.
Beaconing depends on a base rule
Beaconing is a rule-set property. Nothing in imclassify reports that the base rule is missing.
Profile rows match nothing yet
profile_forbidden and profile_suppressions key on entity_profiles.profile_class. No hot-path writer fills that table, so those rows currently match nothing.

The console's detection health report covers the Sigma layer: rules that produced a promoted signal, and rules that fire on too much of the enriched tail.

Output

The host persists the finding. It deposits on the pheromone slot and notes one CLASSIFY reason. It does not write behavioral_signals. A suppressed finding is renamed with a _suppressed suffix, stamped info, and does not deposit. Sequence steps are written to entity_sequences and kept for 168 hours. wake.alert is still mmwake's mark.