pompelmi
Version:
RFI-safe file uploads for Node.js — Express/Koa/Next.js middleware with deep ZIP inspection, MIME/size checks, and optional YARA scanning.
16 lines (15 loc) • 389 B
TypeScript
import type { ScanReport } from './types';
/**
* React Hook: handles <input type="file" onChange> with validation + scanning.
*/
export declare function useFileScanner(): {
results: {
file: File;
report: ScanReport;
}[];
errors: {
file: File;
error: string;
}[];
onChange: (e: React.ChangeEvent<HTMLInputElement>) => Promise<void>;
};