joyce8/EMBER2024-capa huggingface dataset:
Function at 0x41e26b
Capabilities:
Get local ipv4 addresses

Disassembly:
push ebp
mov ebp, esp
push ecx
push ecx
push esi
mov esi, dword [ebp + 8]
test esi, esi
jne 0x41e27d
push 0x57
pop eax
jmp 0x41e2e7
and dword [ebp + 8], 0
push edi
mov edi, dword [sym.imp.ole32.dll_CoTaskMemFree]
mov dword [ebp - 4], 0x3a98
push dword [ebp - 4]
call dword [sym.imp.ole32.dll_CoTaskMemAlloc]
mov dword [esi], eax
test eax, eax
je 0x41e2c8
lea ecx, [ebp - 4]
push ecx
push eax
push 0
push 0x2a
push 2
call sub.IPHLPAPI.DLL_GetAdaptersAddresses
mov dword [ebp - 8], eax
cmp eax, 0x6f
jne 0x41e2d8
push dword [esi]
call edi
and dword [esi], 0
inc dword [ebp + 8]
cmp dword [ebp + 8], 3
jb 0x41e28f
jmp 0x41e2dc
push str.CEthernetHelper::GetAllMACs___Memory_allocation_failed_for_IP_ADAPTER_ADDRESSES_struct
call fcn.00402064
pop ecx
push 8
pop eax
jmp 0x41e2e6
test eax, eax
je 0x41e2e3
push dword [esi]
call edi
and dword [esi], 0
mov eax, dword [ebp - 8]
pop edi
pop esi
leave
ret 4

Function at 0x41e383
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
push esi
xor esi, esi
cmp dword [eax + 0x14], 0x10
push edi
jb 0x41e395
mov eax, dword [eax]
push esi
push 0x80
push 2
push esi
push esi
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x41e3db
mov eax, dword [ebp + 0xc]
cmp dword [eax + 0x14], 0x10
mov ecx, dword [eax + 0x10]
mov dword [ebp + 8], esi
jb 0x41e3c3
mov eax, dword [eax]
push esi
lea edx, [ebp + 8]
push edx
push ecx
push eax
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor esi, esi
inc esi
pop edi
mov eax, esi
pop esi
pop ebp
ret

Function at 0x41e3e1
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
push ebx
push esi
xor esi, esi
cmp dword [eax + 0x14], 0x10
jb 0x41e3f4
mov eax, dword [eax]
push esi
push 0x80
push 2
push esi
push esi
push 0x40000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
je 0x41e451
push edi
push esi
lea eax, [ebp - 4]
push eax
push 2
lea eax, [ebp + 8]
push eax
mov dword [ebp - 4], esi
mov esi, dword [sym.imp.KERNEL32.dll_WriteFile]
push ebx
mov word [ebp + 8], 0xfeff
call esi
mov edi, dword [ebp + 0xc]
push dword [edi]
call dword [sym.imp.OLEAUT32.dll_SysAllocStringByteLen]
push 0
lea ecx, [ebp - 4]
push ecx
push eax
push dword [edi]
push ebx
call esi
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor esi, esi
inc esi
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret
Function at 0x41e899
Capabilities:
Encode data using xor

