joyce8/EMBER2024-capa huggingface dataset:
Function at 0x403e85
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
push esi
push edi
push str.SHELL32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x403fcf
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.SHBrowseForFolder
push edi
call esi
mov dword [ebp - 8], eax
test eax, eax
je 0x403fb6
push 0xc3
push edi
call esi
mov dword [ebp - 0xc], eax
test eax, eax
je 0x403fb6
push str.SHGetPathFromIDList
push edi
call esi
mov esi, eax
test esi, esi
je 0x403fb6
xor ebx, ebx
cmp byte [0x408140], bl
jne 0x403f3e
push 0x408140
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
mov ecx, 0x408140
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x403f05
sub ecx, edx
lea eax, [ecx + 0x408140]
push eax
push 0x408140
call dword [sym.imp.USER32.dll_CharPrevA]
cmp byte [eax], 0x5c
mov dword [ebp - 4], eax
jne 0x403f3e
push eax
push 0x408140
call dword [sym.imp.USER32.dll_CharPrevA]
cmp byte [eax], 0x3a
je 0x403f3e
mov eax, dword [ebp - 4]
mov byte [eax], bl
mov eax, dword [ebp + 8]
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x2c]
push eax
mov byte [0x4078c0], bl
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x20], 0x4076c0
mov dword [ebp - 0x1c], 1
mov dword [ebp - 0x18], 0x403e5d
mov dword [ebp - 0x14], 0x408140
call dword [ebp - 8]
mov ebx, eax
test ebx, ebx
je 0x403fa2
push 0x408140
push ebx
call esi
cmp byte [0x408140], 0
je 0x403f9e
mov edx, 0x408140
mov esi, 0x104
mov ecx, 0x4078c0
call fcn.00401395
push ebx
call dword [ebp - 0xc]
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
xor eax, eax
cmp byte [0x4078c0], al
setne al
jmp 0x403fe5
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [ebp + 8]
xor ebx, ebx
push ebx
push 0x10
push ebx
push ebx
push 0x4c1
push eax
jmp 0x403fde
xor ebx, ebx
push ebx
push 0x10
push ebx
push ebx
push 0x4c2
push dword [ebp + 8]
call fcn.004040e2
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret 4

Function at 0x4042f1
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ebx
push esi
push edi
mov edi, dword [sym.imp.KERNEL32.dll_FindResourceA]
push 0xa
push dword [ebp + 8]
xor ebx, ebx
push ebx
call edi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov esi, eax
cmp esi, dword [ebp + 0x10]
ja 0x40435c
cmp dword [ebp + 0xc], ebx
je 0x40435c
test esi, esi
jne 0x404325
xor eax, eax
jmp 0x40435c
push 0xa
push dword [ebp + 8]
push ebx
call edi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
test edi, edi
je 0x404321
push esi
push edi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
call dword [sym.imp.msvcrt.dll_memcpy_s]
add esp, 0x10
push edi
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, esi
pop edi
pop esi
pop ebx
pop ebp
ret 0xc
Function at 0x4043fd
Capabilities:
Set file attributes

Disassembly:
mov edi, edi
push esi
xor esi, esi
push edi
inc esi
call fcn.0040614f
test eax, eax
je 0x40445f
cmp dword [0x4082fc], 0
jne 0x404453
test byte [0x407a38], 1
jne 0x404453
push 6
push 0
push 0x403139
push dword [0x407654]
mov dword [0x408524], edi
push 0x7d3
call fcn.0040606f
sub eax, 6
je 0x404453
dec eax
je 0x404463
sub eax, 0x832
jne 0x404453
mov dword [0x4082fc], esi
push 0x80
push edi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov eax, esi
pop esi
ret
xor esi, esi
jmp 0x40445f

Function at 0x40459c
Capabilities:
Create directory

