当前位置: 首页 > news >正文

17 BTLO 蓝队靶场 Pretium 解题记录

  • 主题:流量分析
  • 工具:Wireshark 

Wireshark Basic Guide      

Guide 2

场景:In this scenario, a user interacted with a link from an email which downloaded a malicious invoice file. A network capture was performed at the time of the incident and we are asked to analyse the pcap capture.

找这个恶意invoice, File -> Export Objects -> HTTP

题目1. What is the name of the module used to serve the malicious payload?

python3 -m http.server会开启这个服务

题目2:Analysing the traffic, what is the attacker’s IP address?

192.168.1.9

题目3:Now that you know the payload name and the module used to deliver the malicious files, what is the URL that was embedded in the malicious email?

拼起来, 

http://192.168.1.9:443/INVOICE_2021937.pdf.bat

题目4:Find the PowerShell launcher string (you don’t need to include the base64 encoded script)

http流中有:

答案是

powershell -noP -sta -w 1 -enc

参数解释:

-noP
全称:-NoProfile
作用:启动 PowerShell 时不加载当前用户的配置文件($PROFILE)。
目的:加快启动速度,避免用户配置文件中的自定义设置干扰脚本执行。
-sta
全称:-STA(Single-Threaded Apartment)
作用:以单线程模式运行 PowerShell。
背景:某些 COM 组件或旧版 .NET 库需要单线程环境才能正常工作。
-w 1
全称:-WindowStyle 1
作用:将 PowerShell 窗口设置为隐藏模式(WindowStyle.Hidden)。
目的:隐蔽执行,避免被用户察觉。
-enc
全称:-EncodedCommand
作用:接受一个 Base64 编码的字符串,PowerShell 会解码并执行其中的命令。
用途:绕过命令行长度限制。

所以后面的那一串应该用base64解码。

题目5: What is the default user agent being used for communications?

解码后的文件中 user-agent 是 $u,指向 Mozilla/5.0

题目6:You are seeing a lot of HTTP traffic. What is the name of a process where malware communicates with a central server asking for instructions at set time intervals?

这种手法叫beaconing

"Malware beaconing lets hackers know they’ve successfully infected a system so they can then send commands and carry out an attack."

题目7: What is the URI containing ‘login’ that the victim machine is communicating to?

用http和frame包含“login”筛选:

题目8: What is the name of the popular post-exploitation framework used for command-and-control communication?

如果我们通过Wireshark检查仅HTTP流量(过滤http),可以识别出机器被感染后请求的一系列不同URL:

/news.php
/login/process.php
/admin/get.php
Google搜索关键词malware +news.php +/login/process.php +/admin/get.php时,发现关联Powershell Empire

题目8:It is believed that data is being exfiltrated. Investigate and provide the decoded password

附带的一份阅读材料链接提到了通过隐蔽通道解码传输的载荷。其中举例的两种协议是DNS和ICMP。查询发现受感染服务器与攻击服务器之间没有出现任何DNS流量,但使用ip.src == 192.168.1.8 and ip.dst == 192.168.1.9 and icmp可以观察到大量ICMP流量——有一万个数据包:

C:\Users\BTLOTest\Desktop\Investigation>tshark.lnk -r C:\Users\BTLOTest\Desktop\Investigation\LAB.pcap -T fields -e data ip.src == 192.168.1.8 and ip.dst == 192.168.1.9 and icmp > C:\Users\BTLOTest\Desktop\data.txt

-T fields 表示输出格式为字段(而不是默认的摘要)
-e data 表示只提取数据包中的 data 字段(即 ICMP 载荷部分)

然后打开data.txt,用CyberChef,三种Recipe:  From Hex, From Base64 and Regex

Y0uthinky0ucAnc4tchm3$$

问题9:What is the account’s username?

上一题有答案 $sec-account

    http://www.dtcms.com/a/290084.html

    相关文章:

  • Windows GCC修改链接脚本文件实现section块存储函数
  • LVS 集群技术基础
  • docker--挂载
  • Docker安装Elasticsearch 7.17.0和Kibana 7.17.0并配置基础安全
  • 悬镜安全将受邀参加2025开放原子开源生态大会
  • Curtain e-locker 易锁防泄密:无需网络隔离,实现安全与效率并存
  • 量子生成对抗网络:量子计算与生成模型的融合革命
  • uni-api交互反馈组件(showToast)的用法
  • 宝塔面板Nginx报错: IP+端口可以直接从访问,反向代理之后就504了 Gateway Time-out
  • 农村供水智慧化管理系统:从精准监测到智能调度,破解农村用水安全与效率难题
  • MySQL 事务死锁排查:从日志分析到解决实战
  • 某日在某个月份中不存在导致软件出现异常的问题排查(判断闰年以及月份中的天数,附完整源码)
  • 低代码平台能否完全取代传统前端开发
  • Bun v1.2.19发布,node_modules隔离,sql比node快6倍
  • MySQL:表的增删查改
  • 【跨国数仓迁移最佳实践2】MaxCompute SQL执行引擎对复杂类型处理全面重构,保障客户从BigQuery平滑迁移
  • VUE如何设置语音
  • 【实践篇】基于.venv 的 ComfyUI 环境同配置迁移:pyvenv.cfg 路径修改法
  • leetcode-sql-627变更性别
  • 植物根茎切片图像处理与分析系统开发
  • 【大模型】结构化提示词:让AI高效完成复杂任务的“编程语言”
  • 虚拟机扩展磁盘容量后扩展分区大小
  • 部署 Zabbix 企业级分布式监控
  • 【图像处理基石】什么是相机的内外参数?
  • 在Windows Server 2012 R2中安装与配置IIS服务并部署mssql靶机教程
  • 在Web API 开发中践行Security by Default原则
  • 【操作篇】群晖NAS用root权限直接访问系统分区文件
  • 4x4矩阵教程
  • channel_up和lane_up
  • OpenLayers 入门指南【三】:API概要