Disassembly:
push 4
mov eax, 0x4395da
call fcn.0042206f
mov esi, ecx
and dword [ebp - 0x10], 0
and dword [ebp - 4], 0
lea eax, [ebp + 0x10]
push eax
push dword [ebp + 0xc]
call fcn.00414817
lea edi, [esi + 0x28]
push edi
mov dword [ebp - 0x10], edi
call fcn.0042270a
pop ecx
push dword [ebp + 0x14]
mov ecx, esi
movzx ebx, ax
call fcn.0041e85e
xor eax, eax
cmp ax, bx
jae 0x41e902
mov dword [ebp + 0xc], ebx
mov ax, word [edi]
xor ax, word [esi + 0x1ac8]
mov ecx, esi
movzx ebx, ax
push ebx
call fcn.0041e522
mov word [edi], bx
add edi, 2
dec dword [ebp + 0xc]
jne 0x41e8df
mov edi, dword [ebp - 0x10]
test edi, edi
jne 0x41e91e
mov esi, dword [ebp + 8]
and dword [esi], edi
push dword [ebp + 0x10]
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, esi
call fcn.00422147
ret 0x10
push edi
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov esi, dword [ebp + 8]
mov dword [esi], eax
test eax, eax
jne 0x41e90b
push 0x8007000e
call fcn.00401000
int3
Function at 0x41ecd3
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push 8
mov eax, 0x4396b0
call fcn.0042206f
push dword [ebp + 0xc]
movzx eax, word [ebp + 8]
push eax
push dword [0x44d428]
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov edi, eax
xor ebx, ebx
cmp edi, ebx
jne 0x41ed05
mov eax, 0x80004005
jmp 0x41ee22
push edi
push dword [0x44d428]
call dword [sym.imp.KERNEL32.dll_SizeofResource]
push edi
push dword [0x44d428]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_LoadResource]
push 0x17
push ebx
push 0x43b744
lea ecx, [ebp - 0x10]
mov edi, eax
mov dword [ebp - 0x10], ebx
call fcn.0040187a
cmp eax, ebx
jge 0x41ed47
cmp eax, 0x80004002
je 0x41ed47
push eax
call fcn.00420ef0
push ebx
push 0xffffffffffffffff
push 2
push ecx
mov ecx, esp
mov dword [ebp + 0xc], esp
push dword [ebp + 0x10]
mov dword [ebp - 4], ebx
call fcn.00401619
mov ecx, dword [ebp - 0x10]
mov byte [ebp - 4], 1
cmp ecx, ebx
jne 0x41ed6f
push 0x80004003
jmp 0x41ed42
lea eax, [ebp + 8]
push eax
mov byte [ebp - 4], bl
call fcn.00401f57
mov byte [ebp - 4], 2
cmp esi, ebx
jge 0x41ed8d
push 0x80070057
call fcn.00401000
jne 0x41ee2a
mov dword [ebp + 0xc], ebx
push esi
push dword [ebp + 0xc]
mov byte [ebp - 4], 3
push esi
push edi
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push ebx
push dword [ebp + 0xc]
lea ecx, [ebp + 0x10]
call fcn.0041ec2f
mov esi, dword [ebp + 0x10]
push ecx
mov eax, esp
mov dword [ebp - 0x14], esp
mov dword [eax], esi
cmp esi, ebx
je 0x41edcd
lea eax, [esi + 8]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedIncrement]
mov ecx, dword [ebp + 8]
mov byte [ebp - 4], 5
cmp ecx, ebx
je 0x41ed68
mov byte [ebp - 4], 4
call fcn.0041ec85
mov ecx, dword [ebp + 8]
cmp ecx, ebx
je 0x41ed68
call fcn.004011c4
cmp esi, ebx
je 0x41edf8
mov ecx, esi
call fcn.00401a46
push ebx
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov eax, dword [ebp + 8]
mov byte [ebp - 4], bl
cmp eax, ebx
je 0x41ee0f
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov eax, dword [ebp - 0x10]
or dword [ebp - 4], 0xffffffff
cmp eax, ebx
je 0x41ee20
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
xor eax, eax
call fcn.00422147
ret 0xc
push esi
push ebx
call dword [sym.imp.OLEAUT32.dll_SysReAllocStringLen]
mov dword [ebp + 0xc], eax
cmp eax, ebx
jne 0x41ed96
push 0x8007000e
jmp 0x41ed88
Function at 0x420723
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x118
mov eax, dword [0x44af80]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
mov dword [ebp - 0x110], eax
lea eax, [ebp - 0x10c]
push eax
push 0x20019
xor esi, esi
push esi
push 0x440918
push SysReAllocStringLen
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x4207f8
push edi
lea eax, [ebp - 0x118]
push eax
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x114]
push eax
push esi
push esi
push dword [ebp - 0x10c]
mov edi, 0x104
mov dword [ebp - 0x118], edi
mov dword [ebp - 0x114], 1
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x4207e7
cmp dword [ebp - 0x114], 2
mov byte [ebp - 5], al
lea eax, [ebp - 0x108]
jne 0x4207d1
push edi
push dword [ebp - 0x110]
push eax
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
dec eax
lea ecx, [edi - 1]
cmp ecx, eax
sbb esi, esi
inc esi
jmp 0x4207e7
push eax
push edi
push dword [ebp - 0x110]
call fcn.004206c0
xor ecx, ecx
test eax, eax
setge cl
mov esi, ecx
push dword [ebp - 0x10c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
pop edi
jmp 0x4207fa
xor eax, eax
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.00421c7c
leave
ret 4

Function at 0x420ad3
Capabilities:
Allocate or change rwx memory
Execute shellcode via indirect call

Disassembly:
cmp dword [0x44d458], 0
push esi
push edi
jne 0x420a49
call fcn.004209b5
test eax, eax
je 0x420a8e
mov eax, dword [0x44d458]
cmp eax, 1
jne 0x420a6a
push 0xd
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
test eax, eax
je 0x420a8e
jmp 0x420ad0
mov edi, dword [sym.imp.KERNEL32.dll_InterlockedPopEntrySList]
push eax
call edi
test eax, eax
jne 0x420ad0
push 0x40
mov eax, 0x1000
push eax
push eax
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov esi, eax
test esi, esi
jne 0x420a92
xor eax, eax
jmp 0x420ad0
mov eax, dword [esi]
push dword [0x44d458]
call edi
mov edi, eax
test edi, edi
je 0x420ab4
push 0x8000
push 0
push esi
call dword [sym.imp.KERNEL32.dll_VirtualFree]
mov eax, edi
jmp 0x420ad0
lea edi, [esi + 0xff0]
push esi
push dword [0x44d458]
call dword [sym.imp.KERNEL32.dll_InterlockedPushEntrySList]
add esi, 0x10
cmp esi, edi
jb 0x420aba
mov eax, esi
pop edi
pop esi
ret
jmp 0x420a35

Function at 0x421c7c
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x44af80]
jne 0x421c86
repz ret
jmp fcn.00426e6c
Function at 0x43059d
Capabilities:
Link many functions at runtime

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x44af80]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x1c], eax
call fcn.004257ee
and dword [ebp - 0x14], 0
cmp dword [0x44e220], 0
mov dword [ebp - 0x18], eax
jne 0x430650
push str.USER32.DLL
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
test ebx, ebx
je 0x4306f8
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.MessageBoxW
push ebx
call edi
test eax, eax
je 0x4306f8
mov esi, dword [sym.imp.KERNEL32.dll_EncodePointer]
push eax
call esi
push 0x442a1c
push ebx
mov dword [0x44e220], eax
call edi
push eax
call esi
push str.GetLastActivePopup
push ebx
mov dword [0x44e224], eax
call edi
push eax
call esi
push str.GetUserObjectInformationW
push ebx
mov dword [0x44e228], eax
call edi
push eax
call esi
mov dword [0x44e230], eax
test eax, eax
je 0x430650
push str.GetProcessWindowStation
push ebx
call edi
push eax
call esi
mov dword [0x44e22c], eax
mov eax, dword [0x44e22c]
mov ecx, dword [ebp - 0x18]
mov esi, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, ecx
je 0x4306a9
cmp dword [0x44e230], ecx
je 0x4306a9
push eax
call esi
push dword [0x44e230]
mov edi, eax
call esi
mov ebx, eax
test edi, edi
je 0x4306a9
test ebx, ebx
je 0x4306a9
call edi
test eax, eax
je 0x4306a0
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call ebx
test eax, eax
je 0x4306a0
test byte [ebp - 8], 1
jne 0x4306a9
or dword [ebp + 0x10], 0x200000
jmp 0x4306dc
mov eax, dword [0x44e224]
cmp eax, dword [ebp - 0x18]
je 0x4306dc
push eax
call esi
test eax, eax
je 0x4306dc
call eax
mov dword [ebp - 0x14], eax
test eax, eax
je 0x4306dc
mov eax, dword [0x44e228]
cmp eax, dword [ebp - 0x18]
je 0x4306dc
push eax
call esi
test eax, eax
je 0x4306dc
push dword [ebp - 0x14]
call eax
mov dword [ebp - 0x14], eax
push dword [0x44e220]
call esi
test eax, eax
je 0x4306f8
push dword [ebp + 0x10]
push dword [ebp - 0x1c]
push dword [ebp - 0x20]
push dword [ebp - 0x14]
call eax
jmp 0x4306fa
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00421c7c
leave
ret
Function at 0x405df8
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
cmp dword [0x422adc], 0
push esi
jne 0x405e2f
xor ecx, ecx
push 8
mov eax, ecx
pop esi
mov edx, eax
and dl, 1
neg dl
sbb edx, edx
and edx, 0xedb88320
shr eax, 1
xor eax, edx
dec esi
jne 0x405e09
mov dword [ecx*4 + 0x422ad8], eax
inc ecx
cmp ecx, 0x100
jl 0x405e04
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 8]
test edx, edx
not eax
jbe 0x405e60
mov ecx, dword [esp + 0xc]
push edi
movzx edi, byte [ecx]
mov esi, eax
and esi, 0xff
xor esi, edi
shr eax, 8
mov esi, dword [esi*4 + 0x422ad8]
xor eax, esi
inc ecx
dec edx
jne 0x405e42
pop edi
not eax
pop esi
ret 0xc

