Files
securebit-chat/src/components/ui/SessionTimer.jsx

335 lines
12 KiB
React
Raw Normal View History

// SessionTimer Component - v4.02.985 - ECDH + DTLS + SAS
const SessionTimer = ({ timeLeft, sessionType, sessionManager, onDisconnect }) => {
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
const [currentTime, setCurrentTime] = React.useState(timeLeft || 0);
const [showExpiredMessage, setShowExpiredMessage] = React.useState(false);
const [initialized, setInitialized] = React.useState(false);
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
const [connectionBroken, setConnectionBroken] = React.useState(false);
2025-08-11 20:52:14 -04:00
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
const [loggedHidden, setLoggedHidden] = React.useState(false);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
React.useEffect(() => {
if (connectionBroken) {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
if (!loggedHidden) {
console.log('⏱️ SessionTimer initialization skipped - connection broken');
setLoggedHidden(true);
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
return;
}
let initialTime = 0;
if (sessionManager?.hasActiveSession()) {
initialTime = sessionManager.getTimeLeft();
} else if (timeLeft && timeLeft > 0) {
initialTime = timeLeft;
}
if (initialTime <= 0) {
setCurrentTime(0);
setInitialized(false);
setLoggedHidden(true);
return;
}
if (connectionBroken) {
setCurrentTime(0);
setInitialized(false);
setLoggedHidden(true);
return;
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
setCurrentTime(initialTime);
setInitialized(true);
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
setLoggedHidden(false);
}, [sessionManager, connectionBroken]);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
React.useEffect(() => {
if (connectionBroken) {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
if (!loggedHidden) {
setLoggedHidden(true);
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
return;
}
if (timeLeft && timeLeft > 0) {
setCurrentTime(timeLeft);
}
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
setLoggedHidden(false);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
}, [timeLeft, connectionBroken]);
React.useEffect(() => {
if (!initialized) {
return;
}
if (connectionBroken) {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
if (!loggedHidden) {
setLoggedHidden(true);
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
return;
}
if (!currentTime || currentTime <= 0 || !sessionManager) {
return;
}
const interval = setInterval(() => {
if (connectionBroken) {
setCurrentTime(0);
clearInterval(interval);
return;
}
if (sessionManager?.hasActiveSession()) {
const newTime = sessionManager.getTimeLeft();
setCurrentTime(newTime);
if (window.DEBUG_MODE && Math.floor(Date.now() / 30000) !== Math.floor((Date.now() - 1000) / 30000)) {
console.log('⏱️ Timer tick:', Math.floor(newTime / 1000) + 's');
}
if (newTime <= 0) {
setShowExpiredMessage(true);
setTimeout(() => setShowExpiredMessage(false), 5000);
clearInterval(interval);
}
} else {
setCurrentTime(0);
clearInterval(interval);
}
}, 1000);
return () => {
clearInterval(interval);
};
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
}, [initialized, currentTime, sessionManager, connectionBroken]);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
React.useEffect(() => {
const handleSessionTimerUpdate = (event) => {
if (connectionBroken) {
return;
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
if (event.detail.timeLeft && event.detail.timeLeft > 0) {
setCurrentTime(event.detail.timeLeft);
}
};
const handleForceHeaderUpdate = (event) => {
if (connectionBroken) {
return;
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
if (sessionManager && sessionManager.hasActiveSession()) {
const newTime = sessionManager.getTimeLeft();
setCurrentTime(newTime);
} else {
setCurrentTime(event.detail.timeLeft);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
}
};
const handlePeerDisconnect = (event) => {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
setConnectionBroken(true);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
setCurrentTime(0);
setShowExpiredMessage(false);
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
setLoggedHidden(false);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
};
const handleNewConnection = (event) => {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
setConnectionBroken(false);
setLoggedHidden(false);
};
const handleConnectionCleaned = (event) => {
setConnectionBroken(true);
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
setCurrentTime(0);
setShowExpiredMessage(false);
setInitialized(false);
setLoggedHidden(false);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
};
const handleSessionReset = (event) => {
setConnectionBroken(true);
setCurrentTime(0);
setShowExpiredMessage(false);
setInitialized(false);
setLoggedHidden(false);
};
const handleSessionCleanup = (event) => {
setConnectionBroken(true);
setCurrentTime(0);
setShowExpiredMessage(false);
setInitialized(false);
setLoggedHidden(false);
};
const handleDisconnected = (event) => {
setConnectionBroken(true);
setCurrentTime(0);
setShowExpiredMessage(false);
setInitialized(false);
setLoggedHidden(false);
};
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
document.addEventListener('session-timer-update', handleSessionTimerUpdate);
document.addEventListener('force-header-update', handleForceHeaderUpdate);
document.addEventListener('peer-disconnect', handlePeerDisconnect);
document.addEventListener('new-connection', handleNewConnection);
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
document.addEventListener('connection-cleaned', handleConnectionCleaned);
document.addEventListener('session-reset', handleSessionReset);
document.addEventListener('session-cleanup', handleSessionCleanup);
document.addEventListener('disconnected', handleDisconnected);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
return () => {
document.removeEventListener('session-timer-update', handleSessionTimerUpdate);
document.removeEventListener('force-header-update', handleForceHeaderUpdate);
document.removeEventListener('peer-disconnect', handlePeerDisconnect);
document.removeEventListener('new-connection', handleNewConnection);
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
document.removeEventListener('connection-cleaned', handleConnectionCleaned);
document.removeEventListener('session-reset', handleSessionReset);
document.removeEventListener('session-cleanup', handleSessionCleanup);
document.removeEventListener('disconnected', handleDisconnected);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
};
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
}, [sessionManager]);
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
if (showExpiredMessage) {
return React.createElement('div', {
className: 'session-timer expired flex items-center space-x-2 px-3 py-1.5 rounded-lg animate-pulse',
style: { background: 'linear-gradient(135deg, rgba(239, 68, 68, 0.2) 0%, rgba(220, 38, 38, 0.2) 100%)' }
}, [
React.createElement('i', {
key: 'icon',
className: 'fas fa-exclamation-triangle text-red-400'
}),
React.createElement('span', {
key: 'message',
className: 'text-red-400 text-sm font-medium'
}, 'Session Expired!')
]);
}
if (!sessionManager) {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
if (!loggedHidden) {
console.log('⏱️ SessionTimer hidden - no sessionManager');
setLoggedHidden(true);
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
return null;
}
if (connectionBroken) {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
if (!loggedHidden) {
console.log('⏱️ SessionTimer hidden - connection broken');
setLoggedHidden(true);
}
2025-08-11 20:52:14 -04:00
return null;
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
if (!currentTime || currentTime <= 0) {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
if (!loggedHidden) {
console.log('⏱️ SessionTimer hidden - no time left, currentTime:', currentTime);
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
setLoggedHidden(true);
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
return null;
}
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
if (loggedHidden) {
setLoggedHidden(false);
}
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
const totalMinutes = Math.floor(currentTime / (60 * 1000));
const totalSeconds = Math.floor(currentTime / 1000);
const isDemo = sessionType === 'demo';
const isWarning = isDemo ? totalMinutes <= 2 : totalMinutes <= 10;
const isCritical = isDemo ? totalSeconds <= 60 : totalMinutes <= 5;
2025-08-11 20:52:14 -04:00
const formatTime = (ms) => {
const hours = Math.floor(ms / (60 * 60 * 1000));
const minutes = Math.floor((ms % (60 * 60 * 1000)) / (60 * 1000));
const seconds = Math.floor((ms % (60 * 1000)) / 1000);
if (hours > 0) {
return `${hours}:${minutes.toString().padStart(2, '0')}:${seconds.toString().padStart(2, '0')}`;
} else {
return `${minutes}:${seconds.toString().padStart(2, '0')}`;
}
};
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
const getTimerStyle = () => {
Major Security Improvements: - Enhanced user fingerprinting with WebGL, Canvas, and Audio fingerprinting - Hardware binding to prevent F5/Ctrl+F5 abuse - Persistent storage across browser sessions (localStorage + sessionStorage) - Global demo session counter with 10 session limit per device - Multi-tab protection (max 2 tabs simultaneously) - Anti-reset protection with hardware mismatch detection Demo Session Protection: - Advanced fingerprint generation with CPU benchmarking - Enhanced validation with cryptographic verification - Automatic cleanup and session completion tracking - Cooldown periods between sessions (1min + 15min completion) - Weekly partial reset of global counters Fixes: - Fixed SessionTimer console spam after connection disconnect - Added missing registerEnhancedDemoSessionUsage method - Corrected method calls from generateUserFingerprint to generateAdvancedUserFingerprint - Implemented proper event handling for connection state changes WebRTC Improvements: - Added peer-disconnect, new-connection, and connection-cleaned events - Enhanced connection cleanup with proper UI notifications - Fixed SessionTimer state management during disconnections - Prevented infinite re-rendering and console logging Performance Optimizations: - Auto-save persistent data every 30 seconds - Periodic cleanup of old session data (every 6 hours) - Memory management for used preimages (10k limit) - Tab heartbeat system for multi-tab detection Testing: - Demo sessions now properly enforce limits - P2P anonymity maintained (no server validation) - Compatible with incognito mode restrictions - Resistant to common abuse techniques
2025-08-16 20:58:42 -04:00
const totalDuration = sessionType === 'demo' ? 6 * 60 * 1000 : 60 * 60 * 1000;
const timeProgress = (totalDuration - currentTime) / totalDuration;
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
let backgroundColor, textColor, iconColor, iconClass, shouldPulse;
if (timeProgress <= 0.33) {
backgroundColor = 'linear-gradient(135deg, rgba(34, 197, 94, 0.15) 0%, rgba(22, 163, 74, 0.15) 100%)';
textColor = 'text-green-400';
iconColor = 'text-green-400';
iconClass = 'fas fa-clock';
shouldPulse = false;
} else if (timeProgress <= 0.66) {
backgroundColor = 'linear-gradient(135deg, rgba(234, 179, 8, 0.15) 0%, rgba(202, 138, 4, 0.15) 100%)';
textColor = 'text-yellow-400';
iconColor = 'text-yellow-400';
iconClass = 'fas fa-clock';
shouldPulse = false;
} else {
backgroundColor = 'linear-gradient(135deg, rgba(239, 68, 68, 0.15) 0%, rgba(220, 38, 38, 0.15) 100%)';
textColor = 'text-red-400';
iconColor = 'text-red-400';
iconClass = 'fas fa-exclamation-triangle';
shouldPulse = true;
}
return { backgroundColor, textColor, iconColor, iconClass, shouldPulse };
};
const timerStyle = getTimerStyle();
const handleTimerClick = () => {
if (onDisconnect && typeof onDisconnect === 'function') {
onDisconnect();
}
};
2025-08-11 20:52:14 -04:00
return React.createElement('div', {
className: `session-timer flex items-center space-x-2 px-3 py-1.5 rounded-lg transition-all duration-500 cursor-pointer hover:opacity-80 ${
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
isDemo ? 'demo-session' : ''
} ${timerStyle.shouldPulse ? 'animate-pulse' : ''}`,
style: { background: timerStyle.backgroundColor },
onClick: handleTimerClick,
title: 'Click to disconnect and clear session'
2025-08-11 20:52:14 -04:00
}, [
React.createElement('i', {
key: 'icon',
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
className: `${timerStyle.iconClass} ${timerStyle.iconColor}`
2025-08-11 20:52:14 -04:00
}),
React.createElement('span', {
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
key: 'time',
className: `text-sm font-mono font-semibold ${timerStyle.textColor}`
}, formatTime(currentTime)),
React.createElement('div', {
key: 'progress',
className: 'ml-2 w-16 h-1 bg-gray-700 rounded-full overflow-hidden'
}, [
React.createElement('div', {
key: 'progress-bar',
className: `${timerStyle.textColor.replace('text-', 'bg-')} h-full rounded-full transition-all duration-500`,
style: {
width: `${Math.max(0, Math.min(100, (currentTime / (sessionType === 'demo' ? 6 * 60 * 1000 : 60 * 60 * 1000)) * 100))}%`
}
})
])
2025-08-11 20:52:14 -04:00
]);
};
feat: Enhanced demo mode security and vulnerability fixes - **Fixed demo mode timing attack vulnerability** - Added strict rate limiting and user fingerprinting - **Eliminated replay attack vectors** - Implemented preimage tracking and expiration validation - **Enhanced key reuse protection** - Added cryptographic validation and session isolation - **Strengthened free tier abuse prevention** - Multi-layer cooldown system with global limits - **Secure user fingerprinting** - Browser-based identification without privacy invasion - **Global session limits** - Maximum 10 concurrent demo sessions across all users - **Per-user daily limits** - 3 demo sessions per 24 hours with smart cooldown - **Session completion tracking** - Prevents rapid reconnection abuse - **Enhanced preimage generation** - Timestamped, versioned, and entropy-validated - **Configurable security layers** - Individual toggle for encryption, obfuscation, and traffic features - **Debug mode controls** - `window.DEBUG_MODE` for detailed logging and diagnostics - **Emergency security disable** - Graceful fallback when advanced features cause issues - **Vulnerability testing support** - Controlled security layer bypass for penetration testing - **Cross-session compatibility** - Works seamlessly with both paid and free sessions - **Real-time UI updates** - Synchronized timer display across all components - **Session state management** - Automatic cleanup and notification system - **Payment integration** - Smooth transition between demo and paid sessions - **Layered security architecture** - 7+ configurable security features with independent controls - **Traffic analysis protection** - Advanced obfuscation with fake traffic and packet padding - **Connection state monitoring** - Enhanced logging for security audit and debugging - **Fallback mechanisms** - Robust error handling with security-first degradation - **Structured security logs** - Detailed audit trail for security events - **Performance monitoring** - Connection state and encryption layer metrics - **Attack detection logging** - Comprehensive tracking of security violations - **Development diagnostics** - Enhanced debugging for faster development cycles - Refactored `PayPerSessionManager` with enhanced security controls - Added `generateUserFingerprint()` with privacy-preserving identification - Implemented `checkDemoSessionLimits()` with multi-tier validation - Enhanced `EnhancedSecureWebRTCManager` with configurable security layers - Added emergency security disable functionality for testing environments - Improved session timer with cross-component synchronization **Breaking Changes:** None - All changes are backward compatible **Security Impact:** High - Eliminates critical vulnerabilities in free tier **Testing Impact:** Significantly improved - New debug modes and security layer controls
2025-08-14 23:34:54 -04:00
window.SessionTimer = SessionTimer;
window.updateSessionTimer = (newTimeLeft, newSessionType) => {
document.dispatchEvent(new CustomEvent('session-timer-update', {
detail: { timeLeft: newTimeLeft, sessionType: newSessionType }
}));
};