joyce8/EMBER2024-capa huggingface dataset:
Function at 0x491c00
Capabilities:
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
test edx, edx
jne 0x491c0b
xor eax, eax
pop ebp
ret
pop ebp
jmp fcn.00491c20
Function at 0x402844
Capabilities:
Generate random numbers using the delphi lcg

Disassembly:
push ebx
xor ebx, ebx
imul edx, dword [ebx + 0x40e008], 0x8088405
inc edx
mov dword [ebx + 0x40e008], edx
mul edx
mov eax, edx
pop ebx
ret

Function at 0x402c6c
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
movzx eax, word [0x40e018]
mov dword [ebp - 8], eax
lea eax, [ebp - 4]
push eax
push 1
push 0
push 0x402d04
push 0x80000002
call sub.advapi32.dll_RegOpenKeyExA
test eax, eax
jne 0x402ce4
xor eax, eax
push ebp
push 0x402cdd
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 0xc], 4
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
push 0
push 0
push 0x402d20
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegQueryValueExA
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x402ce4
mov eax, dword [ebp - 4]
push eax
call sub.advapi32.dll_RegCloseKey
ret
mov ax, word [0x40e018]
and ax, 0xffc0
mov dx, word [ebp - 8]
and dx, 0x3f
or ax, dx
mov word [0x40e018], ax
mov esp, ebp
pop ebp
ret

Function at 0x40376c
Capabilities:
Write file on windows

Disassembly:
push ecx
cmp byte [0x40f044], 0
je 0x4037cd
cmp word [0x40f218], 0xd7b2
jne 0x403795
cmp dword [0x40f220], 0
jbe 0x403795
mov eax, 0x40f214
call dword [0x40f230]
push 0
lea eax, [esp + 4]
push eax
push 0x1e
push 0x40e060
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
push 0
lea eax, [esp + 4]
push eax
push 2
push 0x4037f4
push 0xfffffffffffffff5
call sub.kernel32.dll_GetStdHandle
push eax
call sub.kernel32.dll_WriteFile
pop edx
ret
cmp byte [0x40e024], 0
jne 0x4037e9
push 0
push 0x40e058
push 0x40e060
push 0
call sub.user32.dll_MessageBoxA
pop edx
ret
Function at 0x4045f0
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
push ebx
xor edx, edx
mov dword [ebp - 0x10], edx
xor edx, edx
push ebp
push 0x404656
push dword fs:[edx]
mov dword fs:[edx], esp
push 7
lea edx, [ebp - 0xb]
push edx
push 0x1004
push eax
call sub.kernel32.dll_GetLocaleInfoA
lea eax, [ebp - 0x10]
lea edx, [ebp - 0xb]
mov ecx, 7
call fcn.00403b3c
mov eax, dword [ebp - 0x10]
lea edx, [ebp - 4]
call fcn.00402860
mov ebx, eax
cmp dword [ebp - 4], 0
je 0x404640
xor ebx, ebx
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40465d
lea eax, [ebp - 0x10]
call fcn.004038e8
ret

Function at 0x404bd0
Capabilities:
Get common file path

Disassembly:
push ebx
add esp, 0xfffffefc
mov ebx, eax
push 0x104
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetSystemDirectoryA
mov edx, ebx
mov eax, esp
call fcn.00404bbc
add esp, 0x104
pop ebx
ret

Function at 0x406c34
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff00
push ebx
push esi
mov esi, ecx
mov ebx, dword [ebp + 8]
push pe_nt_image_headers32
lea ecx, [ebp - 0x100]
push ecx
push edx
push eax
call sub.kernel32.dll_GetLocaleInfoA_1
test eax, eax
jle 0x406c6d
mov ecx, eax
dec ecx
lea edx, [ebp - 0x100]
mov eax, ebx
call fcn.004039d8
jmp 0x406c76
mov eax, ebx
mov edx, esi
call fcn.0040393c
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x406c80
Capabilities:
Get geographical location