Function at 0x438860
Capabilities:
Packed with generic packer

Disassembly:
pushal
mov esi, section.UPX1
lea edi, [esi - 0x22000]
push edi
or ebp, 0xffffffff
jmp 0x438882
mov al, byte [esi]
inc esi
mov byte [edi], al
inc edi
add ebx, ebx
jne 0x438889
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jb 0x438878
mov eax, 1
add ebx, ebx
jne 0x43889b
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc eax, eax
add ebx, ebx
jae 0x438890
jne 0x4388ac
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x438890
xor ecx, ecx
sub eax, 3
jb 0x4388c0
shl eax, 8
mov al, byte [esi]
inc esi
xor eax, 0xffffffff
je 0x438932
mov ebp, eax
add ebx, ebx
jne 0x4388cb
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jne 0x4388d8
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
jne 0x4388fc
inc ecx
add ebx, ebx
jne 0x4388e8
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
adc ecx, ecx
add ebx, ebx
jae 0x4388dd
jne 0x4388f9
mov ebx, dword [esi]
sub esi, 0xfffffffc
adc ebx, ebx
jae 0x4388dd
add ecx, 2
cmp ebp, 0xfffff300
adc ecx, 1
lea edx, [edi + ebp]
cmp ebp, 0xfffffffc
jbe 0x43891c
mov al, byte [edx]
inc edx
mov byte [edi], al
inc edi
dec ecx
jne 0x43890d
jmp 0x43887e
mov eax, dword [edx]
add edx, 4
mov dword [edi], eax
add edi, 4
sub ecx, 4
ja 0x43891c
add edi, ecx
jmp 0x43887e
pop esi
mov edi, esi
mov ecx, 0xe0e
mov al, byte [edi]
inc edi
sub al, 0xe8
cmp al, 1
ja 0x43893a
cmp byte [edi], 0xa
jne 0x43893a
mov eax, dword [edi]
mov bl, byte [edi + 4]
shr ax, 8
rol eax, 0x10
xchg ah, al
sub eax, edi
sub bl, 0xe8
add eax, esi
mov dword [edi], eax
add edi, 5
mov eax, ebx
loop 0x43893f
lea edi, [esi + 0x36000]
mov eax, dword [edi]
or eax, eax
je 0x4389b7
mov ebx, dword [edi + 4]
lea eax, [eax + esi + 0x3820c]
add ebx, esi
push eax
add edi, 8
call dword [esi + 0x382ac]
xchg ebp, eax
mov al, byte [edi]
inc edi
or al, al
je 0x43896c
mov ecx, edi
jns 0x43899b
movzx eax, word [edi]
inc edi
push eax
inc edi
mov ecx, 0xaef24857
push edi
dec eax
repne scasb al, byte es:[edi]
push ebp
call dword [esi + 0x382b0]
or eax, eax
je 0x4389b1
mov dword [ebx], eax
add ebx, 4
jmp 0x438989
call dword [esi + 0x382b4]
popal
jmp 0x41be59
Function at 0x401dc0
Capabilities:
Access peb ldr_data
Check mutex on windows
Create thread
Get file size
Query environment variable
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x81c
mov eax, dword [0x405018]
xor eax, esp
mov dword [esp + 0x818], eax
mov eax, dword [ebp + 0x10]
push ebx
push esi
push edi
mov dword [esp + 0xc], eax
mov eax, dword fs:[0x30]
push 0xf0000000
mov eax, dword [eax + 0xc]
push 1
mov eax, dword [eax + 0x14]
push 0
mov eax, dword [eax + 0x20]
push 0
push 0x405438
mov dword [0x405434], eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
jne 0x401e2c
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x818]
xor ecx, esp
call fcn.0040237d
mov esp, ebp
pop ebp
ret 0x10
push 0
push 0
push 3
push 0
push 1
push 0x80000000
push dword [0x405434]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x401e89
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
push edi
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov ebx, eax
test ebx, ebx
je 0x401e89
push 0
lea eax, [esp + 0x20]
push eax
push edi
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x401e89
push dword [esp + 0xc]
mov edx, edi
mov ecx, ebx
call fcn.00401530
push str.Global3pc6RWOgectGTFqCowxjeGy3XIGPtLwNrsr2zDctYD4hAU5pj4GW7rm8gHrHyTB6
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x401ebe
mov ecx, dword [esp + 0x824]
pop edi
pop esi
pop ebx
xor ecx, esp
xor eax, eax
call fcn.0040237d
mov esp, ebp
pop ebp
ret 0x10
mov esi, dword [sym.imp.KERNEL32.dll_CreateThread]
push 0
push 0
push 0
push 0x401d80
push 0
push 0
call esi
push 0
push 0
push 0
push 0x401cd0
push 0
push 0
call esi
push 0
push 0
push 0
push 0x401bb0
push 0
push 0
call esi
push 0x400
lea eax, [esp + 0x24]
push eax
push str.userprofile
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov esi, dword [sym.imp.ntdll.dll_NtDelayExecution]
mov dword [esp + 0x10], 0x4d2fa200
mov dword [esp + 0x14], 0xffffffff
lea ecx, [esp + 0x20]
call fcn.00401a90
lea eax, [esp + 0x10]
push eax
push 0
call esi
jmp 0x401f22