Disassembly:
mov al, byte [edi]
test al, al
je 0x4045fc
push ebx
push esi
lea esi, [edi + 1]
mov cl, byte [esi]
xor ebx, ebx
cmp cl, 0x3a
jne 0x4045bb
cmp byte [edi + 2], 0x5c
jne 0x4045bb
lea esi, [edi + 3]
jmp 0x4045f5
cmp al, 0x5c
jne 0x4045f5
cmp cl, al
jne 0x4045f5
push 2
lea esi, [edi + 2]
pop ebx
jmp 0x4045f5
cmp byte [esi], 0x5c
jne 0x4045ec
cmp byte [esi - 1], 0x3a
je 0x4045ec
test ebx, ebx
je 0x4045dd
dec ebx
jmp 0x4045ec
push 0
push edi
mov byte [esi], 0
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov byte [esi], 0x5c
push esi
call dword [sym.imp.USER32.dll_CharNextA]
mov esi, eax
cmp byte [esi], 0
jne 0x4045cb
pop esi
pop ebx
ret
Function at 0x404be5
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebx
push esi
xor ebx, ebx
push ebx
push ebx
mov esi, 0x401250
push esi
call fcn.004042f1
push 0xa
push esi
push ebx
mov dword [0x408264], eax
call dword [sym.imp.KERNEL32.dll_FindResourceA]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov dword [0x408260], eax
test eax, eax
je 0x404d4e
mov eax, dword [0x407654]
push edi
test eax, eax
je 0x404c57
mov edi, dword [sym.imp.USER32.dll_GetDlgItem]
push ebx
push 0x842
push eax
call edi
mov esi, dword [sym.imp.USER32.dll_ShowWindow]
push eax
call esi
push 5
push 0x841
push dword [0x407654]
call edi
push eax
call esi
call fcn.00404b16
test eax, eax
jne 0x404c6c
push ebx
push 0x10
push ebx
push ebx
push 0x4ba
jmp 0x404ce7
push 0x408268
push 1
push 0x404844
push fcn.004047ea
push 0x404754
push 0x4046da
push fcn.00404602
push 0x404942
push 0x40492b
call dword [sym.imp.Cabinet.dll_FDICreate]
mov edi, eax
add esp, 0x24
test edi, edi
je 0x404cd7
push 0x408260
push ebx
push 0x404957
push ebx
push 0x401044
push str.MEMCAB
push edi
call dword [sym.imp.Cabinet.dll_FDICopy]
mov esi, eax
add esp, 0x1c
test esi, esi
je 0x404cf4
push edi
call dword [sym.imp.Cabinet.dll_FDIDestroy]
pop ecx
test eax, eax
jne 0x404cf4
mov eax, dword [0x408268]
push ebx
push 0x10
push ebx
push ebx
add eax, 0x514
push eax
push dword [0x407654]
call fcn.004040e2
mov esi, ebx
mov eax, dword [0x408260]
pop edi
test eax, eax
je 0x404d0b
push eax
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov dword [0x408260], ebx
test esi, esi
jne 0x404d27
cmp dword [0x4082f8], ebx
jne 0x404d27
push ebx
push 0x10
push ebx
push ebx
push 0x4f8
push ebx
call fcn.004040e2
test byte [0x407a38], 1
jne 0x404d4c
test byte [0x408b54], 1
jne 0x404d4c
push ebx
push esi
push 0xfa1
push dword [0x407654]
call dword [sym.imp.USER32.dll_SendMessageA]
mov eax, esi
pop esi
pop ebx
ret
Function at 0x404eb0
Capabilities:
Delete file
Set current directory
Set file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, dword [0x408300]
push edi
jmp 0x404f08
cmp dword [0x407a24], 0
jne 0x404ef6
cmp dword [0x408b50], 0
jne 0x404ef6
push 0x80
push dword [esi]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push dword [esi]
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push dword [edi]
mov esi, dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_LocalFree]
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov edi, esi
test esi, esi
jne 0x404ecf
mov eax, dword [0x407a20]
test eax, eax
je 0x404f6e
cmp dword [0x407a24], 0
jne 0x404f6e
cmp dword [0x408b50], 0
jne 0x404f6e
mov edx, 0x408304
mov eax, 0x104
lea ecx, [ebp - 0x108]
call fcn.0040148d
test byte [0x408b54], 0x20
je 0x404f52
lea edi, [ebp - 0x108]
call fcn.004061d6
push 0x401100
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
lea eax, [ebp - 0x108]
push eax
call fcn.004020d3
mov eax, dword [0x407a20]
cmp word [0x408b60], 1
pop edi
pop esi
je 0x404f83
test eax, eax
je 0x404f83
call fcn.00401d0a
mov ecx, dword [ebp - 4]
and dword [0x407a20], 0
xor ecx, ebp
call fcn.004068a6
leave
ret