Disassembly:
push ebx
push esi
push edi
push ecx
mov ebx, ecx
mov esi, edx
mov edi, eax
push 2
lea eax, [esp + 4]
push eax
push esi
push edi
call sub.kernel32.dll_GetLocaleInfoA_1
test eax, eax
jle 0x406ca1
mov al, byte [esp]
jmp 0x406ca3
mov eax, ebx
pop edx
pop edi
pop esi
pop ebx
ret

Function at 0x407dc8
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff4
push ebx
xor edx, edx
mov dword [ebp - 0xc], edx
xor edx, edx
push ebp
push 0x407e2c
push dword fs:[edx]
mov dword fs:[edx], esp
push 7
lea edx, [ebp - 7]
push edx
push 0x1004
push eax
call sub.kernel32.dll_GetLocaleInfoA_1
lea eax, [ebp - 0xc]
lea edx, [ebp - 7]
mov ecx, 7
call fcn.00403b3c
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_GetACP
mov edx, eax
pop eax
call fcn.00405fe8
mov ebx, eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x407e33
lea eax, [ebp - 0xc]
call fcn.004038e8
ret

Function at 0x408dc8
Capabilities:
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push 0
push ebx
mov ebx, eax
xor eax, eax
push ebp
push 0x408e0e
push dword fs:[eax]
mov dword fs:[eax], esp
lea edx, [ebp - 4]
mov eax, ebx
call fcn.00408d2c
mov eax, dword [ebp - 4]
call fcn.00403cc4
push eax
call sub.kernel32.dll_GetFileAttributesA
mov ebx, eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x408e15
lea eax, [ebp - 4]
call fcn.004038e8
ret
Function at 0x40900c
Capabilities:
Accept command line arguments

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffef8
push ebx
push esi
xor ecx, ecx
mov dword [ebp - 4], ecx
mov esi, edx
mov ebx, eax
xor eax, eax
push ebp
push 0x409099
push dword fs:[eax]
mov dword fs:[eax], esp
test ebx, ebx
jne 0x409056
push 0x104
lea eax, [ebp - 0x108]
push eax
push 0
call sub.kernel32.dll_GetModuleFileNameA_1
mov ecx, eax
lea edx, [ebp - 0x108]
mov eax, esi
call fcn.004039d8
jmp 0x409083
call sub.kernel32.dll_GetCommandLineA_1
cmp byte [eax], 0
jne 0x40906a
lea eax, [ebp - 4]
call fcn.004038e8
jmp 0x409079
lea edx, [ebp - 4]
call fcn.00408ed8
test ebx, ebx
je 0x409079
dec ebx
jmp 0x40905b
mov eax, esi
mov edx, dword [ebp - 4]
call fcn.0040393c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4090a0
lea eax, [ebp - 4]
call fcn.004038e8
ret

Function at 0x4090a8
Capabilities:
Get common file path

Disassembly:
push ebx
add esp, 0xfffffefc
mov ebx, eax
push 0x104
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetWindowsDirectoryA
mov edx, ebx
mov eax, esp
call fcn.004061c8
add esp, 0x104
pop ebx
ret

Function at 0x4090d4
Capabilities:
Get common file path

