@seckav/security-sdk
Version:
SecKav Security SDK - Enterprise-grade security platform with AI-powered threat detection, LLM-powered misconfiguration scanning (Gemini/GPT-4/Claude), end-to-end encryption, behavioral analysis, enhanced file scanning, adaptive rate limiting, GDPR/DPDP/C
121 lines • 3.5 kB
TypeScript
import { SecKavConfig } from '../types/common';
export interface EncryptionConfig {
enabled: boolean;
algorithm: string;
keyRotationInterval: number;
encryptSensitiveRoutes: boolean;
encryptAllData: boolean;
sensitiveRoutes: string[];
exemptRoutes: string[];
tlsEnforcement: {
enabled: boolean;
minTlsVersion: string;
requireValidCertificate: boolean;
};
}
export interface EncryptionStatus {
enabled: boolean;
keyId: string;
algorithm: string;
createdAt: string;
expiresAt: string;
isExpired: boolean;
expiringSoon: boolean;
}
export interface EncryptionResult {
success: boolean;
data?: any;
error?: string;
message?: string;
}
export interface KeyRotationResult {
success: boolean;
newKeyId?: string;
algorithm?: string;
expiresAt?: string;
reason?: string;
error?: string;
message?: string;
}
export interface EncryptionTestResult {
success: boolean;
test?: {
algorithm: string;
keyId: string;
originalDataSize: number;
encryptedDataSize: number;
encryptionTime: string;
decryptionTime: string;
totalTime: string;
dataIntegrityCheck: string;
performanceMetrics: {
throughput: string;
efficiency: string;
};
};
error?: string;
message?: string;
}
export declare class EncryptionModule {
private config;
constructor(config: SecKavConfig);
/**
* Get encryption status for organization
*/
getEncryptionStatus(token: string): Promise<EncryptionResult>;
/**
* Get encryption configuration for organization
*/
getEncryptionConfiguration(token: string): Promise<EncryptionResult>;
/**
* Update encryption configuration
*/
updateEncryptionConfiguration(token: string, config: Partial<EncryptionConfig>): Promise<EncryptionResult>;
/**
* Manually rotate encryption key
*/
rotateEncryptionKey(token: string, reason?: string): Promise<KeyRotationResult>;
/**
* Get key rotation history
*/
getKeyRotationHistory(token: string, page?: number, limit?: number): Promise<EncryptionResult>;
/**
* Revoke specific encryption key
*/
revokeEncryptionKey(token: string, keyId: string, reason: string): Promise<EncryptionResult>;
/**
* Test encryption/decryption functionality
*/
testEncryption(token: string, data: any, algorithm?: string): Promise<EncryptionTestResult>;
/**
* Generate SSL certificate
*/
generateCertificate(token: string, domain: string, type?: string): Promise<EncryptionResult>;
/**
* Get certificate status
*/
getCertificateStatus(token: string): Promise<EncryptionResult>;
/**
* Enable encryption for organization
*/
enableEncryption(token: string, config?: Partial<EncryptionConfig>): Promise<EncryptionResult>;
/**
* Disable encryption for organization
*/
disableEncryption(token: string): Promise<EncryptionResult>;
/**
* Create encrypted HTTP client that automatically handles encryption headers
*/
createEncryptedClient(token: string): import("axios").AxiosInstance;
/**
* Get module information
*/
getInfo(): {
name: string;
version: string;
description: string;
features: string[];
apiUrl: string;
};
}
//# sourceMappingURL=EncryptionModule.d.ts.map