/** * Webhook Security * * Implements webhook signature verification and basic payload validation */ export interface WebhookSignatureResult { valid: boolean; error?: string; } export interface PayloadValidationResult { valid: boolean; blocked: boolean; threats?: string[]; sanitized?: unknown; } /** * Check if event has already been processed */ export declare function isEventProcessed(eventId: string): Promise; /** * Mark event as processed */ export declare function markEventProcessed(eventId: string, eventType: string, _issueKey?: string, _ticketId?: string, _payload?: unknown, _error?: unknown): Promise; /** * Clear processed events (useful for testing) */ export declare function clearProcessedEvents(): void; /** * Verify webhook signature using HMAC SHA256 */ export declare function verifyWebhookSignature(payload: string | Buffer, signature: string, secret: string): WebhookSignatureResult; /** * Validate webhook payload with basic checks * * Performs basic validation: length checks, type validation */ export declare function validateWebhookPayload(payload: unknown, options?: { blockSQLi?: boolean; blockXSS?: boolean; strict?: boolean; }): Promise; /** * Validate webhook security (signature + payload) */ export declare function validateWebhookSecurity(body: string | Buffer, signature: string, secret: string, payload: unknown, options?: { validatePayload?: boolean; blockSQLi?: boolean; blockXSS?: boolean; strict?: boolean; }): Promise<{ valid: boolean; signatureValid: boolean; payloadValid: boolean; blocked: boolean; reason?: string; threats?: string[]; }>; //# sourceMappingURL=webhook-security.d.ts.map