Disassembly:
push ebx
add esp, 0xfffffefc
mov ebx, eax
push 0x104
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetSystemDirectoryA
mov edx, ebx
mov eax, esp
call fcn.004061c8
add esp, 0x104
pop ebx
ret
Function at 0x409218
Capabilities:
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 8], ecx
mov dword [ebp - 4], edx
mov edi, eax
xor eax, eax
push ebp
push 0x40934c
push dword fs:[eax]
mov dword fs:[eax], esp
xor ebx, ebx
xor eax, eax
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x10]
push eax
push 0
lea eax, [ebp - 0xc]
push eax
push 0
mov eax, dword [ebp - 4]
push eax
push edi
call sub.advapi32.dll_RegQueryValueExA_1
test eax, eax
jne 0x409336
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp + 0xc]
je 0x409275
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp + 8]
jne 0x409336
cmp dword [ebp - 0x10], 0
jne 0x40928a
mov eax, dword [ebp - 8]
call fcn.004038e8
mov bl, 1
jmp 0x409336
cmp dword [ebp - 0x10], 0x70000000
jb 0x409298
call fcn.00407414
mov esi, dword [ebp - 0x10]
shr esi, 0
lea eax, [ebp - 0x14]
mov ecx, esi
xor edx, edx
call fcn.004039d8
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 0x14]
call fcn.00403d14
push eax
lea eax, [ebp - 0xc]
push eax
push 0
mov eax, dword [ebp - 4]
push eax
push edi
call sub.advapi32.dll_RegQueryValueExA_1
cmp eax, 0xea
je 0x40923e
test eax, eax
jne 0x409336
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp + 0xc]
je 0x4092e6
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp + 8]
jne 0x409336
mov esi, dword [ebp - 0x10]
shr esi, 0
jmp 0x4092ef
dec esi
test esi, esi
je 0x4092fd
mov eax, dword [ebp - 0x14]
cmp byte [eax + esi - 1], 0
je 0x4092ee
cmp dword [ebp - 0xc], 7
jne 0x409308
test esi, esi
je 0x409308
inc esi
lea eax, [ebp - 0x14]
mov edx, esi
call fcn.00403db8
cmp dword [ebp - 0xc], 7
jne 0x409329
test esi, esi
je 0x409329
lea eax, [ebp - 0x14]
call fcn.00403d14
mov byte [eax + esi - 1], 0
mov eax, dword [ebp - 8]
mov edx, dword [ebp - 0x14]
call fcn.0040393c
mov bl, 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x409353
lea eax, [ebp - 0x14]
call fcn.004038e8
ret

Function at 0x409cf8
Capabilities:
Hash data with crc32

Disassembly:
push esi
xor esi, esi
mov ecx, 0x40f7c0
mov eax, esi
mov edx, 8
test al, 1
je 0x409d14
shr eax, 1
xor eax, 0xedb88320
jmp 0x409d16
shr eax, 1
dec edx
jne 0x409d07
mov dword [ecx], eax
inc esi
add ecx, 4
cmp esi, 0x100
jne 0x409d00
pop esi
ret

Function at 0x409d2c
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
push edi
mov esi, ecx
mov edi, edx
mov ebx, eax
cmp dword [0x40f7bc], 0
jne 0x409d4f
call fcn.00409cf8
push 1
push 0x40f7bc
call sub.kernel32.dll_InterlockedExchange
mov eax, edi
test esi, esi
je 0x409d7b
mov edx, ebx
and edx, 0xff
xor ecx, ecx
mov cl, byte [eax]
xor dx, cx
movzx edx, dx
mov edx, dword [edx*4 + 0x40f7c0]
shr ebx, 8
xor edx, ebx
mov ebx, edx
dec esi
inc eax
test esi, esi
jne 0x409d55
mov eax, ebx
pop edi
pop esi
pop ebx
ret
Function at 0x40b800
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
push ebx
push esi
mov esi, edx
mov ebx, eax
lea edx, [ebp - 0xc]
mov eax, ebx
call fcn.0040b7b4
test al, al
jne 0x40b821
xor eax, eax
mov dword [ebp - 4], eax
jmp 0x40b86d
xor eax, eax
push ebp
push 0x40b85d
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, esi
call fcn.00403cc4
push eax
call sub.kernel32.dll_DeleteFileA
mov dword [ebp - 4], eax
call sub.kernel32.dll_GetLastError
mov dword [ebp - 0x10], eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40b864
lea eax, [ebp - 0xc]
call fcn.0040b7f0
ret
mov eax, dword [ebp - 4]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x40bbd8
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
mov ecx, 4
push 0
push 0
dec ecx
jne 0x40bbe0
push ecx
push ebx
push esi
mov esi, eax
xor eax, eax
push ebp
push 0x40bccd
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 8]
call fcn.00409100
mov edx, dword [ebp - 8]
mov ecx, 0x40bce4
xor eax, eax
call fcn.0040bac8
push 0
mov eax, dword [ebp - 4]
call fcn.00403cc4
push eax
call sub.kernel32.dll_CreateDirectoryA
test eax, eax
jne 0x40bc9b
call sub.kernel32.dll_GetLastError
mov ebx, eax
cmp ebx, 0xb7
je 0x40bbfa
lea eax, [ebp - 0xc]
push eax
lea ecx, [ebp - 0x1c]
mov edx, dword [ebp - 4]
mov al, 0x36
call fcn.0040b538
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x18], eax
mov eax, ebx
xor edx, edx
push edx
push eax
lea eax, [ebp - 0x20]
call fcn.00405fc0
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x14], eax
lea edx, [ebp - 0x24]
mov eax, ebx
call fcn.004095e8
mov eax, dword [ebp - 0x24]
mov dword [ebp - 0x10], eax
lea edx, [ebp - 0x18]
mov ecx, 2
mov al, 0x68
call fcn.0040b508
mov ecx, dword [ebp - 0xc]
mov dl, 1
mov eax, dword [0x4053c8]
call fcn.00407420
call fcn.00403348
jmp 0x40bbfa
mov eax, esi
mov edx, dword [ebp - 4]
call fcn.0040393c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40bcd4
lea eax, [ebp - 0x24]
mov edx, 3
call fcn.0040390c
lea eax, [ebp - 0xc]
mov edx, 3
call fcn.0040390c
ret

