Index of every page on this site: llms.txt
All skills
h3xar0n avatar

/defensive-developer

@b1b34c0
Run it yourself

Implements clean, maintainable production code to deliver features and satisfy functional and security test assertions in Phase C GREEN. Use when writing minimal, modular production code to turn failing RED tests GREEN, applying input validation allow-lists, enforcing explicit caller authorization, and using parameterized sinks and least-privilege payloads. Do not use for authoring initial tests, performing initial threat modeling, or running post-implementation security scans.

  • 1 file
  • 2.3 KB
  • Updated 2 months ago
  • GitHub
Use this Skill: https://skilld.dev/gh/h3xar0n/secure-tdd-agent-framework/defensive-developer

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈126 tokens for metadata: the name and description. ≈454 when used: this file.

Description uses 6.3% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈504 characters, or 6.3%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

Feature Implementation & Defensive Developer Skill (Phase C: GREEN Phase)

Overview

Implement clean, modular production code that delivers the requested feature or bug fix and satisfies all functional, edge-case, and security assertions from Phase B while adhering to defensive design principles and project conventions in CONTEXT.md.

Three Defensive Pillars

  1. Simple Input Validation:
    • Enforce type, size, and strict allow-list validation on all incoming data.
    • Prefer structured parsing libraries (pydantic, urllib.parse) over complex regex which may be vulnerable to ReDoS.
  2. Explicit Authorization:
    • Validate caller identity and match required permissions before invoking business logic.
  3. Least Privilege & Safe Operations:
    • Parameterize all SQL/database queries.
    • Use canonical path checks (os.path.realpath) with prefix boundary validation.
    • Return only the minimal data payload required by the client.
    • Mask credentials, PII, and omit internal stack traces in error messages.

Execution Sequence

  1. Inspect Failing Tests & Rules: Review the functional requirements, failing tests from Phase B, and conventions in CONTEXT.md.
  2. Author Clean Production Code:
    • Implement the business logic and algorithms required to satisfy the functional feature requirements.
    • Apply defensive patterns (e.g. utils.security.resolve_safe_path, parameterized SQL statements, pydantic schemas).
  3. Confirm GREEN State:
    • Run the project test suite.
    • Verify that all functional and security tests pass cleanly without errors.
  4. Multi-Finding Handling:
    • When remediating multiple scanner findings, apply the minimal fix for the current failing boundary test, confirm GREEN, then proceed to the next finding's test-fix cycle.

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No third-party reports yet.

Signed by skilld at b1b34c0. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 2 weeks ago.

Activeupdated 2 months ago

README badge

README badge for h3xar0n/secure-tdd-agent-framework/defensive-developer