joyce8/EMBER2024-capa huggingface dataset:
Function at 0x402020
Capabilities:
Delete directory
Delete file
Enumerate files on windows
Enumerate files recursively
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x25c
push ebx
push esi
push edi
mov ebx, dword [ebp + 8]
or eax, 0xffffffff
inc eax
cmp word [ebx + eax*2], 0
jne 0x402032
mov dword [ebp - 0x258], eax
lea edx, [ebx + eax*2]
xor ecx, ecx
mov ax, word [ecx + 0x415d3e]
mov word [edx + ecx], ax
add ecx, 2
test ax, ax
jne 0x402045
lea eax, [ebp - 0x250]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x254], eax
mov eax, dword [ebp - 0x258]
mov word [ebx + eax*2], 0
cmp dword [ebp - 0x254], 0xffffffff
je 0x4021c0
mov dword [ebp - 0x25c], 0
lea edx, [ebp - 0x224]
xor ecx, ecx
mov ax, word [edx + ecx]
cmp ax, word [ecx + 0x415d3a]
jne 0x4020b0
add ecx, 2
test ax, ax
jne 0x402097
xor eax, eax
jmp 0x4020b5
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x402156
lea edx, [ebp - 0x224]
xor ecx, ecx
mov ax, word [edx + ecx]
cmp ax, word [ecx + 0x415d34]
jne 0x4020de
add ecx, 2
test ax, ax
jne 0x4020c5
xor eax, eax
jmp 0x4020e3
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x402156
mov eax, dword [ebp - 0x258]
lea edx, [ebx + eax*2]
lea esi, [ebp - 0x224]
xor ecx, ecx
mov ax, word [esi + ecx]
mov word [edx + ecx], ax
add ecx, 2
test ax, ax
jne 0x4020f8
test byte [ebp - 0x250], 0x10
je 0x40212d
push 0x415e86
push ebx
call fcn.0040e410
add esp, 8
push ebx
call fcn.00402020
mov dword [ebp - 0x25c], eax
jmp 0x40214d
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x40214d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x25c], eax
cmp dword [ebp - 0x25c], 0
jne 0x40218c
lea eax, [ebp - 0x250]
push eax
push dword [ebp - 0x254]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x40208f
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x25c], eax
cmp eax, 0x12
jne 0x40218c
mov dword [ebp - 0x25c], 0
mov eax, dword [ebp - 0x258]
mov word [ebx + eax*2], 0
push dword [ebp - 0x254]
call dword [sym.imp.KERNEL32.dll_FindClose]
cmp dword [ebp - 0x25c], 0
jne 0x4021b8
push ebx
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
je 0x4021c8
mov eax, dword [ebp - 0x25c]
jmp 0x4021d4
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4021d4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x25c], eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x402e80
Capabilities:
Parse pe header
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1014
call fcn.0040cf00
push ebx
push esi
push edi
mov eax, dword [ebp + 0xc]
mov dword [eax], 0
mov eax, dword [ebp + 8]
mov dword [eax], 0
mov dword [eax + 4], 0
push 0
push pe_nt_image_headers32
push 3
push 0
push 1
push 0x80000000
push 0x41d5e8
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x1010], eax
cmp eax, 0xffffffff
je 0x403048
push 0
lea eax, [ebp - 0x100c]
push eax
push 0x1000
lea eax, [ebp - 0x1008]
push eax
push dword [ebp - 0x1010]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40304c
cmp word [ebp - 0x1008], 0x5a4d
jne 0x40305c
mov eax, dword [ebp - 0xfcc]
cmp eax, 0xf08
jae 0x40305c
lea eax, [ebp + eax - 0x1008]
mov dword [ebp - 0x1014], eax
cmp dword [eax], 0x4550
jne 0x40305c
mov eax, dword [ebp - 0x1014]
add eax, 0xf8
lea edx, [ebp - 8]
cmp eax, edx
jae 0x40305c
mov edx, dword [ebp - 0x1014]
cmp word [edx + 6], 0
jbe 0x402f8b
xor edx, edx
xor ecx, ecx
cmp dword [eax + 0x14], edx
ja 0x402f67
mov ebx, edx
jmp 0x402f77
mov esi, dword [eax + 0x14]
add esi, dword [eax + 0x10]
mov edi, dword [ebp + 0xc]
mov dword [edi], esi
mov esi, dword [eax + 0x14]
mov ebx, esi
mov edx, ebx
add eax, 0x28
inc ecx
mov ebx, dword [ebp - 0x1014]
movzx ebx, word [ebx + 6]
cmp ecx, ebx
jl 0x402f5e
push 0
push 0
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
add eax, 2
push eax
push dword [ebp - 0x1010]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
je 0x40305c
mov dword [ebp - 8], 0
mov dword [ebp - 4], 0
push 0
lea eax, [ebp - 0x100c]
push eax
push 8
lea eax, [ebp - 8]
push eax
push dword [ebp - 0x1010]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40304c
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 8]
mov ebx, dword [ebp - 4]
mov dword [eax], ecx
mov dword [eax + 4], ebx
cmp dword [ebp - 0x100c], 8
jb 0x40304c
mov dword [ebp - 8], 0
mov dword [ebp - 4], 0
push 0
lea eax, [ebp - 0x100c]
push eax
push 8
lea eax, [ebp - 8]
push eax
push dword [ebp - 0x1010]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x40304c
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp - 8]
mov ebx, dword [ebp - 4]
mov dword [eax], ecx
mov dword [eax + 4], ebx
cmp dword [ebp - 0x100c], 8
jb 0x40304c
push dword [ebp - 0x1010]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
jmp 0x40306a
xor eax, eax
jmp 0x40306a
push dword [ebp - 0x1010]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x40306a
push dword [ebp - 0x1010]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x403a50
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
xor eax, eax
mov edx, eax
shr edx, 1
mov ecx, eax
and ecx, 1
neg ecx
and ecx, 0xedb88320
xor edx, ecx
mov ecx, edx
shr ecx, 1
and edx, 1
neg edx
and edx, 0xedb88320
xor ecx, edx
mov edx, ecx
shr edx, 1
and ecx, 1
neg ecx
and ecx, 0xedb88320
xor edx, ecx
mov ecx, edx
shr ecx, 1
and edx, 1
neg edx
and edx, 0xedb88320
xor ecx, edx
mov edx, ecx
shr edx, 1
and ecx, 1
neg ecx
and ecx, 0xedb88320
xor edx, ecx
mov ecx, edx
shr ecx, 1
and edx, 1
neg edx
and edx, 0xedb88320
xor ecx, edx
mov edx, ecx
shr edx, 1
and ecx, 1
neg ecx
and ecx, 0xedb88320
xor edx, ecx
mov ecx, edx
shr ecx, 1
and edx, 1
neg edx
and edx, 0xedb88320
xor ecx, edx
mov dword [eax*4 + 0x41e25c], ecx
inc eax
cmp eax, 0x100
jb 0x403a52
mov eax, 0x100
mov edx, dword [eax*4 + 0x41de5c]
mov ecx, edx
and ecx, 0xff
mov ecx, dword [ecx*4 + 0x41e25c]
shr edx, 8
xor ecx, edx
mov dword [eax*4 + 0x41e25c], ecx
inc eax
cmp eax, 0x800
jb 0x403af4
mov dword [0x420260], 0x4076d0
mov dword [0x42025c], 0x4076d0
mov dword [0x420264], 0x407790
call fcn.00407980
test eax, eax
jne 0x403b4f
mov dword [0x42025c], 0x407790
ret