Function at 0x40bcf4
Capabilities:
Shutdown system

Disassembly:
add esp, 0xffffffec
mov eax, dword [0x40e504]
cmp dword [eax], 2
jne 0x40bd5c
push esp
push 0x28
call sub.kernel32.dll_GetCurrentProcess
push eax
call sub.advapi32.dll_OpenProcessToken
test eax, eax
jne 0x40bd17
xor eax, eax
jmp 0x40bd6b
lea eax, [esp + 8]
push eax
push 0x40bd70
push 0
call sub.advapi32.dll_LookupPrivilegeValueA
mov dword [esp + 4], 1
mov dword [esp + 0x10], 2
push 0
push 0
push 0
lea eax, [esp + 0x10]
push eax
push 0
mov eax, dword [esp + 0x14]
push eax
call sub.advapi32.dll_AdjustTokenPrivileges
call sub.kernel32.dll_GetLastError
test eax, eax
je 0x40bd5c
xor eax, eax
jmp 0x40bd6b
push 0
push 2
call sub.user32.dll_ExitWindowsEx
cmp eax, 1
sbb eax, eax
inc eax
add esp, 0x14
ret
Function at 0x40bd84
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov dword [ebp - 4], edx
mov ebx, eax
mov esi, ecx
dec esi
test esi, esi
jl 0x40bdde
inc esi
xor edi, edi
cmp edi, 1
jne 0x40bdaa
mov eax, dword [ebp + 0xc]
push eax
call sub.kernel32.dll_Sleep
jmp 0x40bdb8
cmp edi, 1
jle 0x40bdb8
mov eax, dword [ebp + 8]
push eax
call sub.kernel32.dll_Sleep
mov edx, dword [ebp - 4]
mov eax, ebx
call fcn.0040b800
test eax, eax
jne 0x40bdde
call sub.kernel32.dll_GetLastError
cmp eax, 2
je 0x40bdde
call sub.kernel32.dll_GetLastError
cmp eax, 3
je 0x40bdde
inc edi
dec esi
jne 0x40bd9a
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret 8

