joyce8/EMBER2024-capa huggingface dataset:
Function at 0x422d50
Capabilities:
Extract resource via kernel32 functions

Disassembly:
movzx edx, word [esp + 4]
mov dword [esp + 4], edx
jmp method.CDialog.virtual_320

Function at 0x426db8
Capabilities:
Encrypt data using rc4 prga

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
mov ebx, dword [esi + 0x2c]
push edi
mov edi, dword [esi + 0x3c]
sub edi, dword [esi + 0x74]
mov eax, dword [esi + 0x6c]
mov ecx, dword [esi + 0x2c]
sub edi, eax
lea ecx, [ebx + ecx - 0x106]
mov dword [ebp - 8], edi
cmp eax, ecx
jb 0x426e47
mov eax, dword [esi + 0x38]
push ebx
lea ecx, [eax + ebx]
push ecx
push eax
call fcn.0042aef0
mov eax, dword [esi + 0x4c]
mov ecx, dword [esi + 0x44]
sub dword [esi + 0x70], ebx
sub dword [esi + 0x6c], ebx
add esp, 0xc
sub dword [esi + 0x5c], ebx
mov dword [ebp - 4], eax
lea eax, [ecx + eax*2]
dec eax
dec eax
movzx ecx, word [eax]
mov edx, ecx
sub edx, ebx
cmp ecx, ebx
sbb ecx, ecx
not ecx
and ecx, edx
dec dword [ebp - 4]
mov word [eax], cx
jne 0x426e07
mov eax, dword [esi + 0x40]
mov dword [ebp - 4], ebx
lea eax, [eax + ebx*2]
dec eax
dec eax
movzx ecx, word [eax]
mov edx, ecx
sub edx, ebx
cmp ecx, ebx
sbb ecx, ecx
not ecx
and ecx, edx
dec dword [ebp - 4]
mov word [eax], cx
jne 0x426e29
add edi, ebx
mov dword [ebp - 8], edi
mov edi, dword [esi]
cmp dword [edi + 4], 0
je 0x426f05
mov eax, dword [esi + 0x74]
add eax, dword [esi + 0x6c]
mov ecx, dword [edi + 4]
add eax, dword [esi + 0x38]
mov edx, dword [ebp - 8]
mov dword [ebp - 0xc], eax
mov dword [ebp - 4], ecx
cmp ecx, edx
jbe 0x426e6f
mov dword [ebp - 4], edx
mov edx, dword [ebp - 4]
test edx, edx
jne 0x426e7a
xor eax, eax
jmp 0x426ec6
sub ecx, edx
mov dword [edi + 4], ecx
mov ecx, dword [edi + 0x1c]
mov ecx, dword [ecx + 0x18]
cmp ecx, 1
jne 0x426e97
push edx
push dword [edi]
push dword [edi + 0x30]
call fcn.00427708
jmp 0x426ea7
cmp ecx, 2
jne 0x426eb0
push edx
push dword [edi]
push dword [edi + 0x30]
call fcn.0042903a
mov dword [edi + 0x30], eax
mov eax, dword [ebp - 0xc]
add esp, 0xc
push dword [ebp - 4]
push dword [edi]
push eax
call fcn.0042aef0
mov eax, dword [ebp - 4]
add dword [edi], eax
add esp, 0xc
add dword [edi + 8], eax
add dword [esi + 0x74], eax
mov edi, dword [esi + 0x74]
cmp edi, 3
jb 0x426ef1
mov eax, dword [esi + 0x6c]
mov ecx, dword [esi + 0x38]
lea edx, [eax + ecx]
movzx eax, byte [edx]
mov ecx, dword [esi + 0x58]
mov dword [esi + 0x48], eax
shl eax, cl
movzx ecx, byte [edx + 1]
xor eax, ecx
and eax, dword [esi + 0x54]
mov dword [esi + 0x48], eax
cmp edi, 0x106
jae 0x426f05
mov eax, dword [esi]
cmp dword [eax + 4], 0
jne 0x426dc5
pop edi
pop ebx
leave
ret
Function at 0x429414
Capabilities:
Get geographical location

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x274
mov eax, dword [0x455d50]
xor eax, ebp
mov dword [ebp - 4], eax
cmp dword [ebp + 0xc], 0x800
mov eax, dword [ebp + 8]
push esi
mov dword [ebp - 0x234], eax
mov esi, ecx
lea eax, [ebp - 0xc]
jne 0x4294ac
push 0x445d84
push 4
push eax
call fcn.0042a544
push eax
call fcn.0041a090
add esp, 0x10
push ebx
push edi
call fcn.0042ba66
mov edi, dword [eax]
call fcn.0042ba66
xor ebx, ebx
mov dword [eax], ebx
lea eax, [ebp - 0xc]
push eax
push dword [ebp - 0x234]
lea eax, [ebp - 0x230]
push esi
push 0x111
mov esi, 0x112
push esi
push eax
call fcn.0042ba03
add esp, 0x18
mov dword [ebp - 0x234], eax
call fcn.0042ba66
cmp dword [eax], ebx
je 0x4294c3
call fcn.0042ba66
push dword [eax]
call fcn.00408750
pop ecx
jmp 0x4294ca
push 4
push eax
push 3
push dword [ebp + 0xc]
call dword [sym.imp.KERNEL32.dll_GetLocaleInfoW]
test eax, eax
jne 0x429457
jmp 0x429551
call fcn.0042ba66
mov dword [eax], edi
cmp dword [ebp - 0x234], 0xffffffff
je 0x42954d
cmp dword [ebp - 0x234], esi
jae 0x42954d
lea eax, [ebp - 0x230]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
push 0x3c
mov esi, eax
lea eax, [ebp - 0x270]
push ebx
push eax
mov dword [ebp - 0x274], 0x40
call fcn.0042ace0
add esp, 0xc
push 0x445994
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
cmp eax, ebx
je 0x42953c
push str.FindActCtxSectionStringW
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x42953c
lea ecx, [ebp - 0x274]
push ecx
push esi
push 2
push ebx
push ebx
call eax
test eax, eax
je 0x42953c
push ebx
push ebx
push esi
jmp 0x429545
push ebx
push ebx
lea eax, [ebp - 0x230]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
jmp 0x42954f
xor eax, eax
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.00404b64
leave
ret
Function at 0x403770
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
test edx, edx
jne 0x40377b
xor eax, eax
pop ebp
ret
push esi
mov esi, dword [ebp + 8]
not ecx
cmp esi, 8
jb 0x403837
push edi
mov edi, esi
shr edi, 3
movzx eax, byte [edx]
sub esi, 8
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
movzx eax, byte [edx + 1]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
movzx eax, byte [edx + 2]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
movzx eax, byte [edx + 3]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
movzx eax, byte [edx + 4]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
movzx eax, byte [edx + 5]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
movzx eax, byte [edx + 6]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
movzx eax, byte [edx + 7]
add edx, 8
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
sub edi, 1
jne 0x403790
pop edi
test esi, esi
je 0x40385a
nop dword [eax + eax]
movzx eax, byte [edx]
lea edx, [edx + 1]
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
sub esi, 1
jne 0x403840
not ecx
mov eax, ecx
pop esi
pop ebp
ret

