This commit is contained in:
2025-05-21 00:12:49 +00:00
parent 5c85188183
commit b1890f59ee
27 changed files with 2096 additions and 705 deletions

View File

@ -1,5 +1,5 @@
import * as plugins from '../../plugins.js';
import { MtaService } from '../delivery/classes.mta.js';
// MtaService reference removed
import { logger } from '../../logger.js';
import { SecurityLogger, SecurityLogLevel, SecurityEventType } from '../../security/index.js';
@ -20,14 +20,13 @@ export interface IDkimVerificationResult {
* Enhanced DKIM verifier using smartmail capabilities
*/
export class DKIMVerifier {
public mtaRef: MtaService;
// MtaRef reference removed
// Cache verified results to avoid repeated verification
private verificationCache: Map<string, { result: IDkimVerificationResult, timestamp: number }> = new Map();
private cacheTtl = 30 * 60 * 1000; // 30 minutes cache
constructor(mtaRefArg: MtaService) {
this.mtaRef = mtaRefArg;
constructor() {
}
/**