Add files via upload

This commit is contained in:
PYDT authored and GitHub committed 2023-10-13 18:28:58 +08:00
1 parent 5524e2f689
commit f4bd217445
2 files changed
+19 -17

No files matched your search

+14 -13
View File
@@ -1157,23 +1157,24 @@ class MainWindow_Controller(QMainWindow):
existing_processes.add(p.pid)
psutil.Process(p.pid).suspend()
name, file, cmd = p.name(), p.exe().replace("\\", "/"), p.cmdline()
if "powershell" in name and self.api_scan(cmd[-1].split("'")[-2]):
p.kill()
self.send_notify(self.trans("惡意腳本攔截: ")+name)
elif "cmd.exe" in name and self.api_scan(" ".join(cmd[2:])):
p.kill()
self.send_notify(self.trans("惡意腳本攔截: ")+name)
elif self.scr_scan(cmd) or self.api_scan(cmd[-1]):
p.kill()
self.send_notify(self.trans("惡意軟體攔截: ")+name)
if ":/Windows" in file or ":/Program" in file:
if "powershell" in name and self.api_scan(cmd[-1].split("'")[-2]):
p.kill()
self.send_notify(self.trans("惡意腳本攔截: ")+name)
elif "cmd.exe" in name and self.api_scan(" ".join(cmd[2:])):
p.kill()
self.send_notify(self.trans("惡意腳本攔截: ")+name)
elif self.scr_scan(cmd) or self.api_scan(cmd[-1]):
p.kill()
self.send_notify(self.trans("惡意軟體攔截: ")+name)
elif file != self.pyas and file not in self.whitelist:
if self.sign_scan(file):
self.proc = p
if self.api_scan(file) or self.pe_scan(file):
p.kill()
self.send_notify(self.trans("惡意軟體攔截: ")+name)
elif self.sign_scan(file):
self.proc = p
psutil.Process(p.pid).resume()
gc.collect()
psutil.Process(p.pid).resume()
gc.collect()
except:
pass
+5 -4
View File
@@ -1,5 +1,8 @@
from PyQt5 import QtCore, QtGui, QtWidgets
import PYAS_Resource, sys
from PyQt5.QtGui import *
from PyQt5.QtCore import *
from PyQt5.QtWidgets import *
import sys, PYAS_Resource
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
@@ -11,9 +14,7 @@ class Ui_MainWindow(object):
font.setStyleStrategy(QtGui.QFont.PreferAntialias)
MainWindow.setFont(font)
MainWindow.setFocusPolicy(QtCore.Qt.TabFocus)
icon = QtGui.QIcon()
icon.addPixmap(QtGui.QPixmap(":/icon/Icon.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off)
MainWindow.setWindowIcon(icon)
MainWindow.setWindowIcon(QtGui.QIcon(QFileIconProvider().icon(QFileInfo(str(sys.argv[0])))))
MainWindow.setIconSize(QtCore.QSize(64, 64))
MainWindow.setToolButtonStyle(QtCore.Qt.ToolButtonIconOnly)
MainWindow.setDocumentMode(False)