RTQ
Independently Verifiable

Security Evidence & Verification

RTQ is experimental security infrastructure (Alpha). We replace marketing assertions with an unbroken evidence chain: Claim → Implementation → Test → CI Run → Platform/Commit.

Pinned Commit: e179d2b·Browse Tree at e179d2b

CI Verification Disclaimer & Status

Green CI indicates that the repository's automated checks passed for a particular commit and environment. It does not constitute an independent security audit, formal mathematical verification, or guarantee that the implementation is free of vulnerabilities.

Rule of Claim Strength: The strength of a security claim must never exceed the strength of its evidence.

Verification Methodology

Every claim in RTQ documentation is tagged with an Evidence Level indicating the rigor of the verification behind it. We never describe a unit test as an OS enforcement proof.

LEVEL 0 — DOCUMENTED DESIGN

Behavior is documented in architecture specifications but is not yet asserted by an automated test.

LEVEL 1 — UNIT TESTED

Isolated in-process logic is asserted by automated unit tests. Does not establish OS kernel containment.

LEVEL 2 — INTEGRATION TESTED

Multiple RTQ pipeline components (registry, policy, ticket store) are exercised together.

LEVEL 3 — REAL OS ENFORCEMENT

Test launches the platform’s actual sandbox mechanism and verifies the OS rejects the tested unauthorized operation.

LEVEL 4 — ADVERSARIAL TESTED

Explicit red-team or bypass payloads (symlink traversal, path tampering, replay) attempt to violate boundary.

LEVEL 5 — INDEPENDENTLY AUDITED

Publicly verifiable audit report by a reputable third-party security firm. (RTQ has NOT yet been audited at Level 5).

12 Security Properties Tested in CI

These 12 standalone checks execute in tests/invariants/invariants.test.ts on every push and scheduled CI run. Below is the complete evidence mapping for each property.

INV-01Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Explicit surface: An unregistered capability is denied (no implicit surface).

Implementationpackages/security/src/index.tsLines 295-301
Automated Testtests/invariants/invariants.test.tsLines 54-62
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

Calling rtq.authorize() with an unregistered capability name returns decision: 'denied' with code 'capability.not_registered'.

Not Established By This Test

Does not prove that registered capability handlers themselves are free of internal logic errors or memory corruption.

INV-02Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Explicit surface: A registered capability requested with the wrong version is denied.

Implementationpackages/security/src/index.tsLines 302-307
Automated Testtests/invariants/invariants.test.tsLines 64-72
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

Version numbers must match registered definitions exactly (integer equality check).

Not Established By This Test

Does not verify schema migration safety or semantic version range compatibility across deployments.

INV-03Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Default-deny policy: No matching policy rule results in a denial, never an allow.

Implementationpackages/policy/src/index.tsLines 365-382
Automated Testtests/invariants/invariants.test.tsLines 74-82
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

When the policy engine evaluates an operation against an empty or non-matching rule set, it yields decision: 'deny'.

Not Established By This Test

Does not prevent human operators from inadvertently authoring overly permissive allow rules.

INV-04Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Authoritative risk: Caller claims to lower risk are ignored; declared risk takes precedence.

Implementationpackages/security/src/index.tsLines 337-347
Automated Testtests/invariants/invariants.test.tsLines 84-112
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

A caller passing metadata.claimedRisk = 'low' for a high-risk capability still triggers approval_required with risk = 'high'.

Not Established By This Test

Does not prove the declared risk rating matches real-world exploitability or side effects of arbitrary commands.

INV-05Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Origin is a hint: Unknown origin is never treated as local and escalates approval requirements.

Implementationpackages/security/src/index.tsLines 320-325
Automated Testtests/invariants/invariants.test.tsLines 114-131
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

An untrusted origin 'unknown' is not granted automatic approval for low-risk capabilities.

Not Established By This Test

Relies on host integration accurately passing caller origin identifiers without spoofing outside RTQ.

INV-06Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Approval strategy defaults: High or critical risk is never automatic.

Implementationpackages/security/src/index.tsLines 437-449
Automated Testtests/invariants/invariants.test.tsLines 133-189
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

Default approval strategy resolution for high or critical risk capabilities rejects automatic execution.

Not Established By This Test

Operators can explicitly override defaults with custom policy rules if configured to do so.

INV-07Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Sandbox network deny-by-default: Generates --unshare-net and rejects unsupported allowlists.

Implementationpackages/sandbox/src/index.tsLines 140-195
Automated Testtests/invariants/invariants.test.tsLines 191-217
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

Verifies bubblewrap command line construction unshares the network namespace and throws if network allowlist cannot be enforced.

Not Established By This Test

This unit check does not execute live network sockets in kernel space (real network blocking is tested in macOS darwin.test.ts).

INV-08Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Sandboxed processes do not inherit ambient secrets matching sensitive key patterns.

Implementationpackages/sandbox/src/index.tsLines 85-125
Automated Testtests/invariants/invariants.test.tsLines 219-243
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

buildSandboxEnvironment() strips environment keys matching 'secret', 'token', and 'API_TOKEN' from child processes.

Not Established By This Test

Does not prevent child processes from reading secrets stored on accessible disk paths or over authorized sockets.

INV-09Commit:e179d2b
LEVEL 2 — INTEGRATION TESTED
Claimed Property

Single-use tickets: The second redemption of an authorization ticket is denied (replay rejection).

Implementationpackages/core/src/ticket-store.tsLines 194-206
Automated Testtests/invariants/invariants.test.tsLines 245-263
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

rtq.execute(ticketId) marks ticket redeemed; subsequent execution attempt with identical ticketId returns ok: false.

Not Established By This Test

Relies on in-memory ticket store state within a single Node.js process; does not establish distributed cluster synchronization.

INV-10Commit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Tickets are replay- and tamper-resistant via HMAC-SHA256 signatures.

Implementationpackages/core/src/ticket-store.tsLines 159-164
Automated Testtests/unit/ticket-store.test.tsLines 70-86
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

Modifying any ticket body attribute causes signature verification to fail prior to redemption.

Not Established By This Test

Assumes the HMAC signing key is kept strictly confidential in host memory and never leaked.

INV-11Commit:e179d2b
LEVEL 2 — INTEGRATION TESTED
Claimed Property

Replacing a capability invalidates its previously issued, outstanding tickets.

Implementationpackages/core/src/ticket-store.tsLines 232-240
Automated Testtests/invariants/invariants.test.tsLines 291-323
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

Bumping capability version causes redemption of tickets issued for the previous version to fail.

Not Established By This Test

Tickets for other unchanged capabilities remain redeemable until their standard expiration timestamp.

INV-12Commit:e179d2b
LEVEL 2 — INTEGRATION TESTED
Claimed Property

Approval substitution is rejected: An approval signed for challenge A cannot authorize challenge B.

Implementationpackages/security/src/index.tsLines 470-520
Automated Testtests/invariants/invariants.test.tsLines 325-380
CI Environmentsecurity.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

Device approval signature bound to challengeId A is rejected when submitted against challengeId B.

Not Established By This Test

Does not protect against an attacker with physical access to an unlocked approval device or compromised private keys.

Operating System Sandbox Evidence

Platform isolation claims are tested on their respective GitHub Actions runner operating systems in .github/workflows/sandbox.yml.

OS-DARWINCommit:e179d2b
LEVEL 3 — REAL OS ENFORCEMENT
Claimed Property

macOS (Apple Seatbelt): Kernel-level Seatbelt sandbox blocks unauthorized filesystem writes and network egress.

Implementationpackages/sandbox/src/index.tsLines 220-280
Automated Testtests/sandbox/darwin.test.tsLines 63-117
CI Environmentsandbox.ymlRunner: macos-15
Tested Behavior (Scope)

Executes /usr/bin/sandbox-exec live on macOS runner; verifies /usr/bin/touch fails to write outside allowed directory and /usr/bin/curl fails egress when network=none.

Not Established By This Test

macOS Seatbelt is deprecated by Apple in modern macOS; this test does not prove resistance against local kernel privilege escalation.

OS-LINUXCommit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Linux (bubblewrap): Generates correct bubblewrap argument vector with namespace unsharing and ro/rw binds.

Implementationpackages/sandbox/src/index.tsLines 130-215
Automated Testtests/sandbox/linux.test.tsLines 38-82
CI Environmentsandbox.ymlRunner: ubuntu-latest
Tested Behavior (Scope)

Verifies argv construction includes --unshare-pid, --unshare-net, --unshare-user, --ro-bind for system dirs, and --bind for writable workspaces.

Not Established By This Test

This test file verifies argument assembly and binary probing; it does not spawn a long-running adversarial rootkit payload in this test suite.

OS-WINDOWSCommit:e179d2b
LEVEL 1 — UNIT TESTED
Claimed Property

Windows (AppContainer): Windows runner script exits 1 on failure and output parser reports sandboxed: false if markers missing.

Automated Testtests/sandbox/windows.test.tsLines 6-92
CI Environmentsandbox.ymlRunner: windows-latest
Tested Behavior (Scope)

Verifies windows-runner.ps1 contains no bypass flags and that parseWindowsRunnerOutput correctly interprets AppContainer job markers.

Not Established By This Test

Does not prove AppContainer integrity tokens prevent Win32 GDI or font driver elevation bugs on Windows.

Honest Security Contract

To maintain rigorous credibility, we separate what is built, what is tested, and what has explicitly not been established.

1. What Is Implemented
  • • Explicit capability registration with JSON Schema checks.
  • • Default-deny policy engine with declarative rules.
  • • Authoritative risk calculation ignoring caller claims.
  • • Single-use HMAC-SHA256 authorization ticket minting and consumption.
  • • macOS Seatbelt profile generator & execution wrapper.
  • • Linux bubblewrap namespace argument generator.
  • • Windows PowerShell AppContainer runner script.
  • • Redacted audit log emitter with HMAC integrity.
2. What Is Tested in CI
  • • 12 automated invariants on ubuntu-latest in tests/invariants.
  • • Replay rejection of consumed tickets (INV-09).
  • • Override rejection of caller risk demotion (INV-04).
  • • Approval substitution rejection (INV-12).
  • • Real macOS Seatbelt file-write and network denial on macos-15 (OS-DARWIN).
  • • Bubblewrap argument construction with namespace unsharing (OS-LINUX).
  • • Windows runner fail-closed script contract (OS-WINDOWS).
3. What Has Not Been Established
  • Independent Security Audit: Not yet audited by third-party firm.
  • Formal Proofs: Automated tests are not mathematical proofs.
  • Compromised Kernel: Kernel rootkits can bypass OS sandboxes.
  • Side-Channel Resistance: No defense against microarchitectural timing leaks.
  • Out-of-Runtime Code: Code executing outside RTQ is unconstrained.
  • Blind Human Approval: Cannot force humans to read what they approve.

Active GitHub Actions Workflows

Workflows run on push to main and on pull requests: