/home/u764571690/domains/savitrfoundation.com/public_html/F2
Edit: /home/u764571690/domains/savitrfoundation.com/public_html/F2/get_token.php (1846B)
'Unauthorized origin']);
exit;
}
// Generate secure token with enhanced security
$secret_key = 'finger_data_ultra_secure_' . date('Y-m-d') . '_xampp_htdocs_' . (isset($_SERVER['SERVER_NAME']) ? $_SERVER['SERVER_NAME'] : 'localhost');
$secret = hash('sha256', $secret_key);
$session_id = session_id();
$token = hash('sha256', $secret . $session_id);
// Store in session
$_SESSION['api_token'] = $token;
$_SESSION['api_authenticated'] = time();
$_SESSION['api_secret_key'] = $secret_key;
// Return token
echo json_encode([
'token' => $token,
'session_id' => $session_id,
'expires_in' => 3600,
'timestamp' => time()
]);