<% if _SESSION["logined"] ~= nil then local enable_systemlog = _POST["enable_systemlog"] local systemlog_filename = _POST["systemlog_filename"] local systemlog_maxsize = _POST["systemlog_maxsize"] --local enable_logfile_system = _POST["enable_logfile_system"] --local enable_logscrn_system = _POST["enable_logscrn_system"] --local enable_logfile_task = _POST["enable_logfile_task"] --local enable_logscrn_task = _POST["enable_logscrn_task"] local enable_auditing = _POST["enable_auditing"] local audit_db_filename = _POST["audit_db_filename"] local enable_list_cache = _POST["enable_list_cache"] local enable_thumbnail = _POST["enable_thumbnail"] local enable_ed2k_link = _POST["enable_ed2k_link"] local enable_online_edit = _POST["enable_online_edit"] --local disable_sslv3 = _POST["disable_sslv3"] local disable_tlsv1 = _POST["disable_tlsv1"] local disable_tlsv11 = _POST["disable_tlsv11"] local enable_fips = _POST["enable_fips"] local enable_mfmt = _POST["enable_mfmt"] local disable_ecdsakey = _POST["disable_ecdsakey"] local enable_chmod = _POST["enable_chmod"] local max_download_speed = _POST["max_download_speed"] local max_upload_speed = _POST["max_upload_speed"] local max_thread_num = _POST["max_thread_num"] local file_permissions = _POST["file_permissions"] local folder_permissions = _POST["folder_permissions"] local opensslciphers = _POST["opensslciphers"] local sftp_kex_algos = _POST["sftp_kex_algos"] local sftp_enc_algos = _POST["sftp_enc_algos"] local sftp_mac_algos = _POST["sftp_mac_algos"] local sftplog_level = _POST["sftplog_level"] local weblink_path = _POST["weblink_path"] if c_IsValidDir(weblink_path) == false then weblink_path = "_WEBLINK" end local uploadlink_path = _POST["uploadlink_path"] if c_IsValidDir(uploadlink_path) == false then uploadlink_path = "_UPLOADLINK" end local ipmask = _POST["ipmask"] local ipmasks = json.decode(ipmask) local global_ipmasks = {} if type(ipmasks) == "table" then for _,ipmask in pairs(ipmasks) do local temp = {} table.insert(temp,ipmask.ip) table.insert(temp,ipmask.refuse) table.insert(global_ipmasks,temp) end end local filemask = _POST["filemask"] local filemasks = json.decode(filemask) local global_filemasks = {} if type(filemasks) == "table" then for _,filemask in pairs(filemasks) do local temp = {} table.insert(temp,filemask.filename) table.insert(temp,filemask.refuse) table.insert(global_filemasks,temp) end end c_SetGlobalOptionInt(GOPTION_SYSTEM_LOGFILE_ENABLE_INT,enable_systemlog) c_SetGlobalOptionStr(GOPTION_SYSTEM_LOGFILE_FILENAME_STR,systemlog_filename) c_SetGlobalOptionInt(GOPTION_SYSTEM_LOGFILE_MAXSIZE_INT,systemlog_maxsize) --c_SetGlobalOptionInt(GOPTION_SYSTEM_LOGFILE_SYSTEM_ENABLE_INT,enable_logfile_system) --c_SetGlobalOptionInt(GOPTION_SYSTEM_LOGSCREEN_SYSTEM_ENABLE_INT,enable_logscrn_system) --c_SetGlobalOptionInt(GOPTION_SYSTEM_LOGFILE_TASK_ENABLE_INT,enable_logfile_task) --c_SetGlobalOptionInt(GOPTION_SYSTEM_LOGSCREEN_TASK_ENABLE_INT,enable_logscrn_task) c_DisconnectSQLITE() c_SetGlobalOptionInt(GOPTION_AUDIT_ENABLE_INT,enable_auditing) c_SetGlobalOptionStr(GOPTION_AUDITDB_FILENAME_STR,audit_db_filename) c_SetGlobalOptionInt(GOPTION_ENABLE_LIST_CACHE_INT,enable_list_cache) c_SetGlobalOptionInt(GOPTION_ENABLE_THUMBNAIL_INT,enable_thumbnail) c_SetGlobalOptionInt(GOPTION_ENABLE_ED2K_LINK_INT,enable_ed2k_link) c_SetGlobalOptionInt(GOPTION_ENABLE_ONLINE_EDIT_INT,enable_online_edit) --c_SetGlobalOptionInt(GOPTION_DISABLE_OPENSSLV3,disable_sslv3) c_SetGlobalOptionInt(GOPTION_DISABLE_TLSV1,disable_tlsv1) c_SetGlobalOptionInt(GOPTION_DISABLE_TLSV11,disable_tlsv11) c_SetGlobalOptionInt(GOPTION_ENABLE_FIPS,enable_fips) c_SetGlobalOptionInt(GOPTION_ENABLE_MFMT,enable_mfmt) c_SetGlobalOptionInt(GOPTION_DISABLE_ECDSA_KEY,disable_ecdsakey) c_SetGlobalOptionInt(GOPTION_ENABLE_CHMOD,enable_chmod) c_SetGlobalOptionInt(GOPTION_MAX_DOWNLOAD_SPEED_INT,max_download_speed) c_SetGlobalOptionInt(GOPTION_MAX_UPLOAD_SPEED_INT,max_upload_speed) c_SetGlobalOptionInt(GOPTION_MAX_THREADPOOL_INT,max_thread_num) c_SetGlobalOptionStr(GOPTION_DEFAULT_FILE_PERM,file_permissions) c_SetGlobalOptionStr(GOPTION_DEFAULT_FOLDER_PERM,folder_permissions) c_SetGlobalOptionStr(GOPTION_OPENSSL_CIPHERS,opensslciphers) c_SetGlobalOptionStr(GOPTION_SFTP_KEX_ALGOS,sftp_kex_algos) c_SetGlobalOptionStr(GOPTION_SFTP_ENC_ALGOS,sftp_enc_algos) c_SetGlobalOptionStr(GOPTION_SFTP_MAC_ALGOS,sftp_mac_algos) c_SetGlobalOptionInt(GOPTION_SSHLOG_LEVEL,sftplog_level) c_SetGlobalOptionStr(GOPTION_WEBLINK_PATH,weblink_path) c_SetGlobalOptionStr(GOPTION_UPLOADLINK_PATH,uploadlink_path) c_SetGlobalIPMaskList(global_ipmasks) c_SetGlobalFileMaskList(global_filemasks) end %>