import type { AuditEntry } from './types.js'; export declare class AuditLog { private readonly filePath; private lastHash; constructor(filePath: string); /** * Append an audit entry to the NDJSON log. * Each entry includes the SHA-256 hash of the previous entry * to create a tamper-evident hash chain. */ append(entry: AuditEntry): Promise; /** * Verify the integrity of the entire hash chain. * Returns { valid, entries, brokenAt } — brokenAt is the index * of the first entry with a hash mismatch, or -1 if all valid. */ verifyIntegrity(): Promise<{ valid: boolean; entries: number; brokenAt: number; }>; /** * Read all audit entries from the log file. */ private readAll; /** * Get the hash of the last entry in the log file. * Returns empty string if the file is empty or doesn't exist. */ private getLastHash; /** * Ensure the log file and parent directories exist. */ private ensureFileExists; }