Function at 0x404f9b
Capabilities:
Check if file exists
Create directory
Delete directory
Delete file
Get common file path
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x110
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
push edi
xor esi, esi
mov dword [ebp - 0x10c], eax
xor edi, edi
push esi
push 0x40127c
lea eax, [ebp - 0x108]
push 0x104
push eax
call fcn.00401425
mov edx, dword [ebp - 0x10c]
add esp, 0x10
inc esi
mov dword [ebp - 0x110], esi
mov esi, 0x104
mov ecx, ebx
call fcn.00401395
push esi
lea eax, [ebp - 0x108]
mov ecx, ebx
call fcn.00406177
push ebx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x40505e
mov esi, dword [ebp - 0x110]
cmp esi, 0x190
jl 0x404fbf
push ebx
push 0
push 0x401288
push dword [ebp - 0x10c]
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
je 0x40504c
xor edi, edi
push ebx
inc edi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov ecx, dword [ebp - 4]
mov eax, edi
pop edi
xor ecx, ebp
pop esi
call fcn.004068a6
leave
ret 4
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
xor edi, edi
test eax, eax
je 0x405021
inc edi
mov dword [0x407a20], edi
jmp 0x40504c
Function at 0x40507b
Capabilities:
Create directory
Delete directory
Get system information on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x12c
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 8], 0
push esi
push edi
je 0x405127
push ebx
push edx
lea ebx, [ebp - 0x108]
call fcn.00404f9b
pop ebx
test eax, eax
je 0x405182
mov edi, 0x104
mov esi, 0x408304
lea edx, [ebp - 0x108]
mov eax, edi
mov ecx, esi
call fcn.0040148d
test byte [0x408b54], 0x20
je 0x405118
lea eax, [ebp - 0x12c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
movzx eax, word [ebp - 0x12c]
sub eax, 0
je 0x40510b
dec eax
je 0x405104
dec eax
je 0x4050fd
dec eax
jne 0x405118
mov eax, 0x4012a4
jmp 0x405110
mov eax, 0x40129c
jmp 0x405110
mov eax, 0x401294
jmp 0x405110
mov eax, 0x40128c
push edi
mov ecx, esi
call fcn.00406177
push edi
mov eax, 0x401044
mov ecx, esi
call fcn.00406177
jmp 0x405138
mov esi, 0x408304
mov eax, 0x104
mov ecx, esi
call fcn.0040148d
push esi
call fcn.004054be
xor edi, edi
inc edi
test eax, eax
jne 0x405157
push eax
push esi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
je 0x405186
mov dword [0x407a20], edi
cmp dword [ebp + 0xc], 0
je 0x405192
push 0
push dword [ebp + 0xc]
mov ecx, esi
call fcn.00405580
test eax, eax
jne 0x405192
cmp dword [0x407a20], eax
je 0x405182
and dword [0x407a20], eax
push esi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
xor eax, eax
jmp 0x40519b
call fcn.00405de9
mov dword [0x408b68], eax
jmp 0x405182
and dword [0x408b68], 0
mov eax, edi
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.004068a6
leave
ret 8
Function at 0x4054be
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov ecx, dword [ebp + 8]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4054c9
push esi
sub ecx, edx
push edi
lea esi, [ecx + 0x14]
push esi
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edi, eax
test edi, edi
jne 0x405506
xor esi, esi
push esi
push 0x10
push esi
push esi
push 0x4b5
push esi
call fcn.004040e2
call fcn.00405de9
mov dword [0x408b68], eax
xor eax, eax
jmp 0x405575
mov edx, dword [ebp + 8]
push ebx
mov ecx, edi
call fcn.00401395
push esi
mov eax, 0x4012bc
mov ecx, edi
call fcn.00406177
xor esi, esi
push esi
push 0x4000080
push 1
push esi
push esi
push 0x40000000
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileA]
push edi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
cmp ebx, 0xffffffff
je 0x405568
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x405568
test al, 0x10
je 0x405568
xor eax, eax
mov dword [0x408b68], esi
inc eax
jmp 0x405574
call fcn.00405de9
mov dword [0x408b68], eax
xor eax, eax
pop ebx
pop edi
pop esi
pop ebp
ret 4
Function at 0x405580
Capabilities:
Get common file path
Get disk information
Set current directory

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x31c
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
and dword [ebp - 0x314], 0
push ebx
push esi
lea eax, [ebp - 0x310]
push eax
push 0x104
mov esi, ecx
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
mov ebx, dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
push esi
call ebx
test eax, eax
jne 0x4055e0
push eax
push 0x10
push eax
push eax
push 0x4bc
push eax
call fcn.004040e2
call fcn.00405de9
mov dword [0x408b68], eax
xor eax, eax
jmp 0x4057b0
push edi
lea edi, [ebp - 0x314]
call fcn.0040652f
mov edi, eax
test edi, edi
jne 0x40564a
push 0x1ff
push eax
mov byte [ebp - 0x20c], al
lea eax, [ebp - 0x20b]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
call fcn.00405de9
push edi
mov dword [0x408b68], eax
push 0x200
lea eax, [ebp - 0x20c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push edi
push 0x10
lea eax, [ebp - 0x20c]
push eax
push esi
push 0x4b0
jmp 0x4056c2
xor ecx, ecx
push ecx
push ecx
lea eax, [ebp - 0x318]
push eax
lea eax, [ebp - 0x31c]
push eax
push ecx
push ecx
push ecx
push ecx
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationA]
test eax, eax
jne 0x4056d3
push 0x1ff
push eax
mov byte [ebp - 0x20c], al
lea eax, [ebp - 0x20b]
push eax
call sub.msvcrt.dll_memset
add esp, 0xc
call fcn.00405de9
xor edi, edi
push edi
mov dword [0x408b68], eax
push 0x200
lea eax, [ebp - 0x20c]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push edi
push 0x10
lea eax, [ebp - 0x20c]
push eax
push esi
push 0x4f9
push edi
call fcn.004040e2
lea eax, [ebp - 0x310]
push eax
call ebx
jmp 0x405732
lea eax, [ebp - 0x310]
push eax
call ebx
lea ecx, [ebp - 0xc]
push 6
mov eax, ecx
pop edx
sub esi, eax
lea eax, [edx - 4]
test eax, eax
je 0x4056fa
mov al, byte [esi + ecx]
test al, al
je 0x4056fa
mov byte [ecx], al
inc ecx
dec edx
jne 0x4056e6
test edx, edx
jne 0x4056ff
dec ecx
xor edx, edx
push 8
mov byte [ecx], dl
mov ecx, 0x200
mov eax, edx
pop esi
cmp dword [ebp - 0x314], ecx
je 0x40571d
add ecx, ecx
inc eax
cmp ax, si
jb 0x40570d
cmp ax, si
jne 0x405736
push edx
push 0x10
push edx
push edx
push 0x4c5
push edx
call fcn.004040e2
xor eax, eax
jmp 0x4057af
test byte [0x408b54], 8
je 0x405765
test dword [ebp - 0x318], 0x8000
je 0x405765
movzx eax, ax
mov esi, dword [eax*4 + 0x4079e0]
mov eax, dword [0x408b58]
mov ecx, eax
shr ecx, 2
add esi, esi
add ecx, eax
jmp 0x405775
mov ecx, dword [0x408b58]
movzx eax, ax
mov esi, dword [eax*4 + 0x4079e0]
mov eax, dword [ebp + 8]
and eax, 1
je 0x40578a
test byte [ebp + 8], 2
je 0x40578a
lea eax, [ecx + esi]
cmp eax, edi
jmp 0x405794
test eax, eax
je 0x405792
cmp esi, edi
jmp 0x405794
cmp ecx, edi
jbe 0x4057a6
push ecx
push dword [ebp + 0xc]
lea edx, [ebp - 0xc]
mov ecx, esi
call fcn.004023eb
jmp 0x4057af
xor eax, eax
mov dword [0x408b68], edx
inc eax
pop edi
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.004068a6
leave
ret 8
Function at 0x405d80
Capabilities:
Get common file path

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push 0x104
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
test eax, eax
jne 0x405dc9
push eax
push 0x10
push eax
push eax
push 0x4f0
push eax
call fcn.004040e2
call fcn.00405de9
mov dword [0x408b68], eax
xor eax, eax
jmp 0x405dd8
push 2
push 2
lea ecx, [ebp - 0x108]
call fcn.00405580
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004068a6
leave
ret

