Windows 内存 RAM 分析报告:使用 Volatility
由于我们在 Fedora 上工作,我们将安装 Docker 引擎并启动服务。
日期: 2025 年 11 月
工作环境: Fedora Linux (Docker)
作者: Portelcore 团队
0. 环境准备 (Fedora)
Sección titulada «0. Preparación del Entorno (Fedora)»0.1. 安装 Docker
Sección titulada «0.1. Instalación de Docker»由于我们使用 Fedora,我们将安装 Docker 引擎并启动服务。
命令:
sudo dnf install dnf-plugins-coresudo dnf config-manager --add-repo [https://download.docker.com/linux/fedora/docker-ce.repo](https://download.docker.com/linux/fedora/docker-ce.repo)sudo dnf install docker-ce docker-ce-cli containerd.iosudo systemctl start dockersudo systemctl enable docker# Verificaciódocker --version我们将下载挑战所需的 Docker 镜像并重命名以方便使用。
命令:
# Descargar imágenesdocker pull phocean/volatilitydocker pull sk4la/volatility3:edge
# Cambiar etiquetas (tags)docker image tag phocean/volatility vol2docker image tag sk4la/volatility3:edge vol3
# Verificardocker images结果(截图或确认文本):
[PEGAR AQUÍ LA LISTA DE IMÁGENES DOCKER]我们必须运行命令以安装Docker并下载所需的镜像。我们将运行命令以启动Docker服务并验证其是否正常运行。我们将下载Docker镜像并为其添加标签以便使用。我们将查看镜像的下载和标签结果。
1. 图像1分析 (dump.vmem)
Sección titulada «1. Análisis de Imagen 1 (dump.vmem)»首先,我们必须识别操作系统配置文件,以便使用Volatility 2正确运行其余插件。
命令:
sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw imageinfo结果和分析:
- 建议的配置文件:
Win7SP1x64 - 截图:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw imageinfo[sudo] contraseña para user.portelcore:Volatility Foundation Volatility Framework 2.6.1INFO : volatility.debug : Determining profile based on KDBG search... Suggested Profile(s) : Win7SP1x64, Win7SP0x64, Win2008R2SP0x64, Win2008R2SP1x64_24000, Win2008R2SP1x64_23418, Win2008R2SP1x64, Win7SP1x64_24000, Win7SP1x64_23418 AS Layer1 : WindowsAMD64PagedMemory (Kernel AS) AS Layer2 : FileAddressSpace (/dumps/victim.raw) PAE type : No PAE DTB : 0x187000L KDBG : 0xf800028420a0L Number of Processors : 1 Image Type (Service Pack) : 1 KPCR for CPU 0 : 0xfffff80002843d00L KUSER_SHARED_DATA : 0xfffff78000000000L Image date and time : 2019-05-02 18:11:45 UTC+0000 Image local date and time : 2019-05-02 11:11:45 -0700user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$我们将通过运行pslist来检查配置文件是否正常工作。
命令:
sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 pslist问题:
- 相关截图:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 pslistVolatility Foundation Volatility Framework 2.6.1Offset(V) Name PID PPID Thds Hnds Sess Wow64 Start Exit------------------ -------------------- ------ ------ ------ -------- ------ ------ ------------------------------ ------------------------------0xfffffa8001252040 System 4 0 88 624 ------ 0 2019-05-03 06:32:24 UTC+00000xfffffa800234d8a0 smss.exe 268 4 2 29 ------ 0 2019-05-03 06:32:24 UTC+00000xfffffa8002264550 csrss.exe 360 352 9 363 0 0 2019-05-03 06:32:34 UTC+00000xfffffa80027d67d0 csrss.exe 408 400 7 162 1 0 2019-05-03 06:32:35 UTC+00000xfffffa8002b601c0 wininit.exe 416 352 3 76 0 0 2019-05-03 06:32:35 UTC+00000xfffffa8002b71680 winlogon.exe 444 400 3 111 1 0 2019-05-03 06:32:35 UTC+00000xfffffa8002c69b30 services.exe 504 416 6 184 0 0 2019-05-03 06:32:36 UTC+00000xfffffa80027d9b30 lsass.exe 512 416 6 534 0 0 2019-05-03 06:32:37 UTC+00000xfffffa80027d81f0 lsm.exe 520 416 10 143 0 0 2019-05-03 06:32:37 UTC+00000xfffffa80029cd3e0 svchost.exe 628 504 9 345 0 0 2019-05-03 06:32:48 UTC+00000xfffffa8002d38b30 VBoxService.ex 688 504 12 135 0 0 2019-05-03 06:32:48 UTC+00000xfffffa8002a1bb30 svchost.exe 752 504 7 235 0 0 2019-05-02 18:02:51 UTC+00000xfffffa8002d70650 svchost.exe 852 504 22 473 0 0 2019-05-02 18:02:51 UTC+00000xfffffa8002d9c780 svchost.exe 892 504 17 427 0 0 2019-05-02 18:02:51 UTC+00000xfffffa8002dbe9e0 svchost.exe 920 504 29 878 0 0 2019-05-02 18:02:51 UTC+00000xfffffa8002e3db30 svchost.exe 400 504 10 281 0 0 2019-05-02 18:02:56 UTC+00000xfffffa8002e57890 svchost.exe 1004 504 20 379 0 0 2019-05-02 18:02:56 UTC+00000xfffffa8002dfdab0 spoolsv.exe 1140 504 12 279 0 0 2019-05-02 18:02:57 UTC+00000xfffffa8002f2cb30 svchost.exe 1268 504 17 297 0 0 2019-05-02 18:02:59 UTC+00000xfffffa8002f81460 svchost.exe 1368 504 20 295 0 0 2019-05-02 18:02:59 UTC+00000xfffffa8003148b30 taskhost.exe 1788 504 8 159 1 0 2019-05-02 18:03:09 UTC+00000xfffffa8003172b30 explorer.exe 1860 1756 19 645 1 0 2019-05-02 18:03:09 UTC+00000xfffffa800315eb30 dwm.exe 1896 892 3 69 1 0 2019-05-02 18:03:09 UTC+00000xfffffa800300d700 VBoxTray.exe 1600 1860 13 141 1 0 2019-05-02 18:03:25 UTC+00000xfffffa8003367060 SearchIndexer. 2180 504 11 629 0 0 2019-05-02 18:03:32 UTC+00000xfffffa80033f6060 WmiPrvSE.exe 2876 628 5 113 0 0 2019-05-02 18:03:55 UTC+00000xfffffa8003162060 svchost.exe 1820 504 11 317 0 0 2019-05-02 18:05:09 UTC+00000xfffffa8003371540 wmpnetwk.exe 2464 504 14 440 0 0 2019-05-02 18:05:10 UTC+00000xfffffa80014eeb30 taskhost.exe 1148 504 8 176 0 0 2019-05-02 18:09:58 UTC+0000user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$我们将提供进程列表命令 (pstree, psxview)
命令:
sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 psxview
sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 pstree问题:
- 相关截图:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 pstreeVolatility Foundation Volatility Framework 2.6.1Name Pid PPid Thds Hnds Time-------------------------------------------------- ------ ------ ------ ------ ---- 0xfffffa8002b601c0:wininit.exe 416 352 3 76 2019-05-03 06:32:35 UTC+0000. 0xfffffa80027d9b30:lsass.exe 512 416 6 534 2019-05-03 06:32:37 UTC+0000. 0xfffffa80027d81f0:lsm.exe 520 416 10 143 2019-05-03 06:32:37 UTC+0000. 0xfffffa8002c69b30:services.exe 504 416 6 184 2019-05-03 06:32:36 UTC+0000.. 0xfffffa8002e3db30:svchost.exe 400 504 10 281 2019-05-02 18:02:56 UTC+0000... 0xfffffa80027d67d0:csrss.exe 408 400 7 162 2019-05-03 06:32:35 UTC+0000... 0xfffffa8002b71680:winlogon.exe 444 400 3 111 2019-05-03 06:32:35 UTC+0000.. 0xfffffa8002dbe9e0:svchost.exe 920 504 29 878 2019-05-02 18:02:51 UTC+0000.. 0xfffffa8003367060:SearchIndexer. 2180 504 11 629 2019-05-02 18:03:32 UTC+0000.. 0xfffffa8003162060:svchost.exe 1820 504 11 317 2019-05-02 18:05:09 UTC+0000.. 0xfffffa8002d38b30:VBoxService.ex 688 504 12 135 2019-05-03 06:32:48 UTC+0000.. 0xfffffa80029cd3e0:svchost.exe 628 504 9 345 2019-05-03 06:32:48 UTC+0000... 0xfffffa80033f6060:WmiPrvSE.exe 2876 628 5 113 2019-05-02 18:03:55 UTC+0000.. 0xfffffa8002dfdab0:spoolsv.exe 1140 504 12 279 2019-05-02 18:02:57 UTC+0000.. 0xfffffa8003371540:wmpnetwk.exe 2464 504 14 440 2019-05-02 18:05:10 UTC+0000.. 0xfffffa8002d70650:svchost.exe 852 504 22 473 2019-05-02 18:02:51 UTC+0000.. 0xfffffa8002f81460:svchost.exe 1368 504 20 295 2019-05-02 18:02:59 UTC+0000.. 0xfffffa8003148b30:taskhost.exe 1788 504 8 159 2019-05-02 18:03:09 UTC+0000.. 0xfffffa8002e57890:svchost.exe 1004 504 20 379 2019-05-02 18:02:56 UTC+0000.. 0xfffffa8002a1bb30:svchost.exe 752 504 7 235 2019-05-02 18:02:51 UTC+0000.. 0xfffffa8002f2cb30:svchost.exe 1268 504 17 297 2019-05-02 18:02:59 UTC+0000.. 0xfffffa80014eeb30:taskhost.exe 1148 504 8 176 2019-05-02 18:09:58 UTC+0000.. 0xfffffa8002d9c780:svchost.exe 892 504 17 427 2019-05-02 18:02:51 UTC+0000... 0xfffffa800315eb30:dwm.exe 1896 892 3 69 2019-05-02 18:03:09 UTC+0000 0xfffffa8002264550:csrss.exe 360 352 9 363 2019-05-03 06:32:34 UTC+0000 0xfffffa8001252040:System 4 0 88 624 2019-05-03 06:32:24 UTC+0000. 0xfffffa800234d8a0:smss.exe 268 4 2 29 2019-05-03 06:32:24 UTC+0000 0xfffffa8003172b30:explorer.exe 1860 1756 19 645 2019-05-02 18:03:09 UTC+0000. 0xfffffa800300d700:VBoxTray.exe 1600 1860 13 141 2019-05-02 18:03:25 UTC+0000user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 psxviewVolatility Foundation Volatility Framework 2.6.1Offset(P) Name PID pslist psscan thrdproc pspcid csrss session deskthrd ExitTime------------------ -------------------- ------ ------ ------ -------- ------ ----- ------- -------- --------0x000000005c99c780 svchost.exe 892 True True False True True True True0x000000005c40d700 VBoxTray.exe 1600 True True False True True True True0x000000005c367060 SearchIndexer. 2180 True True False True True True True0x000000005c657890 svchost.exe 1004 True True False True True True True0x000000005c548b30 taskhost.exe 1788 True True False True True True True0x000000005c72cb30 svchost.exe 1268 True True False True True True True0x000000005ca1bb30 svchost.exe 752 True True False True True True True0x000000005e0eeb30 taskhost.exe 1148 True True False True True True True0x000000005cb71680 winlogon.exe 444 True True False True True True True0x000000005cb601c0 wininit.exe 416 True True False True True True True0x000000005c9be9e0 svchost.exe 920 True True False True True True True0x000000005c572b30 explorer.exe 1860 True True False True True True True0x000000005c562060 svchost.exe 1820 True True False True True True True0x000000005c970650 svchost.exe 852 True True False True True True True0x000000005c938b30 VBoxService.ex 688 True True False True True True True0x000000005c3f6060 WmiPrvSE.exe 2876 True True False True True True True0x000000005cfd9b30 lsass.exe 512 True True False True True True False0x000000005cdcd3e0 svchost.exe 628 True True False True True True True0x000000005c781460 svchost.exe 1368 True True False True True True True0x000000005cfd81f0 lsm.exe 520 True True False True True True False0x000000005c63db30 svchost.exe 400 True True False True True True True0x000000005c55eb30 dwm.exe 1896 True True False True True True True0x000000005c9fdab0 spoolsv.exe 1140 True True False True True True True0x000000005c371540 wmpnetwk.exe 2464 True True False True True True True0x000000005c869b30 services.exe 504 True True False True True True False0x000000005d34d8a0 smss.exe 268 True True False True False False False0x000000005e252040 System 4 True True False True False False False0x000000005cfd67d0 csrss.exe 408 True True False True False True True0x000000005d264550 csrss.exe 360 True True False True False True Trueuser.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$SearchIndexer 的进程标识符 (PID) 是什么?
命令:
sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 pslist问题:
- SearchIndexer 的进程标识符 (PID) 是什么?
2180 - 相关截图:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 pslistVolatility Foundation Volatility Framework 2.6.1Offset(V) Name PID PPID Thds Hnds Sess Wow64 Start Exit------------------ -------------------- ------ ------ ------ -------- ------ ------ ------------------------------ ------------------------------0xfffffa8001252040 System 4 0 88 624 ------ 0 2019-05-03 06:32:24 UTC+00000xfffffa800234d8a0 smss.exe 268 4 2 29 ------ 0 2019-05-03 06:32:24 UTC+00000xfffffa8002264550 csrss.exe 360 352 9 363 0 0 2019-05-03 06:32:34 UTC+00000xfffffa80027d67d0 csrss.exe 408 400 7 162 1 0 2019-05-03 06:32:35 UTC+00000xfffffa8002b601c0 wininit.exe 416 352 3 76 0 0 2019-05-03 06:32:35 UTC+00000xfffffa8002b71680 winlogon.exe 444 400 3 111 1 0 2019-05-03 06:32:35 UTC+00000xfffffa8002c69b30 services.exe 504 416 6 184 0 0 2019-05-03 06:32:36 UTC+00000xfffffa80027d9b30 lsass.exe 512 416 6 534 0 0 2019-05-03 06:32:37 UTC+00000xfffffa80027d81f0 lsm.exe 520 416 10 143 0 0 2019-05-03 06:32:37 UTC+00000xfffffa80029cd3e0 svchost.exe 628 504 9 345 0 0 2019-05-03 06:32:48 UTC+00000xfffffa8002d38b30 VBoxService.ex 688 504 12 135 0 0 2019-05-03 06:32:48 UTC+00000xfffffa8002a1bb30 svchost.exe 752 504 7 235 0 0 2019-05-02 18:02:51 UTC+00000xfffffa8002d70650 svchost.exe 852 504 22 473 0 0 2019-05-02 18:02:51 UTC+00000xfffffa8002d9c780 svchost.exe 892 504 17 427 0 0 2019-05-02 18:02:51 UTC+00000xfffffa8002dbe9e0 svchost.exe 920 504 29 878 0 0 2019-05-02 18:02:51 UTC+00000xfffffa8002e3db30 svchost.exe 400 504 10 281 0 0 2019-05-02 18:02:56 UTC+00000xfffffa8002e57890 svchost.exe 1004 504 20 379 0 0 2019-05-02 18:02:56 UTC+00000xfffffa8002dfdab0 spoolsv.exe 1140 504 12 279 0 0 2019-05-02 18:02:57 UTC+00000xfffffa8002f2cb30 svchost.exe 1268 504 17 297 0 0 2019-05-02 18:02:59 UTC+00000xfffffa8002f81460 svchost.exe 1368 504 20 295 0 0 2019-05-02 18:02:59 UTC+00000xfffffa8003148b30 taskhost.exe 1788 504 8 159 1 0 2019-05-02 18:03:09 UTC+00000xfffffa8003172b30 explorer.exe 1860 1756 19 645 1 0 2019-05-02 18:03:09 UTC+00000xfffffa800315eb30 dwm.exe 1896 892 3 69 1 0 2019-05-02 18:03:09 UTC+00000xfffffa800300d700 VBoxTray.exe 1600 1860 13 141 1 0 2019-05-02 18:03:25 UTC+00000xfffffa8003367060 SearchIndexer. 2180 504 11 629 0 0 2019-05-02 18:03:32 UTC+00000xfffffa80033f6060 WmiPrvSE.exe 2876 628 5 113 0 0 2019-05-02 18:03:55 UTC+00000xfffffa8003162060 svchost.exe 1820 504 11 317 0 0 2019-05-02 18:05:09 UTC+00000xfffffa8003371540 wmpnetwk.exe 2464 504 14 440 0 0 2019-05-02 18:05:10 UTC+00000xfffffa80014eeb30 taskhost.exe 1148 504 8 176 0 0 2019-05-02 18:09:58 UTC+0000user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$父进程是什么?它有什么 PID?
命令:
sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 pstree问题:
- 父进程是什么?
services.exe - 它的 PID 是什么?
504 - 相关截图:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 pstreeVolatility Foundation Volatility Framework 2.6.1Name Pid PPid Thds Hnds Time-------------------------------------------------- ------ ------ ------ ------ ---- 0xfffffa8002b601c0:wininit.exe 416 352 3 76 2019-05-03 06:32:35 UTC+0000. 0xfffffa80027d9b30:lsass.exe 512 416 6 534 2019-05-03 06:32:37 UTC+0000. 0xfffffa80027d81f0:lsm.exe 520 416 10 143 2019-05-03 06:32:37 UTC+0000. 0xfffffa8002c69b30:services.exe 504 416 6 184 2019-05-03 06:32:36 UTC+0000.. 0xfffffa8002e3db30:svchost.exe 400 504 10 281 2019-05-02 18:02:56 UTC+0000... 0xfffffa80027d67d0:csrss.exe 408 400 7 162 2019-05-03 06:32:35 UTC+0000... 0xfffffa8002b71680:winlogon.exe 444 400 3 111 2019-05-03 06:32:35 UTC+0000.. 0xfffffa8002dbe9e0:svchost.exe 920 504 29 878 2019-05-02 18:02:51 UTC+0000.. 0xfffffa8003367060:SearchIndexer. 2180 504 11 629 2019-05-02 18:03:32 UTC+0000.. 0xfffffa8003162060:svchost.exe 1820 504 11 317 2019-05-02 18:05:09 UTC+0000.. 0xfffffa8002d38b30:VBoxService.ex 688 504 12 135 2019-05-03 06:32:48 UTC+0000.. 0xfffffa80029cd3e0:svchost.exe 628 504 9 345 2019-05-03 06:32:48 UTC+0000... 0xfffffa80033f6060:WmiPrvSE.exe 2876 628 5 113 2019-05-02 18:03:55 UTC+0000.. 0xfffffa8002dfdab0:spoolsv.exe 1140 504 12 279 2019-05-02 18:02:57 UTC+0000.. 0xfffffa8003371540:wmpnetwk.exe 2464 504 14 440 2019-05-02 18:05:10 UTC+0000.. 0xfffffa8002d70650:svchost.exe 852 504 22 473 2019-05-02 18:02:51 UTC+0000.. 0xfffffa8002f81460:svchost.exe 1368 504 20 295 2019-05-02 18:02:59 UTC+0000.. 0xfffffa8003148b30:taskhost.exe 1788 504 8 159 2019-05-02 18:03:09 UTC+0000.. 0xfffffa8002e57890:svchost.exe 1004 504 20 379 2019-05-02 18:02:56 UTC+0000.. 0xfffffa8002a1bb30:svchost.exe 752 504 7 235 2019-05-02 18:02:51 UTC+0000.. 0xfffffa8002f2cb30:svchost.exe 1268 504 17 297 2019-05-02 18:02:59 UTC+0000.. 0xfffffa80014eeb30:taskhost.exe 1148 504 8 176 2019-05-02 18:09:58 UTC+0000.. 0xfffffa8002d9c780:svchost.exe 892 504 17 427 2019-05-02 18:02:51 UTC+0000... 0xfffffa800315eb30:dwm.exe 1896 892 3 69 2019-05-02 18:03:09 UTC+0000 0xfffffa8002264550:csrss.exe 360 352 9 363 2019-05-03 06:32:34 UTC+0000 0xfffffa8001252040:System 4 0 88 624 2019-05-03 06:32:24 UTC+0000. 0xfffffa800234d8a0:smss.exe 268 4 2 29 2019-05-03 06:32:24 UTC+0000 0xfffffa8003172b30:explorer.exe 1860 1756 19 645 2019-05-02 18:03:09 UTC+0000. 0xfffffa800300d700:VBoxTray.exe 1600 1860 13 141 2019-05-02 18:03:25 UTC+0000user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 psxviewVolatility Foundation Volatility Framework 2.6.1Offset(P) Name PID pslist psscan thrdproc pspcid csrss session deskthrd ExitTime------------------ -------------------- ------ ------ ------ -------- ------ ----- ------- -------- --------0x000000005c99c780 svchost.exe 892 True True False True True True True0x000000005c40d700 VBoxTray.exe 1600 True True False True True True True0x000000005c367060 SearchIndexer. 2180 True True False True True True True0x000000005c657890 svchost.exe 1004 True True False True True True True0x000000005c548b30 taskhost.exe 1788 True True False True True True True0x000000005c72cb30 svchost.exe 1268 True True False True True True True0x000000005ca1bb30 svchost.exe 752 True True False True True True True0x000000005e0eeb30 taskhost.exe 1148 True True False True True True True0x000000005cb71680 winlogon.exe 444 True True False True True True True0x000000005cb601c0 wininit.exe 416 True True False True True True True0x000000005c9be9e0 svchost.exe 920 True True False True True True True0x000000005c572b30 explorer.exe 1860 True True False True True True True0x000000005c562060 svchost.exe 1820 True True False True True True True0x000000005c970650 svchost.exe 852 True True False True True True True0x000000005c938b30 VBoxService.ex 688 True True False True True True True0x000000005c3f6060 WmiPrvSE.exe 2876 True True False True True True True0x000000005cfd9b30 lsass.exe 512 True True False True True True False0x000000005cdcd3e0 svchost.exe 628 True True False True True True True0x000000005c781460 svchost.exe 1368 True True False True True True True0x000000005cfd81f0 lsm.exe 520 True True False True True True False0x000000005c63db30 svchost.exe 400 True True False True True True True0x000000005c55eb30 dwm.exe 1896 True True False True True True True0x000000005c9fdab0 spoolsv.exe 1140 True True False True True True True0x000000005c371540 wmpnetwk.exe 2464 True True False True True True True0x000000005c869b30 services.exe 504 True True False True True True False0x000000005d34d8a0 smss.exe 268 True True False True False False False0x000000005e252040 System 4 True True False True False False False0x000000005cfd67d0 csrss.exe 408 True True False True False True True0x000000005d264550 csrss.exe 360 True True False True False True Trueuser.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$1.6. 最后访问的目录 (Shellbags)
Sección titulada «1.6. Último Directorio Accedido (Shellbags)»我们将通过 Shellbags 调查用户活动,以查看用户访问过哪些文件夹。
进程:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run --rm -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 shellbags > shellbags.txt[sudo] contraseña para user.portelcore:Volatility Foundation Volatility Framework 2.6.1user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$然后,我们创建了一个 Python 脚本来检测和过滤以下信息:
- 系统执行的文件
- 系统目录
- 用户文件
- 用户目录
然后,脚本如下:
import jsonimport sysimport refrom datetime import datetime
SYSTEM_KEYWORDS = [ "Desktop", "My Computer", "Control Panel", "Recycle", "Program Files", "ProgramData", "Windows", "Volume Name", "Libraries", "Network and Sharing Center"]
def limpiar_json(contenido_archivo): """Busca dónde empieza el JSON real (la primera llave '{') e ignora el resto.""" match = re.search(r'\{.*', contenido_archivo, re.DOTALL) if match: return match.group(0) return contenido_archivo
def es_sistema(ruta): """Determina si una ruta es probablemente del sistema/ruido.""" for kw in SYSTEM_KEYWORDS: if kw in ruta: return True return False
def imprimir_seccion(titulo, lista): print(f"\n{'='*80}") print(f" {titulo.upper()} ({len(lista)} entradas)") print(f"{'='*80}") print(f"{'FECHA (UTC)':<30} | {'RUTA / NOMBRE'}") print("-" * 80)
lista_ordenada = sorted(lista, key=lambda x: x[0], reverse=True)
for fecha, ruta in lista_ordenada: print(f"{fecha:<30} | {ruta}")
def main(): if len(sys.argv) < 2: print("Uso: python3 analizar_shellbags_advanced.py <archivo.json>") return
archivo_path = sys.argv[1]
try: with open(archivo_path, 'r') as f: raw_data = f.read()
json_str = limpiar_json(raw_data) data = json.loads(json_str)
cols = data['columns']
try: idx_time = cols.index('LastWrite') if 'LastWrite' in cols else cols.index('LastUpdated') idx_path = cols.index('Path') if 'Path' in cols else cols.index('AbsolutePath')
idx_attr = cols.index('Attributes') if 'Attributes' in cols else -1 idx_filename = cols.index('FileName') if 'FileName' in cols else -1
except ValueError as e: print(f"Error detectant columnes: {cols}") return
user_files = [] user_folders = [] system_files = [] system_folders = []
for fila in data['rows']: path = fila[idx_path] time_str = fila[idx_time] attrs = fila[idx_attr] if idx_attr != -1 else "" filename = fila[idx_filename] if idx_filename != -1 else ""
if not time_str or not path: continue
is_sys = es_sistema(path)
is_folder = "DIR" in attrs
if not is_folder: if re.search(r'\.[a-zA-Z0-9]{2,4}$', filename): is_folder = False elif path.endswith(":\\"): is_folder = True
item = (time_str, path)
if is_sys: if is_folder: system_folders.append(item) else: system_files.append(item) else: if is_folder: user_folders.append(item) else: user_files.append(item)
imprimir_seccion("1. SISTEMA - CARPETAS (System Folders)", system_folders) imprimir_seccion("2. SISTEMA - ARCHIVOS (System Files)", system_files) imprimir_seccion("3. USUARIO - ARCHIVOS ACCEDIDOS (User Files)", user_files) imprimir_seccion("4. USUARIO - CARPETAS VISITADAS (User Folders)", user_folders)
except Exception as e: print(f"Error fatal: {e}")
if __name__ == "__main__": main()之后,我们将运行python进行扫描并查看结果:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ python3 analizar_shellbags.py shellbags.json
================================================================================ 1. SISTEMA - CARPETAS (SYSTEM FOLDERS) (10 entradas)================================================================================FECHA (UTC) | RUTA / NOMBRE--------------------------------------------------------------------------------2019-04-27 10:42:05 UTC+0000 | C:\ProgramData2019-04-27 10:42:05 UTC+0000 | C:\Program Files (x86)2019-04-27 10:38:03 UTC+0000 | C:\Program Files (x86)\Capture2019-04-27 10:34:50 UTC+0000 | C:\ProgramData\Microsoft\Windows2019-04-27 10:34:47 UTC+0000 | C:\ProgramData\Microsoft2019-04-13 07:39:48 UTC+0000 | C:\ProgramData\Microsoft\Windows\Start Menu\Programs\WinRAR2019-04-13 07:39:46 UTC+0000 | C:\ProgramData\Microsoft\Windows\Start Menu2019-04-13 07:39:46 UTC+0000 | C:\ProgramData\Microsoft\Windows\Start Menu\Programs2019-04-13 07:35:42 UTC+0000 | C:\Users\victim\AppData\Roaming\Microsoft\Windows2019-04-13 07:35:42 UTC+0000 | C:\Users\victim\AppData\Roaming\Microsoft\Windows\Start Menu
================================================================================ 2. SISTEMA - ARCHIVOS (SYSTEM FILES) (1 entrada)================================================================================FECHA (UTC) | RUTA / NOMBRE--------------------------------------------------------------------------------2019-04-27 10:38:03 UTC+0000 | C:\Program Files (x86)\Capture\capture_2742019_336.zip
================================================================================ 3. USUARIO - ARCHIVOS ACCEDIDOS (USER FILES) (17 entradas)================================================================================FECHA (UTC) | RUTA / NOMBRE--------------------------------------------------------------------------------2019-05-02 07:00:41 UTC+0000 | Firefox.lnk2019-05-02 07:00:41 UTC+0000 | HxD.lnk2019-05-02 07:00:41 UTC+0000 | Wireshark.lnk2019-05-02 07:00:41 UTC+0000 | ~res-x64.txt2019-05-02 07:00:41 UTC+0000 | ~res-x64_0000.txt2019-05-02 07:00:41 UTC+0000 | Analysis Deatils.txt2019-05-02 07:00:41 UTC+0000 | depends - Shortcut.lnk2019-05-02 07:00:41 UTC+0000 | emotet.txt2019-05-02 07:00:41 UTC+0000 | emotet-regshot.hivu2019-05-02 07:00:41 UTC+0000 | IDA Freeware.lnk2019-05-02 07:00:41 UTC+0000 | OLLYDBG - Shortcut.lnk2019-05-02 07:00:41 UTC+0000 | PEview - Shortcut.lnk2019-05-02 07:00:41 UTC+0000 | Process Hacker 2.lnk2019-05-02 07:00:41 UTC+0000 | Regshot-x64-Unicode - Shortcut.lnk2019-05-02 07:00:41 UTC+0000 | sample 1.hivu2019-05-02 07:00:41 UTC+0000 | WinPcap_4_1_3.exe2019-04-27 10:33:36 UTC+0000 | Local\Temp\odbg110.zip
================================================================================ 4. USUARIO - CARPETAS VISITADAS (USER FOLDERS) (50 entradas)================================================================================FECHA (UTC) | RUTA / NOMBRE--------------------------------------------------------------------------------2019-05-02 07:00:41 UTC+0000 | Life Virus Samples2019-05-02 07:00:41 UTC+0000 | New folder2019-05-02 06:57:18 UTC+0000 | Life Virus Samples2019-05-02 06:57:18 UTC+0000 | New folder2019-04-27 10:48:33 UTC+0000 | Z:\logs\deleted_files2019-04-27 10:42:05 UTC+0000 | C:\Users2019-04-27 10:42:05 UTC+0000 | C:\Users\victim\AppData2019-04-27 10:42:05 UTC+0000 | C:\Users\victim\Downloads2019-04-27 10:38:19 UTC+0000 | Z:\logs2019-04-27 10:34:40 UTC+0000 | C:\Users\victim\AppData\Local2019-04-27 10:34:40 UTC+0000 | C:\Users\victim\AppData\Roaming2019-04-27 10:34:40 UTC+0000 | C:\Users\victim\AppData\LocalLow2019-04-27 10:34:40 UTC+0000 | C:\Users\victim\AppData\Local\Temp2019-04-27 10:34:35 UTC+0000 | C:\Users\victim\AppData\LocalLow\Mozilla2019-04-27 10:34:26 UTC+0000 | C:\Users\victim\AppData\Roaming\Microsoft2019-04-27 10:33:47 UTC+0000 | C:\Users\victim2019-04-27 10:33:36 UTC+0000 | Local\Temp\VBE2019-04-27 10:33:36 UTC+0000 | Local\Temp\TCD9405.tmp2019-04-27 10:33:36 UTC+0000 | Local\Temp\Low2019-04-27 10:33:36 UTC+0000 | Local\Temp\TCD9312.tmp2019-04-23 07:37:46 UTC+0000 | HxDSetup2019-04-23 07:37:46 UTC+0000 | CaptureBAT-Setup-2.0.0-5574-src2019-04-23 07:37:46 UTC+0000 | New folder2019-04-23 07:37:46 UTC+0000 | Malware analysis2019-04-23 07:37:46 UTC+0000 | CMDWatcher_v0.32019-04-23 07:37:46 UTC+0000 | Rehshot2019-04-23 07:37:46 UTC+0000 | OfficeMalScanner2019-04-23 06:54:48 UTC+0000 | Life Virus Samples\13 April2019-04-23 06:54:48 UTC+0000 | Life Virus Samples\New folder2019-04-23 06:54:48 UTC+0000 | Life Virus Samples\DOC2019-04-23 06:54:48 UTC+0000 | Life Virus Samples\18 April2019-04-23 06:54:48 UTC+0000 | Life Virus Samples\18 April\New folder2019-04-23 06:54:48 UTC+0000 | Life Virus Samples\18 April\VirusShare_aa8857f2b367d3e7036e6b788d1d0c3f2019-04-23 06:54:48 UTC+0000 | Life Virus Samples\18 April\Emotet2019-04-23 06:45:23 UTC+0000 | C:\Users\victim\Downloads\Microsoft Office Enterprise 2010 Corporate Final (full activated)\Microsoft Office Enterprise 2010 Corporate Final (full activated)2019-04-23 06:45:21 UTC+0000 | C:\Users\victim\Downloads\Microsoft Office Enterprise 2010 Corporate Final (full activated)2019-04-23 06:45:21 UTC+0000 | C:\Users\victim\Downloads\OfficeMalScanner2019-04-23 06:16:06 UTC+0000 | OfficeMalScanner\VirusShare_edc7428ec4d6b18e2620aee95347b4fa2019-04-23 06:15:54 UTC+0000 | Life Virus Samples\DOC\VirusShare_edc7428ec4d6b18e2620aee95347b4fa2019-04-23 06:14:25 UTC+0000 | Life Virus Samples\18 April\Emotet\New folder2019-04-23 06:14:25 UTC+0000 | Life Virus Samples\18 April\Emotet\VirusShare_05c632fe8ab2727adc9ac7b1b59c3be82019-04-13 08:05:26 UTC+0000 | CaptureBAT-Setup-2.0.0-5574-src\capture-client\SetupScript2019-04-13 08:05:26 UTC+0000 | CaptureBAT-Setup-2.0.0-5574-src\capture-client\ApplicationConfig2019-04-13 07:30:47 UTC+0000 | Malware analysis\Compressed2019-04-13 07:30:47 UTC+0000 | Malware analysis\PEview2019-04-13 07:30:47 UTC+0000 | Malware analysis\Compressed\depends22_x862019-04-13 05:57:48 UTC+0000 | CaptureBAT-Setup-2.0.0-5574-src\capture-client2019-04-11 13:33:14 UTC+0000 | odbg1102019-04-11 13:32:18 UTC+0000 | Local2019-04-11 13:32:18 UTC+0000 | Local\Tempuser.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$结果:
- 最后访问的目录:
Z:\logs\deleted_files - 访问日期:
2019-04-27 10:48:33 UTC+0000
我们将查找活动或已关闭的连接,以检测与 C2(Command & Control)服务器的通信。
命令:
sudo docker run --rm -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 netscan(如果是XP,我们将使用connscan)
然后,我们创建了一个 Python 脚本来检测和过滤以下信息:
import sysimport reimport ipaddress
KNOWN_SERVICES = { 135: ["svchost.exe", "System"], 137: ["System", "nbtscan.exe", "svchost.exe"], 138: ["System", "svchost.exe"], 139: ["System", "svchost.exe"], 445: ["System", "svchost.exe"], 5357: ["System", "svchost.exe"], 5355: ["svchost.exe"], 1900: ["svchost.exe"], 2869: ["System", "svchost.exe"], 5004: ["wmpnetwk.exe", "svchost.exe"], 5005: ["wmpnetwk.exe", "svchost.exe"],
21: ["ftpd.exe"], 22: ["sshd.exe"], 80: ["httpd.exe", "iis.exe", "System"], 443: ["httpd.exe", "System"], 3389: ["svchost.exe", "termsrv.exe"]}
CLIENT_APPS = ["chrome.exe", "firefox.exe", "iexplore.exe", "outlook.exe", "excel.exe", "winword.exe", "powershell.exe", "cmd.exe"]
LOCALHOST_IPS = ["127.0.0.1", "::1"]
RED_BG = '\033[41m\033[37m'PURPLE = '\033[95m'RED = '\033[91m'ORANGE = '\033[33m'YELLOW = '\033[93m'GREEN = '\033[92m'CYAN = '\033[96m'RESET = '\033[0m'
def parse_ip_port(address_str): if address_str == "*:*": return "*", 0 match_v6 = re.search(r'^\[(.*)\]:(\d+)$', address_str) if match_v6: return match_v6.group(1), int(match_v6.group(2)) match_v4 = re.search(r'^(.*):(\d+)$', address_str) if match_v4: return match_v4.group(1), int(match_v4.group(2)) return address_str, 0
def analizar_tipo_ip(ip_str): ip_clean = ip_str.replace("[", "").replace("]", "") if ip_clean in LOCALHOST_IPS: return 'LOOPBACK' if ip_clean == "*" or ip_clean == "0.0.0.0" or ip_clean == "::" or ip_clean == ":::0": return 'ANY' if ip_clean.startswith("169.254") or ip_clean.lower().startswith("fe80:"): return 'LINK_LOCAL' try: ip = ipaddress.ip_address(ip_clean) if ip.is_loopback: return 'LOOPBACK' if ip.is_multicast: return 'MULTICAST' if ip.is_private: return 'PRIVATE' return 'PUBLIC' except ValueError: return 'INVALID'
def es_port_dinamic(port): return 49152 <= port <= 65535
def analizar_netscan_reasoned(archivo_path): alerts_process_mismatch = [] alerts_suspicious_app = [] alerts_c2_traffic = [] alerts_lateral_move = [] alerts_rare_ports = []
stats = {"total": 0, "hidden": 0}
try: with open(archivo_path, 'r') as f: lines = f.readlines()
print(f"\n{CYAN}{'='*90}") print(f" [*] ANALIZADOR NETSCAN FORENSE EXPLICADO v6.0") print(f"{'='*90}{RESET}\n")
for line in lines: if "Offset" in line or "Volatility" in line or not line.strip(): continue parts = line.strip().split() if len(parts) < 5: continue stats["total"] += 1
proto = parts[1] local_addr_raw = parts[2] remote_addr_raw = parts[3] state = "UDP" current_idx = 4 if proto.lower().startswith("tcp"): state = parts[current_idx] current_idx += 1
owner = "?" for i in range(current_idx, len(parts)): if parts[i].isdigit(): if i + 1 < len(parts): owner = " ".join(parts[i+1:]) break if " " in owner: owner = owner.split()[0]
l_ip, l_port = parse_ip_port(local_addr_raw) r_ip, r_port = parse_ip_port(remote_addr_raw) if l_port == 0: continue
info = {'raw': line.strip(), 'l_port': l_port, 'owner': owner, 'proto': proto, 'state': state, 'r_ip': r_ip, 'r_port': r_port, 'reason': ''}
r_type = analizar_tipo_ip(r_ip) l_type = analizar_tipo_ip(l_ip) is_listening = "LISTENING" in state
if not is_listening and (l_type == 'LOOPBACK' or l_type == 'ANY') and (r_type == 'LOOPBACK' or r_type == 'ANY'): stats["hidden"] += 1 continue if r_type == 'MULTICAST' or l_type == 'MULTICAST': stats["hidden"] += 1 continue
if l_port in KNOWN_SERVICES: allowed = [x.lower() for x in KNOWN_SERVICES[l_port]] if owner.lower() not in allowed: info['reason'] = f"El port {l_port} està reservat per a {KNOWN_SERVICES[l_port]}, però es utilizado por '{owner}'. Esto puede indicar inyección de código o suplantación." alerts_process_mismatch.append(info) continue else: stats["hidden"] += 1 continue
if is_listening and owner.lower() in CLIENT_APPS: info['reason'] = f"La aplicación '{owner}' es un client (navegador/oficina) i NUNCA debería estar en mode LISTENING. Possible backdoor." alerts_suspicious_app.append(info) continue
if r_type == 'PRIVATE' and state == 'ESTABLISHED': info['reason'] = f"Conexión activa (ESTABLISHED) con IP privada {r_ip}. Posibles movimientos laterales dentro de la red local." alerts_lateral_move.append(info) continue
if r_type == 'PUBLIC': info['reason'] = f"Conexión con IP pública {r_ip}. Verificar reputación en VirusTotal (Posible Command & Control)." alerts_c2_traffic.append(info) continue
if is_listening: if es_port_dinamic(l_port) and owner.lower() in ["svchost.exe", "system", "lsass.exe", "services.exe", "wininit.exe", "spoolsv.exe"]: stats["hidden"] += 1 continue
info['reason'] = f"El puerto {l_port} NO es un servicio estándar de Windows. A pesar de ser '{owner}', tener abierto un puerto desconocido es altamente sospechoso." alerts_rare_ports.append(info) continue
stats["hidden"] += 1
def print_block(alerts, color, title): print(f"{color}{'='*90}") print(f" {title}") print(f"{'='*90}{RESET}") for x in alerts: print(f"{color}--> DETECCIÓN: {x['raw']}{RESET}") print(f" {CYAN}[MOTIVO]: {x['reason']}{RESET}\n")
if alerts_process_mismatch: print_block(alerts_process_mismatch, RED_BG, "[!!!] ALERTA CRÍTICA: PROCESO INCORRECTO")
if alerts_c2_traffic: print_block(alerts_c2_traffic, RED, "[🌐] CONEXIONES INTERNET ACTIVAS (POTENCIAL C2)")
if alerts_lateral_move: print_block(alerts_lateral_move, PURPLE, "[↔] MOVIMIENTO LATERAL DETECTADO (RED INTERNA)")
if alerts_suspicious_app: print_block(alerts_suspicious_app, ORANGE, "[!] APP SOSPECHOSA ESCUCHANDO")
if alerts_rare_ports: alerts_rare_ports.sort(key=lambda x: x['l_port']) print_block(alerts_rare_ports, YELLOW, "[?] PUERTOS RAROS / NO ESTÁNDAR (Listening)")
print(f"{GREEN}[INFO] Se han ocultado {stats['hidden']} líneas de tráfico normal/ruido de sistema.{RESET}")
except Exception as e: print(f"Error: {e}")
if __name__ == "__main__": analizar_netscan_reasoned(sys.argv[1])之后,我们将运行python进行扫描并查看结果。
结果:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ python3 analizar_netscan.py netscan.txt
========================================================================================== [*] ANALIZADOR NETSCAN FORENSE EXPLICADO v6.0==========================================================================================
========================================================================================== [?] PUERTOS RAROS / NO ESTÁNDAR (Listening)==========================================================================================--> DETECCIÓ: 0x5cabcdd0 TCPv4 0.0.0.0:554 0.0.0.0:0 LISTENING 2464 wmpnetwk.exe [MOTIU]: El puerto 554 NO es un servicio estándar de Windows. A pesar de ser 'wmpnetwk.exe', tener abierto un puerto desconocido es altamente sospechoso.
--> DETECCIÓ: 0x5d5f79c0 TCPv4 0.0.0.0:554 0.0.0.0:0 LISTENING 2464 wmpnetwk.exe [MOTIU]: El puerto 554 NO es un servicio estándar de Windows. A pesar de ser 'wmpnetwk.exe', tener abierto un puerto desconocido es altamente sospechoso.
--> DETECCIÓ: 0x5d5f79c0 TCPv6 :::554 :::0 LISTENING 2464 wmpnetwk.exe [MOTIU]: El puerto 554 NO es un servicio estándar de Windows. A pesar de ser 'wmpnetwk.exe', tener abierto un puerto desconocido es altamente sospechoso.
--> DETECCIÓ: 0x5d5e8960 TCPv4 0.0.0.0:10243 0.0.0.0:0 LISTENING 4 System [MOTIU]: El puerto 10243 NO es un servicio estándar de Windows. A pesar de ser 'System', tener abierto un puerto desconocido es altamente sospechoso.
--> DETECCIÓ: 0x5d5e8960 TCPv6 :::10243 :::0 LISTENING 4 System [MOTIU]: El puerto 10243 NO es un servicio estándar de Windows. A pesar de ser 'System', tener abierto un puerto desconocido es altamente sospechoso.
[INFO] Se han ocultado 61 líneas de tráfico normal/ruido de sistema.user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$1.8. 恶意软件分析(Malfind)
Sección titulada «1.8. Análisis de Malware (Malfind)»我们将搜索具有执行、读取和写入权限的内存区域(PAGE_EXECUTE_READWRITE),这些区域通常表明代码注入。
命令:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run --rm -v $PWD:/dumps:ro vol2 -f /dumps/victim.raw --profile=Win7SP1x64 malfindVolatility Foundation Volatility Framework 2.6.1Process: explorer.exe Pid: 1860 Address: 0x3ee0000Vad Tag: VadS Protection: PAGE_EXECUTE_READWRITEFlags: CommitCharge: 1, MemCommit: 1, PrivateMemory: 1, Protection: 6
0x0000000003ee0000 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................0x0000000003ee0010 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................0x0000000003ee0020 00 00 ee 03 00 00 00 00 00 00 00 00 00 00 00 00 ................0x0000000003ee0030 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
0x0000000003ee0000 0000 ADD [EAX], AL0x0000000003ee0002 0000 ADD [EAX], AL0x0000000003ee0004 0000 ADD [EAX], AL0x0000000003ee0006 0000 ADD [EAX], AL0x0000000003ee0008 0000 ADD [EAX], AL0x0000000003ee000a 0000 ADD [EAX], AL0x0000000003ee000c 0000 ADD [EAX], AL0x0000000003ee000e 0000 ADD [EAX], AL0x0000000003ee0010 0000 ADD [EAX], AL0x0000000003ee0012 0000 ADD [EAX], AL0x0000000003ee0014 0000 ADD [EAX], AL0x0000000003ee0016 0000 ADD [EAX], AL0x0000000003ee0018 0000 ADD [EAX], AL0x0000000003ee001a 0000 ADD [EAX], AL0x0000000003ee001c 0000 ADD [EAX], AL0x0000000003ee001e 0000 ADD [EAX], AL0x0000000003ee0020 0000 ADD [EAX], AL0x0000000003ee0022 ee OUT DX, AL0x0000000003ee0023 0300 ADD EAX, [EAX]0x0000000003ee0025 0000 ADD [EAX], AL0x0000000003ee0027 0000 ADD [EAX], AL0x0000000003ee0029 0000 ADD [EAX], AL0x0000000003ee002b 0000 ADD [EAX], AL0x0000000003ee002d 0000 ADD [EAX], AL0x0000000003ee002f 0000 ADD [EAX], AL0x0000000003ee0031 0000 ADD [EAX], AL0x0000000003ee0033 0000 ADD [EAX], AL0x0000000003ee0035 0000 ADD [EAX], AL0x0000000003ee0037 0000 ADD [EAX], AL0x0000000003ee0039 0000 ADD [EAX], AL0x0000000003ee003b 0000 ADD [EAX], AL0x0000000003ee003d 0000 ADD [EAX], AL0x0000000003ee003f 00 DB 0x0
Process: explorer.exe Pid: 1860 Address: 0x3f90000Vad Tag: VadS Protection: PAGE_EXECUTE_READWRITEFlags: CommitCharge: 2, PrivateMemory: 1, Protection: 6
0x0000000003f90000 00 00 00 00 00 00 00 00 4b 5b b2 8d 2d d2 00 01 ........K[..-...0x0000000003f90010 ee ff ee ff 00 00 00 00 28 01 f9 03 00 00 00 00 ........(.......0x0000000003f90020 28 01 f9 03 00 00 00 00 00 00 f9 03 00 00 00 00 (...............0x0000000003f90030 00 00 f9 03 00 00 00 00 80 00 00 00 00 00 00 00 ................
0x0000000003f90000 0000 ADD [EAX], AL0x0000000003f90002 0000 ADD [EAX], AL0x0000000003f90004 0000 ADD [EAX], AL0x0000000003f90006 0000 ADD [EAX], AL0x0000000003f90008 4b DEC EBX0x0000000003f90009 5b POP EBX0x0000000003f9000a b28d MOV DL, 0x8d0x0000000003f9000c 2dd20001ee SUB EAX, 0xee0100d20x0000000003f90011 ff DB 0xff0x0000000003f90012 ee OUT DX, AL0x0000000003f90013 ff00 INC DWORD [EAX]0x0000000003f90015 0000 ADD [EAX], AL0x0000000003f90017 0028 ADD [EAX], CH0x0000000003f90019 01f9 ADD ECX, EDI0x0000000003f9001b 0300 ADD EAX, [EAX]0x0000000003f9001d 0000 ADD [EAX], AL0x0000000003f9001f 0028 ADD [EAX], CH0x0000000003f90021 01f9 ADD ECX, EDI0x0000000003f90023 0300 ADD EAX, [EAX]0x0000000003f90025 0000 ADD [EAX], AL0x0000000003f90027 0000 ADD [EAX], AL0x0000000003f90029 00f9 ADD CL, BH0x0000000003f9002b 0300 ADD EAX, [EAX]0x0000000003f9002d 0000 ADD [EAX], AL0x0000000003f9002f 0000 ADD [EAX], AL0x0000000003f90031 00f9 ADD CL, BH0x0000000003f90033 0300 ADD EAX, [EAX]0x0000000003f90035 0000 ADD [EAX], AL0x0000000003f90037 008000000000 ADD [EAX+0x0], AL0x0000000003f9003d 0000 ADD [EAX], AL0x0000000003f9003f 00 DB 0x0
Process: svchost.exe Pid: 1820 Address: 0x24f0000Vad Tag: VadS Protection: PAGE_EXECUTE_READWRITEFlags: CommitCharge: 128, MemCommit: 1, PrivateMemory: 1, Protection: 6
0x00000000024f0000 20 00 00 00 e0 ff 07 00 0c 00 00 00 01 00 05 00 ................0x00000000024f0010 00 42 00 50 00 30 00 70 00 60 00 00 00 00 00 00 .B.P.0.p.`......0x00000000024f0020 48 8b 45 28 c7 00 00 00 00 00 c7 40 04 00 00 00 H.E(.......@....0x00000000024f0030 00 48 8b 45 28 48 8d 40 08 48 89 c2 48 8b 45 20 .H.E(H.@.H..H.E.
0x00000000024f0000 2000 AND [EAX], AL0x00000000024f0002 0000 ADD [EAX], AL0x00000000024f0004 e0ff LOOPNZ 0x24f00050x00000000024f0006 07 POP ES0x00000000024f0007 000c00 ADD [EAX+EAX], CL0x00000000024f000a 0000 ADD [EAX], AL0x00000000024f000c 0100 ADD [EAX], EAX0x00000000024f000e 0500004200 ADD EAX, 0x4200000x00000000024f0013 50 PUSH EAX0x00000000024f0014 0030 ADD [EAX], DH0x00000000024f0016 007000 ADD [EAX+0x0], DH0x00000000024f0019 60 PUSHA0x00000000024f001a 0000 ADD [EAX], AL0x00000000024f001c 0000 ADD [EAX], AL0x00000000024f001e 0000 ADD [EAX], AL0x00000000024f0020 48 DEC EAX0x00000000024f0021 8b4528 MOV EAX, [EBP+0x28]0x00000000024f0024 c70000000000 MOV DWORD [EAX], 0x00x00000000024f002a c7400400000000 MOV DWORD [EAX+0x4], 0x00x00000000024f0031 48 DEC EAX0x00000000024f0032 8b4528 MOV EAX, [EBP+0x28]0x00000000024f0035 48 DEC EAX0x00000000024f0036 8d4008 LEA EAX, [EAX+0x8]0x00000000024f0039 48 DEC EAX0x00000000024f003a 89c2 MOV EDX, EAX0x00000000024f003c 48 DEC EAX0x00000000024f003d 8b4520 MOV EAX, [EBP+0x20]
Process: svchost.exe Pid: 1820 Address: 0x4d90000Vad Tag: VadS Protection: PAGE_EXECUTE_READWRITEFlags: CommitCharge: 256, MemCommit: 1, PrivateMemory: 1, Protection: 6
0x0000000004d90000 20 00 00 00 e0 ff 0f 00 0c 00 00 00 01 00 05 00 ................0x0000000004d90010 00 42 00 50 00 30 00 70 00 60 00 00 00 00 00 00 .B.P.0.p.`......0x0000000004d90020 ba fc ff ff ff 03 55 20 03 55 5c b9 04 00 1a 00 ......U..U\.....0x0000000004d90030 4c 8b c5 ff 95 e0 37 00 00 8b 4d 24 89 08 48 8d L.....7...M$..H.
0x0000000004d90000 2000 AND [EAX], AL0x0000000004d90002 0000 ADD [EAX], AL0x0000000004d90004 e0ff LOOPNZ 0x4d900050x0000000004d90006 0f000c00 STR WORD [EAX+EAX]0x0000000004d9000a 0000 ADD [EAX], AL0x0000000004d9000c 0100 ADD [EAX], EAX0x0000000004d9000e 0500004200 ADD EAX, 0x4200000x0000000004d90013 50 PUSH EAX0x0000000004d90014 0030 ADD [EAX], DH0x0000000004d90016 007000 ADD [EAX+0x0], DH0x0000000004d90019 60 PUSHA0x0000000004d9001a 0000 ADD [EAX], AL0x0000000004d9001c 0000 ADD [EAX], AL0x0000000004d9001e 0000 ADD [EAX], AL0x0000000004d90020 bafcffffff MOV EDX, 0xfffffffc0x0000000004d90025 035520 ADD EDX, [EBP+0x20]0x0000000004d90028 03555c ADD EDX, [EBP+0x5c]0x0000000004d9002b b904001a00 MOV ECX, 0x1a00040x0000000004d90030 4c DEC ESP0x0000000004d90031 8bc5 MOV EAX, EBP0x0000000004d90033 ff95e0370000 CALL DWORD [EBP+0x37e0]0x0000000004d90039 8b4d24 MOV ECX, [EBP+0x24]0x0000000004d9003c 8908 MOV [EAX], ECX0x0000000004d9003e 48 DEC EAX0x0000000004d9003f 8d DB 0x8d
Process: wmpnetwk.exe Pid: 2464 Address: 0x280000Vad Tag: VadS Protection: PAGE_EXECUTE_READWRITEFlags: CommitCharge: 16, MemCommit: 1, PrivateMemory: 1, Protection: 6
0x0000000000280000 41 ba 80 00 00 00 48 b8 38 a1 e6 ff fe 07 00 00 A.....H.8.......0x0000000000280010 48 ff 20 90 41 ba 81 00 00 00 48 b8 38 a1 e6 ff H...A.....H.8...0x0000000000280020 fe 07 00 00 48 ff 20 90 41 ba 82 00 00 00 48 b8 ....H...A.....H.0x0000000000280030 38 a1 e6 ff fe 07 00 00 48 ff 20 90 41 ba 83 00 8.......H...A...
0x0000000000280000 41 INC ECX0x0000000000280001 ba80000000 MOV EDX, 0x800x0000000000280006 48 DEC EAX0x0000000000280007 b838a1e6ff MOV EAX, 0xffe6a1380x000000000028000c fe07 INC BYTE [EDI]0x000000000028000e 0000 ADD [EAX], AL0x0000000000280010 48 DEC EAX0x0000000000280011 ff20 JMP DWORD [EAX]0x0000000000280013 90 NOP0x0000000000280014 41 INC ECX0x0000000000280015 ba81000000 MOV EDX, 0x810x000000000028001a 48 DEC EAX0x000000000028001b b838a1e6ff MOV EAX, 0xffe6a1380x0000000000280020 fe07 INC BYTE [EDI]0x0000000000280022 0000 ADD [EAX], AL0x0000000000280024 48 DEC EAX0x0000000000280025 ff20 JMP DWORD [EAX]0x0000000000280027 90 NOP0x0000000000280028 41 INC ECX0x0000000000280029 ba82000000 MOV EDX, 0x820x000000000028002e 48 DEC EAX0x000000000028002f b838a1e6ff MOV EAX, 0xffe6a1380x0000000000280034 fe07 INC BYTE [EDI]0x0000000000280036 0000 ADD [EAX], AL0x0000000000280038 48 DEC EAX0x0000000000280039 ff20 JMP DWORD [EAX]0x000000000028003b 90 NOP0x000000000028003c 41 INC ECX0x000000000028003d ba DB 0xba0x000000000028003e 83 DB 0x830x000000000028003f 00 DB 0x0
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$结果:
-
检测到的可疑进程 (PIDs):
1860, 1820, 2464 -
指标: 是否观察到‘MZ’头或异常十六进制代码?
在输出中未看到经典的
4D 5A头(“MZ”)位于块的开头。这表明他们未注入完整的.exe或.dll文件(或已删除头以隐藏),而是可能是Shellcode或混淆的可执行文件。
我们将转储可疑进程的内存以查找与恶意域名相关的文本字符串(strings)。
步骤 1:内存转储(Dump)命令:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run --rm -v "$PWD":/dumps vol2 -f /dumps/victim.raw --profile=Win7SP1x64 memdump -p 1820 --dump-dir=/dumps/resultat_memdumpVolatility Foundation Volatility Framework 2.6.1************************************************************************Writing svchost.exe [ 1820] to 1820.dmpuser.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run --rm -v "$PWD":/dumps vol2 -f /dumps/victim.raw --profile=Win7SP1x64 memdump -p 1860 --dump-dir=/dumps/resultat_memdumpVolatility Foundation Volatility Framework 2.6.1************************************************************************Writing explorer.exe [ 1860] to 1860.dmpuser.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run --rm -v "$PWD":/dumps vol2 -f /dumps/victim.raw --profile=Win7SP1x64 memdump -p 2464 --dump-dir=/dumps/resultat_memdumpVolatility Foundation Volatility Framework 2.6.1************************************************************************Writing wmpnetwk.exe [ 2464] to 2464.dmpuser.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$步骤 2:字符串搜索(Grep)命令:
-
PID 1820
Ventana de terminal strings resultat_memdump/1820.dmp | grep "www.go"strings resultat_memdump/1820.dmp | grep "www.i"strings resultat_memdump/1820.dmp | grep "www.ic"strings resultat_memdump/1820.dmp | grep -E "[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}" -
PID 1860
Ventana de terminal strings resultat_memdump/1860.dmp | grep "www.go"strings resultat_memdump/1860.dmp | grep "www.i"strings resultat_memdump/1860.dmp | grep "www.ic"strings resultat_memdump/1860.dmp | grep -E "[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}" -
PID 2464
Ventana de terminal strings resultat_memdump/2464.dmp | grep "www.go"strings resultat_memdump/2464.dmp | grep "www.i"strings resultat_memdump/2464.dmp | grep "www.ic"strings resultat_memdump/2464.dmp | grep -E "[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}"
结果(检测到的IOC):
- 域 1:
www.go****.ru->www.goporn.ru, www.go4win.ru, www.go4win.ru, www.gocaps.ru - 域 2:
www.i****.com->www.iciba.com, www.ikaka.com - 域 3:
www.ic******.com->www.icsalabs.com - IP 1:
202..233.->202.107.233.211 - IP 2:
.200..164->209.200.12.164 - IP 3:
209.190..->209.190.122.186
2. 图像分析 2 (imagen2.vmem)
Sección titulada «2. Análisis Imagen 2 (imagen2.vmem)»命令:
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/Snapshot19.vmem imageinfo[sudo] contraseña para user.portelcore:Volatility Foundation Volatility Framework 2.6.1INFO : volatility.debug : Determining profile based on KDBG search... Suggested Profile(s) : Win7SP1x64, Win7SP0x64, Win2008R2SP0x64, Win2008R2SP1x64_24000, Win2008R2SP1x64_23418, Win2008R2SP1x64, Win7SP1x64_24000, Win7SP1x64_23418 AS Layer1 : WindowsAMD64PagedMemory (Kernel AS) AS Layer2 : FileAddressSpace (/dumps/Snapshot19.vmem) PAE type : No PAE DTB : 0x187000L KDBG : 0xf80002bfd0a0L Number of Processors : 1 Image Type (Service Pack) : 1 KPCR for CPU 0 : 0xfffff80002bfed00L KUSER_SHARED_DATA : 0xfffff78000000000L Image date and time : 2020-12-27 23:06:01 UTC+0000 Image local date and time : 2020-12-28 00:06:01 +0100user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$结果:
- 选定的配置文件:
Win7SP1x64
我们将提取用户的NTLM哈希并对其进行破解(或搜索)以获取明文密码。
命令(提取):
user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$ sudo docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/Snapshot19.vmem --profile=Win7SP1x64 hashdumpVolatility Foundation Volatility Framework 2.6.1Administrator:500:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::Guest:501:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::John:1001:aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0:::HomeGroupUser$:1002:aad3b435b51404eeaad3b435b51404ee:91c34c06b7988e216c3bfeb9530cabfb:::user.portelcore@fedora:~/Escritorio/Cyber/M4-Forense/Volatiliy/victimas$结果:
- 用户John的哈希值:
aad3b435b51404eeaad3b435b51404ee:31d6cfe0d16ae931b73c59d7e0c089c0::: - 明文密码(破解后):
[RESPUESTA]
2.3. 设备最后一次关机时间(Shutdown Time)
Sección titulada «2.3. Última Apagada del Equipo (Shutdown Time)»我们将检查内存中的Windows注册表,以确定机器最后一次关机的时间。
命令:
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/imagen2.vmem --profile=[PERFIL] printkey -K "ShutdownTime"结果:
- 日期和时间(UTC):
[RESPUESTA]
2.4. TrueCrypt密码
Sección titulada «2.4. Contraseña de TrueCrypt»我们将查找内存中是否有TrueCrypt加密容器的密码。
命令:
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/imagen2.vmem --profile=[PERFIL] truecryptpassphrase结果:
- 找到的密码:
[RESPUESTA]
法律声明:此实践在受控环境中进行,仅用于教育目的。
1. 图像1(victim.raw)
Sección titulada «1. Análisis Imagen 1 (victim.raw)»注意:建议将长命令的输出重定向到文本文件(例如,> salida.txt),以避免每次都等待。
我们必须确定操作系统。我们将使用Volatility 2 (imageinfo)和Volatility 3 (windows.info).
命令(Volatility 2):
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/victim.raw imageinfo > imageinfo_victim.txtcat imageinfo_victim.txt命令(Volatility 3):
docker run --rm -v "$PWD":/dumps:ro vol3 -f /dumps/victim.raw windows.info结果和分析:
- 检测到的操作系统:
[RESPUESTA] - 建议的配置文件(Vol2)我们将使用:
[ESCRIBIR EL PERFIL AQUÍ] - 截图:
[ENGANXAR RESULTAT DE IMAGEINFO/WINDOWS.INFO]我们将检查配置文件并分析进程树。我们将执行 pslist、pstree 和 psxview。
命令:
# Llistat simple (per verificar perfil)docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/victim.raw --profile=[PERFIL] pslist > pslist.txt
# Arbre de processos (relació pare-fill)docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/victim.raw --profile=[PERFIL] pstree > pstree.txt
# Visió creuada (processos ocults)docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/victim.raw --profile=[PERFIL] psxview > psxview.txt问题:
SearchIndexer的进程标识符(PID)是什么?[RESPUESTA]- 它的父进程(PPID)和 PID 是什么?
[RESPUESTA] - 相关捕获(Pstree 或 Pslist):
[ENGANXAR PART DEL PSLIST/PSTREE ON SURT SEARCHINDEXER]1.3. 最后访问的目录(Shellbags)
Sección titulada «1.3. Último Directorio Accedido (Shellbags)»我们将通过 Shellbags 调查用户活动。
命令:
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/victim.raw --profile=[PERFIL] shellbags > shellbags.txt# Podemos hacer un grep para buscar fechas recientes o abrir el archivo de texto结果:
- 用户最后访问的目录是什么?
[RESPUESTA] - 访问日期:
[RESPUESTA]
我们将查找活动连接。
命令:
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/victim.raw --profile=[PERFIL] netscan# Si netscan no funciona (per ser XP), prova 'connscan' o 'sockets'结果:
- 有可疑端口吗?第一个出现的是哪个?
[RESPUESTA] - 状态和远程IP:
[RESPUESTA]
1.5. 恶意软件分析(Malfind)
Sección titulada «1.5. Análisis de Malware (Malfind)»我们将执行 malfind 以搜索代码注入。我们将查找属性 Vad Tag 和保护 PAGE_EXECUTE_READWRITE 。
命令:
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/victim.raw --profile=[PERFIL] malfind > malfind.txt结果:
- 哪些进程可疑(PIDs)?
[RESPUESTA] - 解释(十六进制/VAD 标记):
[RESPUESTA]
我们将提取前一点检测到的恶意进程的图像并搜索特定模式(字符串) 。
步骤1:内存转储(Dump)命令:
# Substitueix [PID] pels PIDs trobats a malfind (ex: 1234)docker run --rm -v "$PWD":/dumps vol2 -f /dumps/victim.raw --profile=[PERFIL] memdump -p [PID] --dump-dir=/dumps步骤 2:字符串搜索(Grep)
以下命令直接在 Fedora 终端上对已创建的 .dmp 文件执行。
命令和结果:
-
‘www.go*.ru’**
Ventana de terminal strings [PID].dmp | grep "www.go"结果:
[RESPUESTA] -
‘www.i*.com’**
Ventana de terminal strings [PID].dmp | grep "www.i"结果:
[RESPUESTA] -
‘www.ic***.com’**
Ventana de terminal strings [PID].dmp | grep "www.ic"结果:
[RESPUESTA] -
IP ‘202..233.’
Ventana de terminal strings [PID].dmp | grep "202\." | grep "233\."结果:
[RESPUESTA] -
IP ‘*.200..164’
Ventana de terminal strings [PID].dmp | grep "\.200\." | grep "164"结果:
[RESPUESTA] -
IP ‘209.190..’
Ventana de terminal strings [PID].dmp | grep "209\.190\."结果:
[RESPUESTA]
2. 图像分析 2 (Snapshot19.vmem)
Sección titulada «2. Análisis de Imagen 2 (Snapshot19.vmem)»命令:
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/Snapshot19.vmem imageinfo结果:
- 操作系统和配置:
[RESPUESTA]
2.2. 用户密码获取 (John)
Sección titulada «2.2. Obtención de Contraseñas de Usuario (John)»我们将提取凭据并使用列表 rockyou (或在线工具,如果我们没有本地安装 john ) 来找到密码。
命令(提取):
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/Snapshot19.vmem --profile=[PERFIL] hashdump结果:
- 用户John的NTLM哈希:
[COPIAR HASH] - 明文密码 (破解):
[RESPUESTA]
我们将查找注册表键 ShutdownTime。
命令:
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/Snapshot19.vmem --profile=[PERFIL] printkey -K "ShutdownTime"结果:
- 最后一次关机是什么时候?
[RESPUESTA]
2.4. TrueCrypt密码
Sección titulada «2.4. Contraseña de TrueCrypt»我们将查找内存中的加密卷密码。
命令:
docker run --rm -v "$PWD":/dumps:ro vol2 -f /dumps/Snapshot19.vmem --profile=[PERFIL] truecryptpassphrase结果:
- 找到的TrueCrypt密码是什么?
[RESPUESTA]
法律声明:此实践在受控环境中进行,仅用于教育目的。

