forked from yzddmr6/As-Exploits
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
58 lines (55 loc) · 1.47 KB
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
"use strict";
const WIN = require("ui/window"); // 窗口库
const Modules = {
base_info: ["php", "jsp", "aspx"],
reverse_shell: ["php", "jsp", "aspx"],
memshell_inject: ["jsp", "aspx"],
memshell_manage: ["jsp", "aspx"],
av_list: ["*"],
exploit_suggest: ["*"],
screen_shot: ["jsp", "aspx"],
shellcode_loader: ["aspx", "jsp"],
jar_loader: ["jsp"],
bypass_openrasp: ["jsp"],
exec_payload: ["*"],
about: ["*"],
};
/**
* 插件类
*/
class Plugin {
constructor(opt) {
let self = this;
self.opt = opt;
self.core = new antSword["core"][opt["type"]](opt);
let cores = {};
for (let _ in Modules) {
cores[_] = require(`./core/${_}/index`);
}
self.cores = cores;
// 创建一个 window
let win = new WIN({
title: `As-Exploits v1.4 ${opt["ip"]} ${opt.type} By: yzddMr6`,
height: 650,
width: 850,
});
this.win = win;
self.main_layout = win.win.attachLayout("1C");
self.main_cell = self.main_layout.cells("a");
self.tabbar = self.main_cell.attachTabbar();
self.tabbar.setAlign("left");
self.cores_instance = [];
for (let module in Modules) {
if (
Modules[module].includes(self.opt.type) ||
Modules[module].includes("*")
) {
self.cores_instance[module] = new self.cores[module](self);
let instance = self.cores_instance[module];
instance.setName(module);
instance.createLayout(self.tabbar);
}
}
}
}
module.exports = Plugin;