Files
2026-06-16 04:58:56 +08:00

19 lines
511 B
PHP
Executable File

<?php
/**
* 日志 datatable 接口鉴权
*/
if (!function_exists('cloak_datatable_require_auth')) {
function cloak_datatable_require_auth()
{
if (session_status() !== PHP_SESSION_ACTIVE) {
session_start();
}
if (empty($_SESSION['password']) || $_SESSION['password'] != LOGIN_PASSWORD) {
unset($_SESSION['password']);
unset($_SESSION['check_result']);
http_response_code(404);
die('404 Not Found');
}
}
}