Function at 0x431000
Capabilities:
Encode data using xor
Packed with generic packer

Disassembly:
pushal
nop
nop
nop
nop
nop
mov eax, section..text
nop
mov ebx, 0x40915c
nop
nop
mov ecx, 0x7a50280b
nop
test eax, eax
nop
nop
nop
nop
nop
je 0x43104e
nop
nop
nop
xor dword [eax], ecx
nop
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
inc eax
nop
nop
nop
inc eax
nop
nop
nop
nop
nop
nop
nop
inc eax
nop
cmp eax, ebx
nop
nop
nop
nop
nop
jne 0x431024
nop
nop
nop
mov eax, section..data
mov ebx, 0x42f3f8
nop
mov ecx, 0x65a251e6
nop
nop
test eax, eax
nop
nop
nop
je 0x431084
nop
nop
nop
nop
nop
nop
nop
xor dword [eax], ecx
nop
nop
add eax, 4
nop
nop
nop
nop
nop
nop
cmp eax, ebx
nop
nop
jne 0x43106c
nop
nop
nop
nop
popal
nop
nop
nop
jmp 0x401219
Function at 0x401c57
Capabilities:
Check os version
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2d4
mov eax, dword [0xa390c0]
xor eax, ebp
mov dword [ebp - 4], eax
call dword [sym.imp.KERNEL32.dll_GetVersion]
cmp ax, 6
je 0x401ca0
push str.SetDefaultDllDirectories
push 0xa07570
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x401ca0
push 0xc00
call eax
test eax, eax
jne 0x401d3c
push 0x106
lea eax, [ebp - 0x2d4]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x401d3c
cmp eax, 0x104
ja 0x401d3c
push 0x5c
pop ecx
cmp word [ebp + eax*2 - 0x2d6], cx
je 0x401cd7
mov word [ebp + eax*2 - 0x2d4], cx
inc eax
mov cl, byte [str.userenv]
push esi
mov esi, str.userenv
test cl, cl
je 0x401d3b
push ebx
push edi
lea edi, [ebp - 0x2d4]
push 0x6c
lea edi, [edi + eax*2]
pop ebx
mov edx, edi
inc esi
movzx eax, cl
mov cl, byte [esi]
inc esi
mov word [edx], ax
lea edx, [edx + 2]
test cl, cl
jne 0x401cf8
push 0x2e
pop eax
push 0x64
mov word [edx], ax
pop eax
mov word [edx + 2], ax
xor eax, eax
push 8
push eax
mov word [edx + 8], ax
lea eax, [ebp - 0x2d4]
push eax
mov word [edx + 4], bx
mov word [edx + 6], bx
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov cl, byte [esi]
test cl, cl
jne 0x401cf5
pop edi
pop ebx
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0098c9a8
leave
ret
Function at 0x4053f0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
push ecx
xor edx, edx
xor eax, eax
push ebx
push esi
mov esi, dword [ebp + 8]
inc eax
push edi
push 0x20
pop ecx
or dword [esi + 0x90], 0xffffffff
lea ebx, [esi + 0xc8]
or dword [esi + 0x94], 0xffffffff
mov dword [esi + 0x30], eax
mov dword [esi + 0x44], eax
mov eax, dword [esi + 4]
cmp eax, ecx
mov dword [esi + 0x78], edx
cmova eax, ecx
mov dword [esi + 0x7c], edx
mov dword [esi + 0x54], eax
mov eax, dword [esi]
mov dword [esi + 0x34], edx
mov dword [esi + 0x38], edx
mov dword [esi + 0x3c], edx
mov dword [esi + 0x40], edx
mov dword [esi + 0x70], edx
mov dword [esi + 0x88], edx
mov dword [esi + 0x68], edx
mov dword [esi + 0x6c], edx
mov dword [esi + 0x48], edx
mov dword [esi + 0x4c], edx
mov dword [esi + 0x50], edx
mov dword [esi + 0x60], edx
mov dword [esi + 0x64], edx
mov dword [esi + 0x80], edx
mov dword [esi + 0x84], edx
mov dword [esi + 0x58], edx
cmp eax, dword [esi + 0x20]
je 0x4054a8
mov edi, ebx
mov dword [ebp - 4], ecx
mov eax, ecx
cmp dword [edi + 8], edx
je 0x405484
push edi
call fcn.004053c5
mov eax, dword [ebp - 4]
xor edx, edx
add edi, 0x28
sub eax, 1
mov dword [ebp - 4], eax
jne 0x405474
cmp dword [esi + 0x5c], 0
je 0x4054a3
mov eax, dword [esi + 0x14]
push dword [esi + 0x5c]
push eax
call dword [eax + 4]
and dword [esi + 0x5c], 0
mov eax, dword [esi]
mov dword [esi + 0x20], eax
push dword [esi + 0x10]
lea eax, [esi + 0x98]
push eax
call fcn.0040639a
mov ecx, dword [esi + 0x58]
and dword [esi + 0x24], 0
and dword [esi + 0x28], 0
lea eax, [ecx + 5]
imul edx, eax, 0x28
lea eax, [ecx + 1]
mov dword [esi + 0x58], eax
add edx, esi
push edx
mov dword [ebp - 4], edx
call fcn.0040539f
mov edi, eax
test edi, edi
jne 0x405529
mov eax, dword [ebp - 4]
add eax, 0x20
push eax
call fcn.0040652c
mov edi, eax
test edi, edi
jne 0x405529
mov eax, dword [ebp - 4]
add eax, 0x1c
push eax
call fcn.0040652c
mov edi, eax
test edi, edi
jne 0x405529
push dword [ebp - 4]
call fcn.00406311
mov edi, eax
test edi, edi
je 0x405529
and dword [esi + 0x44], 0
push 0x20
pop esi
push ebx
call fcn.00405321
add ebx, 0x28
sub esi, 1
jne 0x405518
mov esi, dword [ebp + 8]
movzx eax, di
or eax, 0x80070000
test edi, edi
cmovle eax, edi
test eax, eax
je 0x40553d
mov dword [esi + 0x40], eax
xor edx, edx
cmp dword [esi + 0x38], edx
jne 0x405551
cmp dword [esi + 0x40], edx
jne 0x405551
cmp dword [esi + 0x3c], edx
jne 0x405551
mov dword [esi + 0x44], edx
xor ecx, ecx
cmp dword [esi + 0x44], edx
pop edi
pop esi
cmovne eax, ecx
pop ebx
leave
ret 4