Function at 0x404040
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [0x5e8464]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, ecx
mov ebx, edx
push edi
mov dword [ebp - 0xc], ebx
mov edi, 1
cmp byte [esi], 0
je 0x404085
push 0
lea eax, [ebp - 0xc]
push eax
push edi
lea eax, [ebp - 5]
push eax
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x404080
mov byte [esi + 8], 1
mov edi, dword [ebp - 0xc]
jmp 0x4040b2
mov ebx, dword [esi + 0x1c]
mov ecx, dword [esi + 0x18]
lea eax, [ebx + 1]
cmp eax, ecx
jbe 0x404096
mov edi, ecx
sub edi, ebx
mov eax, dword [esi + 0x14]
add eax, ebx
push edi
push eax
lea eax, [ebp - 5]
push eax
call fcn.00542c70
lea eax, [ebx + edi]
add esp, 0xc
mov ebx, dword [ebp - 0xc]
mov dword [esi + 0x1c], eax
cmp edi, 1
jne 0x4040d0
movzx eax, byte [ebp - 5]
mov dword [ebx], eax
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0053ed9c
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0
je 0x4040bd
cmp byte [esi + 8], 0
je 0x4040bd
mov ecx, dword [ebp - 4]
or eax, 0xffffffff
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0053ed9c
mov esp, ebp
pop ebp
ret
Function at 0x404190
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x5e8464]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, ecx
push esi
mov esi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push edi
cmp byte [ebx], 0
je 0x4041e3
cmp byte [ebx + 1], 0
je 0x404216
push 2
push 0
push 0
push dword [ebx + 4]
call esi
cmp byte [ebx], 0
je 0x4041e9
cmp byte [ebx + 1], 0
je 0x4041dc
push 1
push 0
push 0
push dword [ebx + 4]
call esi
sub eax, dword [ebx + 0xc]
jmp 0x4041ec
xor eax, eax
mov dword [ebp - 0x10], eax
jmp 0x4041fb
mov eax, dword [ebx + 0x18]
mov dword [ebx + 0x1c], eax
mov eax, dword [ebx + 0x1c]
mov esi, 0xffff
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x18], esi
cmp eax, esi
jae 0x404200
mov esi, eax
mov dword [ebp - 0x18], eax
push 0x404
call fcn.00548ee9
mov edi, eax
add esp, 4
mov dword [ebp - 0x14], edi
test edi, edi
jne 0x40422a
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0053ed9c
mov esp, ebp
pop ebp
ret
mov eax, 4
mov dword [ebp - 0xc], 0xffffffff
cmp esi, eax
jbe 0x404336
nop
mov edx, dword [ebp - 0x10]
add eax, 0x400
cmp eax, esi
mov ecx, esi
cmovbe ecx, eax
mov eax, 0x404
sub edx, ecx
mov dword [ebp - 0x24], ecx
cmp ecx, 0x404
mov dword [ebp - 0x20], edx
mov esi, ecx
cmova esi, eax
cmp byte [ebx], 0
mov dword [ebp - 0x1c], esi
je 0x4042b1
cmp byte [ebx + 1], 0
je 0x404336
mov eax, dword [ebx + 0xc]
push 0
push 0
add eax, edx
push eax
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp byte [ebx], 0
mov edx, esi
je 0x4042b6
push 0
lea eax, [ebp - 8]
push eax
push esi
push edi
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4042ac
mov byte [ebx + 8], 1
mov eax, dword [ebp - 8]
jmp 0x4042e7
mov dword [ebx + 0x1c], edx
mov edx, esi
mov edi, dword [ebx + 0x1c]
mov ecx, dword [ebx + 0x14]
lea eax, [edi + esi]
mov esi, dword [ebx + 0x18]
sub esi, edi
cmp eax, dword [ebx + 0x18]
cmovbe esi, edx
add ecx, edi
push esi
push ecx
push dword [ebp - 0x14]
call fcn.00542c70
lea ecx, [esi + edi]
mov eax, esi
mov esi, dword [ebp - 0x1c]
add esp, 0xc
mov edi, dword [ebp - 0x14]
mov dword [ebx + 0x1c], ecx
xor edx, edx
div esi
cmp eax, 1
jne 0x404336
lea ecx, [esi - 3]
test ecx, ecx
js 0x404321
lea eax, [edi + 3]
add eax, ecx
nop dword [eax]
mov edx, ecx
lea eax, [eax - 1]
dec ecx
cmp byte [eax - 3], 0x50
jne 0x40431d
cmp byte [edx + edi], 0x4b
jne 0x40431d
cmp byte [eax - 1], 5
jne 0x40431d
cmp byte [eax], 6
je 0x404353
test ecx, ecx
jns 0x404300
mov eax, dword [ebp - 0xc]
test eax, eax
jne 0x404336
mov eax, dword [ebp - 0x24]
mov esi, dword [ebp - 0x18]
cmp eax, esi
jb 0x404240
push edi
call fcn.00548ece
mov ecx, dword [ebp - 4]
add esp, 4
mov eax, dword [ebp - 0xc]
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.0053ed9c
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x20]
add eax, ecx
mov dword [ebp - 0xc], eax
jmp 0x404324
Function at 0x404cd0
Capabilities:
Generate random numbers using the delphi lcg
Hash data with crc32

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push edi
mov edi, ecx
mov ebx, edx
test edi, edi
je 0x404eba
cmp dword [edi + 0x18], 0
je 0x404eba
push esi
mov esi, dword [edi + 0x7c]
test esi, esi
je 0x404d30
mov eax, dword [esi]
test eax, eax
je 0x404d05
push eax
call fcn.00548ece
add esp, 4
cmp dword [esi + 0x40], 0
mov dword [esi], 0
je 0x404d19
lea ecx, [esi + 4]
call fcn.004039d0
push esi
mov dword [esi + 0x40], 0
call fcn.00548ece
add esp, 4
mov dword [edi + 0x7c], 0
lea eax, [ebp - 8]
mov ecx, edi
push eax
lea eax, [ebp - 4]
push eax
lea edx, [ebp - 0xc]
call fcn.00404a70
add esp, 8
test eax, eax
je 0x404d55
pop esi
pop edi
mov eax, 0xffffff99
pop ebx
mov esp, ebp
pop ebp
ret
push 0x84
call fcn.00548ee9
mov esi, eax
add esp, 4
test esi, esi
je 0x404d97
push 0x4000
call fcn.00548ee9
mov ecx, dword [ebp - 4]
add esp, 4
mov dword [esi + 0x44], ecx
mov ecx, dword [ebp - 8]
mov dword [esi], eax
mov dword [esi + 0x48], ecx
mov dword [esi + 0x4c], 0
test eax, eax
jne 0x404da3
push esi
call fcn.00548ece
add esp, 4
pop esi
pop edi
mov eax, 0xffffff98
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0x3c]
mov ecx, dword [edi + 0x34]
mov dword [esi + 0x54], eax
mov eax, dword [edi]
mov dword [esi + 0x60], eax
mov eax, dword [edi + 0xc]
mov dword [esi + 0x40], 0
mov dword [esi + 0x50], 0
mov dword [esi + 0x64], ecx
mov dword [esi + 0x68], eax
mov dword [esi + 0x18], 0
test ecx, ecx
je 0x404dfb
lea ecx, [esi + 4]
mov dword [esi + 0x24], 0
mov dword [esi + 0x28], 0
mov dword [esi + 0x2c], 0
call fcn.00403ab0
test eax, eax
jne 0x404dfb
mov dword [esi + 0x40], 1
mov eax, dword [edi + 0x40]
mov cl, byte [edi + 0x30]
mov dword [esi + 0x58], eax
and cl, 1
mov eax, dword [edi + 0x44]
mov dword [esi + 0x5c], eax
mov eax, dword [edi + 0x30]
shr eax, 3
mov byte [esi + 0x6c], cl
test al, 1
je 0x404e1f
mov al, byte [edi + 0x39]
jmp 0x404e22
mov al, byte [edi + 0x3f]
mov byte [esi + 0x80], al
mov edx, 0xc
xor eax, eax
mov dword [esi + 0x70], 0x12345678
test cl, cl
mov dword [esi + 0x74], 0x23456789
mov dword [esi + 0x78], 0x34567890
cmovne eax, edx
mov dword [esi + 0x7c], eax
test ebx, ebx
je 0x404e9b
mov al, byte [ebx]
test al, al
je 0x404e9b
mov ecx, dword [esi + 0x70]
movsx eax, al
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
movzx eax, cl
add eax, dword [esi + 0x74]
imul eax, eax, 0x8088405
mov dword [esi + 0x70], ecx
mov ecx, dword [esi + 0x78]
inc eax
mov dword [esi + 0x74], eax
shr eax, 0x18
xor eax, ecx
shr ecx, 8
movzx eax, al
xor ecx, dword [eax*4 + 0x5cc248]
mov dword [esi + 0x78], ecx
add ebx, 1
jne 0x404e50
mov eax, dword [ebp - 0xc]
add eax, 0x1e
mov dword [edi + 0x7c], esi
add eax, dword [edi + 0x78]
mov dword [esi + 0x3c], eax
xor eax, eax
mov dword [esi + 8], 0
pop esi
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
mov eax, 0xffffff9a
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4059e0
Capabilities:
Check if file exists
Create directory
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x5e8464]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, ecx
push edi
mov edi, edx
test ebx, ebx
je 0x405a85
push 0x104
push ebx
lea eax, [ebp - 0x20c]
push 0x104
push eax
call fcn.00548fbf
lea ecx, [ebp - 0x20c]
add esp, 0x10
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x405a24
sub ecx, edx
sar ecx, 1
je 0x405a64
movzx eax, word [ebp + ecx*2 - 0x20e]
cmp eax, 0x2f
je 0x405a47
cmp eax, 0x5c
jne 0x405a64
lea ecx, [ecx*2 - 2]
cmp ecx, 0x208
jae 0x405b95
xor eax, eax
mov word [ebp + ecx - 0x20c], ax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x405a85
push 0
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
movzx eax, word [edi]
test ax, ax
je 0x405b85
push esi
mov esi, edi
mov ecx, edi
mov edx, eax
cmp dx, 0x2f
je 0x405aa4
cmp dx, 0x5c
jne 0x405aa6
mov esi, ecx
movzx eax, word [ecx + 2]
add ecx, 2
mov edx, eax
test ax, ax
jne 0x405a98
cmp esi, edi
je 0x405af1
sub esi, edi
lea eax, [ebp - 0x20c]
and esi, 0xfffffffe
push esi
push edi
push eax
call fcn.00542c70
add esp, 0xc
cmp esi, 0x208
jae 0x405b95
xor eax, eax
lea edx, [ebp - 0x20c]
mov ecx, ebx
mov word [ebp + esi - 0x20c], ax
call fcn.004059e0
xor eax, eax
mov word [ebp - 0x414], ax
pop esi
test ebx, ebx
je 0x405b19
push 0x104
push ebx
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.00548fbf
add esp, 0x10
xor eax, eax
lea ecx, [ebp - 0x414]
mov word [ebp - 0x20e], ax
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x405b30
sub ecx, edx
mov eax, 0x104
sar ecx, 1
sub eax, ecx
push eax
push edi
push eax
lea eax, [ebp - 0x414]
lea eax, [eax + ecx*2]
push eax
call fcn.00548fbf
xor eax, eax
add esp, 0x10
mov word [ebp - 0x20e], ax
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x405b85
push 0
lea eax, [ebp - 0x414]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.0053ed9c
mov esp, ebp
pop ebp
ret
call fcn.0053eed1
int3
Function at 0x405fb0
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56e937
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x5e8464]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
push 0x44c
call fcn.0053efac
mov edi, eax
mov dword [ebp - 0x14], edi
push 0x44c
push 0
push edi
call fcn.00542b10
add esp, 0x10
mov dword [edi], 0
lea esi, [edi + 0x244]
mov dword [edi + 4], 0xffffffff
mov dword [edi + 0x238], 0xffffffff
mov dword [edi + 0x23c], 0
push esi
push 0x103
mov dword [edi + 0x240], 0
mov dword [ebp - 4], 0xffffffff
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
test ax, ax
jne 0x406040
sub esi, ecx
sar esi, 1
movzx eax, word [edi + esi*2 + 0x242]
cmp eax, 0x5c
je 0x40606c
cmp eax, 0x2f
je 0x40606c
mov dword [edi + esi*2 + 0x244], 0x2f
push 0
push 0x80
push 3
push 0
push 1
push closesocket
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x14], eax
cmp eax, 0xffffffff
je 0x406124
push 1
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov esi, eax
cmp esi, 0xffffffff
push 0x20
setne bl
call fcn.0053efac
mov ecx, dword [ebp - 0x14]
add esp, 4
mov dword [ebp - 0x10], eax
mov byte [eax], 1
mov byte [eax + 0x10], 1
mov byte [eax + 1], bl
mov dword [eax + 4], ecx
mov byte [eax + 8], 0
mov dword [eax + 0xc], 0
cmp esi, 0xffffffff
je 0x4060e8
push 1
push 0
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ecx, dword [ebp - 0x10]
mov dword [ecx + 0xc], eax
mov eax, ecx
mov ecx, eax
call fcn.00404360
mov dword [edi], eax
test eax, eax
je 0x406124
push 8
mov dword [0x5f2228], 0
call fcn.0053efac
add esp, 4
mov dword [eax], 1
mov dword [eax + 4], edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0x23c]
mov dword [0x5f2228], 0x200
test eax, eax
je 0x406141
push eax
call fcn.0053edaa
add esp, 4
mov eax, dword [edi + 0x240]
mov dword [edi + 0x23c], 0
test eax, eax
je 0x40615e
push eax
call fcn.0053edaa
add esp, 4
push 0x44c
push edi
mov dword [edi + 0x240], 0
call fcn.0053efdc
add esp, 8
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x40c880
Capabilities:
Get process heap flags

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56f148
mov eax, dword fs:[0]
push eax
sub esp, 8
push ebx
push esi
push edi
mov eax, dword [0x5e8464]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
mov dword [ebp - 0x14], esi
xor eax, eax
mov dword [esi], 0
mov dword [esi + 0x10], 0
mov dword [esi + 0x14], 7
mov word [esi], ax
mov dword [ebp - 4], eax
mov dword [esi + 0x18], eax
mov dword [esi + 0x28], eax
mov dword [esi + 0x2c], 7
mov word [esi + 0x18], ax
mov byte [ebp - 4], 1
mov edx, dword [ebp + 8]
mov eax, edx
lea ebx, [eax + 2]
nop dword [eax]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40c8f0
sub eax, ebx
lea ecx, [esi + 0x18]
sar eax, 1
push eax
push edx
call fcn.004065c0
mov ecx, dword [ebp + 0xc]
mov eax, esi
mov dword [esi + 0x30], ecx
mov ecx, dword [ebp + 0x10]
mov dword [esi + 0x34], ecx
mov dword [esi + 0x3c], 0
mov dword [esi + 0x38], 0
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc

Function at 0x40df70
Capabilities:
Access peb ldr_data
Get ntdll base address

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x56f1fb
mov eax, dword fs:[0]
push eax
push ecx
push esi
mov eax, dword [0x5e8464]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x10], esi
xor eax, eax
mov dword [esi + 0x20], 0
mov dword [esi + 0x30], 0
mov dword [esi + 0x34], 7
mov word [esi + 0x20], ax
mov dword [ebp - 4], eax
mov dword [esi + 0x38], eax
mov dword [esi + 0x48], eax
mov dword [esi + 0x4c], 7
mov word [esi + 0x38], ax
lea ecx, [esi + 0x54]
mov byte [ebp - 4], 1
call fcn.0040d930
mov dword [esi + 0xd4], 0
xor eax, eax
mov word [esi + 0xd4], ax
mov dword [esi + 0xe4], 0
mov dword [esi + 0xe8], 7
mov dword [esi], eax
mov dword [esi + 4], eax
mov dword [esi + 0x10], eax
mov dword [esi + 0x14], eax
mov dword [esi + 8], eax
mov dword [esi + 0x18], eax
mov dword [esi + 0x1c], eax
mov dword [esi + 0x50], eax
mov dword [esi + 0xc8], eax
mov dword [esi + 0xcc], eax
mov eax, esi
mov dword [esi + 0xc], 0x4000
mov dword [esi + 0xd0], 0xffffffff
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov esp, ebp
pop ebp
ret
Function at 0x40e7c0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
mov ebx, ecx
push edi
mov edi, dword [ebp + 8]
push dword [ebx]
push 1
push dword [ebx + 8]
push edi
call fcn.0054b3f4
mov esi, dword [ebx + 8]
mov ecx, eax
add esp, 0x10
cmp ecx, 1
sete al
mov byte [ebp - 1], al
mov eax, esi
cdq
idiv dword [ebx + 0x18]
mov dword [ebx + 0x1c], eax
cmp ecx, 1
jne 0x40e945
add dword [ebx + 0x14], esi
cmp dword [ebx + 0x4c], 8
push 0xffffffffffffffff
push eax
lea eax, [ebx + 0x38]
push ecx
mov ecx, esp
jb 0x40e812
mov eax, dword [eax]
mov dword [ecx], eax
mov edx, 0x18
push ecx
mov eax, esp
lea ecx, [ebx + 0x20]
mov dword [eax], str.read
call fcn.0040c670
mov eax, dword [ebx + 0x1c]
add esp, 0x10
mov edx, dword [ebx + 0x18]
xor ecx, ecx
mov dword [ebp - 8], 0
mov esi, edi
mov dword [ebp - 0x10], edx
test eax, eax
je 0x40e8f8
mov edi, edx
jmp 0x40e856
mov eax, dword [ebp - 0xc]
mov edx, dword [ebp - 0x10]
dec eax
mov dword [ebp - 0xc], eax
cmp edx, 1
jne 0x40e865
xor edx, edx
cmp byte [esi], dl
jmp 0x40e86a
xor edx, edx
cmp word [esi], dx
sete dl
mov eax, edi
test edx, edx
je 0x40e89f
test ecx, ecx
je 0x40e893
cmp esi, ecx
je 0x40e893
imul edi, dword [ebp - 8]
mov eax, esi
sub eax, ecx
push eax
push ecx
sub ecx, edi
push ecx
call fcn.00542c70
mov eax, dword [ebx + 0x18]
add esp, 0xc
mov edx, dword [ebp - 8]
lea ecx, [eax + esi]
inc edx
mov dword [ebp - 8], edx
jmp 0x40e8a2
mov edx, dword [ebp - 8]
add esi, eax
mov edi, eax
cmp dword [ebp - 0xc], 0
jne 0x40e850
test ecx, ecx
je 0x40e8c6
cmp esi, ecx
je 0x40e8c6
sub esi, ecx
imul eax, edx
push esi
push ecx
sub ecx, eax
push ecx
call fcn.00542c70
add esp, 0xc
mov esi, dword [ebp - 8]
test esi, esi
je 0x40e8f5
push 0xffffffffffffffff
push esi
push ecx
mov eax, esp
mov edx, 1
push ecx
lea ecx, [ebx + 0x20]
mov dword [eax], 0
mov eax, esp
mov dword [eax], str.nulls_removed
call fcn.0040c670
add esp, 0x10
sub dword [ebx + 0x1c], esi
mov edi, dword [ebp + 8]
cmp dword [ebx + 0x18], 1
jle 0x40e945
test byte [ebx + 4], 0x80
je 0x40e945
mov ecx, dword [ebx + 0x1c]
test ecx, ecx
je 0x40e922
nop dword [eax + eax]
movzx eax, word [edi + ecx*2 - 2]
dec ecx
rol ax, 8
mov word [edi + ecx*2], ax
test ecx, ecx
jne 0x40e910
push 0xffffffffffffffff
push 0xffffffffffffffff
push ecx
mov eax, esp
xor edx, edx
push ecx
lea ecx, [ebx + 0x20]
mov dword [eax], 0
mov eax, esp
mov dword [eax], str.endian_swap
call fcn.0040c670
add esp, 0x10
mov al, byte [ebp - 1]
test al, al
jne 0x40e956
mov ecx, ebx
call fcn.0040e050
mov al, byte [ebp - 1]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x40ee00
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push ecx
push ebx
push esi
mov esi, ecx
push edi
mov edi, dword [ebp + 8]
mov ebx, edi
mov eax, dword [esi + 0x18]
mov edx, dword [esi + 0x1c]
imul eax, edx
mov dword [esi + 8], eax
mov eax, dword [ebp + 0xc]
test eax, eax
cmovne ebx, eax
xor eax, eax
test byte [esi + 4], 0x80
mov dword [esp + 0xc], eax
je 0x40eea5
test edi, edi
jne 0x40ee6b
xor ecx, ecx
mov eax, edx
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0053efea
mov ecx, dword [esi + 0x1c]
add esp, 4
add ecx, ecx
mov edi, eax
mov dword [esp + 0xc], edi
push ecx
push ebx
push edi
call fcn.00542c70
mov edx, dword [esi + 0x1c]
add esp, 0xc
mov ebx, edi
test edx, edx
je 0x40ee82
nop
movzx eax, word [edi + edx*2 - 2]
dec edx
rol ax, 8
mov word [edi + edx*2], ax
test edx, edx
jne 0x40ee70
push 0xffffffffffffffff
push 0xffffffffffffffff
push ecx
mov eax, esp
xor edx, edx
push ecx
lea ecx, [esi + 0x20]
mov dword [eax], 0
mov eax, esp
mov dword [eax], str.endian_swap
call fcn.0040c670
add esp, 0x10
push dword [esi]
push 1
push dword [esi + 8]
push ebx
call fcn.0054b005
add esp, 0x10
cmp eax, 1
mov eax, dword [esp + 0xc]
sete bl
test eax, eax
je 0x40eecc
push eax
call fcn.0053edaa
add esp, 4
test bl, bl
je 0x40ef0f
mov eax, dword [esi + 8]
add dword [esi + 0x14], eax
cmp dword [esi + 0x4c], 8
push 0xffffffffffffffff
push dword [esi + 0x1c]
push ecx
lea ecx, [esi + 0x38]
mov eax, esp
jb 0x40eee9
mov ecx, dword [ecx]
mov dword [eax], ecx
mov edx, 0x18
push ecx
mov ecx, esp
mov dword [ecx], str.write
lea ecx, [esi + 0x20]
call fcn.0040c670
add esp, 0x10
mov al, bl
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
mov ecx, esi
call fcn.0040e050
pop edi
pop esi
mov al, bl
pop ebx
mov esp, ebp
pop ebp
ret 8