Function at 0x405e03
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
push edi
xor edi, edi
push edi
push 0x4012d8
mov dword [ebp - 0x24], eax
lea eax, [ebp - 0x18]
xor esi, esi
push 0x14
push eax
inc esi
mov dword [ebp - 0x1c], edi
call fcn.00401425
jmp 0x405e96
push eax
push edi
call dword [sym.imp.KERNEL32.dll_LoadResource]
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
test edi, edi
je 0x405eb6
lea edx, [edi + 8]
mov ecx, edx
lea eax, [ecx + 1]
mov dword [ebp - 0x20], eax
mov al, byte [ecx]
inc ecx
test al, al
jne 0x405e58
sub ecx, dword [ebp - 0x20]
lea eax, [edx + 1]
add eax, ecx
push eax
push edx
push dword [edi + 4]
push dword [edi]
call dword [ebp - 0x24]
push edi
test eax, eax
je 0x405eac
call dword [sym.imp.KERNEL32.dll_FreeResource]
mov eax, dword [ebp - 0x1c]
inc eax
push eax
push 0x4012d8
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x18]
push 0x14
push eax
call fcn.00401425
xor edi, edi
add esp, 0x10
push 0xa
lea eax, [ebp - 0x18]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
test eax, eax
jne 0x405e38
jmp 0x405ec2
xor esi, esi
call dword [sym.imp.KERNEL32.dll_FreeResource]
jmp 0x405ec2
mov dword [0x408b68], 0x80070714
xor esi, esi
mov ecx, dword [ebp - 4]
pop edi
mov eax, esi
xor ecx, ebp
pop esi
call fcn.004068a6
leave
ret 4

