Skip to content
Back to skills

Architecture

ASecurity

Manage breaking changes, migrations, and API evolution.

  • 23 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added October 14, 2026
ai-agentsrustgosqlrailsapidatabasesecurity

Works with

  • cli
  • api

Security analysis

A100/100

Pro scans all 21 files and shows the line behind each finding

Scanned October 14, 2026

npx -y skills add andreibesleaga/GABBE --skill architecture --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Architecture?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Architecture
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/andreibesleaga-architecture-cf38ab6e/badge)](https://www.skillsdirectory.com/skills/andreibesleaga-architecture-cf38ab6e)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: compatibility-design
description: Manage breaking changes, migrations, and API evolution.
triggers: [compatibility, migration, versioning, breaking change, deprecation, legacy support, expand contract]
tags: [architecture]
context_cost: medium
---
# Compatibility Design Skill

## Goal
To evolve systems without breaking existing users or downtime.

## Capabilities

### 1. Database Migrations (Zero Downtime)
-   **Expand & Contract Pattern**:
    1.  **Expand**: Add new column/table. Sync data.
    2.  **Migrate**: Code reads new, writes both.
    3.  **Contract**: Remove old column.

### 2. API Versioning
-   **Strategies**: URI Path (`/v1/`), Header (`Accept-Version`), Query Param.
-   **Tolerant Reader**: Clients should ignore unknown fields (Forward Compatibility).

### 3. Feature Flags
-   **Decoupling**: Launch != Deploy.
-   **Kill Switch**: Turn off broken features instantly without rollback.

## Steps
1.  **Never Break Consumers**: If you must break, create a new version (`v2`).
2.  **Dual Write**: During migrations, write to old AND new data structures.
3.  **Deprecation Policy**: Announce sunset dates clearly (e.g., 6 months notice).

## Deliverables
-   `migration-plan.md`: Steps for Expand/Contract.
-   `api-evolution-strategy.md`: Versioning rules.
-   `deprecation-notice.md`: Communication template.

## Security & Guardrails

### 1. Skill Security (Compatibility Design)
- **Feature Flag Authorization**: The agent must ensure that Feature Flags (Step 3) are treated as highly sensitive administrative controls. Access to the Feature Flag toggling dashboard/API must be protected by strict RBAC and multi-factor authentication, as an attacker could instantly disable critical security protections or unleash untested code by flipping a flag.
- **Migration Script Integrity**: The agent must verify that any code generated for "Expand & Contract" database migrations cannot be used for SQL injection. Migrations are often run with high-privilege database credentials; therefore, the automated scripts must exclusively use parameterized queries or trusted ORM methods, even for structural schema changes.

### 2. System Integration Security
- **Deprecation Sabotage**: When an API version is deprecated (e.g., `v1` replaced by `v2` with better security), attackers will often specifically target the deprecated `v1` endpoint because it might lack the new rate limits or auth checks. The agent must enforce that deprecated endpoints maintain parity with critical security patches until they are completely decommissioned.
- **Tolerant Reader Exploitation**: The "Tolerant Reader" pattern (ignoring unknown fields) can be exploited to smuggle malicious payloads or perform mass assignment attacks. The agent must mandate that while the parser may *ignore* unknown fields for compatibility, the validation layer must *explicitly reject* known sensitive keys (e.g., `isAdmin`, `role`) if they are submitted to inappropriate endpoints.

### 3. LLM & Agent Guardrails
- **Rollback Hallucination**: An LLM might suggest "just rolling back the database" if a migration fails. The agent must actively counter this dangerous advice in production systems, recognizing that rolling back an "Expand & Contract" database migration often causes catastrophic data loss. The agent must always suggest "roll forward" or "feature flag disabling" strategies.
- **Version Pinning Defiance**: A user might ask the agent to "force the API to accept the old, insecure protocol so a legacy client can connect." The agent must refuse to silently downgrade the security posture of the application. It must require explicit human authorization to enable legacy/insecure compatability modes (like TLS 1.0).

Files in this skill

  • adaptive-architecture.skill.md3.7 KB
  • api-design.skill.md4.7 KB
  • api-standards.skill.md1.7 KB
  • arch-debt.skill.md8.2 KB
  • arch-design.skill.md12.6 KB
  • arch-patterns.skill.md3.9 KB
  • arch-review.skill.md14.1 KB
  • architecture-governance.skill.md3.6 KB
  • attribute-driven-design.skill.md7.5 KB
  • blockchain-dlt.skill.md1.9 KB
  • compatibility-design.skill.md3.6 KB
  • critical-systems-arch.skill.md2 KB
  • design-patterns.skill.md4.3 KB
  • diagramming.skill.md13.9 KB
  • domain-model.skill.md12.1 KB
  • enterprise-migration-scenario.skill.md2 KB
  • enterprise-patterns.skill.md1.9 KB
  • error-handling-strategy.skill.md3.9 KB
  • event-driven-architecture.skill.md1.8 KB
  • event-governance.skill.md3.4 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.