Function at 0x40bde8
Capabilities:
Identify system language via api

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff8
push ebx
push esi
push edi
mov edi, ecx
mov byte [ebp - 1], dl
mov esi, eax
mov eax, dword [ebp + 8]
xor edx, edx
mov dword [eax], edx
mov byte [ebp - 2], 0
test edi, edi
je 0x40be35
xor ebx, ebx
jmp 0x40be2a
mov eax, dword [ebp - 8]
mov edx, dword [eax]
mov eax, edi
call fcn.00405e54
test eax, eax
jne 0x40be29
mov eax, dword [ebp + 8]
mov dword [eax], ebx
mov byte [ebp - 2], 2
jmp 0x40bee5
inc ebx
lea edx, [ebp - 8]
mov eax, ebx
call esi
test al, al
jne 0x40be0b
mov al, byte [ebp - 1]
sub al, 1
jb 0x40be40
je 0x40be49
jmp 0x40be52
call fcn.00409394
mov edi, eax
jmp 0x40be54
call sub.kernel32.dll_GetUserDefaultLangID
mov edi, eax
jmp 0x40be54
xor edi, edi
test di, di
je 0x40bee5
xor ebx, ebx
jmp 0x40be90
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x28]
movzx edx, di
cmp eax, edx
jne 0x40be8f
mov eax, dword [ebp - 8]
cmp dword [eax + 0x2c], 0
je 0x40be84
call sub.kernel32.dll_GetACP
mov edx, dword [ebp - 8]
cmp eax, dword [edx + 0x2c]
jne 0x40be8f
mov eax, dword [ebp + 8]
mov dword [eax], ebx
mov byte [ebp - 2], 1
jmp 0x40bee5
inc ebx
lea edx, [ebp - 8]
mov eax, ebx
call esi
test al, al
jne 0x40be61
xor ebx, ebx
jmp 0x40beda
mov eax, dword [ebp - 8]
mov eax, dword [eax + 0x28]
and eax, 0x3ff
mov edx, edi
and dx, 0x3ff
movzx edx, dx
cmp eax, edx
jne 0x40bed9
mov eax, dword [ebp - 8]
cmp dword [eax + 0x2c], 0
je 0x40bece
call sub.kernel32.dll_GetACP
mov edx, dword [ebp - 8]
cmp eax, dword [edx + 0x2c]
jne 0x40bed9
mov eax, dword [ebp + 8]
mov dword [eax], ebx
mov byte [ebp - 2], 1
jmp 0x40bee5
inc ebx
lea edx, [ebp - 8]
mov eax, ebx
call esi
test al, al
jne 0x40be9f
mov al, byte [ebp - 2]
pop edi
pop esi
pop ebx
pop ecx
pop ecx
pop ebp
ret 4
Function at 0x40c2d8
Capabilities:
Create process on windows
Create process suspended

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffa8
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 4], ebx
mov edi, ecx
mov esi, edx
mov ebx, eax
xor eax, eax
push ebp
push 0x40c3ad
push dword fs:[eax]
mov dword fs:[eax], esp
push 0x40c3c4
push ebx
push 0x40c3d0
push esi
lea eax, [ebp - 4]
mov edx, 4
call fcn.00403c28
lea eax, [ebp - 0x48]
xor ecx, ecx
mov edx, 0x44
call fcn.00402824
mov dword [ebp - 0x48], 0x44
lea eax, [ebp - 0x58]
push eax
lea eax, [ebp - 0x48]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
mov eax, dword [ebp - 4]
call fcn.00403cc4
push eax
push 0
call sub.kernel32.dll_CreateProcessA
test eax, eax
jne 0x40c358
mov al, 0x6a
call fcn.0040bf2c
mov eax, dword [ebp - 0x54]
push eax
call sub.kernel32.dll_CloseHandle
call fcn.0040c2ac
push 0xff
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x58]
push eax
push 1
call sub.user32.dll_MsgWaitForMultipleObjects
cmp eax, 1
je 0x40c361
call fcn.0040c2ac
push edi
mov eax, dword [ebp - 0x58]
push eax
call sub.kernel32.dll_GetExitCodeProcess
mov eax, dword [ebp - 0x58]
push eax
call sub.kernel32.dll_CloseHandle
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40c3b4
lea eax, [ebp - 4]
call fcn.004038e8
ret

