目录

  • probe
    • 使用方法
    • 效果
  • routerpcscan
    • 使用方法
    • 效果

版本:Grey Hack v0.7.3618 - Alpha


probe

if params.len != 1 or params[0] == "-h" or params[0] == "--help" then exit(command_info("<b>probe [IP]</b>"))
if not is_valid_ip(params[0]) then exit("probe: invalid ip address")
if not get_shell.host_computer.is_network_active then exit("probe: can't connect. No internet access.")router = get_router(params[0])
ports = router.used_ports
devices = router.devices_lan_ip
print("\n<b>PORTS:</b>")
info = "PORT STATE SERVICE VERSION LAN"
for port in portsother_ip = port.get_lan_ipport_status = "Open"if port.is_closed thenport_status = "Closed"end ifinfo = info + "\n" + port.port_number + " " + port_status + " " + router.port_info(port) + " " + other_ip
end for
print(format_columns(info))
print("\n<b>DEVICES:</b>")
info = "DEVICE LAN STATE PORTS"
COMPUTERS = ""
ROUTERS = ""
SWITCHS = ""for device in devicesDP = router.device_ports(device)port_list = []for P in DPif typeof(P) != "port" then port_list = "Unreachable"breakend ifport_list = port_list + [P.port_number]end forport_list_str = "["for port in port_listport_list_str = port_list_str + str(port) + ","end forif(port_list_str == "[") then port_list_str = "[]"elseport_list_str = port_list_str[:-1] + "]"end ifnew_router = get_router(device)new_switch = get_switch(device)if new_router != null thenSTATE = new_router.firewall_rulesif STATE == [] thenSTATE = "None"elseSTATE = STATE[0].split(" ")[0]end ifif new_switch != null thenSWITCHS = SWITCHS + "SWITCH " + device + " " + STATE + " " + port_list_str + "\n"elseROUTERS = ROUTERS  + "ROUTER " + device + " " + STATE + " " + port_list_str + "\n"end ifend ifif new_switch == null and new_router == null thenif port_list != [] and port_list[0] == 8080 thenif device == router.local_ip thenSTATE = router.firewall_rulesif STATE == [] then STATE = "None"elseSTATE = "Unknown"end ifROUTERS = ROUTERS  + "ROUTER " + device + " " + STATE + " " + port_list_str + "\n"elseCOMPUTERS = COMPUTERS + "COMPUTER " + device + " " + "Null" + " " + port_list_str + "\n"end ifend if
end for
info = info + "\n" + COMPUTERS + "\n" + ROUTERS + "\n" + SWITCHS
print(format_columns(info))

使用方法

函数名 【公网IP】

效果

可以扫描到比nmap更多的信息
nmap的

probe

routerpcscan

if params.len != 2 or params[0] == "-h" or params[0] == "--help" then exit("<b>Usage: "+program_path.split("/")[-1]+" [ip_address] [LAN_address]</b>")
metaxploit = include_lib("/lib/metaxploit.so")
if not metaxploit thenmetaxploit = 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 = params[0]
net_session = metaxploit.net_use( address )
if not net_session then exit("Error: can't connect to net session")
libKernel = net_session.dump_libprint("\nFounded " + libKernel.lib_name + " "+ libKernel.version)if not libKernel then exit("Error: " + libName + " not found.")lanIp = params[1]kernel_router_exploits = metaxploit.scan(libKernel)lanIp = lanIp.split(".")
Head = lanIp[0]+"."+lanIp[1]+"."+lanIp[2]+"."
End = lanIp[-1].to_intGetKeyword = function()for kernel_router_exploit in kernel_router_exploitsresult_lists = metaxploit.scan_address(libKernel, kernel_router_exploit).split("Unsafe check: ")[1:]for result_list in result_liststarget_str = result_list.split(".")[0]target_key = target_str.split(" ")[-1]for _ in range(1, 255, 1)if _ != End thenresult = libKernel.overflow(kernel_router_exploit, target_key[3:-4], Head + str(_))if typeof(result) == "computer" thenreturn [kernel_router_exploit, target_key[3:-4]]else if typeof(result) != "null" and typeof(result) != "computer" thenbreakend ifend ifend forif typeof(result) != "null" and typeof(result) != "computer" then continueend forend for
end functionKey = GetKeyword()Output = ""for _ in range(1, 255, 1)if _ != End thenresult = libKernel.overflow(Key[0], Key[1], Head + str(_))if typeof(result) == "computer" thenOutput = Output + Head + str(_) + "\n"end ifend if
end for
clear_screen
if Output == "" then exit("<b>Fail...</b>")
elseprint("<b>Found Computers: </b>\n")print(Output)
end if

使用方法

函数名 【公网IP】【路由器局域网IP】

效果

