Security
Control what agents can do, encrypt sensitive data, and defend against prompt injection.
Pages
- Approvals and Annotations —
@ApprovalRequired,@Security, per-action gates. - Enforcement —
SecurityEnforcer, access control, audit logging. - Encryption — AES-256-GCM at-rest, envelope encryption.
- Prompt Injection — Detection and mitigation.
- Redaction —
RedactorSPI, default pattern catalog, per-tenant policy dispatch, audit events. - Cost Governance —
CostBudgetper tenant / agent / capability,BudgetStatesnapshots, hierarchical scope rollup, hard-stop / soft-warn / defer policies. - Accountability —
AgentPrincipalverifiable identity,AgentLiabilityRecordaudit trail,AuthorityScopebounds,ReputationLedger,PaymentBrokerfor agent-to-agent settlement. - Sandbox —
SandboxSPI for isolated execution,ProcessSandbox/ContainerSandboxbackends,SandboxPool, per-execute observability events. - Server Hardening —
tnsai-serverHTTP/WS surface: bind policy, Bearer auth, Origin allowlist, per-session capability tokens, workspace allowlist for/api/index. - Code Review Harness —
CodeReviewPipeline(deepsec pattern),MatcherSpi+ 10 built-in CWE matchers,ReviewAgentSpifor LLM-driven review,FileSystemPipelineStateStore, SARIF / JSON / Markdown exporters.
Validation and Invariants
The Quality module provides multi-agent parallel validation (ParallelValidationExecutor), runtime invariant checking (InvariantChecker), conditional rule evaluation (RuleEngine), and input validation (ValidationService).
Security & Approvals
TnsAI provides a layered security model for agent actions: approval tokens for human-in-the-loop gating, AG-UI interrupts for blocking agent execution until a user responds, input/output guardrails for validation and sanitization, and a declarative @Security annotation that combines audit, access control, and encryption policies in one place.