{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://grokify.github.io/threat-model-spec/versions/v0.8.0/threat-model.schema.json",
  "$ref": "#/$defs/ThreatModel",
  "$defs": {
    "ASPMDomainID": {
      "type": "string",
      "enum": [
        "git-posture",
        "code-security",
        "secret-pii-scan",
        "open-source-security",
        "sbom",
        "iac-scan",
        "cicd-posture",
        "container-security",
        "artifact-security",
        "cloud-context"
      ]
    },
    "Actor": {
      "properties": {
        "id": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/ElementType"
        },
        "malicious": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "label"
      ]
    },
    "AgentCapabilities": {
      "properties": {
        "tools": {
          "items": {
            "$ref": "#/$defs/AgentTool"
          },
          "type": "array"
        },
        "permissions": {
          "items": {
            "$ref": "#/$defs/AgentPermission"
          },
          "type": "array"
        },
        "sandboxLevel": {
          "$ref": "#/$defs/AgentSandboxLevel"
        },
        "requiresApproval": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "approvalBypassable": {
          "type": "boolean"
        },
        "maxExecutionTime": {
          "type": "string"
        },
        "resourceLimits": {
          "$ref": "#/$defs/AgentResourceLimits"
        },
        "networkRestrictions": {
          "$ref": "#/$defs/AgentNetworkRestrictions"
        },
        "integratedServices": {
          "items": {
            "$ref": "#/$defs/AgentIntegration"
          },
          "type": "array"
        },
        "escalationPaths": {
          "items": {
            "$ref": "#/$defs/AgentEscalationPath"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "AgentCapabilityType": {
      "type": "string",
      "enum": [
        "code-execution",
        "file-access",
        "network-access",
        "shell-access",
        "database-access",
        "api-access",
        "browser-control",
        "messaging",
        "memory-access",
        "tool-invocation"
      ]
    },
    "AgentEscalationPath": {
      "properties": {
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "sourceCapability": {
          "$ref": "#/$defs/AgentCapabilityType"
        },
        "targetCapability": {
          "$ref": "#/$defs/AgentCapabilityType"
        },
        "mechanism": {
          "type": "string"
        },
        "mitigations": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "asiIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name",
        "sourceCapability",
        "targetCapability"
      ]
    },
    "AgentIntegration": {
      "properties": {
        "service": {
          "type": "string"
        },
        "permissions": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "credentialId": {
          "type": "string"
        },
        "scopes": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "service"
      ]
    },
    "AgentNetworkRestrictions": {
      "properties": {
        "allowedHosts": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "blockedHosts": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "allowedPorts": {
          "items": {
            "type": "integer"
          },
          "type": "array"
        },
        "internetAccess": {
          "type": "boolean"
        },
        "localhostAccess": {
          "type": "boolean"
        },
        "internalNetworkAccess": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "AgentPermission": {
      "properties": {
        "resource": {
          "type": "string"
        },
        "actions": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "scope": {
          "type": "string"
        },
        "conditions": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "resource"
      ]
    },
    "AgentResourceLimits": {
      "properties": {
        "maxMemoryMb": {
          "type": "integer"
        },
        "maxCpuPercent": {
          "type": "integer"
        },
        "maxDiskMb": {
          "type": "integer"
        },
        "maxOpenFiles": {
          "type": "integer"
        },
        "maxProcesses": {
          "type": "integer"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "AgentSandboxLevel": {
      "type": "string",
      "enum": [
        "none",
        "process",
        "container",
        "vm",
        "remote"
      ]
    },
    "AgentTool": {
      "properties": {
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "capabilityType": {
          "$ref": "#/$defs/AgentCapabilityType"
        },
        "enabled": {
          "type": "boolean"
        },
        "requiresApproval": {
          "type": "boolean"
        },
        "riskLevel": {
          "$ref": "#/$defs/RiskLevel"
        },
        "parameters": {
          "items": {
            "$ref": "#/$defs/AgentToolParameter"
          },
          "type": "array"
        },
        "asiIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name",
        "capabilityType"
      ]
    },
    "AgentToolParameter": {
      "properties": {
        "name": {
          "type": "string"
        },
        "type": {
          "type": "string"
        },
        "required": {
          "type": "boolean"
        },
        "validation": {
          "type": "string"
        },
        "sensitiveData": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name"
      ]
    },
    "AlertThreshold": {
      "properties": {
        "metric": {
          "type": "string"
        },
        "threshold": {
          "type": "string"
        },
        "window": {
          "type": "string"
        },
        "severity": {
          "type": "string"
        },
        "description": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "metric",
        "threshold"
      ]
    },
    "AnalysisProducer": {
      "properties": {
        "type": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "version": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "type",
        "name"
      ]
    },
    "AnalysisRun": {
      "properties": {
        "id": {
          "type": "string"
        },
        "stage": {
          "$ref": "#/$defs/Stage"
        },
        "method": {
          "type": "string"
        },
        "profile": {
          "$ref": "#/$defs/AnalysisRunProfile"
        },
        "producer": {
          "$ref": "#/$defs/AnalysisProducer"
        },
        "inputArtifactIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "startedAt": {
          "type": "string"
        },
        "completedAt": {
          "type": "string"
        },
        "status": {
          "$ref": "#/$defs/AnalysisRunStatus"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "stage",
        "producer",
        "status"
      ]
    },
    "AnalysisRunProfile": {
      "type": "string",
      "enum": [
        "first-party",
        "third-party",
        "open-source"
      ]
    },
    "AnalysisRunStatus": {
      "type": "string",
      "enum": [
        "in-progress",
        "completed",
        "failed"
      ]
    },
    "ArchitectureAssertion": {
      "properties": {
        "id": {
          "type": "string"
        },
        "subjectId": {
          "type": "string"
        },
        "predicate": {
          "type": "string"
        },
        "expected": {
          "type": "string"
        },
        "observed": {
          "type": "string"
        },
        "expectedEvidenceIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "observedEvidenceIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "status": {
          "$ref": "#/$defs/ArchitectureAssertionStatus"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "subjectId",
        "predicate",
        "expected",
        "status"
      ]
    },
    "ArchitectureAssertionStatus": {
      "type": "string",
      "enum": [
        "supported",
        "contradicted",
        "unverified"
      ]
    },
    "Artifact": {
      "properties": {
        "id": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/ArtifactType"
        },
        "uri": {
          "type": "string"
        },
        "revision": {
          "type": "string"
        },
        "stage": {
          "$ref": "#/$defs/Stage"
        },
        "digest": {
          "type": "string"
        },
        "observedAt": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "type"
      ]
    },
    "ArtifactType": {
      "type": "string",
      "enum": [
        "product-spec",
        "technical-spec",
        "architecture-diagram",
        "api-spec",
        "source-tree",
        "dependency-manifest",
        "sbom",
        "iac",
        "deployment-manifest",
        "runtime-endpoint",
        "telemetry",
        "incident"
      ]
    },
    "Asset": {
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/AssetType"
        },
        "classification": {
          "$ref": "#/$defs/SensitivityLevel"
        },
        "owner": {
          "type": "string"
        },
        "elementIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "dataTypes": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "complianceFrameworks": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "value": {
          "type": "string"
        },
        "retentionPeriod": {
          "type": "string"
        },
        "producerRunId": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "name",
        "classification"
      ]
    },
    "AssetClassification": {
      "type": "string",
      "enum": [
        "crown-jewel",
        "high",
        "medium",
        "low"
      ]
    },
    "AssetType": {
      "type": "string",
      "enum": [
        "data",
        "service",
        "infrastructure",
        "credential",
        "identity",
        "intellectual-property"
      ]
    },
    "Assumption": {
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/AssumptionType"
        },
        "rationale": {
          "type": "string"
        },
        "impact": {
          "type": "string"
        },
        "impactSeverity": {
          "type": "string"
        },
        "validationStatus": {
          "$ref": "#/$defs/ValidationStatus"
        },
        "validationMethod": {
          "type": "string"
        },
        "validatedDate": {
          "type": "string"
        },
        "owner": {
          "type": "string"
        },
        "relatedComponentIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "notes": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "title"
      ]
    },
    "AssumptionType": {
      "type": "string",
      "enum": [
        "trust",
        "security",
        "operational",
        "environment",
        "threat",
        "compliance",
        "dependency"
      ]
    },
    "AtomicTestMapping": {
      "properties": {
        "techniqueId": {
          "type": "string"
        },
        "atomicTests": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "validated": {
          "type": "boolean"
        },
        "lastRun": {
          "type": "string"
        },
        "result": {
          "$ref": "#/$defs/AtomicTestResult"
        },
        "notes": {
          "type": "string"
        },
        "platform": {
          "type": "string"
        },
        "executionTime": {
          "type": "integer"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "techniqueId"
      ]
    },
    "AtomicTestResult": {
      "type": "string",
      "enum": [
        "passed",
        "failed",
        "blocked",
        "skipped",
        "error"
      ]
    },
    "Attack": {
      "properties": {
        "step": {
          "type": "integer"
        },
        "from": {
          "type": "string"
        },
        "to": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "action": {
          "type": "string"
        },
        "outcome": {
          "type": "string"
        },
        "mitreTactic": {
          "$ref": "#/$defs/MITRETactic"
        },
        "mitreTechnique": {
          "type": "string"
        },
        "atlasTechnique": {
          "type": "string"
        },
        "owaspIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "asiIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "strideThreats": {
          "items": {
            "$ref": "#/$defs/STRIDEThreat"
          },
          "type": "array"
        },
        "linddunThreats": {
          "items": {
            "$ref": "#/$defs/LINDDUNThreat"
          },
          "type": "array"
        },
        "description": {
          "type": "string"
        },
        "redTeamNotes": {
          "type": "string"
        },
        "blueTeamNotes": {
          "type": "string"
        },
        "remediationNote": {
          "type": "string"
        },
        "testRef": {
          "$ref": "#/$defs/TestReference"
        },
        "componentRefs": {
          "items": {
            "$ref": "#/$defs/ComponentReference"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "step",
        "from",
        "to",
        "label"
      ]
    },
    "AttackPath": {
      "properties": {
        "nodes": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "edges": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "totalWeight": {
          "type": "number"
        },
        "riskScore": {
          "type": "number"
        },
        "length": {
          "type": "integer"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "nodes",
        "totalWeight",
        "riskScore",
        "length"
      ]
    },
    "AttackPattern": {
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/AttackPatternType"
        },
        "description": {
          "type": "string"
        },
        "prerequisites": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "attackSteps": {
          "items": {
            "$ref": "#/$defs/AttackPatternStep"
          },
          "type": "array"
        },
        "vulnerablePatterns": {
          "items": {
            "$ref": "#/$defs/PatternCodeExample"
          },
          "type": "array"
        },
        "securePatterns": {
          "items": {
            "$ref": "#/$defs/PatternCodeExample"
          },
          "type": "array"
        },
        "detectionPatterns": {
          "items": {
            "$ref": "#/$defs/PatternDetection"
          },
          "type": "array"
        },
        "cweIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "mitreTechniques": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "owaspIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "asiIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "references": {
          "items": {
            "$ref": "#/$defs/Reference"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "name",
        "type"
      ]
    },
    "AttackPatternStep": {
      "properties": {
        "step": {
          "type": "integer"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "action": {
          "type": "string"
        },
        "outcome": {
          "type": "string"
        },
        "mitreTactic": {
          "$ref": "#/$defs/MITRETactic"
        },
        "mitreTechnique": {
          "type": "string"
        },
        "cweIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "step",
        "name"
      ]
    },
    "AttackPatternType": {
      "type": "string",
      "enum": [
        "cswsh",
        "token-exfiltration",
        "sandbox-escape",
        "local-priv-esc",
        "agent-manipulation",
        "ssrf",
        "prompt-injection",
        "tool-abuse",
        "session-hijacking",
        "url-param-injection"
      ]
    },
    "AttackTree": {
      "properties": {
        "rootId": {
          "type": "string"
        },
        "nodes": {
          "items": {
            "$ref": "#/$defs/AttackTreeNode"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "rootId",
        "nodes"
      ]
    },
    "AttackTreeNode": {
      "properties": {
        "id": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "nodeType": {
          "$ref": "#/$defs/AttackTreeNodeType"
        },
        "description": {
          "type": "string"
        },
        "children": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "mitreTechnique": {
          "type": "string"
        },
        "strideThreats": {
          "items": {
            "$ref": "#/$defs/STRIDEThreat"
          },
          "type": "array"
        },
        "probability": {
          "type": "number"
        },
        "cost": {
          "type": "string"
        },
        "difficulty": {
          "type": "string"
        },
        "countermeasure": {
          "type": "string"
        },
        "mitigated": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "label",
        "nodeType"
      ]
    },
    "AttackTreeNodeType": {
      "type": "string",
      "enum": [
        "AND",
        "OR",
        "LEAF"
      ]
    },
    "AttackTreeReportBody": {
      "properties": {
        "sourceDiagramType": {
          "$ref": "#/$defs/DiagramType"
        },
        "entryPointHeuristic": {
          "type": "string"
        },
        "tree": {
          "$ref": "#/$defs/AttackTree"
        },
        "pathAnalysis": {
          "$ref": "#/$defs/PathAnalysisResult"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "sourceDiagramType"
      ]
    },
    "Author": {
      "properties": {
        "name": {
          "type": "string"
        },
        "email": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name"
      ]
    },
    "Boundary": {
      "properties": {
        "id": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/BoundaryType"
        },
        "parentId": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "implicitlyTrusted": {
          "type": "boolean"
        },
        "trustAssumption": {
          "type": "string"
        },
        "trustViolationRisk": {
          "type": "string"
        },
        "breachVector": {
          "type": "string"
        },
        "authenticationRequired": {
          "type": "boolean"
        },
        "authorizationEnforced": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "label",
        "type"
      ]
    },
    "BoundaryType": {
      "type": "string",
      "enum": [
        "browser",
        "localhost",
        "network",
        "cloud",
        "breached",
        "container",
        "sandbox",
        "agent",
        "origin"
      ]
    },
    "BrowserExecutionInfo": {
      "properties": {
        "origin": {
          "type": "string"
        },
        "sameSite": {
          "type": "string"
        },
        "crossOriginIsolated": {
          "type": "boolean"
        },
        "serviceWorker": {
          "type": "boolean"
        },
        "webWorker": {
          "type": "boolean"
        },
        "localStorageAccess": {
          "type": "boolean"
        },
        "cookieAccess": {
          "type": "boolean"
        },
        "localhostAccess": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "BusinessImpact": {
      "properties": {
        "revenueImpact": {
          "$ref": "#/$defs/LossEstimate"
        },
        "customerImpact": {
          "type": "string"
        },
        "regulatoryImpact": {
          "type": "string"
        },
        "reputationImpact": {
          "type": "string"
        },
        "operationalImpact": {
          "type": "string"
        },
        "legalImpact": {
          "type": "string"
        },
        "criticality": {
          "type": "string"
        },
        "recoveryTimeEstimate": {
          "$ref": "#/$defs/Duration"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "CISControlMapping": {
      "properties": {
        "controlId": {
          "type": "string"
        },
        "controlName": {
          "type": "string"
        },
        "safeguardId": {
          "type": "string"
        },
        "safeguardName": {
          "type": "string"
        },
        "implementationGroup": {
          "type": "string"
        },
        "assetType": {
          "type": "string"
        },
        "securityFunction": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "controlId"
      ]
    },
    "CVEMapping": {
      "properties": {
        "id": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "affectedComponents": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "affectedVersions": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "cvss": {
          "$ref": "#/$defs/CVSSMapping"
        },
        "url": {
          "type": "string"
        },
        "references": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id"
      ]
    },
    "CVSSMapping": {
      "properties": {
        "version": {
          "type": "string"
        },
        "vector": {
          "type": "string"
        },
        "baseScore": {
          "type": "number"
        },
        "severity": {
          "$ref": "#/$defs/CVSSSeverity"
        },
        "description": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "version",
        "vector",
        "baseScore",
        "severity"
      ]
    },
    "CVSSSeverity": {
      "type": "string",
      "enum": [
        "None",
        "Low",
        "Medium",
        "High",
        "Critical"
      ]
    },
    "CWEMapping": {
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id"
      ]
    },
    "ChecklistItem": {
      "properties": {
        "item": {
          "type": "string"
        },
        "required": {
          "type": "boolean"
        },
        "notes": {
          "type": "string"
        },
        "category": {
          "type": "string"
        },
        "severity": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "item"
      ]
    },
    "CloudInfo": {
      "properties": {
        "provider": {
          "type": "string"
        },
        "region": {
          "type": "string"
        },
        "vpc": {
          "type": "string"
        },
        "subnet": {
          "type": "string"
        },
        "resourceId": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "CodePattern": {
      "properties": {
        "language": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "code": {
          "type": "string"
        },
        "explanation": {
          "type": "string"
        },
        "cwe": {
          "type": "string"
        },
        "framework": {
          "type": "string"
        },
        "filePath": {
          "type": "string"
        },
        "lineRange": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "language",
        "description",
        "code"
      ]
    },
    "ComplianceFramework": {
      "type": "string",
      "enum": [
        "soc2",
        "pci-dss",
        "hipaa",
        "gdpr",
        "ccpa",
        "fedramp",
        "nist-sp-800-53",
        "nist-sp-800-171",
        "sox",
        "glba"
      ]
    },
    "ComplianceMapping": {
      "properties": {
        "framework": {
          "$ref": "#/$defs/ComplianceFramework"
        },
        "requirementId": {
          "type": "string"
        },
        "requirementName": {
          "type": "string"
        },
        "category": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "evidence": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "framework",
        "requirementId"
      ]
    },
    "ComponentReference": {
      "properties": {
        "id": {
          "type": "string"
        },
        "purl": {
          "type": "string"
        },
        "cpe": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "version": {
          "type": "string"
        },
        "supplier": {
          "type": "string"
        },
        "license": {
          "type": "string"
        },
        "vulnerabilityIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "ConfigChange": {
      "properties": {
        "setting": {
          "type": "string"
        },
        "value": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "platform": {
          "type": "string"
        },
        "file": {
          "type": "string"
        },
        "currentValue": {
          "type": "string"
        },
        "impact": {
          "type": "string"
        },
        "restartRequired": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "setting",
        "value"
      ]
    },
    "Contact": {
      "properties": {
        "name": {
          "type": "string"
        },
        "role": {
          "type": "string"
        },
        "email": {
          "type": "string"
        },
        "phone": {
          "type": "string"
        },
        "slack": {
          "type": "string"
        },
        "pagerDuty": {
          "type": "string"
        },
        "availability": {
          "type": "string"
        },
        "primary": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name"
      ]
    },
    "ContainerExecutionInfo": {
      "properties": {
        "runtime": {
          "type": "string"
        },
        "image": {
          "type": "string"
        },
        "privileged": {
          "type": "boolean"
        },
        "hostPid": {
          "type": "boolean"
        },
        "hostNetwork": {
          "type": "boolean"
        },
        "volumes": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "readOnlyRootFs": {
          "type": "boolean"
        },
        "dropCapabilities": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "Controls": {
      "properties": {
        "nistCsf": {
          "items": {
            "$ref": "#/$defs/NISTCSFMapping"
          },
          "type": "array"
        },
        "cis": {
          "items": {
            "$ref": "#/$defs/CISControlMapping"
          },
          "type": "array"
        },
        "iso27001": {
          "items": {
            "$ref": "#/$defs/ISO27001Mapping"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "CoverageLevel": {
      "type": "string",
      "enum": [
        "none",
        "minimal",
        "partial",
        "substantial",
        "full"
      ]
    },
    "CoverageSummary": {
      "properties": {
        "totalTechniques": {
          "type": "integer"
        },
        "coveredFull": {
          "type": "integer"
        },
        "coveredSubstantial": {
          "type": "integer"
        },
        "coveredPartial": {
          "type": "integer"
        },
        "coveredMinimal": {
          "type": "integer"
        },
        "notCovered": {
          "type": "integer"
        },
        "coveragePercent": {
          "type": "number"
        },
        "effectiveCoveragePercent": {
          "type": "number"
        },
        "gapsByTactic": {
          "additionalProperties": {
            "type": "integer"
          },
          "type": "object"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "totalTechniques",
        "coveredFull",
        "coveredSubstantial",
        "coveredPartial",
        "coveredMinimal",
        "notCovered",
        "coveragePercent",
        "effectiveCoveragePercent"
      ]
    },
    "CredentialFlow": {
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/CredentialType"
        },
        "assetId": {
          "type": "string"
        },
        "stages": {
          "items": {
            "$ref": "#/$defs/CredentialFlowEvent"
          },
          "type": "array"
        },
        "expirationDuration": {
          "type": "string"
        },
        "revocable": {
          "type": "boolean"
        },
        "rotationPolicy": {
          "type": "string"
        },
        "scope": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "riskLevel": {
          "$ref": "#/$defs/RiskLevel"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "name",
        "type"
      ]
    },
    "CredentialFlowEvent": {
      "properties": {
        "stage": {
          "$ref": "#/$defs/CredentialFlowStage"
        },
        "elementId": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "transportProtocol": {
          "type": "string"
        },
        "transportMechanism": {
          "type": "string"
        },
        "encrypted": {
          "type": "boolean"
        },
        "attackStep": {
          "type": "integer"
        },
        "vulnerability": {
          "type": "string"
        },
        "cweIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "stage"
      ]
    },
    "CredentialFlowStage": {
      "type": "string",
      "enum": [
        "created",
        "stored",
        "transmitted",
        "exfiltrated",
        "reused",
        "revoked",
        "expired"
      ]
    },
    "CredentialType": {
      "type": "string",
      "enum": [
        "api-key",
        "bearer-token",
        "refresh-token",
        "jwt",
        "session-token",
        "password",
        "private-key",
        "certificate",
        "oauth",
        "websocket-token"
      ]
    },
    "Currency": {
      "properties": {
        "amount": {
          "type": "number"
        },
        "code": {
          "type": "string"
        },
        "symbol": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "amount"
      ]
    },
    "DataSourceType": {
      "type": "string",
      "enum": [
        "logs",
        "siem",
        "edr",
        "ndr",
        "ids",
        "waf",
        "cloudtrail",
        "api-gateway",
        "network-capture",
        "user-behavior",
        "audit-log"
      ]
    },
    "DefenseGuidance": {
      "properties": {
        "detectionRules": {
          "items": {
            "$ref": "#/$defs/DetectionRule"
          },
          "type": "array"
        },
        "iocs": {
          "items": {
            "$ref": "#/$defs/IOC"
          },
          "type": "array"
        },
        "logSources": {
          "items": {
            "$ref": "#/$defs/LogSource"
          },
          "type": "array"
        },
        "huntingQueries": {
          "items": {
            "$ref": "#/$defs/HuntingQuery"
          },
          "type": "array"
        },
        "monitoringRecommendations": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "alertThresholds": {
          "items": {
            "$ref": "#/$defs/AlertThreshold"
          },
          "type": "array"
        },
        "notes": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "DependencyRisk": {
      "properties": {
        "componentRef": {
          "$ref": "#/$defs/ComponentReference"
        },
        "riskLevel": {
          "$ref": "#/$defs/RiskLevel"
        },
        "vulnerabilityCount": {
          "type": "integer"
        },
        "criticalCount": {
          "type": "integer"
        },
        "highCount": {
          "type": "integer"
        },
        "outdatedBy": {
          "type": "integer"
        },
        "lastUpdated": {
          "type": "string"
        },
        "deprecated": {
          "type": "boolean"
        },
        "unmaintained": {
          "type": "boolean"
        },
        "directDependency": {
          "type": "boolean"
        },
        "notes": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "Detection": {
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "threatIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "attackSteps": {
          "items": {
            "type": "integer"
          },
          "type": "array"
        },
        "mitreTechniques": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "method": {
          "type": "string"
        },
        "dataSources": {
          "items": {
            "$ref": "#/$defs/DataSourceType"
          },
          "type": "array"
        },
        "coverage": {
          "$ref": "#/$defs/DetectionCoverage"
        },
        "latencySeconds": {
          "type": "integer"
        },
        "falsePositiveRate": {
          "type": "string"
        },
        "detectionLogic": {
          "type": "string"
        },
        "tool": {
          "type": "string"
        },
        "playbookId": {
          "type": "string"
        },
        "alertSeverity": {
          "type": "string"
        },
        "enabled": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "title",
        "coverage"
      ]
    },
    "DetectionCoverage": {
      "type": "string",
      "enum": [
        "none",
        "partial",
        "full"
      ]
    },
    "DetectionCoverageMatrix": {
      "properties": {
        "techniques": {
          "items": {
            "$ref": "#/$defs/TechniqueCoverage"
          },
          "type": "array"
        },
        "summary": {
          "$ref": "#/$defs/CoverageSummary"
        },
        "lastUpdated": {
          "type": "string"
        },
        "source": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "techniques"
      ]
    },
    "DetectionFormat": {
      "type": "string",
      "enum": [
        "sigma",
        "yara",
        "splunk",
        "elastic",
        "kql",
        "snort",
        "suricata",
        "custom"
      ]
    },
    "DetectionRule": {
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "format": {
          "$ref": "#/$defs/DetectionFormat"
        },
        "rule": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "severity": {
          "type": "string"
        },
        "falsePositives": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "references": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "mitreTechniques": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "tags": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "status": {
          "type": "string"
        },
        "author": {
          "type": "string"
        },
        "date": {
          "type": "string"
        },
        "testRefs": {
          "items": {
            "$ref": "#/$defs/TestReference"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "name",
        "format",
        "rule"
      ]
    },
    "DiagramType": {
      "type": "string",
      "enum": [
        "dfd",
        "attack-chain",
        "sequence",
        "attack-tree"
      ]
    },
    "DiagramView": {
      "properties": {
        "type": {
          "$ref": "#/$defs/DiagramType"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "direction": {
          "$ref": "#/$defs/Direction"
        },
        "legend": {
          "$ref": "#/$defs/Legend"
        },
        "mappings": {
          "$ref": "#/$defs/Mappings"
        },
        "elements": {
          "items": {
            "$ref": "#/$defs/Element"
          },
          "type": "array"
        },
        "boundaries": {
          "items": {
            "$ref": "#/$defs/Boundary"
          },
          "type": "array"
        },
        "flows": {
          "items": {
            "$ref": "#/$defs/Flow"
          },
          "type": "array"
        },
        "attacks": {
          "items": {
            "$ref": "#/$defs/Attack"
          },
          "type": "array"
        },
        "targets": {
          "items": {
            "$ref": "#/$defs/Target"
          },
          "type": "array"
        },
        "actors": {
          "items": {
            "$ref": "#/$defs/Actor"
          },
          "type": "array"
        },
        "phases": {
          "items": {
            "$ref": "#/$defs/Phase"
          },
          "type": "array"
        },
        "messages": {
          "items": {
            "$ref": "#/$defs/Message"
          },
          "type": "array"
        },
        "attackTree": {
          "$ref": "#/$defs/AttackTree"
        },
        "threats": {
          "items": {
            "$ref": "#/$defs/ThreatEntry"
          },
          "type": "array"
        },
        "mitigations": {
          "items": {
            "$ref": "#/$defs/Mitigation"
          },
          "type": "array"
        },
        "detections": {
          "items": {
            "$ref": "#/$defs/Detection"
          },
          "type": "array"
        },
        "responseActions": {
          "items": {
            "$ref": "#/$defs/ResponseAction"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "type"
      ]
    },
    "Direction": {
      "type": "string",
      "enum": [
        "right",
        "down",
        "left",
        "up"
      ]
    },
    "Duration": {
      "properties": {
        "value": {
          "type": "integer"
        },
        "unit": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "value",
        "unit"
      ]
    },
    "EPSSData": {
      "properties": {
        "cve": {
          "type": "string"
        },
        "epssScore": {
          "type": "number"
        },
        "percentile": {
          "type": "number"
        },
        "dateScored": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "cve",
        "epssScore",
        "percentile"
      ]
    },
    "Element": {
      "properties": {
        "id": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/ElementType"
        },
        "parentId": {
          "type": "string"
        },
        "classification": {
          "$ref": "#/$defs/AssetClassification"
        },
        "strideThreats": {
          "items": {
            "$ref": "#/$defs/STRIDEThreat"
          },
          "type": "array"
        },
        "description": {
          "type": "string"
        },
        "network": {
          "$ref": "#/$defs/NetworkInfo"
        },
        "assetIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "agentCapabilities": {
          "$ref": "#/$defs/AgentCapabilities"
        },
        "executionContext": {
          "$ref": "#/$defs/ExecutionContext"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "label",
        "type"
      ]
    },
    "ElementType": {
      "type": "string",
      "enum": [
        "process",
        "datastore",
        "external-entity",
        "gateway",
        "browser",
        "agent",
        "api"
      ]
    },
    "EscapeVector": {
      "properties": {
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "sourceContext": {
          "$ref": "#/$defs/ExecutionEnvironmentType"
        },
        "targetContext": {
          "$ref": "#/$defs/ExecutionEnvironmentType"
        },
        "targetPrivilegeLevel": {
          "$ref": "#/$defs/ExecutionPrivilegeLevel"
        },
        "mechanism": {
          "type": "string"
        },
        "prerequisites": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "cweIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "mitreTechnique": {
          "type": "string"
        },
        "mitigations": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name",
        "sourceContext",
        "targetContext"
      ]
    },
    "Evidence": {
      "properties": {
        "id": {
          "type": "string"
        },
        "artifactId": {
          "type": "string"
        },
        "locator": {
          "$ref": "#/$defs/EvidenceLocator"
        },
        "digest": {
          "type": "string"
        },
        "excerpt": {
          "type": "string"
        },
        "summary": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "locator"
      ]
    },
    "EvidenceLocator": {
      "properties": {
        "type": {
          "$ref": "#/$defs/EvidenceLocatorType"
        },
        "path": {
          "type": "string"
        },
        "startLine": {
          "type": "integer"
        },
        "endLine": {
          "type": "integer"
        },
        "uri": {
          "type": "string"
        },
        "section": {
          "type": "string"
        },
        "keyPath": {
          "type": "string"
        },
        "dataSource": {
          "type": "string"
        },
        "query": {
          "type": "string"
        },
        "timeWindow": {
          "type": "string"
        },
        "url": {
          "type": "string"
        },
        "observedAt": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "type"
      ]
    },
    "EvidenceLocatorType": {
      "type": "string",
      "enum": [
        "file",
        "document",
        "config",
        "query",
        "url"
      ]
    },
    "ExecutionContext": {
      "properties": {
        "environmentType": {
          "$ref": "#/$defs/ExecutionEnvironmentType"
        },
        "privilegeLevel": {
          "$ref": "#/$defs/ExecutionPrivilegeLevel"
        },
        "user": {
          "type": "string"
        },
        "groups": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "processName": {
          "type": "string"
        },
        "workingDirectory": {
          "type": "string"
        },
        "environmentVariables": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "capabilities": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "selinuxContext": {
          "type": "string"
        },
        "appArmorProfile": {
          "type": "string"
        },
        "seccompProfile": {
          "type": "string"
        },
        "containerInfo": {
          "$ref": "#/$defs/ContainerExecutionInfo"
        },
        "browserInfo": {
          "$ref": "#/$defs/BrowserExecutionInfo"
        },
        "networkAccess": {
          "$ref": "#/$defs/ExecutionNetworkAccess"
        },
        "filesystemAccess": {
          "$ref": "#/$defs/ExecutionFilesystemAccess"
        },
        "escapeVectors": {
          "items": {
            "$ref": "#/$defs/EscapeVector"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "environmentType",
        "privilegeLevel"
      ]
    },
    "ExecutionEnvironmentType": {
      "type": "string",
      "enum": [
        "host",
        "container",
        "vm",
        "browser",
        "serverless",
        "sandbox"
      ]
    },
    "ExecutionFilesystemAccess": {
      "properties": {
        "readPaths": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "writePaths": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "executePaths": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "mountPoints": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "tempDirectory": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "ExecutionNetworkAccess": {
      "properties": {
        "canAccessInternet": {
          "type": "boolean"
        },
        "canAccessLocalhost": {
          "type": "boolean"
        },
        "canAccessInternalNetwork": {
          "type": "boolean"
        },
        "allowedPorts": {
          "items": {
            "type": "integer"
          },
          "type": "array"
        },
        "blockedPorts": {
          "items": {
            "type": "integer"
          },
          "type": "array"
        },
        "dnsAccess": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "ExecutionPrivilegeLevel": {
      "type": "string",
      "enum": [
        "root",
        "admin",
        "user",
        "service",
        "restricted",
        "none"
      ]
    },
    "ExploitDifficulty": {
      "type": "string",
      "enum": [
        "trivial",
        "low",
        "medium",
        "high",
        "expert"
      ]
    },
    "ExploitationGuidance": {
      "properties": {
        "prerequisites": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "exploitationSteps": {
          "items": {
            "$ref": "#/$defs/ExploitationStep"
          },
          "type": "array"
        },
        "tools": {
          "items": {
            "$ref": "#/$defs/OffensiveTool"
          },
          "type": "array"
        },
        "payloadPatterns": {
          "items": {
            "$ref": "#/$defs/PayloadPattern"
          },
          "type": "array"
        },
        "successIndicators": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "difficulty": {
          "$ref": "#/$defs/ExploitDifficulty"
        },
        "testRefs": {
          "items": {
            "$ref": "#/$defs/TestReference"
          },
          "type": "array"
        },
        "notes": {
          "type": "string"
        },
        "timeToExploit": {
          "type": "string"
        },
        "skillLevel": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "ExploitationStep": {
      "properties": {
        "step": {
          "type": "integer"
        },
        "action": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "tool": {
          "type": "string"
        },
        "example": {
          "type": "string"
        },
        "expectedResult": {
          "type": "string"
        },
        "mitreTechnique": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "step",
        "action"
      ]
    },
    "FAIRAssessment": {
      "properties": {
        "threatEventFrequency": {
          "$ref": "#/$defs/FrequencyEstimate"
        },
        "vulnerability": {
          "$ref": "#/$defs/Percentage"
        },
        "primaryLoss": {
          "$ref": "#/$defs/LossEstimate"
        },
        "secondaryLoss": {
          "$ref": "#/$defs/LossEstimate"
        },
        "annualizedLossExpectancy": {
          "$ref": "#/$defs/Currency"
        },
        "riskScore": {
          "type": "number"
        },
        "assessmentDate": {
          "type": "string"
        },
        "assessor": {
          "type": "string"
        },
        "notes": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "Finding": {
      "properties": {
        "id": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/FindingType"
        },
        "stage": {
          "$ref": "#/$defs/Stage"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "targetRefs": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "evidenceIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "confidence": {
          "type": "number"
        },
        "status": {
          "$ref": "#/$defs/FindingStatus"
        },
        "aspmDomainId": {
          "$ref": "#/$defs/ASPMDomainID"
        },
        "producerRunId": {
          "type": "string"
        },
        "promotedToId": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "type",
        "title",
        "status"
      ]
    },
    "FindingStatus": {
      "type": "string",
      "enum": [
        "candidate",
        "validated",
        "rejected",
        "insufficient-evidence"
      ]
    },
    "FindingType": {
      "type": "string",
      "enum": [
        "observation",
        "threat-candidate",
        "vulnerability",
        "weakness",
        "drift",
        "control-gap"
      ]
    },
    "Flow": {
      "properties": {
        "from": {
          "type": "string"
        },
        "to": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/FlowType"
        },
        "bidirectional": {
          "type": "boolean"
        },
        "protocol": {
          "type": "string"
        },
        "encrypted": {
          "type": "boolean"
        },
        "authenticated": {
          "type": "boolean"
        },
        "crossOrigin": {
          "type": "boolean"
        },
        "credentialFlowId": {
          "type": "string"
        },
        "dataClassification": {
          "$ref": "#/$defs/AssetClassification"
        },
        "cweIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "from",
        "to"
      ]
    },
    "FlowType": {
      "type": "string",
      "enum": [
        "normal",
        "attack",
        "exfil",
        "credential",
        "websocket",
        "cswsh",
        "lateral"
      ]
    },
    "FrameworkID": {
      "type": "string",
      "enum": [
        "stride",
        "linddun",
        "mitre-attack",
        "owasp",
        "attack-tree"
      ]
    },
    "FrameworkReport": {
      "properties": {
        "id": {
          "type": "string"
        },
        "framework": {
          "$ref": "#/$defs/FrameworkID"
        },
        "generatedAt": {
          "type": "string"
        },
        "sourceRevision": {
          "type": "string"
        },
        "strideBody": {
          "$ref": "#/$defs/STRIDEReportBody"
        },
        "linddunBody": {
          "$ref": "#/$defs/LINDDUNReportBody"
        },
        "mitreAttackBody": {
          "$ref": "#/$defs/MITREAttackReportBody"
        },
        "owaspBody": {
          "$ref": "#/$defs/OWASPReportBody"
        },
        "attackTreeBody": {
          "$ref": "#/$defs/AttackTreeReportBody"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "framework"
      ]
    },
    "FrequencyEstimate": {
      "properties": {
        "min": {
          "type": "number"
        },
        "max": {
          "type": "number"
        },
        "mostLikely": {
          "type": "number"
        },
        "confidence": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "min",
        "max",
        "mostLikely"
      ]
    },
    "Gate": {
      "properties": {
        "id": {
          "type": "string"
        },
        "stage": {
          "$ref": "#/$defs/Stage"
        },
        "criteria": {
          "items": {
            "$ref": "#/$defs/GateCriterion"
          },
          "type": "array"
        },
        "result": {
          "$ref": "#/$defs/GateResult"
        },
        "evaluatedBy": {
          "type": "string"
        },
        "evidenceIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "evaluatedAt": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "stage",
        "result"
      ]
    },
    "GateCriterion": {
      "properties": {
        "metric": {
          "type": "string"
        },
        "operator": {
          "type": "string"
        },
        "value": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "metric",
        "operator",
        "value"
      ]
    },
    "GateResult": {
      "type": "string",
      "enum": [
        "passed",
        "failed",
        "pending"
      ]
    },
    "HuntingQuery": {
      "properties": {
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "platform": {
          "$ref": "#/$defs/DetectionFormat"
        },
        "query": {
          "type": "string"
        },
        "hypothesis": {
          "type": "string"
        },
        "dataSources": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "mitreTechniques": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "expectedResults": {
          "type": "string"
        },
        "author": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name",
        "platform",
        "query"
      ]
    },
    "IOC": {
      "properties": {
        "type": {
          "$ref": "#/$defs/IOCType"
        },
        "value": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "confidence": {
          "type": "string"
        },
        "validUntil": {
          "type": "string"
        },
        "source": {
          "type": "string"
        },
        "malwareFamily": {
          "type": "string"
        },
        "threatActor": {
          "type": "string"
        },
        "tags": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "type",
        "value"
      ]
    },
    "IOCType": {
      "type": "string",
      "enum": [
        "ip",
        "domain",
        "url",
        "hash",
        "filepath",
        "email",
        "registry",
        "process",
        "certificate",
        "pattern"
      ]
    },
    "ISO27001Mapping": {
      "properties": {
        "controlId": {
          "type": "string"
        },
        "controlName": {
          "type": "string"
        },
        "domain": {
          "type": "string"
        },
        "objective": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "controlId"
      ]
    },
    "IncidentPlaybook": {
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "threatType": {
          "type": "string"
        },
        "severity": {
          "type": "string"
        },
        "steps": {
          "items": {
            "$ref": "#/$defs/PlaybookStep"
          },
          "type": "array"
        },
        "contacts": {
          "items": {
            "$ref": "#/$defs/Contact"
          },
          "type": "array"
        },
        "tools": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "references": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "mitreTechniques": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "slaMinutes": {
          "type": "integer"
        },
        "lastReviewed": {
          "type": "string"
        },
        "owner": {
          "type": "string"
        },
        "tags": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "name"
      ]
    },
    "LINDDUNMapping": {
      "properties": {
        "category": {
          "$ref": "#/$defs/LINDDUNThreat"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "affectedDataTypes": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "affectedComponents": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "dataSubjects": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "privacyPrinciple": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "category"
      ]
    },
    "LINDDUNReportBody": {
      "properties": {
        "mappings": {
          "items": {
            "$ref": "#/$defs/LINDDUNMapping"
          },
          "type": "array"
        },
        "coverageByCategory": {
          "additionalProperties": {
            "type": "integer"
          },
          "type": "object"
        },
        "categoriesCovered": {
          "items": {
            "$ref": "#/$defs/LINDDUNThreat"
          },
          "type": "array"
        },
        "categoriesMissing": {
          "items": {
            "$ref": "#/$defs/LINDDUNThreat"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "mappings",
        "coverageByCategory",
        "categoriesCovered",
        "categoriesMissing"
      ]
    },
    "LINDDUNThreat": {
      "type": "string",
      "enum": [
        "L",
        "I",
        "N",
        "D",
        "Di",
        "U",
        "Nc"
      ]
    },
    "Legend": {
      "properties": {
        "show": {
          "type": "boolean"
        },
        "showStride": {
          "type": "boolean"
        },
        "showLinddun": {
          "type": "boolean"
        },
        "showMitre": {
          "type": "boolean"
        },
        "showAssets": {
          "type": "boolean"
        },
        "showElements": {
          "type": "boolean"
        },
        "showBoundaries": {
          "type": "boolean"
        },
        "showMitigations": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "show"
      ]
    },
    "Library": {
      "properties": {
        "name": {
          "type": "string"
        },
        "language": {
          "type": "string"
        },
        "purpose": {
          "type": "string"
        },
        "url": {
          "type": "string"
        },
        "examples": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "version": {
          "type": "string"
        },
        "installCommand": {
          "type": "string"
        },
        "license": {
          "type": "string"
        },
        "alternatives": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name",
        "language",
        "purpose"
      ]
    },
    "Lifecycle": {
      "properties": {
        "currentStage": {
          "$ref": "#/$defs/Stage"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "LogSource": {
      "properties": {
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "eventIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "fields": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "category": {
          "type": "string"
        },
        "platform": {
          "type": "string"
        },
        "retentionDays": {
          "type": "integer"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name"
      ]
    },
    "LossEstimate": {
      "properties": {
        "min": {
          "type": "number"
        },
        "max": {
          "type": "number"
        },
        "mostLikely": {
          "type": "number"
        },
        "currency": {
          "$ref": "#/$defs/Currency"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "min",
        "max",
        "mostLikely"
      ]
    },
    "MITREATLASMapping": {
      "properties": {
        "tacticId": {
          "type": "string"
        },
        "tacticName": {
          "type": "string"
        },
        "techniqueId": {
          "type": "string"
        },
        "techniqueName": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "tacticId",
        "techniqueId"
      ]
    },
    "MITREAttackMapping": {
      "properties": {
        "tacticId": {
          "type": "string"
        },
        "tacticName": {
          "type": "string"
        },
        "techniqueId": {
          "type": "string"
        },
        "techniqueName": {
          "type": "string"
        },
        "subTechniqueId": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "tacticId",
        "techniqueId"
      ]
    },
    "MITREAttackReportBody": {
      "properties": {
        "mappings": {
          "items": {
            "$ref": "#/$defs/MITREAttackMapping"
          },
          "type": "array"
        },
        "detectionCoverage": {
          "$ref": "#/$defs/DetectionCoverageMatrix"
        },
        "mappedTechniquesWithoutCoverage": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "mappings"
      ]
    },
    "MITRETactic": {
      "type": "string",
      "enum": [
        "TA0001",
        "TA0002",
        "TA0003",
        "TA0004",
        "TA0005",
        "TA0006",
        "TA0007",
        "TA0008",
        "TA0009",
        "TA0010",
        "TA0011",
        "TA0040"
      ]
    },
    "Mappings": {
      "properties": {
        "mitreAttack": {
          "items": {
            "$ref": "#/$defs/MITREAttackMapping"
          },
          "type": "array"
        },
        "mitreAtlas": {
          "items": {
            "$ref": "#/$defs/MITREATLASMapping"
          },
          "type": "array"
        },
        "owasp": {
          "items": {
            "$ref": "#/$defs/OWASPMapping"
          },
          "type": "array"
        },
        "cwe": {
          "items": {
            "$ref": "#/$defs/CWEMapping"
          },
          "type": "array"
        },
        "cve": {
          "items": {
            "$ref": "#/$defs/CVEMapping"
          },
          "type": "array"
        },
        "cvss": {
          "$ref": "#/$defs/CVSSMapping"
        },
        "stride": {
          "items": {
            "$ref": "#/$defs/STRIDEMapping"
          },
          "type": "array"
        },
        "linddun": {
          "items": {
            "$ref": "#/$defs/LINDDUNMapping"
          },
          "type": "array"
        },
        "controls": {
          "$ref": "#/$defs/Controls"
        },
        "compliance": {
          "items": {
            "$ref": "#/$defs/ComplianceMapping"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "Message": {
      "properties": {
        "seq": {
          "type": "integer"
        },
        "from": {
          "type": "string"
        },
        "to": {
          "type": "string"
        },
        "label": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/FlowType"
        },
        "mitreTechnique": {
          "type": "string"
        },
        "note": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "seq",
        "from",
        "to",
        "label"
      ]
    },
    "MetricDuration": {
      "properties": {
        "value": {
          "type": "number"
        },
        "unit": {
          "$ref": "#/$defs/MetricTimeUnit"
        },
        "source": {
          "type": "string"
        },
        "confidence": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "value",
        "unit"
      ]
    },
    "MetricTimeUnit": {
      "type": "string",
      "enum": [
        "seconds",
        "minutes",
        "hours",
        "days",
        "weeks"
      ]
    },
    "Mitigation": {
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "threatIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "strideCategories": {
          "items": {
            "$ref": "#/$defs/STRIDEThreat"
          },
          "type": "array"
        },
        "controlId": {
          "type": "string"
        },
        "status": {
          "$ref": "#/$defs/MitigationStatus"
        },
        "owner": {
          "type": "string"
        },
        "verifiedDate": {
          "type": "string"
        },
        "effectiveness": {
          "type": "string"
        },
        "notes": {
          "type": "string"
        },
        "producerRunId": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "title",
        "status"
      ]
    },
    "MitigationStatus": {
      "type": "string",
      "enum": [
        "planned",
        "implemented",
        "partial",
        "accepted",
        "transferred",
        "not-applicable"
      ]
    },
    "ModelPhase": {
      "type": "string",
      "enum": [
        "design",
        "development",
        "review",
        "production",
        "incident"
      ]
    },
    "Motivation": {
      "type": "string",
      "enum": [
        "financial",
        "espionage",
        "disruption",
        "destruction",
        "ideological",
        "revenge",
        "notoriety",
        "curiosity",
        "competitive"
      ]
    },
    "NISTCSFFunction": {
      "type": "string",
      "enum": [
        "Identify",
        "Protect",
        "Detect",
        "Respond",
        "Recover"
      ]
    },
    "NISTCSFMapping": {
      "properties": {
        "function": {
          "$ref": "#/$defs/NISTCSFFunction"
        },
        "category": {
          "type": "string"
        },
        "categoryName": {
          "type": "string"
        },
        "subcategory": {
          "type": "string"
        },
        "subcategoryName": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "function",
        "category"
      ]
    },
    "NetworkInfo": {
      "properties": {
        "host": {
          "type": "string"
        },
        "ports": {
          "items": {
            "type": "integer"
          },
          "type": "array"
        },
        "protocols": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "zone": {
          "type": "string"
        },
        "cidr": {
          "type": "string"
        },
        "cloud": {
          "$ref": "#/$defs/CloudInfo"
        },
        "webSocket": {
          "$ref": "#/$defs/WebSocketConfig"
        },
        "allowedOrigins": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "originValidation": {
          "type": "boolean"
        },
        "rateLimitRps": {
          "type": "integer"
        },
        "rateLimitConnections": {
          "type": "integer"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "OWASPCategory": {
      "type": "string",
      "enum": [
        "api",
        "llm",
        "web",
        "agentic"
      ]
    },
    "OWASPMapping": {
      "properties": {
        "category": {
          "$ref": "#/$defs/OWASPCategory"
        },
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "url": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "category",
        "id"
      ]
    },
    "OWASPReportBody": {
      "properties": {
        "mappings": {
          "items": {
            "$ref": "#/$defs/OWASPMapping"
          },
          "type": "array"
        },
        "coverageByList": {
          "additionalProperties": {
            "type": "integer"
          },
          "type": "object"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "mappings",
        "coverageByList"
      ]
    },
    "OffensiveTool": {
      "properties": {
        "name": {
          "type": "string"
        },
        "purpose": {
          "type": "string"
        },
        "url": {
          "type": "string"
        },
        "template": {
          "type": "string"
        },
        "category": {
          "type": "string"
        },
        "license": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name"
      ]
    },
    "PathAnalysisResult": {
      "properties": {
        "allPaths": {
          "items": {
            "$ref": "#/$defs/AttackPath"
          },
          "type": "array"
        },
        "shortestPath": {
          "$ref": "#/$defs/AttackPath"
        },
        "criticalPaths": {
          "items": {
            "$ref": "#/$defs/AttackPath"
          },
          "type": "array"
        },
        "reachableNodes": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "unreachableTargets": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "PatternCodeExample": {
      "properties": {
        "language": {
          "type": "string"
        },
        "framework": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "code": {
          "type": "string"
        },
        "explanation": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "language",
        "code"
      ]
    },
    "PatternDetection": {
      "properties": {
        "name": {
          "type": "string"
        },
        "format": {
          "$ref": "#/$defs/DetectionFormat"
        },
        "rule": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "falsePositives": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name"
      ]
    },
    "PayloadPattern": {
      "properties": {
        "type": {
          "type": "string"
        },
        "pattern": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "variants": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "encoding": {
          "type": "string"
        },
        "bypassTarget": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "type",
        "pattern"
      ]
    },
    "Percentage": {
      "properties": {
        "min": {
          "type": "number"
        },
        "max": {
          "type": "number"
        },
        "mostLikely": {
          "type": "number"
        },
        "confidence": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "min",
        "max",
        "mostLikely"
      ]
    },
    "Phase": {
      "properties": {
        "name": {
          "type": "string"
        },
        "mitreTactic": {
          "$ref": "#/$defs/MITRETactic"
        },
        "description": {
          "type": "string"
        },
        "startMessage": {
          "type": "integer"
        },
        "endMessage": {
          "type": "integer"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "name",
        "startMessage",
        "endMessage"
      ]
    },
    "PlaybookPhase": {
      "type": "string",
      "enum": [
        "preparation",
        "identification",
        "containment",
        "eradication",
        "recovery",
        "lessons-learned"
      ]
    },
    "PlaybookStep": {
      "properties": {
        "step": {
          "type": "integer"
        },
        "phase": {
          "$ref": "#/$defs/PlaybookPhase"
        },
        "action": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "owner": {
          "type": "string"
        },
        "automated": {
          "type": "boolean"
        },
        "automationScript": {
          "type": "string"
        },
        "timeMinutes": {
          "type": "integer"
        },
        "dependencies": {
          "items": {
            "type": "integer"
          },
          "type": "array"
        },
        "escalationTrigger": {
          "type": "string"
        },
        "notes": {
          "type": "string"
        },
        "commands": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "checklist": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "step",
        "action"
      ]
    },
    "Prerequisite": {
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/AssumptionType"
        },
        "required": {
          "type": "boolean"
        },
        "status": {
          "type": "string"
        },
        "dependsOn": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "relatedThreatIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "notes": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "title"
      ]
    },
    "Reference": {
      "properties": {
        "title": {
          "type": "string"
        },
        "url": {
          "type": "string"
        },
        "type": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "title",
        "url"
      ]
    },
    "RemediationGuidance": {
      "properties": {
        "vulnerablePatterns": {
          "items": {
            "$ref": "#/$defs/CodePattern"
          },
          "type": "array"
        },
        "securePatterns": {
          "items": {
            "$ref": "#/$defs/CodePattern"
          },
          "type": "array"
        },
        "reviewChecklist": {
          "items": {
            "$ref": "#/$defs/ChecklistItem"
          },
          "type": "array"
        },
        "recommendedLibraries": {
          "items": {
            "$ref": "#/$defs/Library"
          },
          "type": "array"
        },
        "configurationChanges": {
          "items": {
            "$ref": "#/$defs/ConfigChange"
          },
          "type": "array"
        },
        "testingApproach": {
          "$ref": "#/$defs/TestingApproach"
        },
        "timeToFix": {
          "type": "string"
        },
        "complexity": {
          "type": "string"
        },
        "breakingChanges": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "notes": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "ResourceLevel": {
      "type": "string",
      "enum": [
        "minimal",
        "limited",
        "moderate",
        "extensive",
        "unlimited"
      ]
    },
    "ResponseAction": {
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "triggerDetectionIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "actionType": {
          "type": "string"
        },
        "automated": {
          "type": "boolean"
        },
        "playbookUrl": {
          "type": "string"
        },
        "owner": {
          "type": "string"
        },
        "escalationPath": {
          "type": "string"
        },
        "slaMinutes": {
          "type": "integer"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "title"
      ]
    },
    "RiskAssessment": {
      "properties": {
        "likelihood": {
          "type": "integer"
        },
        "impact": {
          "type": "integer"
        },
        "score": {
          "type": "integer"
        },
        "level": {
          "$ref": "#/$defs/RiskLevel"
        },
        "likelihoodRationale": {
          "type": "string"
        },
        "impactRationale": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "likelihood",
        "impact"
      ]
    },
    "RiskLevel": {
      "type": "string",
      "enum": [
        "critical",
        "high",
        "medium",
        "low",
        "info"
      ]
    },
    "SBOMReference": {
      "properties": {
        "format": {
          "type": "string"
        },
        "version": {
          "type": "string"
        },
        "uri": {
          "type": "string"
        },
        "serialNumber": {
          "type": "string"
        },
        "documentNamespace": {
          "type": "string"
        },
        "components": {
          "items": {
            "$ref": "#/$defs/ComponentReference"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "SSVCAssessment": {
      "properties": {
        "vulnerabilityId": {
          "type": "string"
        },
        "exploitation": {
          "type": "string"
        },
        "automatable": {
          "type": "string"
        },
        "technicalImpact": {
          "type": "string"
        },
        "missionPrevalence": {
          "type": "string"
        },
        "publicWellBeing": {
          "type": "string"
        },
        "decision": {
          "type": "string"
        },
        "notes": {
          "type": "string"
        },
        "assessedAt": {
          "type": "string"
        },
        "assessedBy": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "STRIDEMapping": {
      "properties": {
        "category": {
          "$ref": "#/$defs/STRIDEThreat"
        },
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "affectedComponents": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "category"
      ]
    },
    "STRIDEReportBody": {
      "properties": {
        "mappings": {
          "items": {
            "$ref": "#/$defs/STRIDEMapping"
          },
          "type": "array"
        },
        "coverageByCategory": {
          "additionalProperties": {
            "type": "integer"
          },
          "type": "object"
        },
        "categoriesCovered": {
          "items": {
            "$ref": "#/$defs/STRIDEThreat"
          },
          "type": "array"
        },
        "categoriesMissing": {
          "items": {
            "$ref": "#/$defs/STRIDEThreat"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "mappings",
        "coverageByCategory",
        "categoriesCovered",
        "categoriesMissing"
      ]
    },
    "STRIDEThreat": {
      "type": "string",
      "enum": [
        "S",
        "T",
        "R",
        "I",
        "D",
        "E"
      ]
    },
    "Scenario": {
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/ScenarioType"
        },
        "threatActorId": {
          "type": "string"
        },
        "preconditions": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "attackPath": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "targetAssetIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "targetElementIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "threatIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "risk": {
          "$ref": "#/$defs/RiskAssessment"
        },
        "outcome": {
          "type": "string"
        },
        "businessImpact": {
          "type": "string"
        },
        "mitigationIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "detectionIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "notes": {
          "type": "string"
        },
        "producerRunId": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "title"
      ]
    },
    "ScenarioType": {
      "type": "string",
      "enum": [
        "external-attack",
        "insider-threat",
        "supply-chain",
        "data-breach",
        "privacy-violation",
        "denial-of-service",
        "escalation"
      ]
    },
    "SecurityMetrics": {
      "properties": {
        "mttd": {
          "$ref": "#/$defs/MetricDuration"
        },
        "mttr": {
          "$ref": "#/$defs/MetricDuration"
        },
        "mttc": {
          "$ref": "#/$defs/MetricDuration"
        },
        "mttre": {
          "$ref": "#/$defs/MetricDuration"
        },
        "detectionRate": {
          "type": "number"
        },
        "falsePositiveRate": {
          "type": "number"
        },
        "truePositiveRate": {
          "type": "number"
        },
        "escalationRate": {
          "type": "number"
        },
        "incidentCount": {
          "type": "integer"
        },
        "alertVolume": {
          "type": "integer"
        },
        "measuredAt": {
          "type": "string"
        },
        "measurementPeriod": {
          "type": "string"
        },
        "notes": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "SecurityRequirement": {
      "properties": {
        "id": {
          "type": "string"
        },
        "statement": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/SecurityRequirementType"
        },
        "criticality": {
          "type": "string"
        },
        "originArtifactId": {
          "type": "string"
        },
        "verificationIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "statement",
        "type"
      ]
    },
    "SecurityRequirementType": {
      "type": "string",
      "enum": [
        "invariant",
        "prohibited-outcome",
        "privacy-requirement",
        "approval-requirement",
        "recovery-requirement",
        "detection-requirement"
      ]
    },
    "SensitivityLevel": {
      "type": "string",
      "enum": [
        "public",
        "internal",
        "confidential",
        "restricted",
        "secret"
      ]
    },
    "Sophistication": {
      "type": "string",
      "enum": [
        "none",
        "low",
        "medium",
        "high",
        "advanced"
      ]
    },
    "Stage": {
      "type": "string",
      "enum": [
        "product-definition",
        "builder-definition",
        "implementation",
        "deployment",
        "builder-operations",
        "product-operations"
      ]
    },
    "Target": {
      "properties": {
        "elementId": {
          "type": "string"
        },
        "classification": {
          "$ref": "#/$defs/AssetClassification"
        },
        "strideThreats": {
          "items": {
            "$ref": "#/$defs/STRIDEThreat"
          },
          "type": "array"
        },
        "impact": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "elementId",
        "classification"
      ]
    },
    "TechniqueCoverage": {
      "properties": {
        "techniqueId": {
          "type": "string"
        },
        "techniqueName": {
          "type": "string"
        },
        "tactic": {
          "type": "string"
        },
        "coverage": {
          "$ref": "#/$defs/CoverageLevel"
        },
        "detectionIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "dataSources": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "notes": {
          "type": "string"
        },
        "confidence": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "techniqueId",
        "coverage"
      ]
    },
    "TestPurpose": {
      "type": "string",
      "enum": [
        "exploitation",
        "detection",
        "remediation",
        "regression"
      ]
    },
    "TestReference": {
      "properties": {
        "testId": {
          "type": "string"
        },
        "testFile": {
          "type": "string"
        },
        "purpose": {
          "$ref": "#/$defs/TestPurpose"
        },
        "description": {
          "type": "string"
        },
        "suiteId": {
          "type": "string"
        },
        "attackStep": {
          "type": "integer"
        },
        "automated": {
          "type": "boolean"
        },
        "tool": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "testId",
        "purpose"
      ]
    },
    "TestSuiteReference": {
      "properties": {
        "suiteId": {
          "type": "string"
        },
        "suiteFile": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "tests": {
          "items": {
            "$ref": "#/$defs/TestReference"
          },
          "type": "array"
        },
        "tags": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "ciEnabled": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "suiteId"
      ]
    },
    "TestingApproach": {
      "properties": {
        "unitTests": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "integrationTests": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "securityTests": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "regressionTests": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "manualTests": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "testRefs": {
          "items": {
            "$ref": "#/$defs/TestReference"
          },
          "type": "array"
        },
        "acceptanceCriteria": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "tools": {
          "items": {
            "type": "string"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "ThreatActor": {
      "properties": {
        "id": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "type": {
          "$ref": "#/$defs/ThreatActorType"
        },
        "aliases": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "description": {
          "type": "string"
        },
        "sophistication": {
          "$ref": "#/$defs/Sophistication"
        },
        "motivations": {
          "items": {
            "$ref": "#/$defs/Motivation"
          },
          "type": "array"
        },
        "resources": {
          "$ref": "#/$defs/ResourceLevel"
        },
        "primaryGoals": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "ttps": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "targetedIndustries": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "targetedRegions": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "knownCampaigns": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "references": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "producerRunId": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "name",
        "type"
      ]
    },
    "ThreatActorType": {
      "type": "string",
      "enum": [
        "nation-state",
        "criminal",
        "hacktivist",
        "insider",
        "competitor",
        "terrorist",
        "script-kiddie",
        "researcher"
      ]
    },
    "ThreatEntry": {
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "strideCategory": {
          "$ref": "#/$defs/STRIDEThreat"
        },
        "linddunCategory": {
          "$ref": "#/$defs/LINDDUNThreat"
        },
        "affectedElements": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "affectedAssets": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "status": {
          "$ref": "#/$defs/ThreatStatus"
        },
        "risk": {
          "$ref": "#/$defs/RiskAssessment"
        },
        "severity": {
          "type": "string"
        },
        "likelihood": {
          "type": "string"
        },
        "mitigationIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "attackVector": {
          "type": "string"
        },
        "preconditions": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "ssvcAssessment": {
          "$ref": "#/$defs/SSVCAssessment"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "title",
        "status"
      ]
    },
    "ThreatModel": {
      "properties": {
        "id": {
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "version": {
          "type": "string"
        },
        "phase": {
          "$ref": "#/$defs/ModelPhase"
        },
        "authors": {
          "items": {
            "$ref": "#/$defs/Author"
          },
          "type": "array"
        },
        "references": {
          "items": {
            "$ref": "#/$defs/Reference"
          },
          "type": "array"
        },
        "mappings": {
          "$ref": "#/$defs/Mappings"
        },
        "diagrams": {
          "items": {
            "$ref": "#/$defs/DiagramView"
          },
          "type": "array"
        },
        "threatActors": {
          "items": {
            "$ref": "#/$defs/ThreatActor"
          },
          "type": "array"
        },
        "assumptions": {
          "items": {
            "$ref": "#/$defs/Assumption"
          },
          "type": "array"
        },
        "prerequisites": {
          "items": {
            "$ref": "#/$defs/Prerequisite"
          },
          "type": "array"
        },
        "mitigations": {
          "items": {
            "$ref": "#/$defs/Mitigation"
          },
          "type": "array"
        },
        "assets": {
          "items": {
            "$ref": "#/$defs/Asset"
          },
          "type": "array"
        },
        "scenarios": {
          "items": {
            "$ref": "#/$defs/Scenario"
          },
          "type": "array"
        },
        "redTeam": {
          "$ref": "#/$defs/ExploitationGuidance"
        },
        "blueTeam": {
          "$ref": "#/$defs/DefenseGuidance"
        },
        "remediation": {
          "$ref": "#/$defs/RemediationGuidance"
        },
        "playbooks": {
          "items": {
            "$ref": "#/$defs/IncidentPlaybook"
          },
          "type": "array"
        },
        "testSuites": {
          "items": {
            "$ref": "#/$defs/TestSuiteReference"
          },
          "type": "array"
        },
        "riskAssessment": {
          "$ref": "#/$defs/FAIRAssessment"
        },
        "businessImpact": {
          "$ref": "#/$defs/BusinessImpact"
        },
        "epssData": {
          "items": {
            "$ref": "#/$defs/EPSSData"
          },
          "type": "array"
        },
        "atomicTests": {
          "items": {
            "$ref": "#/$defs/AtomicTestMapping"
          },
          "type": "array"
        },
        "detectionCoverage": {
          "$ref": "#/$defs/DetectionCoverageMatrix"
        },
        "metrics": {
          "$ref": "#/$defs/SecurityMetrics"
        },
        "sbom": {
          "$ref": "#/$defs/SBOMReference"
        },
        "vexStatements": {
          "items": {
            "$ref": "#/$defs/VEXStatement"
          },
          "type": "array"
        },
        "dependencyRisks": {
          "items": {
            "$ref": "#/$defs/DependencyRisk"
          },
          "type": "array"
        },
        "credentialFlows": {
          "items": {
            "$ref": "#/$defs/CredentialFlow"
          },
          "type": "array"
        },
        "attackPatterns": {
          "items": {
            "$ref": "#/$defs/AttackPattern"
          },
          "type": "array"
        },
        "lifecycle": {
          "$ref": "#/$defs/Lifecycle"
        },
        "artifacts": {
          "items": {
            "$ref": "#/$defs/Artifact"
          },
          "type": "array"
        },
        "analysisRuns": {
          "items": {
            "$ref": "#/$defs/AnalysisRun"
          },
          "type": "array"
        },
        "evidence": {
          "items": {
            "$ref": "#/$defs/Evidence"
          },
          "type": "array"
        },
        "securityRequirements": {
          "items": {
            "$ref": "#/$defs/SecurityRequirement"
          },
          "type": "array"
        },
        "architectureAssertions": {
          "items": {
            "$ref": "#/$defs/ArchitectureAssertion"
          },
          "type": "array"
        },
        "findings": {
          "items": {
            "$ref": "#/$defs/Finding"
          },
          "type": "array"
        },
        "gates": {
          "items": {
            "$ref": "#/$defs/Gate"
          },
          "type": "array"
        },
        "frameworkReports": {
          "items": {
            "$ref": "#/$defs/FrameworkReport"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "id",
        "title",
        "diagrams"
      ]
    },
    "ThreatStatus": {
      "type": "string",
      "enum": [
        "potential",
        "theoretical",
        "identified",
        "analyzing",
        "mitigated",
        "accepted",
        "transferred",
        "monitoring"
      ]
    },
    "VEXStatement": {
      "properties": {
        "id": {
          "type": "string"
        },
        "vulnerabilityId": {
          "type": "string"
        },
        "status": {
          "type": "string"
        },
        "justification": {
          "type": "string"
        },
        "impactStatement": {
          "type": "string"
        },
        "actionStatement": {
          "type": "string"
        },
        "products": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "subcomponents": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "supplier": {
          "type": "string"
        },
        "timestamp": {
          "type": "string",
          "format": "date-time"
        },
        "lastUpdated": {
          "type": "string",
          "format": "date-time"
        },
        "version": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "ValidationStatus": {
      "type": "string",
      "enum": [
        "not-validated",
        "validated",
        "invalidated",
        "pending"
      ]
    },
    "WebSocketConfig": {
      "properties": {
        "protocol": {
          "$ref": "#/$defs/WebSocketProtocol"
        },
        "endpoint": {
          "type": "string"
        },
        "allowedOrigins": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "originValidation": {
          "type": "boolean"
        },
        "csrfProtection": {
          "type": "boolean"
        },
        "authenticationRequired": {
          "type": "boolean"
        },
        "authenticationMethod": {
          "type": "string"
        },
        "rateLimitRps": {
          "type": "integer"
        },
        "rateLimitConnections": {
          "type": "integer"
        },
        "messageSizeLimit": {
          "type": "integer"
        },
        "subProtocols": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "vulnerabilities": {
          "items": {
            "$ref": "#/$defs/WebSocketVulnerability"
          },
          "type": "array"
        }
      },
      "additionalProperties": false,
      "type": "object"
    },
    "WebSocketProtocol": {
      "type": "string",
      "enum": [
        "ws",
        "wss"
      ]
    },
    "WebSocketVulnType": {
      "type": "string",
      "enum": [
        "cswsh",
        "no-origin-validation",
        "no-rate-limit",
        "no-authentication",
        "weak-authentication",
        "no-encryption",
        "message-injection",
        "denial-of-service"
      ]
    },
    "WebSocketVulnerability": {
      "properties": {
        "type": {
          "$ref": "#/$defs/WebSocketVulnType"
        },
        "description": {
          "type": "string"
        },
        "cweIds": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "severity": {
          "type": "string"
        },
        "exploitable": {
          "type": "boolean"
        }
      },
      "additionalProperties": false,
      "type": "object",
      "required": [
        "type"
      ]
    }
  }
}