From 8138179e6889898da2cbc0eaf1f2e2f860483404 Mon Sep 17 00:00:00 2001 From: "bt.cn" <31841517+aaPanel@users.noreply.github.com> Date: Sat, 16 Oct 2021 14:48:55 +0800 Subject: [PATCH] #Optimize APP login #Add XSS filtering in more places --- BTPanel/__init__.py | 76 +++++------------ class/config.py | 8 +- class/crontab.py | 4 +- class/data.py | 1 + class/database.py | 5 ++ class/files.py | 2 +- class/firewalls.py | 2 +- class/ftp.py | 2 +- class/panelSite.py | 13 +-- class/public.py | 114 +++++++++++++------------ class/wxapp.py | 204 ++++++-------------------------------------- 11 files changed, 126 insertions(+), 305 deletions(-) diff --git a/BTPanel/__init__.py b/BTPanel/__init__.py index c83787cc..bd9aed84 100644 --- a/BTPanel/__init__.py +++ b/BTPanel/__init__.py @@ -14,8 +14,9 @@ import threading import time import re import uuid +panel_path = '/www/server/panel' if not os.name in ['nt']: - os.chdir('/www/server/panel') + os.chdir(panel_path) if not 'class/' in sys.path: sys.path.insert(0,'class/') @@ -203,7 +204,7 @@ def error_404(e):