├── README.md ├── WhoIsWeblogic.log ├── WhoIsWeblogic.py ├── ipresult.txt └── ipsource.txt /README.md: -------------------------------------------------------------------------------- 1 | 软件作者:Tide_RabbitMask 2 | 免责声明:Pia!(o ‵-′)ノ”(ノ﹏<。) 3 | 本工具仅用于安全测试,请勿用于非法使用,要乖哦~ 4 | 5 | WhoIsWeblogic 功能特色: 6 | 1.完善的超时处理机制 7 | 2.多进程任务高效并发 8 | 3.简洁直观的监控界面 9 | 4.健全的日志记录功能 10 | 5.健全的异常处理机制 11 | 12 | WhoIsWeblogic 文件说明: 13 | ipsource.txt:待读取目标 14 | ipresult.txt:已识别目标 15 | WhoIsWeblogic.log:运行日志 16 | 17 | 【软件使用Demo】 18 | #WhoIsWeblogic控制台: 19 | ========================================================================= 20 | 当前站点:http://127.0.0.1:7001/console/login/LoginForm.jsp 状态码:200 21 | 当前站点:http://127.0.0.1:7001/wls-wsat/CoordinatorPortType 状态码:200 22 | 当前站点:http://127.0.0.1:7001/_async/AsyncResponseService 状态码:200 23 | 当前站点:http://127.0.0.1:7001/ws_utc/config.do 状态码:404 24 | >>>>>任务结束 25 | ========================================================================= 26 | 27 | 28 | #WhoIsWeblogic.log: 29 | ========================================================================= 30 | 2019-07-08 23:15:13,844 当前站点:http://127.0.0.1:7001/console/login/LoginForm.jsp 状态码:200 31 | 32 | 2019-07-08 23:15:13,858 当前站点:http://127.0.0.1:7001/wls-wsat/CoordinatorPortType 状态码:200 33 | 34 | 2019-07-08 23:15:13,865 当前站点:http://127.0.0.1:7001/_async/AsyncResponseService 状态码:200 35 | 36 | 2019-07-08 23:15:13,871 当前站点:http://127.0.0.1:7001/ws_utc/config.do 状态码:404 37 | ========================================================================= 38 | 39 | 40 | #ipresult.txt:【Tips:ipresult.txt文件可直接被WeblogicScanLot调用。】 41 | ========================================================================= 42 | 127.0.0.1:7001 43 | ========================================================================= 44 | 45 | -------------------------------------------------------------------------------- /WhoIsWeblogic.log: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/rabbitmask/WhoIsWeblogic/2bd0dbe25815355f24d3d39f7deee5438821db51/WhoIsWeblogic.log -------------------------------------------------------------------------------- /WhoIsWeblogic.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | # _*_ coding:utf-8 _*_ 3 | ''' 4 | ____ _ _ _ _ __ __ _ 5 | | _ \ __ _| |__ | |__ (_) |_| \/ | __ _ ___| | __ 6 | | |_) / _` | '_ \| '_ \| | __| |\/| |/ _` / __| |/ / 7 | | _ < (_| | |_) | |_) | | |_| | | | (_| \__ \ < 8 | |_| \_\__,_|_.__/|_.__/|_|\__|_| |_|\__,_|___/_|\_\ 9 | 10 | ''' 11 | import logging 12 | import requests 13 | from multiprocessing import Pool, Manager 14 | 15 | headers = {'user-agent': 'ceshi/0.0.1'} 16 | filename1='ipsource.txt' 17 | filename2='ipresult.txt' 18 | 19 | logging.basicConfig(filename='WhoIsWeblogic.log', 20 | format='%(asctime)s %(message)s', 21 | filemode="w", level=logging.INFO) 22 | 23 | #Weblogic模糊识别模块 24 | def isweblogic(url): 25 | if 'http' not in url: 26 | url = 'http://' + url 27 | try: 28 | url1=url+'/console/login/LoginForm.jsp' 29 | r1 = requests.get(url1,timeout=5,headers=headers) 30 | logging.info("当前站点:{}\t状态码:{}\n".format(url1,r1.status_code)) 31 | print("当前站点:{}\t状态码:{}".format(url1,r1.status_code)) 32 | 33 | url2=url+'/wls-wsat/CoordinatorPortType' 34 | r2 = requests.get(url2,timeout=5,headers=headers) 35 | logging.info("当前站点:{}\t状态码:{}\n".format(url2,r2.status_code)) 36 | print("当前站点:{}\t状态码:{}".format(url2,r2.status_code)) 37 | 38 | url3=url+'/_async/AsyncResponseService' 39 | r3 = requests.get(url3,timeout=5,headers=headers) 40 | logging.info("当前站点:{}\t状态码:{}\n".format(url3,r3.status_code)) 41 | print("当前站点:{}\t状态码:{}".format(url3,r3.status_code)) 42 | 43 | url4=url+'/ws_utc/config.do' 44 | r4 = requests.get(url4,timeout=5,headers=headers) 45 | logging.info("当前站点:{}\t状态码:{}\n".format(url4,r4.status_code)) 46 | print("当前站点:{}\t状态码:{}".format(url4,r4.status_code)) 47 | 48 | return r1.status_code,r2.status_code,r3.status_code,r4.status_code 49 | except: 50 | logging.info("当前站点:{}\t响应超时\n".format(url)) 51 | print("当前站点:{}\t响应超时\n".format(url)) 52 | 53 | def readtxt(url,i,q): 54 | r1,r2,r3,r4=isweblogic(url) 55 | if r1 == 200 or r2 == 200 or r3 ==200 or r4 ==200: 56 | fw = open(filename2, 'a') 57 | fw.write(url + '\n') 58 | fw.close() 59 | q.put(i) 60 | 61 | # 进程池管理模块 62 | def poolmana(): 63 | p = Pool(20) 64 | q = Manager().Queue() 65 | fr = open(filename1, 'r') 66 | urls=fr.readlines() 67 | fr.close() 68 | for i in range(len(urls)): 69 | url = urls[i] 70 | url = url.replace("\n", '') 71 | p.apply_async(readtxt, args=(url,i,q)) 72 | p.close() 73 | p.join() 74 | print('>>>>>任务结束\n') 75 | 76 | def main(): 77 | poolmana() 78 | 79 | if "__main__" == __name__: 80 | main() -------------------------------------------------------------------------------- /ipresult.txt: -------------------------------------------------------------------------------- 1 | 127.0.0.1:7001 2 | -------------------------------------------------------------------------------- /ipsource.txt: -------------------------------------------------------------------------------- 1 | 127.0.0.1:7001 --------------------------------------------------------------------------------