Skip to content

[Tracking] M8 declarative security audit framework #361

@cssbruno

Description

@cssbruno

Umbrella for the M8 declarative, auditable security framework: a single machine- and human-readable security posture, a gowdk audit command that checks it against a baseline and declared policies, frontend audits, and an IR-driven integration-test runner. Designed to be auditable by a human or an LLM, and explicitly anti-magic (the audit never runs as part of gowdk build; every finding cites a code + file:line; severity lives only in the diagnostic registry).

Shipped (slice 1) — PR #360

  • internal/securitymanifest: pure IR-derived posture → gowdk-security.json (routes, endpoints, contracts; guards, CSRF, body limit, public/default-deny, source).
  • internal/auditspec: composable policy model (named policies, extends, route/endpoint/frontend selectors), evaluation engine, and a built-in baseline encoding the security.md production-readiness gates.
  • gowdk audit command (human + --json, non-zero exit on error findings) and build-time emission of gowdk-security.json.
  • Experimental audit_* / policy_* diagnostic codes, gowdk explain-able.

Remaining

Design decisions (locked)

Related

PR #360. Refs #179 (testkit), #182 (features from IR metadata), #120 (CSRF tests), #119 (fail-closed secret). Spec: docs/product/security-audit-spec.md.

Metadata

Metadata

Assignees

No one assigned

    Labels

    diagnosticsDiagnostic codes, spans, and messagesenhancementNew feature or requestsecuritySecurity hardening and security-sensitive behavior

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions