Linux ip-172-26-2-223 5.4.0-1018-aws #18-Ubuntu SMP Wed Jun 24 01:15:00 UTC 2020 x86_64
Apache
: 172.26.2.223 | : 18.217.140.32
Cant Read [ /etc/named.conf ]
8.1.13
www
www.github.com/MadExploits
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
CPANEL RESET
CREATE WP USER
BLACK DEFEND!
README
+ Create Folder
+ Create File
/
www /
server /
panel /
mod /
base /
web_conf /
[ HOME SHELL ]
Name
Size
Permission
Action
__pycache__
[ DIR ]
drwxr-xr-x
__init__.py
2.77
KB
-rw-r--r--
access_restriction.py
23.34
KB
-rw-r--r--
config_mgr.py
6.28
KB
-rw-r--r--
default_site.py
4.46
KB
-rw-r--r--
dir_tool.py
9.89
KB
-rw-r--r--
dns_api.py
62.05
KB
-rw-r--r--
domain_tool.py
12.46
KB
-rw-r--r--
ip_restrict.py
11.43
KB
-rw-r--r--
limit_net.py
10.47
KB
-rw-r--r--
logmanager.py
34.68
KB
-rw-r--r--
proxy.py
24.07
KB
-rw-r--r--
redirect.py
28.54
KB
-rw-r--r--
referer.py
14.65
KB
-rw-r--r--
ssl.py
51.7
KB
-rw-r--r--
util.py
5.19
KB
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : __init__.py
import json import os.path import shutil import sys if "/www/server/panel/class" not in sys.path: sys.path.insert(0, "/www/server/panel/class") from .ip_restrict import IpRestrict, RealIpRestrict from .redirect import RealRedirect, Redirect from .access_restriction import AccessRestriction, RealAccessRestriction from .domain_tool import domain_to_puny_code, check_domain, normalize_domain, NginxDomainTool, ApacheDomainTool, \ is_domain from .dns_api import DNSApiManager, RealDnsMager from .dir_tool import DirTool from .referer import Referer, RealReferer from .logmanager import LogMgr, RealLogMgr from .proxy import Proxy, RealProxy from .ssl import SSLManager, RealSSLManger from .config_mgr import ConfigMgr from .default_site import set_default_site, get_default_site, check_default def remove_sites_service_config(site_name: str, config_prefix: str = ""): """ 用于删除一个网站的nginx,apache的所有相关配置文件和配置项 包含: 配置文件,访问限制, 反向代理, 重定向, 防盗链,证书目录, IP黑白名单, 历史配置文件, 默认站点, 日志格式配置记录, 伪静态等 """ # 配置文件 ng_file = "/www/server/panel/vhost/nginx/{}{}.conf".format(config_prefix, site_name) if os.path.exists(ng_file): os.remove(ng_file) ap_file = "/www/server/panel/vhost/apache/{}{}.conf".format(config_prefix, site_name) if os.path.exists(ap_file): os.remove(ap_file) # 访问限制 RealAccessRestriction(config_prefix=config_prefix).remove_site_access_restriction_info(site_name) # 反向代理 RealProxy(config_prefix=config_prefix).remove_site_proxy_info(site_name) # 重定向 RealRedirect(config_prefix=config_prefix).remove_site_redirect_info(site_name) # 防盗链 RealReferer(config_prefix=config_prefix).remove_site_referer_info(site_name) # 证书目录 cert_path = "/www/server/panel/vhost/cert/" + site_name if os.path.isdir(cert_path): shutil.rmtree(cert_path) # IP黑白名单 RealIpRestrict(config_prefix=config_prefix).remove_site_ip_restrict_info(site_name) # 历史配置文件 ConfigMgr(site_name=site_name, config_prefix=config_prefix).clear_history_file() # 默认站点 d_site_name, d_prefix = get_default_site() if d_site_name == site_name and d_prefix == config_prefix: d_file = "/www/server/panel/data/mod_default_site.pl" f = open(d_file, mode="w+") json.dump({"name": None, "prefix": None}, f) # 日志格式配置记录 RealLogMgr(conf_prefix=config_prefix).remove_site_log_format_info(site_name) # 伪静态 rewrite_path = "/www/server/panel/vhost/rewrite/{}{}.conf".format(config_prefix, site_name) if os.path.isdir(rewrite_path): os.remove(rewrite_path)
Close