一键ThinkPHP漏洞检测工具

2019年11月7日00:01:47 发表评论
AD1 AD2 AD3 AD4

一键ThinkPHP漏洞检测工具

ThinkPHP漏洞检测工具,基于Python3编写,代码如下:

  1. #!/usr/bin/env python
  2. # coding=utf-8
  3. from gevent import monkey;monkey.patch_all()
  4. from gevent.pool import Pool
  5. from plugins.thinkphp_checkcode_time_sqli import thinkphp_checkcode_time_sqli_verify
  6. from plugins.thinkphp_construct_code_exec import thinkphp_construct_code_exec_verify
  7. from plugins.thinkphp_construct_debug_rce import thinkphp_construct_debug_rce_verify
  8. from plugins.thinkphp_debug_index_ids_sqli import thinkphp_debug_index_ids_sqli_verify
  9. from plugins.thinkphp_driver_display_rce import thinkphp_driver_display_rce_verify
  10. from plugins.thinkphp_index_construct_rce import thinkphp_index_construct_rce_verify
  11. from plugins.thinkphp_index_showid_rce import thinkphp_index_showid_rce_verify
  12. from plugins.thinkphp_invoke_func_code_exec import thinkphp_invoke_func_code_exec_verify
  13. from plugins.thinkphp_lite_code_exec import thinkphp_lite_code_exec_verify
  14. from plugins.thinkphp_method_filter_code_exec import thinkphp_method_filter_code_exec_verify
  15. from plugins.thinkphp_multi_sql_leak import thinkphp_multi_sql_leak_verify
  16. from plugins.thinkphp_pay_orderid_sqli import thinkphp_pay_orderid_sqli_verify
  17. from plugins.thinkphp_request_input_rce import thinkphp_request_input_rce_verify
  18. from plugins.thinkphp_view_recent_xff_sqli import thinkphp_view_recent_xff_sqli_verify
  19. import sys
  20. import gevent
  21. print('''
  22.  ___________                    
  23. |_   _| ___ \                   
  24.   | | | |_/ /__  ___ __ _ _ __  
  25.   | | |  __/ __|/ __/ _` | '_ \ 
  26.   | | | |  \__ \ (_| (_| | | | |
  27.   \_/ \_|  |___/\___\__,_|_| |_|          
  28.                 code by Lucifer
  29. ''')
  30. targeturl = input("[*]Give me a target: ")
  31. if targeturl.find('http') == -1:
  32.     exit(1)
  33. poclist = [
  34.     'thinkphp_checkcode_time_sqli_verify("{0}")'.format(targeturl),
  35.     'thinkphp_construct_code_exec_verify("{0}")'.format(targeturl),
  36.     'thinkphp_construct_debug_rce_verify("{0}")'.format(targeturl),
  37.     'thinkphp_debug_index_ids_sqli_verify("{0}")'.format(targeturl),
  38.     'thinkphp_driver_display_rce_verify("{0}")'.format(targeturl),
  39.     'thinkphp_index_construct_rce_verify("{0}")'.format(targeturl),
  40.     'thinkphp_index_showid_rce_verify("{0}")'.format(targeturl),
  41.     'thinkphp_invoke_func_code_exec_verify("{0}")'.format(targeturl),
  42.     'thinkphp_lite_code_exec_verify("{0}")'.format(targeturl),
  43.     'thinkphp_method_filter_code_exec_verify("{0}")'.format(targeturl),
  44.     'thinkphp_multi_sql_leak_verify("{0}")'.format(targeturl),
  45.     'thinkphp_pay_orderid_sqli_verify("{0}")'.format(targeturl),
  46.     'thinkphp_request_input_rce_verify("{0}")'.format(targeturl),
  47.     'thinkphp_view_recent_xff_sqli_verify("{0}")'.format(targeturl),
  48. ]
  49. def pocexec(pocstr):
  50.     exec(pocstr)
  51.     gevent.sleep(0)
  52. pool = Pool(10)
  53. threads = [pool.spawn(pocexec, item) for item in poclist]
  54. gevent.joinall(threads)

项目地址:【传送链接

发表评论

后发表评论