AeThex-OS/packages/aethex-core/lib/Compliance.d.ts

53 lines
No EOL
1.4 KiB
TypeScript

/**
* AeThex Compliance - COPPA/FERPA Age Gating & Audit Logging
* Provides compliance checks and audit trail management
*/
export interface AuditLogEntry {
userId: string;
type: string;
result: boolean;
timestamp: Date;
metadata?: Record<string, any>;
}
export declare class Compliance {
private static auditLog;
/**
* Check if user is COPPA compliant (13+)
*/
static isCOPPACompliant(age: number): boolean;
/**
* Check if user requires parental consent (<13)
*/
static requiresParentConsent(age: number): boolean;
/**
* Check if data collection is allowed
*/
static canCollectData(user: {
age: number;
parentConsent?: boolean;
}): boolean;
/**
* Log a compliance check for audit trail
*/
static logCheck(userId: string, type: string, result: boolean, metadata?: Record<string, any>): void;
/**
* Get audit log for a user
*/
static getAuditLog(userId?: string): AuditLogEntry[];
/**
* Clear audit log (admin only)
*/
static clearAuditLog(): void;
/**
* Export audit log as JSON
*/
static exportAuditLog(): string;
/**
* Check FERPA compliance (educational records)
*/
static isFERPACompliant(user: {
age: number;
educationalContext: boolean;
}): boolean;
}
//# sourceMappingURL=Compliance.d.ts.map