Lab 1-1

Lab 1-1

Questions and Short Answers

  1. Upload the files to http://www.VirusTotal.com/ and view the reports. Does either file match any existing antivirus signatures?

    A: These files were written specifically for this book, so as of this writing, you should not find a signature for them on VirusTotal.com. Of course, if these files become part of the antivirus signatures as a result of the publication of this book, the results will be different.

  2. When were these files compiled?

    A: Both files were compiled on December 19, 2010, within 1 minute of each other.

    • 在 VT(www.VirusTotal.com)中查看的结果如下:

      Lab01-01.exe:

      Lab01-01.dll:

    • 使用 PEview 软件查看如下:

      Lab01-01.exe:

      本该在此处显示,却为空。

      Lab01-01.dll:

  3. Are there any indications that either of these files is packed or obfuscated? If so, what are these indicators?

    A: There are no indications that either file is packed or obfuscated.

    查看是否加壳可以用PEiD软件:

  4. Do any imports hint at what this malware does? If so, which imports are they?

    A: The interesting imports from Lab01-01.exe are FindFirstFile, FindNextFile, and CopyFile. These imports tell us that the program searches the file-system and copies files.

    kernel32.dll是Windows 9x/Me中非常重要的32位动态链接库文件,属于内核级文件。它控制着系统的内存管理、数据的输入输出操作和中断处理,当Windows启动时,kernel32.dll就驻留在内存中特定的写保护区域,使别的程序无法占用这个内存区域。

    msvcrt.dll是微软在windows操作系统中提供的C语言运行库执行文件(MicrosoftCRuntimeLibrary),其中提供了printf、malloc、strcpy等C语言库函数的具体运行实现,并且为使用C/C++(Vc)编绎的程序提供了初始化(如获取命令行参数)以及退出等功能。

    The most interesting imports from Lab01-01.dll are CreateProcess and Sleep. We also see that this file imports functions from WS2_32.dll, which provides network functionality.

  5. Are there any other files or host-based indicators that you could look for on infected systems?

    A: Examine C:\Windows?System32?kerne132.dll for additional malicious activity. Note that the file kerne132.dll, with the number 1 instead of the letter l, is meant to look like the system file kernel32.dll. This file can be used as a host indicator to search for the malware.

    通过 IDA 查看 Lab01-01.exe,View -> Open subviews -> Strings :

  6. What network-based indicators could be used to find this malware on infected machines?

    A: The .dll file contains a reference to local IP address 127.26.152.13. This address is an artifact of this program having been created for educational and not malicious purposes. If this was real malware, the IP address should be routable, and it would be a good network-based indicator for use in identifying this malware.

    通过 IDA 查看 Lab01-01.dll,View -> Open subviews -> Strings :

  7. What would you guess is the purpose of these files?

    A: The .dll file is probably a backdoor. The .exe file is used to install or run the DLL.

Detailed Analysis

To answer the first question, we upload the file to VirusTotal.com, which performs a scan against antivirus signatures.

Next, we open the files in PEview. For each file, we navigate to the IMAGE_NT_HEADERS??IMAGE_FILE_HEADER?? -> Time Date Stamp field, which tells us the compile time. Both files were compiled on December 19, 2010, within 1 minute of each other. This confirms our suspicions that these files are part of the same package. In fact, a compile time that close strongly suggests that these files were created at the same time by the same author. We know that the files are related because of the compile times and where they were found. It’s likely that the .exe will use or install the .dll, because DLLs cannot run on their own.

Then we check to see if either file is packed. Both files have small but reasonable numbers of imports and well-formed sections with appropriate sizes. PEiD labels this as unpacked code compiled with Microsoft Visual C++, which tells us that these files are not packed. The fact that the files have few imports tells us that they are likely small programs. Notice that the DLL file has no exports, which is abnormal, but not indicative of the file being packed. (You will learn more about this export section when we return to these files in Lab 7-3.)

Next, we look at the files’ imports and strings beginning with the .exe. All of the imports from msvcrt.dll are functions that are included in nearly every executable as part of the wrapper code added by the compiler.

When we look at the imports from kernel32.dll, we see functions for opening and manipulating files, as well as the functions FindFirstFile and FindNextFile. These functions tell us that the malware searches through the filesystem, and that it can open and modify files. We can’t be sure what the program is searching for, but the .exe string suggests that it is searching for 1 executables on the victim’s system.

We also see the strings C:\Windows\System32\Kernel32.dll and C:\windows?system32\kerne132.dll. (Notice the change from the letter l to the number 1
in kernel32.dll.) The file kerne132.dll is clearly meant to disguise itself as the Windows kernel32.dll file. The file kerne132.dll can serve as a host-based indicator to locate infections, and it is one that we should analyze for malicious code.

Next, we look at the imports and strings for Lab01-01.dll, which imports functions from WS2_32.dll. Because these functions are imported by ordinal, we don’t know which functions are being imported.

We also see two interesting functions imported from kernel32.dll: CreateProcess and Sleep, which are commonly used as backdoors. These functions are particularly interesting to us in combination with the strings exec and sleep. The exec string is probably sent over the network to command the backdoor to run a program with CreateProcess. The sleep string is probably used to command the backdoor program to sleep. (This malware is complex. We’ll return to it in Lab 7-3, once we have covered the skills to analyze it fully.)

