-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvulxS.src
More file actions
34 lines (34 loc) · 1.67 KB
/
vulxS.src
File metadata and controls
34 lines (34 loc) · 1.67 KB
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
//--
//-- $$$$$$$$\ $$\
//-- \____$$ | $$ |
//-- $$ / $$$$$$\ $$ | $$$$$$\ $$\ $$\ $$\
//-- $$ / $$ __$$\ $$ |$$ __$$\ $$ | $$ | $$ |
//-- $$ / $$$$$$$$ |$$ |$$ / $$ |$$ | $$ | $$ |
//-- $$ / $$ ____|$$ |$$ | $$ |$$ | $$ | $$ |
//-- $$$$$$$$\\$$$$$$$\ $$ |\$$$$$$ |\$$$$$\$$$$ |
//-- \________|\_______|\__| \______/ \_____\____/
//--
//--For testing remote vulnerabilities takes optional port as the 3rd arg. Defaults to 22
//--Usage: vulxS [memory address] [value] [port?]
if params.len < 2 or params.len > 3 or params[0] == "-h" or params[0] == "--help" then exit("<b>Usage: "+program_path.split("/")[-1]+" [memory address] [value] [port]</b>")
metaxploit = include_lib("/lib/metaxploit.so")
if not metaxploit then
metaxploit = include_lib(current_path + "/metaxploit.so")
end if
if not metaxploit then exit("Error: Can't find metaxploit library in the /lib path or the current folder")
address = "1.1.1.1" //--use the ip of your test server that has the prepped ports and lib
pass = "123" //--whatver you want the password to be on exploit that changes pass
port = 22 //--default port
if params.len == 3 then port = params[2].to_int
memoryAddress = params[0]
value = params[1]
net_session = metaxploit.net_use(address, port)
if not net_session then exit("Error: can't connect to net session")
metaLib = net_session.dump_lib
result = metaLib.overflow(memoryAddress, value, pass)
print typeof(result)
if typeof(result) == "number" then print result
if typeof(result) == "file" then
print result.path
if not result.is_folder then print result.name + " contains:" + char(10) + result.get_content
end if