/** * Security Tournament Engine * * Dual tournament RL system for zero-day discovery with live verification. * Two competing agents race to discover vulnerabilities - winner's strategy * updates the security model weights. * * This is the DEFAULT security capability for AGI Core. */ import { type SecurityFinding, type RemediationSummary } from './universalSecurityAudit.js'; export interface SecurityTournamentConfig { /** Working directory for storing tournament state */ workingDir: string; /** Target providers to audit */ providers: ('gcp' | 'aws' | 'azure')[]; /** GCP project IDs to scan */ projectIds?: string[]; /** Enable auto-remediation */ autoFix?: boolean; /** Include zero-day predictions */ includeZeroDay?: boolean; /** Max tournament rounds */ maxRounds?: number; /** Callback for progress updates */ onProgress?: (event: SecurityTournamentEvent) => void; } export interface SecurityTournamentEvent { type: 'round.start' | 'round.complete' | 'finding.discovered' | 'finding.verified' | 'finding.fixed' | 'tournament.complete'; round?: number; agent?: 'primary' | 'refiner'; finding?: SecurityFinding; summary?: SecurityTournamentSummary; } export interface SecurityTournamentSummary { totalRounds: number; primaryWins: number; refinerWins: number; ties: number; totalFindings: number; verifiedFindings: number; fixedFindings: number; criticalCount: number; highCount: number; mediumCount: number; duration: number; winningStrategy: string; } export interface AgentSecurityStrategy { /** Focus areas for this agent */ focusAreas: string[]; /** Test categories to prioritize */ priorityCategories: string[]; /** Heuristics to emphasize */ heuristics: string[]; /** Aggressiveness level 0-1 */ aggressiveness: number; } export interface TournamentWeights { /** Weight for number of findings */ findingsWeight: number; /** Weight for severity (critical > high > medium) */ severityWeight: number; /** Weight for verification success */ verificationWeight: number; /** Weight for successful remediation */ remediationWeight: number; /** Winning strategy history */ winningStrategies: string[]; /** Last updated timestamp */ lastUpdated: string; } export declare function runSecurityTournament(config: SecurityTournamentConfig): Promise<{ summary: SecurityTournamentSummary; findings: SecurityFinding[]; remediation?: RemediationSummary; }>; export declare function runQuickSecurityCheck(workingDir: string): Promise<{ status: 'secure' | 'at-risk' | 'critical'; findings: SecurityFinding[]; message: string; }>; export default runSecurityTournament; //# sourceMappingURL=securityTournament.d.ts.map