Preference

恶意代码分析实战 Lab 1-1 习题笔记

原文地址:https://www.cnblogs.com/d0ct0rx/p/10224402.html

时间: 2024-10-13 02:09:30

Lab 1-1的相关文章

Simulation.Lab.Software.SimLab.Composer.2015.v6.1.MACOSX 1CD

CA Spectrum Linux VM 10.01.00.00.103 Linux 2DVD  Tahoe Design HYDROFLO v3.0.0.4 1CD  CA Spectrum Windows VM 10.01.00.00.103 Win64 2DVD  Delcam Exchange 2016 R2 CR 8.3.1005 Win64 1CD  Delcam PowerSHAPE 2016 SP2 Update only 1CD  ESI Group VA One 2015.0

x01.Lab.StoreApp: XP 停服,微软变脸

变脸,川剧的一种表演形式,除了哄哄小孩,似乎别无用处.而川剧变脸从业者何其多也,存在时间何其长也.以如此多的从业者,如此长的时间,来进行科研,其成果一定是斐然吧.推而广之,试问天下谁能敌! 微软变脸,足以改变世界.这次变脸,不仅是形式上的,而且是骨子里的.为适应手机.平板的性能苛求,其应用商店程序是建立在 WinRT 的基础上,而 WinRT 是建立在 COM 基础上.即面向对象,又拥抱底层,可谓鱼与熊掌兼得.不仅如此,其开发者许可,应用商店成立,无一不在显示微软的掌控能力."天下英雄,尽入毂中

Citrix Provisioning Services LAB時出現Unable to contact th database Server

今天在執行PVS LAB時出現下圖 後來發現為SQL連入的要調整如下圖1.Machine Account2.對應DB3.DB權限 如果是用SA帳戶作為本機的SQL,就是調這組帳戶 調完後對應就可以使用PVS 感謝

Lab颜色空间进行颜色提取 及其实现

这段时间在做车灯检测,晚上有些尾灯偏黄色亮度偏弱,仅用灰度度是不够的,经比较了在RGB.HSV.Lab颜色空间下进行颜色提取,发现Lab颜色模型的效果是最好的.下面介绍Lab的原理及其代码实现. Lab颜色模型由三个要素组成,一个要素是亮度(L),a 和b是两个颜色通道.a包括的颜色是从深绿色(低亮度值)到灰色(中亮度值)再到亮粉红色(高亮度值):b是从亮蓝色(低亮度值)到灰色(中亮度值)再到黄色(高亮度值).因此,这种颜色混合后将产生具有明亮效果的色彩.(这段百度的,哈哈 ) RGB转换到La

Lab - Hot Standby Router Protocol

Topology Objective Configure inter-VLAN routing with HSRP to provide redundant, fault-tolerant routing to the internal network. Background Hot Standby Router Protocol (HSRP) is a Cisco-proprietary redundancy protocol for establishing a fault-tolerant

MIT OS lab Makefile 分析

lab1 中的Makefile主要是根目录下的GNUMakefile, kern/Makefrag, boot/Makefrag, 后两者通过include直接包含到GNUMakefile中. 1 # 2 # This makefile system follows the structuring conventions 3 # recommended by Peter Miller in his excellent paper: 4 # 5 # Recursive Make Considere

CSAPP 3e : Data lab

/* * CS:APP Data Lab * * <Please put your name and userid here> * * bits.c - Source file with your solutions to the Lab. * This is the file you will hand in to your instructor. * * WARNING: Do not include the <stdio.h> header; it confuses the

CSAPP 3e: Bomb lab (phase_1)

这一个lab拖了好久才开始慢慢完成,花的时间比较多,我也是没想到会需要这么多时间来折腾.考虑到如果把所有关卡的内容都一次发出来,太长了.所以分开操作吧. 然后,有一点是,在开始解题前的确该好好认识一下GDB,因为要使用这个工具.虽然我也感觉有些东西是可以等需要的时候再查的,但是后来找到了一篇介绍gdb命令的,写的比较详细,就下载了打印出来,占用了几节课的时间好好看了一下,就感觉特别有用,比之前更加熟悉了GDB.大概是在网页上看的时候比较急躁,所以吸收不好吧23333.还有,在解题过程中参考了不少

CSAPP 3e: Bomb lab (phase_2) + lab中的GDB 使用

这里是第二关,在这里分享一些在解题过程中用到的GDB功能. 首先,要进行断点,比如,在第二关中,断点操作有: 81: input = read_line(); 82: phase_2(input); 83: phase_defused(); break 81; break 82; break 83; 分别在read_line,phase_2,phase_defused,三个函数入口进行了断点. 另外,还有一个地方需要断点,那就是explode_bomb:操作:break explode_bomb

x01.Lab.StreetApp: MVVM

Store App 特别适用于 MVVM 模式.由于要用到 SQLite,Bing Maps,所以第一步从网上搜索并安装这两个扩展.很难想象在智能手机上运行 SQL Server 这种巨无霸型数据库,SQLite 便成为首选.运行 SQLite,需要 C++ 扩展,而解决方案属性 => 配置管理中,CPU 也不能是 Any,应改为 x86.安装后,其添加引用窗口的 扩展 项如下: 第二步,当然是下载源代码了.可到我的置顶随笔 x01.Lab.Download 中获取.解压后,双击 Lab.sln