/** * [WHO]: DangerDetector * [FROM]: Depends on node:os, node:path, ../interface.js * [TO]: Consumed by extension entry point (./index.ts) * [HERE]: extensions/builtin/security-audit/engine/detector.ts - */ import type { SecurityCheckResult, SecurityConfig } from "../interface.js"; /** * Danger Detector class */ export declare class DangerDetector { private dangerousPatterns; private sensitivePaths; private whitelist; constructor(config?: Partial); /** * Check if command is dangerous */ checkCommand(command: string): SecurityCheckResult; /** * Check if file operation is allowed */ checkFileOperation(operation: "read" | "write" | "edit", path: string): SecurityCheckResult; /** * Get human-readable reason for pattern */ private getReasonForPattern; /** * Get human-readable reason for sensitive path */ private getReasonForSensitivePath; /** * Update dangerous patterns */ setDangerousPatterns(patterns: string[]): void; /** * Update sensitive paths */ setSensitivePaths(paths: string[]): void; /** * Update whitelist */ setWhitelist(whitelist: string[]): void; }