Zum Hauptinhalt springen
tsecurity.de LIVE
Echtzeit-Radar & Feeds
Alle RSS Feeds ➔
👥 Community & Social
•••••••••
Sichere ProgrammierungIMTS 2026: The West's Largest Manufacturing Show Goes Full AI(24.09.2026 um 03:00 Uhr)
••••••••••
Sichere ProgrammierungIMTS 2026: The West's Largest Manufacturing Show Goes Full AI(24.09.2026 um 03:00 Uhr)
•
Intelligence View
⚡ tsecurity.de Intelligence

How I Set Up Codex for Spec-Driven Development

I wanted Codex to feel like a reliable teammate, not a fast autocomplete that occasionally rewrites half my repo. The shift that worked for me was simple: No approved spec, no code changes. This post is my real setup flow based on my…

0
↗ Quelle (dev.to)
Reagiere als Erste:r — dein Feedback zählt!

I wanted Codex to feel like a reliable teammate, not a fast autocomplete that occasionally rewrites half my repo.



The shift that worked for me was simple:




No approved spec, no code changes.




This post is my real setup flow based on my init.md blueprint in spec-driven-template-codex, plus how I actually use it day to day when building features.






The System in One Flow






User request
|
v
spec-architect drafts task spec
|
v
human approval gate
|
v
agent-router picks specialist
|
v
specialist implements inside scope_in only
|
v
validation (npm run verify)
|
v
commit with spec deletion + evidence
|
v
full-branch PR review






This ordering matters more than any individual prompt trick.






What I Build First in a New Repo



My init.md breaks setup into explicit tasks. In practice, I treat them as six foundation layers.






1) Project Standard Files (CODEX.md + AGENTS.md)



I keep two top-level files:





  • CODEX.md is the canonical contract.


  • AGENTS.md is the loader that tells Codex to follow that contract.



CODEX.md carries the rules that I do not want to renegotiate per session:




  • command list (dev, build, lint, verify)

  • architecture boundaries

  • domain routing table

  • commit policy

  • the hard workflow gates



I keep this file direct and non-negotiable. If a rule is optional, I remove it.






2) Behavioral Blueprint in .codex/WORKFLOW.md



This file is where behavior is encoded, not implied.



My key block is:




  • first principle: never implement without an approved spec

  • spec-first gate on every request

  • architect mode when no spec exists

  • mandatory subagent chain (spec-architect -> agent-router -> specialist)

  • model enforcement (model + model_reasoning_effort on every agent)

  • evidence gate tied to deleted specs



I use .codex/STRATEGY.md as the stable "why" and .codex/WORKFLOW.md as the executable "how".






3) Agent Topology in .codex/agents/*.toml



I split responsibilities so one agent is not making every decision end-to-end.



Core agents:





  • spec-architect: plans and drafts specs only


  • agent-router: reads approved specs and dispatches

  • domain specialists: implement only in scope_in


  • pr-reviewer: branch-level quality gate



A detail that made my setup much more predictable: every agent file pins both model and model_reasoning_effort. I do not allow inheritance.



My usual pattern:




  • strongest reasoning for architecture and review

  • medium reasoning for implementation specialists

  • lower-cost, fast routing for dispatch-only work






4) Spec Template as the Unit of Work



Each task is a TASK-YYYY-MM-DD-###.spec.md with strict front matter:




  • goal


  • scope_in and scope_out

  • constraints

  • validation

  • status

  • collaborators and design flags when needed



The point is not bureaucracy. The point is forcing clarity before edits begin.



I keep tasks small enough to finish in around 30 minutes. If I cannot describe it that tightly, it usually means I am hiding complexity.






5) Hard Guardrails with Hooks



This is where workflow stops being "best effort."



I add .codex/hooks/workflow-guard.sh and wire it through .codex/hooks.json (or inline in .codex/config.toml).



The guard blocks patterns that silently damage quality:




  • git commit --no-verify

  • broad staging like git add .

  • commit attempts without staged spec deletion

  • missing required agent files

  • missing model or model_reasoning_effort fields

  • missing or invalid evidence JSON for deleted specs

  • mismatch between evidence model values and pinned agent models



The important behavior is that policy is enforced at command time, not remembered manually.






6) Evidence + Memory



For every completed spec, I track chain evidence in:




  • .codex/evidence/agent-chain/<spec-id>.json



I record:




  • agent name

  • model used

  • chain step (architect, router, specialist)

  • timestamp

  • success status



I also initialize .codex/memory/ for persistent preferences and constraints so sessions start with context instead of re-discovery.






My Day-to-Day Execution Pattern



Once the repo is bootstrapped, feature work becomes very repeatable.






Step 1: Request -> Draft Spec



I start by spawning spec-architect and asking it to create or update a spec.



If there is no approved spec, no implementation is allowed.






Step 2: Approve Before Code



I keep status flow explicit:



draft -> approved -> in_progress -> done|blocked



Approval is where I catch wrong assumptions early, before diff churn begins.






Step 3: Route by Domain



I spawn agent-router on the approved spec.




  • If domain is clear, route to one specialist.

  • If domain is mixed, split specs first.

  • Parallel only for truly non-overlapping owned paths.






Step 4: Implement Only Inside Scope



Specialists are constrained by spec boundaries.



No "while I'm here" changes.

No opportunistic refactors outside scope.



This keeps diffs reviewable and rollback-friendly.






Step 5: Validate and Commit Under Policy



I run npm run verify, then commit with strict formatting.



My commit gate expects spec lifecycle completion behavior, including spec deletion and matching evidence when required by workflow.






Step 6: Run PR-Level Review



After feature specs are done, I run a full-branch review.



That catches regressions that are invisible when you only inspect one task at a time.






What Changed After I Adopted This



Three practical improvements stood out.






1) Fewer accidental repo-wide edits



Explicit scope_in stopped many "small change" cascades.






2) Faster reviews



Review conversation shifted from "what happened?" to "is this the right behavior?" because intent was already encoded in specs.






3) Better handoffs across days



When I pause and resume later, I continue from spec status and evidence instead of reconstructing context from raw diffs.






Common Failure Modes I Guard Against






"This is too small for a spec"



Small tasks are where process drift starts. I still create a tiny spec.






"Let's skip verify once"



If verify is painful, optimize verify. Skipping it just moves failure later.






"Agent touched unrelated files"



I treat that as workflow failure, not a harmless side effect. I re-scope and rerun.






"We can commit now and clean evidence later"



I avoid deferred compliance. Evidence exists to prove the actual chain that happened.






Minimal Setup Order If You Want to Copy This



If you are starting fresh, this is the shortest safe sequence:




  1. Create CODEX.md and AGENTS.md

  2. Add specs/templates/TASK.spec.template.md

  3. Add .codex/WORKFLOW.md and .codex/STRATEGY.md

  4. Create core agents in .codex/agents/

  5. Enable hooks in .codex/config.toml and wire workflow-guard.sh

  6. Add evidence schema path under .codex/evidence/agent-chain/

  7. Test blocked and allowed commit scenarios



If step 7 is skipped, your rules are probably not real yet.






Final Takeaway



My Codex setup works because it converts process from documentation into enforcement:




  • specs define intent

  • agents separate responsibilities

  • hooks enforce non-negotiable policies

  • evidence proves what actually ran

  • PR review validates system-level safety



I still iterate prompts, but prompts are now the smallest part of the system.



The bigger win is having a workflow that stays stable even when tasks, tools, or models change.

CTI Threat Relationship Graph2 Knoten / 1 Relationen
CVE / Incident Software MITRE ATT&CK CWE Weakness IoC
SOC Incident Playbook: Remote Code Execution (RCE) Defense
title: Detect Exploitation - How I Set Up Codex for Spec-Driven Development
id: 302e35f0-6b9f-4e25-8958-54872fc3543f
status: experimental
description: Automatisch generierte SIEM-Erkennungsregel basierend auf CTI Intelligence
references:
  - https://tsecurity.de/
author: iShareStuff CTI Automated Detection Engine
date: 2026-09-24
logsource:
  category: network_connection
  product: any
detection:
  selection:
      CommandLine|contains:
        - 'exploit'
  condition: selection
falsepositives:
  - Legitime administrative Zugriffe oder Penetrationstests
level: high
tags:
  - attack.initial_access
rule CTI_Threat_Indicator {
    meta:
        author = "iShareStuff CTI Automated Detection Engine"
        date = "2026-09-24"
        description = "YARA Signature for "
    strings:
        $str = "How I Set Up Codex for Spec-Dr" ascii wide
    condition:
        any of them
}
Infrastructure Blast Radius & Exposure
HIGH CASCADING
Perimeter & External Ingress
GEFÄHRDET (85%)
Lateral Movement & Pivot
GEFÄHRDET (90%)
Data Stores & Crown Jewels
Geringes Risiko
Supply Chain & Cascading Reach
Geringes Risiko
tsecurity.de Cognitive Threat RAG
Fokus-Vektor:

Kognitive Analyse für identifizierte Bedrohung: Erhöhte Bedrohungslage im Bereich How I Set Up Codex for Spec-Driven Devel.... Basierend auf 368k Vektor-Korrelationen werden sofortige Isolationsmaßnahmen für betroffene Endpunkte empfohlen.

🛡️ Angriffsfläche & Exposure

Netzwerk/Remote-Zugriff ohne Vorauthentifizierung möglich.

⚡ Empfohlene Sofortmaßnahmen
  • 1. Perimeter-Inspektion: Relevante Portfreigaben und exponierte Endpunkte unverzüglich scannen.
  • 2. Patch-Applikation: Hersteller-Hotfix einspielen oder betroffene Daemons in isolierte DMZ-Segmente überführen.
  • 3. Telemetrie & EDR-Alerts: Prozessaufrufe und Child-Processes auf anomale Shell-Spawns überwachen.
🔗 Semantisch verwandte Zero-Days MariaDB 11.7 VEC
Ähnliche Beiträge
🔍 Verwandte News

Auch interessante Nachrichten How I Set Up Codex for Spec-Driven Development

Thematisch verwandte Begriffe: Codex, SpecDriven, Development · 6 Treffer

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Laden...

Beiträge werden geladen ...

Laden...

Videos werden geladen ...

Zum Aktualisieren ziehen
ZERO-DAY CVE-2026-96676 | A vulnerability was identified in Fast FAC1900R 20190827_2.0.2. The impa…
Advisory →
TTS Reader • tsecurity.de Voice
tsecurity.de Icon
tsecurity.de App
Offline-Lesen, Eilmeldungen & 0ms Ladezeit

Installiere tsecurity.de direkt auf deinen Home-Bildschirm für das ultimative Vollbild-Magazinerlebnis ohne Browser-Leisten.

Nächster Beitrag
Themen-Radar & Intelligence Matrix
Echtzeit-Taxonomie nach Angriffsvektoren & Plattformen

tsecurity.de Live Threat Radar

🔴 LIVE RADAR
MONITORING
AKTIV
CVE-DATENBANK
LIVE
🔍
Community Radar & Live Chat
Sentinel Bot online • Live-Stream
Dein Cluster: Security Explorer
Match:
lädt…
Verbindung zum Community-Stream wird aufgebaut...
Bearbeitungsmodus — Senden überschreibt deine Nachricht
Community-Puls — was gerade passiert
lädt…
Aktivitäten deiner Analysten
lädt…
Neues Thema oder Eilmeldung einreichen

Reiche interessante Links, Zero-Days oder Debatten ein. Die Community entscheidet per Upvote über die Veröffentlichung.

Heiß diskutierte Einreichungen
🔖 Gespeicherte Artikel
📂 Keine gespeicherten Artikel vorhanden.
Zurück Ziehen Vor
Links: vorheriger Artikel • Rechts: nächster Artikel • unten: schließen
News NIS-2 Frühwarnung Tier-1 Intel TTP ⏱️ 3 Min vor 10 Min
Artikeldaten werden geladen...

Zurück: vorheriger • Vor: nächster
↗ Original-Quelle
Social Reaktionen Deine Reaktion zählt
Einstufung & Relevanz-Poll 0 Stimmen
In sozialen Netzwerken teilen 1-Klick