feat(security): migrate content scanning and bounce detection to Rust security bridge; add scanContent IPC command and Rust content scanner with tests; update TS RustSecurityBridge and callers, and adjust CI package references
This commit is contained in:
15
dist_ts/security/classes.rustsecuritybridge.d.ts
vendored
15
dist_ts/security/classes.rustsecuritybridge.d.ts
vendored
@@ -48,6 +48,12 @@ interface IReputationResult {
|
||||
listed_count: number;
|
||||
total_checked: number;
|
||||
}
|
||||
interface IContentScanResult {
|
||||
threatScore: number;
|
||||
threatType: string | null;
|
||||
threatDetails: string | null;
|
||||
scannedElements: string[];
|
||||
}
|
||||
interface IVersionInfo {
|
||||
bin: string;
|
||||
core: string;
|
||||
@@ -88,6 +94,13 @@ export declare class RustSecurityBridge {
|
||||
diagnosticCode?: string;
|
||||
statusCode?: string;
|
||||
}): Promise<IBounceDetection>;
|
||||
/** Scan email content for threats (phishing, spam, malware, etc.). */
|
||||
scanContent(opts: {
|
||||
subject?: string;
|
||||
textBody?: string;
|
||||
htmlBody?: string;
|
||||
attachmentNames?: string[];
|
||||
}): Promise<IContentScanResult>;
|
||||
/** Check IP reputation via DNSBL. */
|
||||
checkIpReputation(ip: string): Promise<IReputationResult>;
|
||||
/** Verify DKIM signatures on a raw email message. */
|
||||
@@ -123,4 +136,4 @@ export declare class RustSecurityBridge {
|
||||
mailFrom: string;
|
||||
}): Promise<IEmailSecurityResult>;
|
||||
}
|
||||
export type { IDkimVerificationResult, ISpfResult, IDmarcResult, IEmailSecurityResult, IValidationResult, IBounceDetection, IReputationResult as IRustReputationResult, IVersionInfo, };
|
||||
export type { IDkimVerificationResult, ISpfResult, IDmarcResult, IEmailSecurityResult, IValidationResult, IBounceDetection, IContentScanResult, IReputationResult as IRustReputationResult, IVersionInfo, };
|
||||
|
||||
Reference in New Issue
Block a user