File tree Expand file tree Collapse file tree 2 files changed +13
-13
lines changed Expand file tree Collapse file tree 2 files changed +13
-13
lines changed Original file line number Diff line number Diff line change @@ -117,6 +117,18 @@ def completer(text, state):
117
117
atexit .register (readline .write_history_file , HISTFILE )
118
118
119
119
120
+ # kill process by name
121
+ def check_kill_process (pstring ):
122
+ '''
123
+ cross-platform way of killing process by name
124
+ '''
125
+ import psutil
126
+
127
+ for proc in psutil .process_iter ():
128
+ if pstring in str (proc .cmdline ):
129
+ proc .kill ()
130
+
131
+
120
132
def debug_except ():
121
133
'''
122
134
display traceback info
Original file line number Diff line number Diff line change 14
14
import lib .cli .console as console
15
15
import lib .tools .baidu as baidu
16
16
import lib .tools .exploits as ExecExp
17
- from lib .cli .console import debug_except , input_check
17
+ from lib .cli .console import debug_except , input_check , check_kill_process
18
18
from lib .tools import zoomeye
19
19
20
20
@@ -37,18 +37,6 @@ class SessionParameters:
37
37
'\\ data\\ ss.json'
38
38
39
39
40
- # kill process by name
41
- def check_kill_process (pstring ):
42
- '''
43
- cross-platform way of killing process by name
44
- '''
45
- import psutil
46
-
47
- for proc in psutil .process_iter ():
48
- if pstring in str (proc .cmdline ):
49
- proc .kill ()
50
-
51
-
52
40
def list_exp ():
53
41
'''
54
42
list all labeled exploits under the root of your exploit dir
You can’t perform that action at this time.
0 commit comments