/**
 * Validate that a path is safe and within the allowed root directory
 */
export declare function validatePath(filePath: string, config?: SecurityConfig): string;
/**
 * Validate multiple paths
 */
export declare function validatePaths(filePaths: string[], config?: SecurityConfig): string[];
/**
 * Check if a path matches any blocked pattern
 */
export declare function isBlockedPath(filePath: string, config?: SecurityConfig): boolean;
/**
 * Validate file size
 */
export declare function validateFileSize(filePath: string, config?: SecurityConfig): Promise<number>;
/**
 * Check if path is a symbolic link
 */
export declare function isSymlink(filePath: string): Promise<boolean>;
/**
 * Validate that a path is not a symlink (or follow it if allowed)
 */
export declare function validateSymlink(filePath: string, config?: SecurityConfig): Promise<string>;
/**
 * Full path validation including all security checks
 */
export declare function validateFilePath(filePath: string, config?: SecurityConfig): Promise<{ path: string, size: number }>;
/**
 * Validate a batch of files with total size limit
 */
export declare function validateFileBatch(filePaths: string[], config?: SecurityConfig): Promise<{ paths: string[], totalSize: number }>;
/**
 * Create a timeout wrapper for async operations
 */
export declare function withTimeout<T>(promise: Promise<T>, timeoutMs: number, operation?: string): Promise<T>;
/**
 * Create a secure file processor with all protections
 */
export declare function createSecureProcessor<T>(processor: (filePath: string) => Promise<T>, config?: SecurityConfig): (filePath: string) => Promise<T>;
/**
 * Create a secure batch processor
 */
export declare function createSecureBatchProcessor<T>(processor: (filePaths: string[]) => Promise<T>, config?: SecurityConfig): (filePaths: string[]) => Promise<T>;
/**
 * Sanitize a filename to prevent path traversal
 */
export declare function sanitizeFilename(filename: string): string;
/**
 * Check if a path is safe (doesn't contain traversal sequences)
 */
export declare function isSafePath(path: string): boolean;
/**
 * Create security middleware for the generator
 */
export declare function createSecurityMiddleware(config?: SecurityConfig): {
  validatePath: (filePath: string) => string
  validatePaths: (filePaths: string[]) => string[]
  validateFile: (filePath: string) => Promise<{ path: string, size: number }>
  validateBatch: (filePaths: string[]) => Promise<{ paths: string[], totalSize: number }>
  withTimeout: <T>(promise: Promise<T>, operation?: string) => Promise<T>
  secureProcessor: <T>(processor: (filePath: string) => Promise<T>) => (filePath: string) => Promise<T>
  isBlocked: (filePath: string) => boolean
  getConfig: () => Required<SecurityConfig>
};
/**
 * Default security configuration
 */
export declare const DEFAULT_SECURITY_CONFIG: Required<SecurityConfig>;
/**
 * Security configuration options
 */
export declare interface SecurityConfig {
  rootDir?: string
  maxFileSize?: number
  maxTotalSize?: number
  timeout?: number
  followSymlinks?: boolean
  maxFiles?: number
  blockedPatterns?: string[]
}
/**
 * Security error codes
 */
export type SecurityErrorCode = | 'PATH_TRAVERSAL'
  | 'FILE_TOO_LARGE'
  | 'TOTAL_SIZE_EXCEEDED'
  | 'TIMEOUT'
  | 'SYMLINK_NOT_ALLOWED'
  | 'MAX_FILES_EXCEEDED'
  | 'BLOCKED_PATTERN'
  | 'INVALID_PATH';
/**
 * Security validation error
 */
export declare class SecurityError extends Error {
  public readonly code: SecurityErrorCode;
  public readonly path?: string;
  constructor(message: string, code: SecurityErrorCode, path?: string);
}
