1
0
ServicesList/_conf/protect.php
2025-06-17 21:07:09 +02:00

15 lines
339 B
PHP

<?php
// Security: prohibits direct access to the file
if (php_sapi_name() !== 'cli' && realpath(__FILE__) === realpath($_SERVER['SCRIPT_FILENAME'])) {
// Send HTTP code 404
http_response_code(404);
// Fallback for legacy servers (Apache, FastCGI)
header('Status: 404 Not Found');
// Stops the script
exit;
}
?>