Function at 0x403cd0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 4
push ebx
push esi
push edi
mov ebx, dword [ebp + 0xc]
mov esi, dword [ebp + 0x10]
mov edi, dword [esi]
test edi, edi
je 0x403ced
mov dword [esi], 0
jmp 0x403cf1
xor eax, eax
jmp 0x403d38
mov dword [ebp - 4], 0
push 0
lea eax, [ebp - 4]
push eax
mov eax, 0x400000
cmp edi, 0x400000
cmovbe eax, edi
push eax
push ebx
mov eax, dword [ebp + 8]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov edx, dword [ebp - 4]
add ebx, edx
sub edi, edx
add dword [esi], edx
test eax, eax
je 0x403d32
cmp dword [ebp - 4], 0
je 0x403ced
test edi, edi
jne 0x403cf1
jmp 0x403ced
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc

Function at 0x403d50
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 4
push ebx
push esi
push edi
mov ebx, dword [ebp + 0xc]
mov esi, dword [ebp + 0x10]
mov edi, dword [esi]
test edi, edi
je 0x403d6d
mov dword [esi], 0
jmp 0x403d71
xor eax, eax
jmp 0x403db8
mov dword [ebp - 4], 0
push 0
lea eax, [ebp - 4]
push eax
mov eax, 0x400000
cmp edi, 0x400000
cmovbe eax, edi
push eax
push ebx
mov eax, dword [ebp + 8]
push dword [eax]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov edx, dword [ebp - 4]
add ebx, edx
sub edi, edx
add dword [esi], edx
test eax, eax
je 0x403db2
cmp dword [ebp - 4], 0
je 0x403d6d
test edi, edi
jne 0x403d71
jmp 0x403d6d
call dword [sym.imp.KERNEL32.dll_GetLastError]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x403e70
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 4
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
lea edx, [ebp - 4]
push edx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov esi, eax
cmp esi, 0xffffffff
jne 0x403e9c
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x403eae
mov edx, dword [ebp - 4]
xor eax, eax
xor edi, edi
add eax, esi
adc edx, edi
mov dword [ebx], eax
mov dword [ebx + 4], edx
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8

