ctrlshiftleft
Version:
AI-powered toolkit for embedding QA and security testing into development workflows
38 lines (37 loc) • 1.52 kB
TypeScript
import { ChecklistItem, ImpactLevel, LikelihoodLevel } from '../types/checklistTypes';
/**
* Calculates a risk rating based on impact and likelihood
* @param impact Impact rating
* @param likelihood Likelihood rating
* @returns Risk rating (critical, high, medium, low, info)
*/
export declare function calculateRiskRating(impact: ImpactLevel, likelihood: LikelihoodLevel): 'critical' | 'high' | 'medium' | 'low' | 'info';
/**
* Formats a CVSS score with color based on severity
* @param score CVSS score (0.0-10.0)
* @returns Colored string representation
*/
export declare function formatCVSSScore(score: number): string;
/**
* Generates a colored security risk badge based on severity
* @param severity Risk severity
* @returns Colored badge string
*/
export declare function formatSeverityBadge(severity: string): string;
/**
* Creates a visual risk matrix representation
* @returns ASCII risk matrix as a string
*/
export declare function generateRiskMatrix(): string;
/**
* Generates a detailed risk report for a list of security checklist items
* @param items Array of security checklist items
* @returns Formatted risk report as a string
*/
export declare function generateSecurityRiskReport(items: ChecklistItem[]): string;
/**
* Converts a CVSS vector string to a human-readable explanation
* @param vector CVSS vector string (e.g., "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N")
* @returns Human-readable explanation
*/
export declare function explainCVSSVector(vector: string): string;