Function at 0x1004fd30
Capabilities:
Enumerate pe sections

Disassembly:
sub esp, 8
mov ecx, dword [esp + 0x14]
mov eax, ecx
push ebx
mov ebx, dword [esp + 0x10]
push ebp
mov ebp, dword [esp + 0x18]
push esi
shl eax, 4
lea esi, [ebx + 0x1c]
cmp dword [ebx + 0x6c], 0
push edi
mov dword [esp + 0x20], esi
mov dword [esp + 0x10], eax
je 0x1004fded
mov edi, dword [ebx + 0xc]
mov edx, edi
sub edi, dword [esi]
sub edx, eax
mov dword [esp + 0x14], edi
xor edi, edi
test byte [ebp + 0x22], 0xa
jne 0x1004fd99
mov eax, dword [ebp]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
cmp byte [eax + 7], 0
je 0x1004fd8e
mov edi, dword [ebp + 0x18]
movzx ecx, byte [eax + 6]
inc edi
add edi, ecx
mov ecx, dword [esp + 0x24]
mov eax, dword [ebp + 4]
cmp dword [ebx + 0xc], eax
jae 0x1004fd99
mov dword [ebx + 0xc], eax
mov eax, dword [ebx + 0x6c]
test al, 2
je 0x1004fdc1
shl edi, 4
add dword [ebp], edi
sub edx, dword [ebp]
push ecx
sar edx, 4
movzx eax, dx
push eax
push 0xffffffffffffffff
push 1
push ebx
call fcn.1004faf0
add esp, 0x14
sub dword [ebp], edi
mov ecx, dword [ebp + 8]
test byte [ecx + 0x22], 2
jne 0x1004fdde
mov eax, dword [ecx]
mov ecx, dword [ecx + 0x10]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
sub ecx, dword [eax + 0x34]
sar ecx, 2
dec ecx
mov dword [ebx + 0x60], ecx
mov eax, dword [esi]
add eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x24]
mov dword [ebx + 0xc], eax
jmp 0x1004fdf5
mov dword [esp + 0x20], esi
mov dword [esp + 0x10], eax
mov eax, dword [ebp + 8]
mov dword [ebx + 0x14], eax
movsx edi, word [ebp + 0x20]
mov ebp, dword [ebp]
cmp edi, 0xffffffff
je 0x1004fe91
test edi, edi
je 0x1004fe86
cmp edi, 1
je 0x1004fe49
cmp edi, 0xffffffff
jge 0x1004fe93
mov eax, dword [esp + 0x20]
mov esi, ebp
push 0
push ebp
push ebx
sub esi, dword [eax]
call fcn.1005e900
mov eax, dword [esp + 0x2c]
add esp, 0xc
mov ebp, dword [eax]
mov eax, 0xfffffffd
sub eax, edi
add ebp, esi
mov edi, eax
cmp edi, 0xffffffff
jne 0x1004fe93
mov edi, dword [esp + 0x24]
jmp 0x1004fe93
test ecx, ecx
jne 0x1004fe60
pop edi
xor al, al
mov byte [ebp + 8], al
lea eax, [ebp + 0x10]
pop esi
pop ebp
mov dword [ebx + 0xc], eax
pop ebx
add esp, 8
ret
mov edx, dword [ebx + 0xc]
sub edx, dword [esp + 0x10]
pop edi
pop esi
mov eax, dword [edx]
mov ecx, dword [edx + 4]
mov dword [ebp], eax
mov dword [ebp + 4], ecx
mov al, byte [edx + 8]
mov byte [ebp + 8], al
lea eax, [ebp + 0x10]
pop ebp
mov dword [ebx + 0xc], eax
pop ebx
add esp, 8
ret
pop edi
pop esi
mov dword [ebx + 0xc], ebp
pop ebp
pop ebx
add esp, 8
ret
mov edi, ecx
mov ebx, dword [ebx + 0xc]
xor esi, esi
sub ebx, dword [esp + 0x10]
cmp dword [esp + 0x24], esi
jle 0x1004fed5
mov eax, ebx
lea edx, [ebp + 8]
sub eax, ebp
mov dword [esp + 0x20], eax
nop dword [eax]
cmp esi, edi
jge 0x1004fef2
mov eax, dword [ebx]
inc esi
mov ecx, dword [ebx + 4]
add ebx, 0x10
mov dword [edx - 8], eax
mov eax, dword [esp + 0x20]
mov dword [edx - 4], ecx
mov al, byte [eax + edx]
mov byte [edx], al
add edx, 0x10
cmp esi, dword [esp + 0x24]
jl 0x1004feb0
cmp esi, edi
jge 0x1004fef2
mov eax, esi
mov ecx, edi
shl eax, 4
add eax, 8
add eax, ebp
sub ecx, esi
mov byte [eax], 0
lea eax, [eax + 0x10]
sub ecx, 1
jne 0x1004fee7
mov eax, dword [esp + 0x1c]
shl edi, 4
add edi, ebp
mov dword [eax + 0xc], edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret