Repository navigation
Findings-catalogue fixes, part 4 (low/info items and design notes) - #8
Merged
Merged
Conversation
…onest replay, indexed timestamps Findings-catalogue items, each with a test that fails before the change: - COSMOS-2: CosmosForensicStore read, then upserted, so two writers of one span id could both see it absent and the second replaced the first. It now uses create_item (atomic) and compares only on a conflict; a retried create meets its own identical copy and stays idempotent. - AUTHZ-16: the engine asserted rule.condition outside its fail-closed try, so a broken rule crashed the call instead of denying it, and -O dropped the check. The authorization and gateway asserts are explicit checks. - REPLAY-1: with one parent per span, the walk can only re-enter a span through a duplicate, yet that was reported as a cycle. Duplicates are now reported as duplicates; real cycles still show as unreachable spans. - STORE-2: listing and retention ran json_extract over every span under the store lock. Spans carry an indexed ts column; old databases migrate. - TCD-22: the fake Cosmos container ignored the SQL; it now refuses any query but the one it answers, and has create_item. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…o wasted restore Findings-catalogue items, each with a test that fails before the change: - DOC-1 (and a real defect behind it): both Cosmos builders used the async Azure clients, which need aiohttp, and SENTINEL does not install it. So setting AZURE_COSMOS_ENDPOINT failed at startup with a bare import error; Cosmos persistence could not run. New extra sentinel-prox[cosmos]; without it the error names the extra. The unused duplicate create_cosmos_store (whose docstring promised wiring "in a later phase") is removed. - GW-18: releasing ended sessions reads the SDK's private _server_instances. Losing it meant no releases at all, so every tenant would hit its session cap for good, silently. Now one accessor, an error logged once if it is missing, and a test pinning the SDK attribute. - CM-10: restore guessed each trace's scenario from its user input, which is redacted before storage, so the guess never matched, and it loaded every span of every trace at startup to make it. Removed; the scenario comes from the ownership row. - DCC-23 / GW-20: removed build_web_server and _expected_token (unused); corrected a comment that still said trust is keyed by agent alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…d gauge from data Findings-catalogue items; checked in a browser where noted: - DEMO-04: the before/after baseline always ran the scripted transcript, so with a live model the dashboard compared a model against a script. It now uses the run's driver choice and web mode; the direct client gained list_tools so a live-model driver can run there. Test fails before. - DEMO-09: the kill chain named web_fetch and block-untrusted-origin, and the verdict claimed "the exfiltration would have succeeded", whatever the run did. Both come from the recorded steps now. In a browser, the privilege scenario shows no untrusted input, a clean lineage, and delete_record refused by rule never; the hero names web_fetch. - DEMO-26: the trust gauge hard-coded a threshold of 40. The configured value is in /capabilities (and the trust endpoint) and the dashboard reads it. - DEMO-16: the examples said an external /mcp run appears in the live view; it is listed in the history tab. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CLS-2: the rule-based labels matched only the demo's tool names, so blocks on an operator's own tools were mostly "unclassified". After the existing demo rules, a tool whose name contains a destructive or privileged verb (delete, drop, refund, transfer, exec...) is privilege_escalation, and an outbound one (send, post, upload, webhook...) blocked by authorization or on a tainted lineage is exfiltration. camelCase, snake, kebab and dotted names are split into words. Test fails before the change for four of five cases. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
CM-18: fan-out wakes every subscriber, and each one serialized every event itself (model_dump + json.dumps per subscriber per event). BroadcastEvent now caches its JSON text, so the cost is one serialization per event. Test counts model_dump calls across five subscribers: five before, one after. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- DUR-1: "durably emitted" now says what each store guarantees. - TRUST-5: trust/config.yaml says which events cost trust and which do not. - DEMO-06: the evasion page is written against the local shield's patterns. - DCC-10 (rest): README and cli docstring list the keys sentinel.yaml takes. - TCD-21: a phase-6 test called zero auth "the default posture". - TCD-25: the non-bypassability test covers the proxy's own path only. - TCD-27: the positioning doc claimed "the same class of guarantee" as CaMeL. - PP-15: the union-vs-walk test says what it does and does not prove. - AUTHZ-13: the AST docstring lists boolean literals. - docs/design-notes.md: each finding deliberately left as it is, with why. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ll open Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
1 task done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The remaining low-severity and informational findings from the catalogue. Every behaviour change has a test that fails on the code before it, checked by running it against the old code.
Fixes
aiohttp, so settingAZURE_COSMOS_ENDPOINTfailed at startup. Fixed with a new extra,sentinel-prox[cosmos]; without it the error now says which extra to install.create_item.assertcrashed outside the fail-closed path. Asserts on the authorization and gateway paths are explicit checks.create_item.build_web_serverand_expected_token.Docs
Corrected:
sentinel.yamlaccepts (DCC-10);/mcpruns appear on the dashboard (DEMO-16).New
docs/design-notes.mdrecords every finding deliberately kept as it is, with the reason, plus the one still open: GW-12, a server-side browser session store.Testing
Windows, Python 3.11:
mypy --strict: clean.🤖 Generated with Claude Code