test(opcua): event-queue overflow with the per-folder/Server-object ACL active (#838 item 2)
EventQueueOverflowAclWireTests drives >4096 condition events at a folder notifier item and a Server-object (i=2253) item with Security:Acl enforcement on, a non-publishing client, and a second session reading a node-manager node throughout: - denied (EqA-owned scripted) events interleaved with allowed native ones, under one Lock hold and per-projection: no deadlock, reads stay bounded, deferral peak stays within 2 x (MaxDeferredEventsPerCondition + 1), delivery <= item QueueSize, oldest dropped / newest kept in report order, one EventQueueOverflowEventType published ahead of the survivors (SDK DiscardOldest, Part 4 5.13.1.5), zero denied events delivered; - a grant revoked (state.Apply -> revalidation, re-entering Lock) while a deferred tail waits behind a full folder channel: neither the tail nor later events reach the revoked session's folder or Server-object item; a still-granted session on the same channel receives all of it. Falsified: with enforcement off (and with the revocation removed) all three cases fail. No production defect found. Claude-Session: https://claude.ai/code/session_01GT67AD99zQQqpLCVm3p7xk
This commit is contained in:
@@ -219,7 +219,11 @@ Two things to know before relying on any of this:
|
||||
`ConditionalWeakTable` keyed by the item; cuts clear when the deferral count hits 0. Tests:
|
||||
`ConditionRefreshDeferralWireTests`; folder items keep the residual (SDK channel + memoised verdict). Folder events follow Part 3's shape —
|
||||
`ReceiveEvents` on EventType + SourceNode (SDK check, kept first) AND our decision; non-condition events on a
|
||||
folder item fail closed under enforcement. Tests: `FolderEventFloodWireTests`.
|
||||
folder item fail closed under enforcement. Tests: `FolderEventFloodWireTests`. Overflow WITH the ACL doing work (#838
|
||||
item 2) — denied condition interleaved, folder + `i=2253` items, non-publishing client, concurrent Read, grant revoked
|
||||
while a deferred tail waits — is `EventQueueOverflowAclWireTests`: the item-queue overflow is the SDK's DiscardOldest
|
||||
(newest kept, one `EventQueueOverflowEventType` ahead of the survivors); deferred events are decided at DELIVERY, so a
|
||||
revocation stops the waiting tail; events already in the item queue when a grant is revoked may still publish (authorized when queued).
|
||||
- **ns=0 standard nodes stay ungated by design, even with `Security:Acl:Enabled`** (#617) — `ServerStatus`,
|
||||
`NamespaceArray`, `ServiceLevel` etc. are served by the SDK's core node manager outside our authorizer and
|
||||
clients read them to connect and to judge redundancy health; they carry no plant data. Every raw/UNS node,
|
||||
|
||||
Reference in New Issue
Block a user