Function at 0x40c470
Capabilities:
Allocate or change rwx memory
Get system information on windows

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xffffffbc
mov edi, eax
lea esi, [esp + 0x28]
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetSystemInfo
mov ebx, edi
push 0x1c
push esi
push ebx
call sub.kernel32.dll_VirtualQuery
test eax, eax
je 0x40c524
jmp 0x40c519
cmp dword [esi + 0x10], 0x1000
jne 0x40c505
test byte [esi + 0x15], 1
jne 0x40c505
xor ebx, ebx
mov eax, dword [esi + 0x14]
cmp eax, 1
je 0x40c4c4
cmp eax, 2
je 0x40c4c4
cmp eax, 0x10
je 0x40c4c4
cmp eax, 0x20
jne 0x40c4d9
push esp
push 0x40
mov eax, dword [esi + 0xc]
push eax
mov eax, dword [esi]
push eax
call sub.kernel32.dll_VirtualProtect
test eax, eax
je 0x40c4d9
mov bl, 1
xor ebp, ebp
jmp 0x40c4ea
mov eax, dword [esi]
add eax, ebp
call fcn.0040c468
add ebp, dword [esp + 8]
cmp ebp, dword [esi + 0xc]
jb 0x40c4dd
test bl, bl
je 0x40c505
push esp
mov eax, dword [esp + 4]
push eax
mov eax, dword [esi + 0xc]
push eax
mov eax, dword [esi]
push eax
call sub.kernel32.dll_VirtualProtect
mov eax, dword [esi]
add eax, dword [esi + 0xc]
mov ebx, eax
push 0x1c
push esi
push ebx
call sub.kernel32.dll_VirtualQuery
test eax, eax
je 0x40c524
mov eax, dword [esi + 4]
cmp eax, edi
je 0x40c49c
add esp, 0x44
pop ebp
pop edi
pop esi
pop ebx
ret
Function at 0x404000
Capabilities:
Allocate thread local storage

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
call dword [sym.imp.KERNEL32.dll_TlsAlloc]
cmp eax, 0xffffffff
je 0x404036
mov dword [0x446040], eax
mov edx, sym.unk_463
mov dword [esp + 4], edx
mov dword [esp], eax
call fcn.0040cae0
test eax, eax
sete al
movzx eax, al
mov dword [0x43e0d0], eax
leave
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
sete al
movzx eax, al
mov dword [0x43e0d0], eax
leave
ret

Function at 0x404120
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
lea eax, [ebp - 0xc]
sub esp, 0x68
mov dword [ebp - 0x20], eax
lea eax, [ebp - 0x40]
mov dword [ebp - 0xc], ebx
mov dword [ebp - 8], esi
mov dword [ebp - 4], edi
mov dword [ebp - 0x28], sym.unk_21
mov dword [ebp - 0x24], 0x43cbc4
mov dword [ebp - 0x1c], 0x4041e0
mov dword [ebp - 0x18], esp
mov dword [esp], eax
call fcn.0040d050
cmp dword [0x43e0d0], 0
mov dword [ebp - 0x44], 0x446050
je 0x4041c0
jl 0x404200
mov dword [ebp - 0x3c], 1
mov eax, dword [0x446040]
mov dword [ebp - 0x4c], eax
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [ebp - 0x50], eax
mov eax, dword [ebp - 0x4c]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x50]
sub esp, 4
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [ebp - 0x54]
sub esp, 4
test eax, eax
mov dword [ebp - 0x48], eax
je 0x4042a3
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0x44], eax
lea esi, [esi]
lea eax, [ebp - 0x40]
mov dword [esp], eax
call fcn.0040d130
mov eax, dword [ebp - 0x44]
mov ebx, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp - 4]
mov esp, ebp
pop ebp
ret
mov edx, dword [0x446660]
mov eax, 0xffffffff
test edx, edx
je 0x40421a
mov eax, dword [0x43e0d4]
test eax, eax
je 0x40425a
xor eax, eax
test eax, eax
jne 0x404250
mov edi, dword [0x43e0d0]
test edi, edi
js 0x404250
mov dword [ebp - 0x44], 0x446050
mov ebx, dword [0x43e0d0]
test ebx, ebx
je 0x4041c0
jmp 0x40416e
xor esi, esi
mov dword [0x43e0d0], esi
jmp 0x404228
mov dword [esp], 0x43e0d8
mov dword [ebp - 0x3c], 1
call sub.KERNEL32.dll_InterlockedIncrement
sub esp, 4
test eax, eax
je 0x4042e1
mov eax, dword [0x43e0d4]
test eax, eax
jne 0x404218
mov dword [esp], 0
mov eax, dword [sym.imp.KERNEL32.dll_Sleep]
mov dword [ebp - 0x3c], 1
call eax
sub esp, 4
mov eax, dword [0x43e0d4]
test eax, eax
je 0x40427d
jmp 0x404218
mov dword [esp], 8
call sub.msvcrt.dll_malloc
mov dword [ebp - 0x48], eax
test eax, eax
je 0x4042d5
mov dword [esp + 4], eax
mov eax, dword [0x446040]
mov dword [esp], eax
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
sub esp, 8
xor edx, edx
test eax, eax
je 0x40430a
test edx, edx
je 0x4042f5
mov dword [ebp - 0x3c], 1
call sym.unk_452
call sym.unk_464
mov eax, 1
mov dword [0x43e0d4], eax
jmp 0x404218
mov eax, dword [ebp - 0x48]
mov dword [eax], 0
mov dword [eax + 4], 0
jmp 0x4041b6
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, eax
jmp 0x4042d1
Function at 0x409824
Capabilities:
Create process on windows
Create process suspended

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffa8
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 4], ebx
mov edi, ecx
mov esi, edx
mov ebx, eax
xor eax, eax
push ebp
push 0x4098f7
push dword fs:[eax]
mov dword fs:[eax], esp
push 0x409910
push ebx
push 0x40991c
push esi
lea eax, [ebp - 4]
mov edx, 4
call fcn.0040336c
lea eax, [ebp - 0x48]
xor ecx, ecx
mov edx, 0x44
call fcn.00402750
mov dword [ebp - 0x48], 0x44
lea eax, [ebp - 0x58]
push eax
lea eax, [ebp - 0x48]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
mov eax, dword [ebp - 4]
call fcn.004033cc
push eax
push 0
call sub.kernel32.dll_CreateProcessA
test eax, eax
jne 0x4098a4
mov al, 0x62
call fcn.004093fc
mov eax, dword [ebp - 0x54]
push eax
call sub.kernel32.dll_CloseHandle_1
call fcn.004097f8
push 0xff
push 0xffffffffffffffff
push 0
lea eax, [ebp - 0x58]
push eax
push 1
call sub.user32.dll_MsgWaitForMultipleObjects
dec eax
je 0x4098ad
call fcn.004097f8
push edi
mov eax, dword [ebp - 0x58]
push eax
call sub.kernel32.dll_GetExitCodeProcess
mov eax, dword [ebp - 0x58]
push eax
call sub.kernel32.dll_CloseHandle_1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4098fe
lea eax, [ebp - 4]
call fcn.00403150
ret