Function at 0x405fed
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, 0x104
mov edx, 0x408304
mov eax, esi
lea ecx, [ebp - 0x108]
call fcn.0040148d
push esi
mov esi, 0x4010dc
mov eax, esi
lea ecx, [ebp - 0x108]
call fcn.00406177
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x406056
test al, 0x10
jne 0x406056
push 8
push 0
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExA]
jmp 0x40605d
push esi
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.004068a6
leave
ret

Function at 0x40614f
Capabilities:
Check if file exists
Get file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x406166
xor eax, eax
jmp 0x40616e
shr eax, 4
not eax
and eax, 1
pop ebp
ret 4
Function at 0x406396
Capabilities:
Check os version
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xb4
mov eax, dword [0x40700c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [0x4072e0]
push esi
xor esi, esi
mov dword [ebp - 0xb0], 0xc
mov dword [ebp - 0xa8], esi
cmp ebx, 0xfffffffe
jne 0x4064c1
lea eax, [ebp - 0xa4]
push eax
mov dword [0x4072e0], esi
mov dword [ebp - 0xa4], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
test eax, eax
je 0x4064bb
xor ebx, ebx
inc ebx
cmp dword [ebp - 0x94], ebx
jne 0x4064bb
cmp dword [ebp - 0xa0], 4
jne 0x4064bb
cmp dword [ebp - 0x9c], 0xa
jae 0x4064bb
push 0x4a
call dword [sym.imp.USER32.dll_GetSystemMetrics]
test eax, eax
je 0x4064bb
lea eax, [ebp - 0xac]
push eax
push 0x20019
push esi
push 0x4012e4
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4064bb
lea eax, [ebp - 0xb0]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0xb4]
push eax
push esi
push 0x401044
push dword [ebp - 0xac]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
push dword [ebp - 0xac]
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
je 0x40648a
mov eax, dword [0x4072e0]
jmp 0x4064c3
push edi
lea eax, [ebp - 0x10]
push eax
lea edi, [ebp - 0xa8]
call fcn.0040627d
pop edi
test eax, eax
je 0x4064bb
mov eax, dword [ebp - 0xa8]
and eax, 0x3ff
cmp eax, ebx
je 0x4064b3
cmp eax, 0xd
jne 0x4064bb
mov dword [0x4072e0], ebx
jmp 0x4064c1
mov ebx, dword [0x4072e0]
mov eax, ebx
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.004068a6
leave
ret

Function at 0x4064d6
Capabilities:
Get disk size

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x10
push esi
xor esi, esi
cmp byte [eax], 0
mov dword [ebp - 8], esi
mov dword [ebp - 4], esi
mov dword [ebp - 0x10], esi
mov dword [ebp - 0xc], esi
je 0x406525
lea ecx, [ebp - 0xc]
push ecx
lea ecx, [ebp - 0x10]
push ecx
lea ecx, [ebp - 4]
push ecx
lea ecx, [ebp - 8]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceA]
test eax, eax
je 0x406525
mov eax, dword [ebp - 4]
imul eax, dword [ebp - 8]
push 0x400
push dword [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_MulDiv]
mov esi, eax
mov eax, esi
pop esi
leave
ret
Function at 0x406897
Capabilities:
Terminate process