Function at 0x403fb0
Capabilities:
Timestomp file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
mov ebx, dword [ebp + 0xc]
mov esi, dword [ebp + 0x10]
mov edi, dword [eax]
cmp edi, 0xffffffff
je 0x403ffd
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 8]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileTime]
test eax, eax
je 0x403ffd
mov ebx, dword [ebx]
mov dword [ebp - 0x14], ebx
mov esi, dword [esi]
mov dword [ebp - 0x18], esi
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 8]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_SetFileTime]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc

Function at 0x4075c0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa2c
push ebx
mov ebx, dword [ebp + 8]
push 0x208
lea eax, [ebp - 0x410]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, 0x208
ja 0x407615
lea eax, [ebp - 0x410]
push eax
call fcn.00414cd0
push ebx
lea eax, [ebp - 0x410]
push eax
push str._ls_ls
push 0x30e
lea eax, [ebp - 0xa2c]
push eax
call fcn.0040e940
add esp, 0x14
jmp 0x40762a
push 0x30e
push ebx
lea eax, [ebp - 0xa2c]
push eax
call fcn.0040e9d0
add esp, 0xc
push 8
push 0
lea eax, [ebp - 0xa2c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x407a30
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x94
mov dword [ebp - 0x94], 0x94
lea eax, [ebp - 0x94]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov edx, eax
cmp dword [ebp - 0x90], 5
setae al
movzx eax, al
xor ecx, ecx
test edx, edx
cmove eax, ecx
mov esp, ebp
pop ebp
ret
Function at 0x40d1b0
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x416530
push 0x40e668
push dword fs:[0]
mov dword fs:[0], esp
sub esp, 0x54
push ebx
push esi
push edi
mov dword [ebp - 0x18], esp
push 0x2000000
call fcn.004107b0
pop ecx
mov dword [0x420268], eax
call fcn.0040ed90
test eax, eax
je 0x40d2ac
mov dword [ebp - 4], 0
call fcn.0040efb0
call fcn.0040f110
call fcn.0040f1f0
call fcn.0040f4f0
call fcn.0040f5a0
mov ebx, 0x417810
jmp 0x40d21f
call dword [ebx]
add ebx, 4
cmp ebx, 0x417810
jb 0x40d21a
mov dword [ebp - 0x34], 0
lea eax, [ebp - 0x60]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov ebx, eax
call fcn.0040f650
movzx edx, word [ebp - 0x30]
mov ecx, 0xa
test dword [ebp - 0x34], 1
cmovne ecx, edx
push ecx
push eax
push 0
push ebx
call fcn.00402000
mov ebx, eax
mov esi, 0x417810
jmp 0x40d272
call dword [esi]
add esi, 4
cmp esi, 0x417810
jb 0x40d26d
push ebx
call fcn.0040f690
or dword [ebp - 4], 0xffffffff
jmp 0x40d2b9
push 0xfffffffffffffffe
call fcn.0040f760
pop ecx
jmp 0x40d1f3
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
lea esp, [ebp - 0x70]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x40f4f0
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
mov esi, eax
cmp byte [esi], 0
jne 0x40f523
push 0x104
lea eax, [ebp - 0x104]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea esi, [ebp - 0x104]
lea eax, [ebp - 0x10c]
push eax
lea eax, [ebp - 0x108]
push eax
push 0
push 0
push esi
call fcn.0040f380
add esp, 0x14
mov eax, dword [ebp - 0x108]
mov edx, dword [ebp - 0x10c]
lea eax, [edx + eax*4]
push eax
call fcn.0040dad0
pop ecx
mov edi, eax
test edi, edi
je 0x40f58b
lea eax, [ebp - 0x10c]
push eax
lea eax, [ebp - 0x108]
push eax
mov ebx, dword [ebp - 0x108]
lea eax, [edi + ebx*4]
push eax
push edi
push esi
call fcn.0040f380
add esp, 0x14
dec ebx
mov dword [0x4202a4], ebx
mov dword [0x4202a8], edi
jmp 0x40f593
push 0xfffffffffffffffc
call fcn.0040f760
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x40f5a0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 4
push ebx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_GetEnvironmentStrings]
test eax, eax
cmove eax, dword [0x41802c]
mov dword [ebp - 4], eax
mov esi, eax
xor eax, eax
cmp byte [esi], 0
je 0x40f5df
or edx, 0xffffffff
inc edx
cmp byte [esi + edx], 0
jne 0x40f5c7
lea edi, [edx + 1]
cmp byte [esi], 0x3d
je 0x40f5d8
add eax, edi
add esi, edi
cmp byte [esi], 0
jne 0x40f5c4
inc eax
push eax
call fcn.0040dad0
pop ecx
mov edx, eax
mov dword [0x4202ac], eax
test eax, eax
je 0x40f63d
mov eax, dword [ebp - 4]
mov esi, eax
cmp byte [esi], 0
je 0x40f624
or eax, 0xffffffff
inc eax
cmp byte [esi + eax], 0
jne 0x40f5ff
lea edi, [eax + 1]
cmp byte [esi], 0x3d
je 0x40f61d
xor ecx, ecx
mov al, byte [esi + ecx]
mov byte [edx + ecx], al
inc ecx
test al, al
jne 0x40f610
add edx, edi
add esi, edi
cmp byte [esi], 0
jne 0x40f5fc
mov byte [edx], 0
mov eax, dword [ebp - 4]
cmp eax, dword [0x41802c]
je 0x40f645
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_FreeEnvironmentStringsA]
jmp 0x40f645
push 0xfffffffffffffffc
call fcn.0040f760
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x413620
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x810
push ebx
push esi
push edi
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp + 0x10]
lea esi, [edx + eax]
mov dword [ebp - 0xc], 0
mov dword [ebp - 8], 0
mov dword [ebp - 4], 0
mov eax, dword [ebp + 0x10]
mov edi, eax
cmp edi, esi
jae 0x413704
lea eax, [ebp - 0xd]
lea edx, [ebp - 0x80c]
lea ecx, [ebp - 0x80c]
cmp eax, ecx
jbe 0x413686
cmp edi, esi
jae 0x413686
cmp byte [edi], 0xa
jne 0x41367a
inc dword [ebp - 8]
mov byte [edx], 0xd
inc edx
inc edx
inc edi
mov cl, byte [edi - 1]
mov byte [edx - 1], cl
cmp edx, eax
jb 0x41366a
lea eax, [ebp - 0x80c]
mov ebx, edx
sub ebx, eax
push dword [ebp + 0xc]
call fcn.00413f00
pop ecx
test eax, eax
je 0x4136ba
call dword [sym.imp.KERNEL32.dll_GetConsoleOutputCP]
push ebx
lea edx, [ebp - 0x80c]
push edx
push dword [0x4206b0]
push eax
call fcn.004140b0
add esp, 0x10
push dword [ebp + 0xc]
call fcn.00413eb0
pop ecx
push 0
lea edx, [ebp - 0x810]
push edx
push ebx
lea edx, [ebp - 0x80c]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4136fb
mov eax, dword [ebp - 0x810]
add dword [ebp - 0xc], eax
cmp dword [ebp - 0x810], ebx
jb 0x413704
inc edi
cmp edi, esi
jb 0x413657
jmp 0x413704
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov ebx, dword [ebp - 8]
mov dword [eax], ecx
mov dword [eax + 4], ebx
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 4]
mov dword [eax + 8], edx
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x413730
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x814
push ebx
push esi
push edi
mov ebx, dword [ebp + 0xc]
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp + 0x10]
add edx, eax
mov dword [ebp - 0x814], edx
mov dword [ebp - 0xc], 0
mov dword [ebp - 8], 0
mov dword [ebp - 4], 0
mov eax, dword [ebp + 0x10]
mov esi, eax
cmp esi, dword [ebp - 0x814]
jae 0x41384d
lea eax, [ebp - 0xe]
lea edx, [ebp - 0x80c]
lea ecx, [ebp - 0x80c]
cmp eax, ecx
jbe 0x4137b2
cmp esi, dword [ebp - 0x814]
jae 0x4137b2
cmp word [esi], 0xa
jne 0x4137a0
add dword [ebp - 8], 2
mov word [edx], 0xd
add edx, 2
add edx, 2
add esi, 2
mov cx, word [esi - 2]
mov word [edx - 2], cx
cmp edx, eax
jb 0x413786
lea eax, [ebp - 0x80c]
mov edi, edx
sub edi, eax
push ebx
call fcn.00413f00
pop ecx
test eax, eax
je 0x413816
push ebx
call fcn.00413eb0
pop ecx
push 0
lea edx, [ebp - 0x810]
push edx
mov edx, edi
shr edx, 1
push edx
lea edx, [ebp - 0x80c]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteConsoleW]
test eax, eax
je 0x413844
shl dword [ebp - 0x810], 1
mov eax, dword [ebp - 0x810]
add dword [ebp - 0xc], eax
cmp dword [ebp - 0x810], edi
jb 0x41384d
add esi, 2
cmp esi, dword [ebp - 0x814]
jb 0x413773
jmp 0x41384d
push ebx
call fcn.00413eb0
pop ecx
push 0
lea edx, [ebp - 0x810]
push edx
push edi
lea edx, [ebp - 0x80c]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4137f4
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
jmp 0x41384d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov ebx, dword [ebp - 8]
mov dword [eax], ecx
mov dword [eax + 4], ebx
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 4]
mov dword [eax + 8], edx
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x413870
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc10
push ebx
push esi
push edi
mov eax, dword [ebp + 0x14]
mov edx, dword [ebp + 0x10]
add edx, eax
mov dword [ebp - 0xc0c], edx
mov eax, dword [ebp + 0x10]
mov ebx, eax
mov dword [ebp - 0xc08], 0
cmp ebx, dword [ebp - 0xc0c]
jae 0x41392c
lea eax, [ebp - 2]
lea edx, [ebp - 0x400]
lea ecx, [ebp - 0x400]
cmp eax, ecx
jbe 0x4138e0
cmp ebx, dword [ebp - 0xc0c]
jae 0x4138e0
cmp word [ebx], 0xa
jne 0x4138ce
mov word [edx], 0xd
add edx, 2
add edx, 2
add ebx, 2
mov cx, word [ebx - 2]
mov word [edx - 2], cx
cmp edx, eax
jb 0x4138b8
push 0
push 0
push 0x800
lea eax, [ebp - 0xc00]
push eax
lea eax, [ebp - 0x400]
sub edx, eax
sar edx, 1
push edx
lea eax, [ebp - 0x400]
push eax
push 0
push 0xfde9
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
je 0x413938
lea esi, [ebp + eax - 0xc00]
lea eax, [ebp - 0xc00]
cmp esi, eax
jbe 0x413997
lea edi, [ebp - 0xc00]
jmp 0x41396a
mov dword [ebp - 0xc10], 0
jmp 0x413944
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0xc10], eax
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0xc08]
mov dword [eax], edx
mov eax, dword [ebp + 8]
mov dword [eax + 4], 0
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0xc10]
mov dword [eax + 8], edx
mov eax, dword [ebp + 8]
jmp 0x4139da
push dword [ebp + 0xc]
call fcn.00413eb0
pop ecx
push 0
lea edx, [ebp - 0xc04]
push edx
mov edx, esi
sub edx, edi
push edx
push edi
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x4139b6
add edi, dword [ebp - 0xc04]
cmp edi, esi
jb 0x41396a
mov eax, ebx
sub eax, dword [ebp + 0x10]
mov dword [ebp - 0xc08], eax
add ebx, 2
cmp ebx, dword [ebp - 0xc0c]
jb 0x4138a5
jmp 0x41392c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [ebp + 8]
mov ecx, dword [ebp - 0xc08]
mov dword [edx], ecx
mov edx, dword [ebp + 8]
mov dword [edx + 4], 0
mov edx, dword [ebp + 8]
mov dword [edx + 8], eax
mov eax, dword [ebp + 8]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x414820
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
push edi
push 0x2000
call fcn.0040dad0
pop ecx
mov esi, eax
test esi, esi
je 0x414889
push 0x1000
push esi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov edi, eax
test edi, edi
je 0x41488d
cmp edi, 0x1000
ja 0x4148a5
mov ebx, 1
jmp 0x41485d
xor ebx, ebx
test ebx, ebx
je 0x41486d
push esi
push dword [ebp + 0xc]
call dword [0x4192bc]
jmp 0x41487b
push 0x415f18
push dword [ebp + 0xc]
call dword [0x4192bc]
push esi
call fcn.0040de80
pop ecx
test ebx, ebx
setne al
jmp 0x4148d0
xor al, al
jmp 0x4148d0
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xcb
jne 0x41485b
push esi
call fcn.0040de80
pop ecx
xor al, al
jmp 0x4148d0
lea eax, [edi + edi]
push eax
push esi
call fcn.0040e230
add esp, 8
mov esi, eax
test esi, esi
je 0x414889
push edi
push esi
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
jne 0x414854
push esi
call fcn.0040de80
pop ecx
xor al, al
pop edi
pop esi
pop ebx
pop ebp
ret 8
Function at 0x414de0
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x410
push esi
push edi
mov edx, dword [ebp + 8]
lea edi, [ebp - 0x208]
xor eax, eax
mov ecx, 0x208
rep stosb byte es:[edi], al
lea edi, [ebp - 0x410]
xor eax, eax
mov ecx, 0x208
rep stosb byte es:[edi], al
push edx
push 0x104
lea eax, [ebp - 0x410]
push eax
call fcn.0040ce70
add esp, 0xc
lea eax, [ebp - 0x410]
push eax
call fcn.00414cd0
push 0x5c
lea eax, [ebp - 0x410]
push eax
call fcn.0040e4c0
add esp, 8
mov esi, eax
xor edi, edi
jmp 0x414ecd
lea eax, [ebp - 0x410]
neg eax
add eax, esi
sar eax, 1
inc eax
push eax
lea eax, [ebp - 0x410]
push eax
push 0x104
lea eax, [ebp - 0x208]
push eax
call fcn.0040e4e0
add esp, 0x10
push 0
lea eax, [ebp - 0x208]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x414ea5
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
cmp edi, 0xb7
je 0x414ebd
push 0x5c
lea eax, [esi + 2]
push eax
call fcn.0040e4c0
add esp, 8
mov esi, eax
jmp 0x414ecd
cmp byte [0x41cfbc], 0
je 0x414ebd
lea eax, [ebp - 0x208]
push eax
push 1
call dword [0x4192c4]
push 0x5c
lea eax, [esi + 2]
push eax
call fcn.0040e4c0
add esp, 8
mov esi, eax
test esi, esi
jne 0x414e47
mov eax, edi
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4

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