Function at 0x409990
Capabilities:
Allocate or change rwx memory
Get system information on windows

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xffffffbc
mov edi, eax
lea esi, [esp + 0x28]
lea eax, [esp + 4]
push eax
call sub.kernel32.dll_GetSystemInfo
mov ebx, edi
push 0x1c
push esi
push ebx
call sub.kernel32.dll_VirtualQuery
test eax, eax
je 0x409a44
jmp 0x409a39
cmp dword [esi + 0x10], 0x1000
jne 0x409a25
test byte [esi + 0x15], 1
jne 0x409a25
xor ebx, ebx
mov eax, dword [esi + 0x14]
cmp eax, 1
je 0x4099e4
cmp eax, 2
je 0x4099e4
cmp eax, 0x10
je 0x4099e4
cmp eax, 0x20
jne 0x4099f9
push esp
push 0x40
mov eax, dword [esi + 0xc]
push eax
mov eax, dword [esi]
push eax
call sub.kernel32.dll_VirtualProtect
test eax, eax
je 0x4099f9
mov bl, 1
xor ebp, ebp
jmp 0x409a0a
mov eax, dword [esi]
add eax, ebp
call fcn.00409988
add ebp, dword [esp + 8]
cmp ebp, dword [esi + 0xc]
jb 0x4099fd
test bl, bl
je 0x409a25
push esp
mov eax, dword [esp + 4]
push eax
mov eax, dword [esi + 0xc]
push eax
mov eax, dword [esi]
push eax
call sub.kernel32.dll_VirtualProtect
mov eax, dword [esi]
add eax, dword [esi + 0xc]
mov ebx, eax
push 0x1c
push esi
push ebx
call sub.kernel32.dll_VirtualQuery
test eax, eax
je 0x409a44
mov eax, dword [esi + 4]
cmp eax, edi
je 0x4099bc
add esp, 0x44
pop ebp
pop edi
pop esi
pop ebx
ret