Disassembly:
push 0x58
push 0x406dc8
call fcn.00406d1c
xor ebx, ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 4], ebx
lea eax, [ebp - 0x68]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
mov dword [ebp - 4], 0xfffffffe
mov dword [ebp - 4], 1
mov eax, dword fs:[0x18]
mov edi, dword [eax + 4]
mov esi, ebx
push ebx
push edi
push 0x4079cc
call dword [sym.imp.KERNEL32.dll_InterlockedCompareExchange]
test eax, eax
je 0x40670e
cmp eax, edi
jne 0x406701
xor edi, edi
inc edi
mov esi, edi
jmp 0x406711
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x4066e5
xor edi, edi
inc edi
cmp dword [0x4079d0], edi
jne 0x406723
push 0x1f
call sub.msvcrt.dll__amsg_exit
pop ecx
jmp 0x406751
cmp dword [0x4079d0], ebx
jne 0x40674b
mov dword [0x4079d0], edi
push 0x401018
push 0x40100c
call fcn.00406685
pop ecx
pop ecx
test eax, eax
je 0x406751
jmp 0x406880
mov dword [0x407304], edi
cmp dword [0x4079d0], edi
jne 0x406774
push 0x401008
push section..text
call sub.msvcrt.dll__initterm
pop ecx
pop ecx
mov dword [0x4079d0], 2
test esi, esi
jne 0x406784
push ebx
push 0x4079cc
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
cmp dword [0x4079d4], 0
je 0x4067a6
push 0x4079d4
call fcn.00406b90
pop ecx
test eax, eax
je 0x4067a6
push ebx
push 2
push ebx
call dword [0x4079d4]
mov eax, dword [sym.imp.msvcrt.dll__acmdln]
mov esi, dword [eax]
mov dword [ebp - 0x1c], esi
mov edi, dword [ebp - 0x20]
mov cl, byte [esi]
cmp cl, 0x20
ja 0x406803
test cl, cl
je 0x4067c2
test edi, edi
jne 0x406803
mov al, byte [esi]
test al, al
je 0x4067d2
cmp al, 0x20
ja 0x4067d2
inc esi
mov dword [ebp - 0x1c], esi
jmp 0x4067c2
test byte [ebp - 0x3c], 1
je 0x4067de
movzx eax, word [ebp - 0x38]
jmp 0x4067e1
push 0xa
pop eax
push eax
push esi
push ebx
push 0x400000
call main
mov dword [0x407300], eax
cmp dword [0x407318], 0
jne 0x40685c
push eax
call dword [sym.imp.msvcrt.dll_exit]
cmp cl, 0x22
jne 0x406814
xor eax, eax
test edi, edi
sete al
mov edi, eax
mov dword [ebp - 0x20], edi
movzx eax, cl
push eax
call dword [sym.imp.msvcrt.dll__ismbblead]
pop ecx
test eax, eax
je 0x406827
inc esi
mov dword [ebp - 0x1c], esi
inc esi
mov dword [ebp - 0x1c], esi
jmp 0x4067b3
cmp dword [0x407304], 0
jne 0x406870
call dword [sym.imp.msvcrt.dll__cexit]
mov eax, dword [0x407300]
mov dword [ebp - 4], 0xfffffffe
jmp 0x40688c
mov dword [ebp - 4], 0xfffffffe
mov eax, 0xff
call fcn.00406d61
ret
call fcn.00406c51
jmp 0x4066ae

Function at 0x406b00
Capabilities:
Parse pe header

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
je 0x406b16
xor eax, eax
pop ebp
ret
mov ecx, dword [eax + 0x3c]
add ecx, eax
xor eax, eax
cmp dword [ecx], 0x4550
jne 0x406b31
mov edx, 0x10b
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
Function at 0x406b40
Capabilities:
Enumerate pe sections

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x3c]
add ecx, eax
movzx eax, word [ecx + 0x14]
push ebx
movzx ebx, word [ecx + 6]
add eax, 0x18
push esi
xor edx, edx
add eax, ecx
push edi
test ebx, ebx
je 0x406b7e
mov edi, dword [ebp + 0xc]
mov esi, dword [eax + 0xc]
cmp edi, esi
jb 0x406b76
mov ecx, dword [eax + 8]
add ecx, esi
cmp edi, ecx
jb 0x406b80
inc edx
add eax, 0x28
cmp edx, ebx
jb 0x406b66
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret