joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4209ab
Capabilities:
Parse pe header

Disassembly:
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x4209ea
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x4209ea
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4209ea
mov eax, 0x10b
cmp word [ecx + 0x18], ax
jne 0x4209ea
cmp dword [ecx + 0x74], 0xe
jbe 0x4209ea
cmp dword [ecx + 0xe8], 0
setne al
ret
xor al, al
ret

Function at 0x433160
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
mov ecx, 0x5a4d
cmp word [eax], cx
jne 0x43318d
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x43318d
mov edx, 0x10b
xor eax, eax
cmp word [ecx + 0x18], dx
sete al
pop ebp
ret
xor eax, eax
pop ebp
ret

Function at 0x401050
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [0x40103c]
push esi
push edi
push 0x3f
mov dword [ebp - 0x10c], eax
mov eax, dword [0x401040]
pop ecx
push dword [ebp + 8]
mov dword [ebp - 0x108], eax
xor eax, eax
push eax
lea edi, [ebp - 0x104]
push 0x410
rep stosd dword es:[edi], eax
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov esi, eax
test esi, esi
je 0x4010bc
lea eax, [ebp - 8]
push eax
push 4
lea eax, [ebp - 4]
push eax
push esi
call sub.PSAPI.DLL_EnumProcessModules
test eax, eax
je 0x4010bc
push 0x104
lea eax, [ebp - 0x10c]
push eax
push dword [ebp - 4]
push esi
call sub.PSAPI.DLL_GetModuleBaseNameA
push dword [ebp + 8]
lea eax, [ebp - 0x10c]
push eax
push 0x401024
call sub.msvcrt.dll_printf
add esp, 0xc
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
leave
ret

Function at 0x4010de
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1004
call fcn.00401150
lea eax, [ebp - 4]
push eax
push 0x1000
lea eax, [ebp - 0x1004]
push eax
call sub.PSAPI.DLL_EnumProcesses
test eax, eax
je 0x401125
push esi
mov esi, dword [ebp - 4]
shr esi, 2
push edi
push 0
pop edi
je 0x401123
push dword [ebp + edi*4 - 0x1004]
call fcn.00401050
inc edi
cmp edi, esi
pop ecx
jb 0x401111
pop edi
pop esi
xor eax, eax
leave
ret

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

Disassembly:
pushal
nop
nop
nop
nop
nop
mov eax, section..text
nop
nop
mov ebx, 0x40c7d0
nop
mov ecx, 0x26a608ba
nop
nop
nop
test eax, eax
nop
nop
nop
nop
je 0x43204e
nop
nop
nop
nop
nop
xor dword [eax], ecx
inc eax
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
cmp eax, ebx
nop
nop
nop
nop
jne 0x432024
nop
mov eax, section..reloc
nop
nop
mov ebx, 0x42f314
mov ecx, 0x63402b1a
nop
nop
nop
nop
test eax, eax
nop
nop
je 0x432084
nop
nop
nop
nop
nop
nop
nop
xor dword [eax], ecx
add eax, 4
nop
nop
nop
nop
cmp eax, ebx
nop
nop
nop
nop
nop
nop
nop
jne 0x43206c
nop
popal
nop
nop
nop
nop
jmp 0x431219
Function at 0x4016b0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push esi
mov ebx, ecx
push 2
push 0
push dword [ebx]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fseek]
push dword [ebx]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_ftell]
push 0
push 0
push dword [ebx]
mov esi, eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fseek]
push dword [ebx]
push esi
push 1
push dword [ebp + 8]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
add esp, 0x2c
mov eax, 1
pop esi
pop ebx
pop ebp
ret 8