配合probe的扫描结果可搜寻该局域网路由器下的computer

【 Grey Hack 】加强版nmap相关推荐

  1. 【 Grey Hack 】综合工具 shellOs

    目录 交互界面 基本功能 本地攻击 攻击本机 远程攻击 应用程序 扫描功能 更新IP并扫描 深度扫描 黑入功能 类shell交互界面 一些特殊命令 bounce run ScanPsw vim bui ...

  2. 【 Grey Hack 】大数四则运算

    目录 效果 加 减 乘 除 乘方 源码 版本:Grey Hack v0.7.3619 - Alpha 在Gs中,位数大于15的整数将以科学计数法显示,故这里提供一种基于字符串加法的四则大数运算算法.由 ...

  3. 【 Grey Hack 】WIFI万能钥匙

    目录 脚本源码 使用方法 效果 版本:Grey Hack v0.7.3618 - Alpha 脚本源码 computer = get_shell.host_computer status = &quo ...

  4. 【 Grey Hack 】记一次被黑经历

    目录 又被搞了 版本:Grey Hack v0.7.3618 - Alpha 胆大包天的我黑进游戏内shop的IP后,顺着其上面的日志溯源到不少疑似其他玩家租的服务器,暂时没什么进展 不久后回到桌面才 ...

  5. 【 Grey Hack 】万金油脚本:常见端口修改Password

    目录 脚本源码 用法 效果及示例 版本:Grey Hack v0.7.3618 - Alpha 适用于SSH (22) 端口.FTP (21) 端口.HTTP (80) 端口.SMTP (25) 端口 ...

  6. 【 Grey Hack 】万金油脚本:原地提权工具

    目录 脚本源码 用法 效果及示例 版本:Grey Hack v0.7.3618 - Alpha 脚本源码 metaxploit = include_lib("/lib/metaxploit. ...

  7. 【 Grey Hack 】反向Shell

    目录 调查 准备反向shell 反向shell 提权 版本:Grey Hack v0.7.3618 - Alpha 如图,本案例中目标IP尚未开放常见端口 调查 通过路由器获得目标PC的用户邮箱账号和 ...

  8. 【 Grey Hack 】万金油脚本:在路由器上获取shell

    目录 脚本源码 用法 效果及示例 版本:Grey Hack v0.7.3618 - Alpha 脚本源码 if params.len != 2 or params[0] == "-h&quo ...

  9. 【 Grey Hack 】万金油脚本:从路由器获取Password

    目录 脚本源码 用法 效果及示例 版本:Grey Hack v0.7.3618 - Alpha 脚本源码 if params.len != 2 or params[0] == "-h&quo ...

最新文章

  1. CodeSmith使用笔记
  2. Vue的报错Echarts Cannot read property ‘init‘ of undefined
  3. clear nTotal nNum=1计算机考试,信息学奥赛常考算法——模拟法
  4. java 网页正文抽取算法_网页正文抽取算法 ContentExtractor
  5. Mybatis的resultMap自定义映射
  6. 多目标优化算法_阿里提出多目标优化全新算法框架,同时提升电商GMV和CTR
  7. rpc:call/4函数解析
  8. python三本经典书籍-关于 Python 的经典入门书籍有哪些?
  9. 安卓机顶盒运行linux,全志 Allwinner A20 机顶盒刷入原生 Debian
  10. 华为研发模式演进历程
  11. openwrt路由器安装Transmission软件包与web控制台(中文界面)
  12. tcp服务器修改端口号,RAKsmart服务器:Windows修改远程端口号的图文教程
  13. java实现微博九宫格图片切分
  14. 操作系统 考研习题 详细解析(1)
  15. 神经网络参数量和计算量,神经网络计算公式
  16. 读书《你能写出好故事:写作的诀窍、大脑的奥秘、认知的陷阱》
  17. ARM Linux异常处理之data abort(一)
  18. Linux系统安装开源版PyMOL
  19. 比较两给json是否一致
  20. MapReduce学习之概述和设计构思

热门文章

  1. mycat读写分离部署步骤
  2. 简单文件传输TFTP服务器搭建 Linux RHEL6
  3. php 的命名空间 看鸟哥后的随笔
  4. 咨询的真相8:咨询业的“前世今生”
  5. 开源软件 安全风险_3开源安全风险及其解决方法
  6. leetcode1221. 分割平衡字符串(贪心算法)
  7. assign复制对象_JavaScript标准对象:assign,values,hasOwnProperty和getOwnPropertyNames方法介绍...
  8. golang go语言_在7小时内学习快速简单的Go编程语言(Golang)
  9. 如何使用Retrofit,OkHttp,Gson,Glide和Coroutines处理RESTful Web服务
  10. fpga中的slack_是否想减少部署过程的恐怖程度? 在Slack中构建ChatOps。