building-vulnerability-exception-tracking-system skill (Anthropic-Cybersecurity-Skills)

From Public Agent Wiki

What it does. Build a vulnerability exception and risk acceptance tracking system covering approval workflows, compensating controls documentation, and automatic expiration for vulnerabilities that miss SLA remediation timelines. Use when standing up a governance process for risk acceptance and exception approvals to support PCI DSS, SOC 2, or NIST CSF compliance. Part of mukul975/Anthropic-Cybersecurity-Skills (817 security skills) (mukul975/Anthropic-Cybersecurity-Skills).

Upstream mukul975/Anthropic-Cybersecurity-Skills
Skill file skills/building-vulnerability-exception-tracking-system/SKILL.md
License Apache-2.0 (skill folder LICENSE)
Author mukul975
Fetched 2026-09-10

Install

  • npx skills add mukul975/Anthropic-Cybersecurity-Skills --skill building-vulnerability-exception-tracking-system, or copy the skill folder into ~/.claude/skills/building-vulnerability-exception-tracking-system/.
  • Raw file: curl -sL https://raw.githubusercontent.com/mukul975/Anthropic-Cybersecurity-Skills/HEAD/skills/building-vulnerability-exception-tracking-system/SKILL.md

SKILL.md (verbatim)

name: building-vulnerability-exception-tracking-system
description: Build a vulnerability exception and risk acceptance tracking system covering approval workflows, compensating controls documentation, and automatic expiration for vulnerabilities that miss SLA remediation timelines. Use when standing up a governance process for risk acceptance and exception approvals to support PCI DSS, SOC 2, or NIST CSF compliance.
domain: cybersecurity
subdomain: vulnerability-management
tags:
- vulnerability-exception
- risk-acceptance
- compensating-controls
- exception-tracking
- vulnerability-management
- governance
version: '1.0'
author: mahipal
license: Apache-2.0
nist_csf:
- ID.RA-01
- ID.RA-02
- ID.IM-02
- ID.RA-06
mitre_attack:
- T1190
- T1068

Building Vulnerability Exception Tracking System

Overview

A vulnerability exception tracking system manages cases where vulnerabilities cannot be remediated within SLA timelines. It provides structured workflows for requesting exceptions, documenting compensating controls, obtaining risk acceptance approvals, and automatically expiring exceptions when their validity period ends. This ensures organizations maintain visibility into accepted risks while complying with frameworks like PCI DSS, SOC 2, and NIST CSF.

When to Use

  • When deploying or configuring building vulnerability exception tracking system capabilities in your environment
  • When establishing security controls aligned to compliance requirements
  • When building or improving security architecture for this domain
  • When conducting security assessments that require this implementation

Prerequisites

  • Python 3.9+ with flask, sqlalchemy, requests, jinja2
  • PostgreSQL or SQLite database
  • Email/Slack integration for approval notifications
  • Vulnerability management platform API (DefectDojo, Qualys, Tenable)

Exception Request Workflow

Exception Categories

Category Description Max Duration Approver Level
Remediation Delay Patch available but deployment blocked 30 days Team Lead + Security
No Fix Available Vendor has not released a patch 90 days Security Director
Business Critical System cannot be patched without outage 60 days VP Engineering + CISO
False Positive Finding is not a real vulnerability Permanent Security Analyst
Compensating Control Alternative mitigation in place 180 days Security Architect

Required Fields for Exception Request

exception_schema = {
    "cve_id": "CVE-2024-XXXX",
    "finding_id": "unique-finding-reference",
    "asset_hostname": "prod-db-01.corp.local",
    "severity": "high",
    "cvss_score": 8.1,
    "category": "remediation_delay",
    "justification": "Database upgrade required before patch can be applied",
    "compensating_controls": [
        "WAF rule blocking exploit pattern deployed",
        "Network segmentation restricting access to trusted VLANs only",
        "Enhanced monitoring via Splunk alert for exploitation indicators"
    ],
    "requested_expiration": "2024-06-15",
    "requestor_email": "dbadmin@company.com",
    "approver_emails": ["security-lead@company.com", "ciso@company.com"],
    "risk_rating": "medium",
}

Database Schema

CREATE TABLE vulnerability_exceptions (
    id SERIAL PRIMARY KEY,
    cve_id VARCHAR(20) NOT NULL,
    finding_id VARCHAR(100) NOT NULL,
    asset_hostname VARCHAR(255),
    severity VARCHAR(20),
    cvss_score DECIMAL(3,1),
    category VARCHAR(50) NOT NULL,
    justification TEXT NOT NULL,
    compensating_controls TEXT,
    status VARCHAR(20) DEFAULT 'pending',
    requested_by VARCHAR(255) NOT NULL,
    approved_by VARCHAR(255),
    requested_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
    approved_at TIMESTAMP,
    expires_at TIMESTAMP NOT NULL,
    expired BOOLEAN DEFAULT FALSE,
    risk_rating VARCHAR(20),
    review_notes TEXT,
    created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP,
    updated_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);

CREATE TABLE exception_audit_log (
    id SERIAL PRIMARY KEY,
    exception_id INTEGER REFERENCES vulnerability_exceptions(id),
    action VARCHAR(50) NOT NULL,
    actor VARCHAR(255) NOT NULL,
    details TEXT,
    created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);

CREATE INDEX idx_exception_status ON vulnerability_exceptions(status);
CREATE INDEX idx_exception_expires ON vulnerability_exceptions(expires_at);
CREATE INDEX idx_exception_cve ON vulnerability_exceptions(cve_id);

Implementation

Exception Request API

from flask import Flask, request, jsonify
from datetime import datetime, timezone
import json

app = Flask(__name__)

@app.route("/api/exceptions", methods=["POST"])
def create_exception():
    data = request.json
    required = ["cve_id", "finding_id", "category", "justification", "expires_at", "requestor_email"]
    for field in required:
        if field not in data:
            return jsonify({"error": f"Missing required field: {field}"}), 400

    # Validate expiration does not exceed category maximum
    max_days = {"remediation_delay": 30, "no_fix": 90, "business_critical": 60,
                "false_positive": 365, "compensating_control": 180}
    # Insert into database and notify approvers
    return jsonify({"status": "pending", "id": "exc-12345"})

@app.route("/api/exceptions/<exc_id>/approve", methods=["POST"])
def approve_exception(exc_id):
    approver = request.json.get("approver_email")
    notes = request.json.get("notes", "")
    # Update status to approved, record approver and timestamp
    return jsonify({"status": "approved"})

@app.route("/api/exceptions/<exc_id>/reject", methods=["POST"])
def reject_exception(exc_id):
    reviewer = request.json.get("reviewer_email")
    reason = request.json.get("reason")
    # Update status to rejected, record reviewer and reason
    return jsonify({"status": "rejected"})

Expiration Checker (Daily Cron)

# Check for expired exceptions daily
python3 scripts/process.py --check-expirations

# Generate monthly exception report
python3 scripts/process.py --report --output exception_report.json

Compensating Controls Documentation

For each exception, compensating controls must address:

  1. Detection: How will exploitation attempts be detected?
  2. Prevention: What barriers reduce exploitation likelihood?
  3. Response: What incident response procedures are in place?
  4. Monitoring: What continuous monitoring ensures controls remain effective?

References

Other files in this skill

assets/template.md (verbatim)

Vulnerability Exception Request Template

Exception Request Form

Vulnerability Information

  • CVE ID: CVE-YYYY-NNNNN
  • Finding ID: [Scanner reference number]
  • Affected Asset(s): [hostname/IP]
  • Severity: [Critical/High/Medium/Low]
  • CVSS Score: [0.0 - 10.0]
  • Discovery Date: [YYYY-MM-DD]
  • Original SLA Deadline: [YYYY-MM-DD]

Exception Details

  • Category: [ ] Remediation Delay [ ] No Fix Available [ ] Business Critical [ ] False Positive [ ] Compensating Control
  • Requested Expiration Date: [YYYY-MM-DD]
  • Justification: [Detailed explanation of why remediation cannot be completed within SLA]

Compensating Controls

  1. Detection Control: [How will exploitation attempts be detected?]
  2. Prevention Control: [What barriers reduce exploitation likelihood?]
  3. Response Procedure: [What IR procedures are in place for this vulnerability?]
  4. Monitoring: [What ongoing monitoring ensures controls remain effective?]

Risk Assessment

  • Residual Risk Rating: [High/Medium/Low]
  • Business Impact if Exploited: [Description]
  • Likelihood of Exploitation: [High/Medium/Low]

Requestor

  • Name: [Full name]
  • Email: [email@company.com]
  • Department: [Team/Department]
  • Date: [YYYY-MM-DD]

Approval Section (For Approver Use)

Decision

  • Approved - Exception granted with conditions below
  • Rejected - See rejection reason below
  • More Information Required - See notes below

Conditions (if approved)

  • [List any additional conditions]

Reviewer Notes

  • [Notes from security review]

Approver

  • Name: [Full name]
  • Title: [Job title]
  • Date: [YYYY-MM-DD]
  • Signature: [Digital signature or email confirmation reference]

references/api-reference.md (verbatim)

API Reference: Vulnerability Exception Tracking

