Function at 0x1000fca0
Capabilities:
Enumerate pe sections
Write file on windows

Disassembly:
sub esp, 0x80c
push ebx
push ebp
mov ebp, dword [esp + 0x820]
push esi
push edi
xor edi, edi
mov eax, dword [ebp + 0x91a]
mov dword [esp + 0x14], edi
cmp eax, edi
mov dword [esp + 0x10], edi
jne 0x1000fcdd
mov ebx, dword [esp + 0x820]
lea eax, [esp + 0x1c]
push eax
mov ecx, dword [ebx + 0x54]
push ecx
call dword [sym.imp.USER32.dll_CharToOemA]
jmp 0x1000fcf3
mov ebx, dword [esp + 0x820]
lea eax, [esp + 0x1c]
mov edx, dword [ebx + 0x54]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
cmp dword [ebp + 0x91e], edi
je 0x1000fd62
mov ecx, dword [ebx + 0x24]
mov dword [esp + 0x10], 0x14
add ecx, 0x14
push ecx
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
add esp, 4
cmp eax, edi
mov dword [esp + 0x14], eax
je 0x1001018c
mov word [eax], 1
mov word [eax + 2], 0x10
mov edx, dword [ebx + 0x18]
mov dword [eax + 4], edx
mov ecx, dword [ebx + 0x1c]
mov dword [eax + 8], ecx
mov edx, dword [ebx + 0x10]
mov dword [eax + 0xc], edx
mov ecx, dword [ebx + 0x14]
mov dword [eax + 0x10], ecx
mov ecx, dword [ebx + 0x24]
cmp ecx, edi
jbe 0x1000fd5e
mov esi, dword [ebx + 0x48]
mov edx, eax
mov eax, ecx
lea edi, [edx + 0x14]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x14]
mov eax, dword [ebp + 0xa2]
push ebp
cmp eax, 0xffffffff
jne 0x1000ff55
mov ecx, dword [ebp + 0x4e74]
mov edx, dword [esp + 0x14]
mov eax, dword [ebx + 0x24]
push 0
neg ecx
sbb ecx, ecx
and edx, 0xffff
and ecx, 0xc
add ecx, edx
mov edx, dword [esp + 0x82c]
add ecx, eax
mov eax, dword [ebx + 0x20]
lea ecx, [ecx + eax + 0x1e]
push ecx
push edx
push ebx
call fcn.1000bdd0
add esp, 0x14
test eax, eax
je 0x1000fdd6
test edi, edi
je 0x1000fdbc
push edi
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
mov eax, dword [ebp + 0x9a]
pop edi
neg eax
sbb eax, eax
pop esi
and al, 0xf6
pop ebp
add eax, 0x13
pop ebx
add esp, 0x80c
ret
mov eax, dword [ebp + 0x91e]
mov ebp, dword [ebx + 0x24]
mov ecx, dword [ebx + 0x20]
neg eax
sbb eax, eax
and eax, 0x14
add eax, ebp
lea edx, [eax + ecx + 0x1f]
push edx
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
mov ebp, eax
add esp, 4
test ebp, ebp
je 0x1000ff48
mov dword [ebp], 0x4034b50
mov ax, word [ebx + 2]
mov word [ebp + 4], ax
mov cx, word [ebx + 0x36]
mov word [ebp + 6], cx
mov dx, word [ebx + 6]
mov word [ebp + 8], dx
mov eax, dword [ebx + 8]
mov edx, dword [esp + 0x828]
mov dword [ebp + 0xa], eax
mov ecx, dword [ebx + 0xc]
mov dword [ebp + 0xe], ecx
mov eax, dword [edx + 0x91e]
test eax, eax
je 0x1000fe4b
lea ecx, [ebp + 0x12]
or eax, 0xffffffff
mov dword [ecx], eax
mov dword [ecx + 4], eax
jmp 0x1000fe57
mov eax, dword [ebx + 0x10]
mov dword [ebp + 0x12], eax
mov ecx, dword [ebx + 0x18]
mov dword [ebp + 0x16], ecx
mov ax, word [ebx + 0x20]
mov esi, dword [esp + 0x10]
mov word [ebp + 0x1a], ax
mov cx, word [ebx + 0x24]
add esi, ecx
lea edi, [ebp + 0x1e]
mov ax, si
mov dword [esp + 0x10], esi
mov word [ebp + 0x1c], ax
sub ax, word [ebx + 0x24]
mov ecx, dword [ebx + 0x20]
lea esi, [esp + 0x1c]
mov word [esp + 0x10], ax
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [edx + 0x91e]
test eax, eax
mov eax, dword [esp + 0x10]
je 0x1000feb6
mov esi, dword [ebx + 0x24]
mov ecx, eax
and ecx, 0xffff
add ecx, esi
mov esi, dword [esp + 0x14]
jmp 0x1000fec0
mov ecx, dword [ebx + 0x24]
test ecx, ecx
jbe 0x1000fed5
mov esi, dword [ebx + 0x48]
mov edx, dword [ebx + 0x20]
lea edi, [edx + ebp + 0x1e]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebx + 0x24]
mov edx, dword [ebx + 0x20]
mov esi, eax
lea eax, [esp + 0x18]
and esi, 0xffff
push 0
add ecx, esi
push eax
lea eax, [ecx + edx + 0x1e]
mov ecx, dword [esp + 0x82c]
push eax
push ebp
mov edx, dword [ecx]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x1000ff1e
mov eax, dword [ebx + 0x24]
mov ecx, dword [ebx + 0x20]
add eax, esi
lea edx, [eax + ecx + 0x1e]
mov eax, dword [esp + 0x18]
cmp eax, edx
je 0x10010117
push ebp
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov eax, dword [esp + 0x18]
add esp, 4
test eax, eax
je 0x1000ff38
push eax
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
pop edi
pop esi
pop ebp
mov eax, 0xa
pop ebx
add esp, 0x80c
ret
test edi, edi
je 0x1001018c
jmp 0x10010183
call fcn.1000c660
mov esi, eax
mov eax, dword [ebp + 0x4e74]
add esp, 4
mov ecx, edx
mov edx, dword [esp + 0x10]
neg eax
sbb eax, eax
and edx, 0xffff
and eax, 0xc
add eax, edx
mov edx, dword [ebx + 0x24]
add eax, edx
mov edx, dword [ebx + 0x20]
lea eax, [eax + edx + 0x1e]
cdq
cmp ecx, edx
jg 0x1000ffc2
jl 0x1000ff91
cmp esi, eax
jae 0x1000ffc2
mov eax, dword [esp + 0x824]
push ebp
push eax
call fcn.1000c760
mov esi, eax
add esp, 8
test esi, esi
je 0x1000ffc2
test edi, edi
je 0x1000ffb5
push edi
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x80c
ret
mov ecx, dword [ebp + 0x91e]
mov esi, dword [ebx + 0x24]
mov edx, dword [ebx + 0x20]
neg ecx
sbb ecx, ecx
and ecx, 0x14
add ecx, esi
lea eax, [ecx + edx + 0x1f]
push eax
call sub.api_ms_win_crt_heap_l1_1_0.dll_malloc
mov ebp, eax
add esp, 4
test ebp, ebp
je 0x1001017f
mov dword [ebp], 0x4034b50
mov cx, word [ebx + 2]
mov word [ebp + 4], cx
mov dx, word [ebx + 0x36]
mov word [ebp + 6], dx
mov ax, word [ebx + 6]
mov word [ebp + 8], ax
mov ecx, dword [ebx + 8]
mov dword [ebp + 0xa], ecx
mov edx, dword [ebx + 0xc]
mov dword [ebp + 0xe], edx
mov edx, dword [esp + 0x828]
mov eax, dword [edx + 0x91e]
test eax, eax
je 0x10010037
lea ecx, [ebp + 0x12]
or eax, 0xffffffff
mov dword [ecx], eax
mov dword [ecx + 4], eax
jmp 0x10010043
mov eax, dword [ebx + 0x10]
mov dword [ebp + 0x12], eax
mov ecx, dword [ebx + 0x18]
mov dword [ebp + 0x16], ecx
mov ax, word [ebx + 0x20]
mov word [ebp + 0x1a], ax
mov eax, dword [edx + 0x91e]
test eax, eax
je 0x10010075
mov cx, word [ebx + 0x24]
mov esi, dword [esp + 0x10]
add esi, ecx
mov ax, si
mov dword [esp + 0x10], esi
mov word [ebp + 0x1c], ax
sub ax, word [ebx + 0x24]
mov word [esp + 0x10], ax
jmp 0x1001007d
mov ax, word [ebx + 0x24]
mov word [ebp + 0x1c], ax
mov ecx, dword [ebx + 0x20]
lea esi, [esp + 0x1c]
mov eax, ecx
lea edi, [ebp + 0x1e]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [edx + 0x91e]
test eax, eax
je 0x100100b4
mov ecx, dword [esp + 0x10]
mov esi, dword [ebx + 0x24]
and ecx, 0xffff
add ecx, esi
mov esi, dword [esp + 0x14]
jmp 0x100100be
mov ecx, dword [ebx + 0x24]
test ecx, ecx
jbe 0x100100d3
mov esi, dword [ebx + 0x48]
mov eax, dword [ebx + 0x20]
lea edi, [eax + ebp + 0x1e]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x10]
mov eax, dword [ebx + 0x24]
lea ecx, [esp + 0x18]
and esi, 0xffff
push 0
push ecx
mov ecx, dword [ebx + 0x20]
add eax, esi
lea eax, [eax + ecx + 0x1e]
mov ecx, dword [edx + 0xa2]
push eax
push ebp
push ecx
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
je 0x10010155
mov edx, dword [ebx + 0x24]
mov eax, dword [ebx + 0x20]
add edx, esi
lea ecx, [edx + eax + 0x1e]
mov eax, dword [esp + 0x18]
cmp eax, ecx
jne 0x10010155
push ebp
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov eax, dword [esp + 0x18]
add esp, 4
test eax, eax
je 0x10010141
push eax
mov dword [ebx + 0x5c], esi
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x80c
ret
pop edi
pop esi
mov dword [ebx + 0x5c], 0
pop ebp
xor eax, eax
pop ebx
add esp, 0x80c
ret
mov eax, dword [esp + 0x14]
test eax, eax
je 0x10010166
push eax
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
push ebp
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
mov eax, 0xa
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x80c
ret
test edi, edi
je 0x1001018c
push edi
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
add esp, 4
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
add esp, 0x80c
ret