Function at 0x401830
Capabilities:
Hash data using sha256

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x90
mov eax, dword [0x43d0e4]
xor eax, esp
mov dword [esp + 0x8c], eax
mov edx, dword [ebp + 8]
mov ecx, edx
push esi
push edi
mov edi, dword [ebp + 0xc]
mov dword [esp + 8], 0
lea esi, [ecx + 1]
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0x6a09e667
mov dword [esp + 0x14], 0xbb67ae85
mov dword [esp + 0x18], 0x3c6ef372
mov dword [esp + 0x1c], 0xa54ff53a
mov dword [esp + 0x20], 0x510e527f
mov dword [esp + 0x24], 0x9b05688c
mov dword [esp + 0x28], 0x1f83d9ab
mov dword [esp + 0x2c], 0x5be0cd19
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4018a7
sub ecx, esi
push ecx
lea ecx, [esp + 0xc]
call fcn.00404b30
add esp, 4
lea edx, [esp + 0x74]
lea ecx, [esp + 8]
call fcn.00404be0
mov byte [edi], 0
xor esi, esi
nop
mov eax, edi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4018d5
movzx ecx, byte [esp + esi + 0x74]
sub eax, edx
push ecx
add eax, edi
push str._02x
push eax
call fcn.00401650
inc esi
add esp, 0xc
cmp esi, 0x20
jl 0x4018d0
mov ecx, dword [esp + 0x94]
pop edi
pop esi
xor ecx, esp
call fcn.0042d114
mov esp, ebp
pop ebp
ret

Function at 0x401d80
Capabilities:
Encode data using xor

Disassembly:
push ebx
push esi
push edi
mov edi, edx
xor eax, eax
xor esi, esi
mov ebx, ecx
test edi, edi
jle 0x401da8
nop
movzx edx, byte [esi + ebx]
inc esi
add edx, eax
imul eax, edx, 0x401
mov ecx, eax
shr ecx, 6
xor eax, ecx
cmp esi, edi
jl 0x401d90
lea ecx, [eax + eax*8]
mov eax, ecx
shr eax, 0xb
pop edi
xor eax, ecx
pop esi
imul eax, eax, 0x8001
pop ebx
ret
Function at 0x4052b0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
mov ebx, ecx
push esi
push edi
mov dword [ebp - 8], ebx
cmp byte [ebx + 0x200], 0
mov edx, dword [ebx + 0x208]
mov esi, edx
sete al
xor edi, edi
mov byte [ebx + 0x200], al
lea ecx, [esi + 1]
nop dword [eax + eax]
mov al, byte [esi]
inc esi
test al, al
jne 0x4052e0
sub esi, ecx
mov ecx, dword [ebp + 8]
lea eax, [ecx + 1]
mov dword [ebp - 4], eax
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4052f2
sub ecx, dword [ebp - 4]
add esi, edx
mov dword [ebp - 4], ecx
cmp edx, esi
jae 0x405328
mov bl, dl
mov ecx, dword [ebp + 8]
mov al, dl
sub al, bl
add al, al
add al, byte [edi + ecx]
xor byte [edx], al
lea eax, [edi + 1]
xor edi, edi
inc edx
cmp eax, dword [ebp - 4]
cmovbe edi, eax
cmp edx, esi
jb 0x405307
mov ebx, dword [ebp - 8]
mov eax, dword [ebx + 0x204]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4

Function at 0x405340
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
push esi
push edi
mov edi, ecx
mov ecx, dword [ebp + 8]
mov dword [ebp - 4], edi
cmp byte [edi + 0x200], 0
lea ebx, [ecx + 1]
mov edx, dword [edi + 0x208]
sete al
xor esi, esi
mov byte [edi + 0x200], al
nop word [eax + eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x405370
mov eax, dword [ebp + 0xc]
sub ecx, ebx
lea ebx, [edx + eax]
cmp edx, ebx
jae 0x4053b0
mov edi, dword [ebp + 8]
mov ah, dl
mov byte [ebp + 0xf], ah
nop dword [eax + eax]
mov al, dl
sub al, ah
add al, al
add al, byte [esi + edi]
xor byte [edx], al
lea eax, [esi + 1]
xor esi, esi
inc edx
cmp eax, ecx
cmovbe esi, eax
mov ah, byte [ebp + 0xf]
cmp edx, ebx
jb 0x405390
mov edi, dword [ebp - 4]
mov eax, dword [edi + 0x204]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x405b30
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, dword [ebp + 8]
push edi
mov edi, ecx
mov dword [ebp - 4], edi
test ebx, ebx
je 0x405c64
cmp dword [ebx], 0
je 0x405c64
cmp byte [edi + 0x251], 0
je 0x405b83
push dword [edi + 0x208]
mov byte [edi + 0x251], 0
call fcn.0042df44
push dword [edi + 0x214]
call fcn.0042df44
push dword [edi + 0x220]
call fcn.0042df44
add esp, 0xc
push esi
mov esi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fseek]
push 2
push 0
push dword [ebx]
call esi
push dword [ebx]
mov ebx, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_ftell]
call ebx
add esp, 0x10
add eax, 0xfa00
mov ecx, edi
push eax
call fcn.004056d0
push dword [edi + 0x204]
push 0
push dword [edi + 0x208]
call sub.VCRUNTIME140.dll_memset
push dword [edi + 0x204]
push 0
push dword [edi + 0x214]
call sub.VCRUNTIME140.dll_memset
mov eax, dword [ebp + 8]
mov edi, dword [edi + 0x208]
push 2
push 0
push dword [eax]
call esi
mov eax, dword [ebp + 8]
push dword [eax]
call ebx
mov esi, eax
mov eax, dword [ebp + 8]
push 0
push 0
push dword [eax]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fseek]
mov eax, dword [ebp + 8]
push dword [eax]
push esi
push 1
push edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov edi, dword [ebp + 8]
add esp, 0x44
mov esi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fseek]
push 2
push 0
push dword [edi]
call esi
push dword [edi]
call ebx
mov edi, dword [ebp - 4]
push 2
push 0
mov ecx, dword [edi + 0x208]
mov byte [eax + ecx], 0
mov eax, dword [ebp + 8]
push dword [eax]
call esi
mov eax, dword [ebp + 8]
push dword [eax]
call ebx
add esp, 0x20
mov ecx, edi
push eax
push dword [ebp + 0xc]
call fcn.00405340
mov ecx, edi
call fcn.004067b0
pop esi
pop edi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret 8
pop edi
or eax, 0xffffffff
pop ebx
mov esp, ebp
pop ebp
ret 8
Function at 0x407730
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1c
push ebx
mov ebx, ecx
push esi
push edi
cmp dword [ebx + 0x38], 0
je 0x40775c
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::xsputn_char_const___long_long___int64__]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x20]
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 0x10]
mov dword [esp + 0x20], esi
mov ecx, dword [eax]
lea eax, [ebx + 0x30]
mov dword [esp + 0x24], edi
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], eax
test ecx, ecx
je 0x407784
mov eax, dword [eax]
mov ecx, dword [eax]
jmp 0x40778a
xor ecx, ecx
mov dword [esp + 0x18], eax
mov eax, ecx
cdq
mov dword [esp + 0x10], eax
mov ecx, edx
mov dword [esp + 0x14], ecx
test edi, edi
jl 0x4077f2
jg 0x4077a1
test esi, esi
je 0x4077f2
test ecx, ecx
jl 0x4077ed
jg 0x4077ab
test eax, eax
je 0x4077ed
cmp edi, ecx
jg 0x4077bf
jl 0x4077b5
cmp esi, eax
jae 0x4077bf
mov eax, esi
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], edi
push eax
push dword [ebp + 8]
push dword [esp + 0x24]
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [esp + 0x24]
add esp, 0xc
mov edx, dword [esp + 0x10]
mov ecx, dword [ebp + 8]
add ecx, edx
sub esi, edx
mov eax, dword [eax]
sbb edi, dword [esp + 0x14]
sub dword [eax], edx
mov eax, dword [ebx + 0x20]
add dword [eax], edx
jmp 0x4077f5
mov ecx, dword [ebp + 8]
jmp 0x4077ff
mov ecx, dword [ebp + 8]
test edi, edi
jl 0x407819
jg 0x4077ff
test esi, esi
je 0x407819
mov eax, dword [ebx + 0x4c]
test eax, eax
je 0x407819
push eax
push esi
push 1
push ecx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
sub esi, eax
sbb edi, 0
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
sub eax, esi
sbb edx, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x407830
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
mov eax, dword [ebp + 0x10]
sub esp, 0xc
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 0xc]
push esi
push edi
test eax, eax
jg 0x40785b
jl 0x40784e
test ecx, ecx
jne 0x40785b
xor eax, eax
xor edx, edx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x38], 0
je 0x407877
push eax
push ecx
push dword [ebp + 8]
mov ecx, ebx
call dword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::xsgetn_char___long_long___int64__]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x1c]
mov edi, ecx
mov eax, dword [eax]
mov dword [esp + 0x14], eax
test eax, eax
je 0x4078c9
mov eax, dword [ebx + 0x2c]
lea edx, [ebx + 0x2c]
mov dword [esp + 0x10], edx
mov eax, dword [eax]
test eax, eax
je 0x4078d0
mov edi, dword [ebp + 8]
cmp eax, ecx
mov esi, ecx
cmovb esi, eax
push esi
push dword [esp + 0x18]
push edi
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [ebx + 0x2c]
add edi, esi
mov dword [esp + 0x20], edi
add esp, 0xc
mov edi, dword [ebp + 0xc]
sub edi, esi
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
mov esi, dword [esp + 0x14]
jmp 0x4078d3
lea eax, [ebx + 0x2c]
mov dword [esp + 0x10], eax
mov esi, dword [ebp + 8]
cmp dword [ebx + 0x4c], 0
je 0x407946
mov ecx, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [ecx], eax
jne 0x4078fd
mov eax, dword [ebx + 0xc]
mov edx, dword [ebx + 0x54]
mov ecx, dword [ebx + 0x50]
sub edx, ecx
mov dword [eax], ecx
mov eax, dword [ebx + 0x1c]
mov dword [eax], ecx
mov eax, dword [esp + 0x10]
mov eax, dword [eax]
mov dword [eax], edx
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
cmp edi, 0xfff
jbe 0x407934
nop word [eax + eax]
push dword [ebx + 0x4c]
push 0xfff
push 1
push esi
call eax
add esp, 0x10
add esi, eax
sub edi, eax
cmp eax, 0xfff
jne 0x407946
cmp edi, eax
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
ja 0x407910
test edi, edi
je 0x407946
push dword [ebx + 0x4c]
push edi
push 1
push esi
call eax
add esp, 0x10
sub edi, eax
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
sub eax, edi
pop edi
pop esi
sbb edx, 0
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x407cd0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x43d0e4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp ebx, 0xffffffff
jne 0x407d00
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042d114
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x20]
mov eax, dword [eax]
test eax, eax
je 0x407d30
mov edx, dword [esi + 0x30]
mov edx, dword [edx]
add edx, eax
cmp eax, edx
jae 0x407d30
call dword [sym.imp.MSVCP140.dll_protected:_char____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::_Pninc_void_]
pop esi
mov byte [eax], bl
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042d114
mov esp, ebp
pop ebp
ret 4
cmp dword [esi + 0x4c], 0
push edi
je 0x407e2a
mov edi, dword [esi + 0xc]
lea eax, [esi + 0x3c]
cmp dword [edi], eax
jne 0x407d59
mov edx, dword [esi + 0x54]
mov ecx, dword [esi + 0x50]
sub edx, ecx
mov dword [edi], ecx
mov eax, dword [esi + 0x1c]
mov dword [eax], ecx
mov eax, dword [esi + 0x2c]
mov dword [eax], edx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x407d8d
push dword [esi + 0x4c]
movsx eax, bl
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
add esp, 8
or ecx, 0xffffffff
cmp eax, ecx
cmovne ecx, ebx
pop edi
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042d114
mov esp, ebp
pop ebp
ret 4
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x25], bl
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x25]
push eax
lea eax, [esi + 0x40]
push eax
call dword [sym.imp.MSVCP140.dll_public:_int___thiscall_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet___char_const___char_const___char_const____char___char___char___const]
sub eax, 0
je 0x407de9
sub eax, 1
je 0x407de9
sub eax, 2
jne 0x407e2a
mov edx, dword [esi + 0x4c]
mov cl, byte [ebp - 0x25]
call fcn.00405220
or ecx, 0xffffffff
test al, al
pop edi
cmovne ecx, ebx
pop esi
mov eax, ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042d114
mov esp, ebp
pop ebp
ret 4
mov edi, dword [ebp - 0x2c]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x407e07
push dword [esi + 0x4c]
push edi
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
cmp edi, eax
jne 0x407e2a
lea ecx, [ebp - 0x25]
mov byte [esi + 0x3d], 1
or eax, 0xffffffff
cmp dword [ebp - 0x30], ecx
pop edi
pop esi
cmovne eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042d114
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebp - 4]
or eax, 0xffffffff
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0042d114
mov esp, ebp
pop ebp
ret 4
Function at 0x408470
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov eax, dword [0x43d0e4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
cmp dword [esi + 0x38], 0
je 0x40852c
cmp byte [esi + 0x3d], 0
je 0x40852c
mov eax, dword [esi]
push edi
push 0xffffffffffffffff
call dword [eax + 0xc]
cmp eax, 0xffffffff
je 0x40851a
mov ecx, dword [esi + 0x38]
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [esi + 0x40]
push eax
call dword [sym.imp.MSVCP140.dll_public:_int___thiscall_std::codecvt_char__char__struct__Mbstatet_::unshift_struct__Mbstatet___char___char___char___const]
sub eax, 0
je 0x4084e1
sub eax, 1
je 0x4084e5
sub eax, 2
jne 0x40851a
mov byte [esi + 0x3d], al
mov al, 1
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042d114
mov esp, ebp
pop ebp
ret
mov byte [esi + 0x3d], 0
mov edi, dword [ebp - 0x28]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x408503
push dword [esi + 0x4c]
push edi
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
cmp edi, eax
jne 0x40851a
cmp byte [esi + 0x3d], 0
pop edi
sete al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042d114
mov esp, ebp
pop ebp
ret
pop edi
xor al, al
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042d114
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov al, 1
xor ecx, ebp
pop esi
call fcn.0042d114
mov esp, ebp
pop ebp
ret
Function at 0x409640
Capabilities:
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push ecx
cmp dword [0x4746c0], 0
push ebx
push esi
push edi
mov esi, ecx
jne 0x4096b1
push str.ADVAPI32.DLL
mov dword [0x4746dc], 0xc
mov dword [0x4746e4], 0
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
test edi, edi
je 0x4096a7
push str.ConvertStringSecurityDescriptorToSecurityDescriptorW
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push edi
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
test ebx, ebx
je 0x4096a7
push 0
push 0x4746e0
push 1
push 0x435090
call ebx
mov dword [0x4746c0], eax
jmp 0x4096b1
mov dword [0x4746e0], 0
mov ecx, dword [esi + 8]
imul ecx, dword [esi + 0xc]
push dword [esi + 4]
mov eax, dword [esi + 0x10]
lea eax, [ecx + eax*4]
push eax
push 0
push 4
push 0x4746dc
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov dword [esi + 0x18], eax
test eax, eax
je 0x409793
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
je 0x409793
mov ecx, dword [esi + 8]
imul ecx, dword [esi + 0xc]
mov eax, dword [esi + 0x10]
lea eax, [ecx + eax*4]
push eax
push 0
push 0
push 6
push dword [esi + 0x18]
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [esi + 0x1c], eax
test eax, eax
je 0x409793
mov ecx, dword [esi + 0xc]
xor edi, edi
test ecx, ecx
jle 0x40975b
mov edx, dword [esi + 8]
lea ebx, [edi + 1]
mov eax, dword [esi + 0x1c]
imul edx, ebx
add eax, edx
mov dword [ebp - 4], eax
lea eax, [ecx - 1]
xor ecx, ecx
cmp edi, eax
cmovne ecx, edx
mov edx, dword [ebp - 4]
mov dword [edx - 4], ecx
test edi, edi
jne 0x409748
mov edi, dword [esi + 0xc]
lea eax, [edi - 1]
mov edi, ebx
imul eax, dword [esi + 8]
mov dword [edx - 8], eax
mov ecx, dword [esi + 0xc]
cmp edi, ecx
jl 0x409720
mov eax, dword [esi + 8]
imul eax, ecx
xor ecx, ecx
add eax, dword [esi + 0x1c]
mov dword [esi + 0x14], eax
cmp dword [esi + 0x10], ecx
jle 0x409780
nop
mov eax, dword [esi + 0x14]
mov dword [eax + ecx*4], 0xffffffff
inc ecx
cmp ecx, dword [esi + 0x10]
jl 0x409770
mov eax, dword [esi + 0x14]
pop edi
mov dword [eax], 0
mov eax, dword [esi + 0x1c]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4097a0
Capabilities:
Read file via mapping

Disassembly:
push esi
mov esi, ecx
push dword [esi + 4]
push 1
push 6
call dword [sym.imp.KERNEL32.dll_OpenFileMappingA]
mov edx, eax
mov dword [esi + 0x18], edx
test edx, edx
je 0x4097e9
mov ecx, dword [esi + 0xc]
imul ecx, dword [esi + 8]
mov eax, dword [esi + 0x10]
lea eax, [ecx + eax*4]
push eax
push 0
push 0
push 6
push edx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [esi + 0x1c], eax
test eax, eax
je 0x4097e9
mov ecx, dword [esi + 8]
imul ecx, dword [esi + 0xc]
add ecx, eax
mov dword [esi + 0x14], ecx
pop esi
ret
xor eax, eax
pop esi
ret
Function at 0x409ef0
Capabilities:
Check if file exists
Enumerate files on windows
Enumerate files recursively

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x354
mov eax, dword [0x43d0e4]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
mov esi, ecx
push edi
mov edi, dword [ebp + 8]
test esi, esi
je 0x40a0ea
push ebx
push 0x104
lea eax, [ebp - 0x20c]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
mov ebx, dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy]
lea eax, [ebp - 0x20c]
push 0x103
push esi
push eax
call ebx
add esp, 0x18
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x40a0e9
push edi
push esi
call fcn.0040a250
add esp, 8
lea eax, [ebp - 0x20c]
push 0x43518c
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendA]
lea eax, [ebp - 0x34c]
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
mov dword [ebp - 0x350], eax
cmp eax, 0xffffffff
je 0x40a0e2
nop dword [eax]
lea ecx, [ebp - 0x34c]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
je 0x40a0d6
push 0x104
lea eax, [ebp - 0x108]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
test byte [ebp - 0x34c], 0x10
je 0x40a095
add esp, 0xc
lea eax, [ebp - 0x320]
mov ecx, 0x435190
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x409ff4
test dl, dl
je 0x409ff0
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x409ff4
add eax, 2
add ecx, 2
test dl, dl
jne 0x409fd4
xor eax, eax
jmp 0x409ff9
sbb eax, eax
or eax, 1
test eax, eax
mov eax, dword [ebp - 0x350]
je 0x409f90
mov eax, 0x435194
lea ecx, [ebp - 0x320]
nop
mov dl, byte [ecx]
cmp dl, byte [eax]
jne 0x40a030
test dl, dl
je 0x40a02c
mov dl, byte [ecx + 1]
cmp dl, byte [eax + 1]
jne 0x40a030
add ecx, 2
add eax, 2
test dl, dl
jne 0x40a010
xor eax, eax
jmp 0x40a035
sbb eax, eax
or eax, 1
test eax, eax
mov eax, dword [ebp - 0x350]
je 0x409f90
push 0x103
lea eax, [ebp - 0x108]
push esi
push eax
call ebx
add esp, 0xc
lea eax, [ebp - 0x320]
push eax
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendA]
lea eax, [ebp - 0x108]
push edi
push eax
call fcn.0040a250
push edi
mov edx, fcn.0040a250
lea ecx, [ebp - 0x108]
call fcn.00409ef0
mov eax, dword [ebp - 0x350]
add esp, 0xc
jmp 0x409f90
push 0x103
lea eax, [ebp - 0x108]
push esi
push eax
call ebx
add esp, 0x18
lea eax, [ebp - 0x320]
push eax
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendA]
lea eax, [ebp - 0x108]
push edi
push eax
call fcn.0040a250
mov eax, dword [ebp - 0x350]
add esp, 8
jmp 0x409f90
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [ebp - 0x350]
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
pop ebx
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.0042d114
mov esp, ebp
pop ebp
ret