Function at 0x406639
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
lea eax, [ebp - 4]
xor esi, esi
push eax
push esi
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push esi
push esi
call fcn.009e515b
mov ecx, dword [ebp + 8]
add esp, 0x18
mov dword [ecx], eax
test eax, eax
jne 0x406665
call fcn.0040654b
mov esi, eax
mov eax, esi
pop esi
leave
ret 0xc
Function at 0x408108
Capabilities:
Create directory

Disassembly:
push 0x44
mov eax, 0xa03adb
call fcn.0098cc5a
cmp byte [0xa3af54], 0
mov edi, dword [ebp + 8]
jne 0x408155
push edi
lea eax, [ebp - 0x18]
push eax
call fcn.004076e2
xor ebx, ebx
push ebx
push dword [eax]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push dword [ebp - 0x18]
mov esi, eax
call fcn.0098cc24
pop ecx
test esi, esi
jne 0x408163
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x408167
xor al, al
jmp 0x40819c
xor ebx, ebx
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
je 0x408144
mov al, 1
jmp 0x40819c
lea ecx, [ebp - 0x50]
call fcn.0040898f
lea ecx, [ebp - 0x28]
call fcn.00406b2f
push ebx
push edi
lea ecx, [ebp - 0x50]
mov dword [ebp - 4], ebx
call fcn.00408b57
test al, al
je 0x408191
mov ebx, dword [ebp - 0x30]
shr ebx, 4
and bl, 1
push dword [ebp - 0x28]
call fcn.0098cc24
pop ecx
mov al, bl
call fcn.0098cc37
ret 4