Disassembly:
mov eax, dword [esp + 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x414eff
test eax, 0x10
je 0x414eff
mov eax, 1
ret 4
xor eax, eax
ret 4
Function at 0x410030
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebp
mov ebp, esp
push ebx
mov ebx, dword [ebp + 8]
push edi
mov edi, dword [ebp + 0xc]
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x41004b
pop edi
pop ebx
pop ebp
ret
push esi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x410082
push edi
push ebx
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ecx, dword [ebp + 0x10]
add eax, esi
and ecx, 0xf
jbe 0x41007e
jmp 0x410070
cmp esi, eax
jae 0x410082
dec ecx
movzx edx, word [esi]
lea esi, [esi + edx*2 + 2]
jne 0x410070
cmp esi, eax
jb 0x410089
pop esi
pop edi
xor eax, eax
pop ebx
pop ebp
ret
movzx eax, word [esi]
neg eax
sbb eax, eax
and eax, esi
pop esi
pop edi
pop ebx
pop ebp
ret

Function at 0x411080
Capabilities:
Get number of processors

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x553408
mov eax, dword fs:[0]
push eax
push ecx
push ebx
push esi
push edi
mov eax, dword [0x5ba318]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
call fcn.00410270
push 0x410170
push 0x410110
push 5
push 0x1fd0
lea eax, [esi + 0x48]
xor edi, edi
push eax
mov dword [ebp - 4], edi
mov dword [esi], vtable.CMMI_TrendItem.0
call fcn.0053abd1
fldz
fld dword [0x5679a0]
mov edx, 1
mov dword [esi + 0x20], edi
mov dword [esi + 0x24], edi
mov dword [esi + 0x28], edi
mov dword [esi + 0x2c], edi
mov dword [esi + 0x30], edi
mov dword [esi + 0x34], edx
mov dword [esi + 0x38], 0xa
mov dword [esi + 0x40], edi
mov dword [esi + 0x3c], 0x64
lea eax, [esi + 0x1fe0]
lea ecx, [edi + 5]
fxch st(1)
mov ebx, edx
fst dword [eax + 4]
mov dword [eax - 0x1f98], edi
fxch st(1)
mov dword [eax], edi
fst dword [eax + 8]
mov dword [eax + 0xc], 0xff
fxch st(1)
mov dword [eax + 0x10], edx
fst dword [eax + 0x14]
mov dword [eax + 0x1c], edi
fxch st(1)
mov dword [eax + 0x20], 0xffff
fst dword [eax + 0x18]
mov word [eax - 0x1f74], 0x301
mov word [eax - 0x1f72], bx
mov word [eax - 0x1f70], bx
add eax, 0x1fd0
sub ecx, edx
jne 0x41110e
fstp st(1)
mov dword [esi + 0x1c], edx
fstp st(0)
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret