Skip to content
Back to skills

Architecture

ASecurity

Analyze, document, and modernize legacy systems (COBOL, Mainframe, Fortran).

  • 23 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added October 14, 2026
ai-agentspythongosqlrailsawstestingrefactoringapidatabasesecurity

Works with

  • 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-4ab7bf16/badge)](https://www.skillsdirectory.com/skills/andreibesleaga-architecture-4ab7bf16)

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: legacy-modernization
description: Analyze, document, and modernize legacy systems (COBOL, Mainframe, Fortran).
triggers: [legacy code, cobol, mainframe, fortran, ibm z, jcl, db2, cics, modernization, rewrite, migration]
tags: [architecture]
context_cost: medium
---
# Legacy Modernization Skill

## Goal
To respect the critical nature of legacy systems while safely guiding them toward modernization. **Rule #1: Do no harm.**

## Capabilities

### 1. Code Analysis (The Archaeologist)
-   **Explain Logic**: Translate COBOL/Fortran business logic into plain English or Pseudocode.
-   **Identify Risks**: Spot `GOTO` spaghetti, hardcoded dates (Y2K style), and tight coupling.
-   **Data Mapping**: Map VSAM/Copybooks to JSON/SQL schemas.

### 2. Modernization Patterns
-   **API Wrapping (The Facade)**: Create a REST/gRPC wrapper around the legacy core.
-   **Strangler Fig**: Incrementally replace functions with microservices.
-   **Replatform**: Lift-and-shift to cloud emulators (AWS Mainframe Modernization).

### 3. Testing Legacy
-   **Characterization Tests**: "Lock down" current behavior before changing ANYTHING.
-   **Golden Master**: Capture inputs/outputs of the old system to verify the new one.

## Steps
1.  **Assume Importance**: If it's running, it's making money. Treat legacy code with reverence.
2.  **No Big Bang**: Never suggest a full rewrite from scratch unless the system is < 10k LOC.
3.  **Document First**: most legacy failures happen because nobody knows *what* the code does.

## Deliverables
-   `legacy-analysis.md`: Explanation of flow.
-   `wrapper-api.yaml`: OpenAPI spec for the legacy system.
-   `strangler-plan.md`: Step-by-step migration path.

## Security & Guardrails

### 1. Skill Security (Legacy Modernization)
- **Golden Master Secrecy**: When the agent assists in creating "Golden Master" tests (capturing inputs/outputs of the old system), it must recognize that mainframe/legacy databases often lack modern column-level encryption. The captured test fixtures will likely contain live PII or financial data. The agent must mandate strict data masking/anonymization before the Golden Master is saved to modern version control.
- **API Wrapper Credential Injection**: When implementing the "Facade/API Wrapper" (Step 2), the modern microservice often needs a highly privileged service account to interface with the legacy system (e.g., a "God Mode" DB2 user). The agent must verify this credential is injected via a secure Secret Manager at runtime, never encoded in the modernization translation layer.

### 2. System Integration Security
- **Bypass of Legacy Business Logic Guards**: Legacy systems (like COBOL programs) often intertwine business logic with security validation (e.g., checking if a user's department matches the account prefix within a massive `GOTO` loop). The agent must ensure that the new Strangler Fig endpoints replicate or improve these explicit, undocumented authorization checks, not just the "happy path" data transformation.
- **Strangler Fig Route Hijacking**: During the migration phase, the routing layer (e.g., an API Gateway) decides whether traffic goes to the Legacy or Modern system. The agent must secure this routing configuration, as unauthorized manipulation could route sensitive transactions to a partially implemented, insecure modern endpoint that lacks full auditing.

### 3. LLM & Agent Guardrails
- **Automated Refactoring Blindspots**: If the LLM is asked to translate COBOL to Python, it might drop or mistranslate "arcane" or confusing legacy logic that is actually a critical, decades-old security patch for an edge-case exploit. The agent must flag complex, misunderstood blocks for manual human review rather than guessing their intent.
- **Hallucinated Protocol Security**: The LLM might assume that integrating with a mainframe via standard TN3270 or raw socket connections is inherently secure because it's behind a firewall. The agent must advocate for securing the legacy transit layer (e.g., using IPSec or tunneling) to prevent internal lateral movement from sniffing unencrypted Mainframe traffic.

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.