Function at 0x4081a4
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp byte [0xa3af54], 0
jne 0x4081e2
push esi
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
call fcn.004076e2
push 0
push dword [eax]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0098cc24
pop ecx
test esi, esi
pop esi
jne 0x4081de
xor al, al
jmp 0x4081f2
mov al, 1
jmp 0x4081f2
push 0
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
setne al
leave
ret 4

Function at 0x408368
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push esi
mov esi, dword [ebp + 8]
push esi
call fcn.00409168
cmp eax, 0xffffffff
je 0x408395
mov ecx, eax
and cl, 0x11
cmp cl, 1
jne 0x408395
and eax, 0xfffffffe
push eax
push esi
call fcn.004088fe
test al, al
je 0x4083bf
cmp byte [0xa3af54], 0
push esi
jne 0x4083c7
lea eax, [ebp - 0xc]
push eax
call fcn.004076e2
push dword [eax]
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0098cc24
pop ecx
test esi, esi
jne 0x4083c3
xor al, al
jmp 0x4083d2
mov al, 1
jmp 0x4083d2
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
setne al
pop esi
leave
ret 4

Function at 0x408646
Capabilities:
Delete directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
cmp byte [0xa3af54], 0
jne 0x408682
push esi
push dword [ebp + 8]
lea eax, [ebp - 0xc]
push eax
call fcn.004076e2
push dword [eax]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryA]
push dword [ebp - 0xc]
mov esi, eax
call fcn.0098cc24
pop ecx
test esi, esi
pop esi
jne 0x40867e
xor al, al
jmp 0x408690
mov al, 1
jmp 0x408690
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
test eax, eax
setne al
leave
ret 4