Exception States

State Description
draft Initial creation, not yet submitted
pending_approval Awaiting approval chain
approved All approvers accepted
rejected Any approver denied
expired Past expiration date
revoked Manually revoked

Approval Chain by Severity

Severity Approvers
Critical Security Lead -> CISO -> Risk Committee
High Security Lead -> CISO
Medium Security Lead
Low Security Lead

Maximum Exception Duration

Severity Max Days
Critical 30
High 90
Medium 180
Low 365

ServiceNow GRC API

# Create risk exception
curl -X POST "https://instance.service-now.com/api/now/table/sn_grc_exception" \
  -u "user:pass" \
  -H "Content-Type: application/json" \
  -d '{"short_description":"CVE-2024-1234 exception","risk_score":"8.5","state":"draft"}'

Archer GRC API

# Create exception record
curl -X POST "https://archer.example.com/api/core/content" \
  -H "Authorization: Archer session-token=$TOKEN" \
  -d '{"Content":{"LevelId":42,"FieldContents":{"1001":{"Value":"Exception for CVE-2024-1234"}}}}'

Compensating Control Categories

Category Examples
Network Segmentation, ACLs, micro-segmentation
Monitoring Enhanced logging, alerting, SIEM rules
Application WAF rules, input validation, rate limiting
Access MFA, PAM, least privilege enforcement
Process Manual review, change control, audit

references/standards.md (verbatim)

Standards and References - Vulnerability Exception Tracking

Primary Standards

NIST SP 800-53 Rev 5 - RA-5(5)

PCI DSS v4.0 - Compensating Controls

ISO 27001:2022 - Clause 6.1.3

  • Title: Information Security Risk Treatment
  • Relevance: Risk acceptance must be formally documented with appropriate authority approval

CIS Controls v8 - Control 7

  • Title: Continuous Vulnerability Management
  • Sub-control 7.7: Remediate detected vulnerabilities within prescribed timelines; document exceptions with compensating controls

SOC 2 - CC3.2

  • Title: Risk Assessment
  • Relevance: Requires evidence of risk acceptance decisions and compensating controls documentation

Compliance Requirements for Exceptions

Framework Exception Requirement Documentation Required
PCI DSS 4.0 Compensating Controls Worksheet Constraint, objective, controls, validation
SOC 2 Type II Risk acceptance evidence Approval chain, justification, review cadence
HIPAA Risk analysis documentation PHI impact, safeguards, timeline
NIST CSF 2.0 Risk response decisions Acceptance criteria, residual risk
ISO 27001 Statement of Applicability Risk owner approval, review schedule

references/workflows.md (verbatim)

Workflows - Vulnerability Exception Tracking

Workflow 1: Exception Request and Approval

Steps

  1. Asset owner identifies vulnerability that cannot be remediated within SLA
  2. Owner submits exception request with justification and compensating controls
  3. System validates request completeness and category-specific fields
  4. System routes request to appropriate approver based on severity and category
  5. Approver reviews justification and compensating controls
  6. Approver approves, rejects, or requests additional information
  7. If approved, exception is recorded with expiration date
  8. Vulnerability status updated in scanner/DefectDojo to "exception_approved"
  9. Audit log entry created with full approval chain

Workflow 2: Daily Expiration Check

Steps

  1. Cron job queries all active exceptions with expires_at <= today + 14 days
  2. For exceptions expiring within 14 days: send renewal reminder to requestor
  3. For exceptions expiring within 7 days: send urgency reminder with escalation
  4. For expired exceptions: update status to "expired", revert vulnerability to "open"
  5. Send expiration notification to asset owner and security team
  6. Regenerate SLA tracking to include re-opened findings

Workflow 3: Quarterly Exception Review

Steps

  1. Generate report of all active exceptions grouped by category and severity
  2. For each exception, verify compensating controls are still in place
  3. Review if vendor patch has become available for "no_fix" exceptions
  4. Re-assess risk rating based on current threat landscape
  5. Escalate exceptions with changed risk profiles for re-approval
  6. Update exception records with review notes and new risk ratings
  7. Submit quarterly report to security governance committee

Workflow 4: Compensating Control Validation

Steps

  1. For each active exception, extract listed compensating controls
  2. Validate each control is still operational:
    • WAF rules: Query WAF API for rule status
    • Network segmentation: Verify firewall rules
    • Monitoring alerts: Confirm SIEM rules are active and triggering
  3. Flag exceptions where compensating controls have degraded
  4. Notify exception requestor and security team of control failures
  5. If controls cannot be restored within 48 hours, revoke exception

Back to mukul975/Anthropic-Cybersecurity-Skills (817 security skills) or Agent skills.