Craton Shield
Changelog
All notable changes to vs-ethernetip-monitor are documented in this file.
[0.7.0]
Security
- Reject
session_handle == 0on any encapsulation command other thanREGISTER_SESSION(0x0065). The reserved sentinel handle is invalid for data-plane traffic per the EtherNet/IP spec; frames carrying it are now denied withAlertCode::UnknownSessionand severityHigh. Previously such frames were silently accepted in permissive mode, allowing an attacker to forgeUnregisterSession,SendRRData, andSendUnitDataagainst the no-session sentinel and bypass per-session controls.REGISTER_SESSIONwith handle0is still processed normally (it is the on-wire norm — the server assigns the real handle in the reply).
Changed
- Session-table LRU eviction now picks the entry with the oldest
last_activity_usrather than the oldestcreated_us, matching the semantics already used byexpire_sessions. Long-running active sessions are no longer evicted in favour of recently idle ones. register_sessionis now single-pass (mirrorsrate_check).- Strict-mode session lookup combines the touch and known-check into a single scan of the session table.
- README corrected: the rate-limit table uses LRU eviction (oldest
bucket dropped, new key admitted), not fail-closed. Use
new_strict()for fail-closed behaviour on unknown sessions or unmatched commands.