<% local msg = {} if _SESSION["logined"] ~= nil then local data = {} rawset(data, "sha256_enable", c_GetAdminOptionInt(ADMIN_OPTION_ENABLE_SHA256) == 1) rawset(data, "log_enable", c_GetAdminOptionInt(ADMIN_OPTION_LOGFILE_ENABLE_INT) == 1) rawset(data, "log_file", c_GetAdminOptionStr(ADMIN_OPTION_LOGFILE_FILENAME_STR)) rawset(data, "adminlog_maxsize", c_GetAdminOptionInt(ADMIN_OPTION_LOGFILE_MAXSIZE_INT)) rawset(data, "log_permission", c_GetAdminOptionStr(ADMIN_OPTION_LOG_FILE_PERM)) rawset(msg, "code", 0) rawset(msg, "data", data) else rawset(msg, "code", -1) rawset(msg, "error", "not logged in") end print(json.encode(msg)) %>