Function at 0x46c560
Capabilities:
Enumerate pe sections

Disassembly:
push ecx
push ebp
push edi
mov edi, dword [esp + 0x10]
test edi, edi
mov ebp, ecx
mov dword [esp + 8], ebp
jne 0x46c579
pop edi
xor eax, eax
pop ebp
pop ecx
ret 8
mov eax, dword [edi]
mov dword [ebp + 4], eax
mov cx, word [edi + 4]
mov word [ebp + 8], cx
mov dx, word [edi + 6]
mov word [ebp + 0xa], dx
movzx eax, word [edi + 8]
movzx ecx, ax
mov eax, dword [ebp + 0xc]
push ebx
lea ebx, [ebp + 0xc]
sub eax, 0x10
push esi
mov edx, 1
sub edx, dword [eax + 0xc]
mov eax, dword [eax + 8]
mov esi, ecx
shr esi, 1
sub eax, esi
or edx, eax
mov dword [esp + 0x18], ecx
jge 0x46c5c6
mov ecx, esi
mov eax, ebx
call fcn.00404d50
mov ecx, dword [esp + 0x18]
mov edx, dword [ebx]
push ecx
lea ecx, [edi + 0xa]
push ecx
push edx
call fcn.00483140
mov eax, esi
add esp, 0xc
cmp eax, 0xffffffff
jne 0x46c5f5
mov eax, dword [ebx]
test eax, eax
je 0x46c5fd
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x46c5e6
sub eax, edx
sar eax, 1
test eax, eax
jl 0x46c7c7
mov ecx, dword [ebx]
cmp eax, dword [ecx - 8]
jg 0x46c7c7
mov esi, dword [esp + 0x18]
mov dword [ecx - 0xc], eax
mov ecx, dword [ebx]
mov word [ecx + eax*2], 0
movzx eax, word [esi + edi + 0xa]
add esi, 0xa
movzx ecx, ax
mov eax, dword [ebp + 0x10]
add ebp, 0x10
sub eax, 0x10
mov edx, 1
sub edx, dword [eax + 0xc]
mov eax, dword [eax + 8]
mov ebx, ecx
shr ebx, 1
sub eax, ebx
add esi, 2
or edx, eax
mov dword [esp + 0x18], ecx
jge 0x46c654
mov ecx, ebx
mov eax, ebp
call fcn.00404d50
mov ecx, dword [esp + 0x18]
mov edx, dword [ebp]
push ecx
lea ecx, [esi + edi]
push ecx
push edx
call fcn.00483140
add esp, 0xc
cmp ebx, 0xffffffff
jne 0x46c683
mov ebx, dword [ebp]
test ebx, ebx
je 0x46c68b
lea ecx, [ebx + 2]
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x46c674
sub ebx, ecx
sar ebx, 1
test ebx, ebx
jl 0x46c7c7
mov eax, dword [ebp]
cmp ebx, dword [eax - 8]
jg 0x46c7c7
add esi, dword [esp + 0x18]
mov dword [eax - 0xc], ebx
mov eax, dword [ebp]
mov ebp, dword [esp + 0x10]
mov word [eax + ebx*2], 0
movzx eax, word [esi + edi]
movzx ecx, ax
mov eax, dword [ebp + 0x14]
add ebp, 0x14
sub eax, 0x10
mov edx, 1
sub edx, dword [eax + 0xc]
mov eax, dword [eax + 8]
mov ebx, ecx
shr ebx, 1
sub eax, ebx
add esi, 2
or edx, eax
mov dword [esp + 0x18], ecx
jge 0x46c6e4
mov ecx, ebx
mov eax, ebp
call fcn.00404d50
mov ecx, dword [esp + 0x18]
mov edx, dword [ebp]
push ecx
lea ecx, [esi + edi]
push ecx
push edx
call fcn.00483140
add esp, 0xc
cmp ebx, 0xffffffff
jne 0x46c713
mov ebx, dword [ebp]
test ebx, ebx
je 0x46c71b
lea ecx, [ebx + 2]
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x46c704
sub ebx, ecx
sar ebx, 1
test ebx, ebx
jl 0x46c7c7
mov eax, dword [ebp]
cmp ebx, dword [eax - 8]
jg 0x46c7c7
add esi, dword [esp + 0x18]
mov dword [eax - 0xc], ebx
mov eax, dword [ebp]
mov ebp, dword [esp + 0x10]
mov word [eax + ebx*2], 0
movzx eax, word [esi + edi]
movzx ecx, ax
mov eax, dword [ebp + 0x18]
add ebp, 0x18
sub eax, 0x10
mov edx, 1
sub edx, dword [eax + 0xc]
mov eax, dword [eax + 8]
mov ebx, ecx
shr ebx, 1
sub eax, ebx
add esi, 2
or edx, eax
mov dword [esp + 0x18], ecx
jge 0x46c774
mov ecx, ebx
mov eax, ebp
call fcn.00404d50
mov ecx, dword [esp + 0x18]
push ecx
mov ecx, dword [ebp]
add esi, edi
push esi
push ecx
call fcn.00483140
add esp, 0xc
cmp ebx, 0xffffffff
jne 0x46c7a2
mov ebx, dword [ebp]
test ebx, ebx
je 0x46c7a6
lea ecx, [ebx + 2]
mov ax, word [ebx]
add ebx, 2
test ax, ax
jne 0x46c793
sub ebx, ecx
sar ebx, 1
test ebx, ebx
jl 0x46c7c7
mov eax, dword [ebp]
cmp ebx, dword [eax - 8]
jg 0x46c7c7
mov dword [eax - 0xc], ebx
mov edx, dword [ebp]
pop esi
mov word [edx + ebx*2], 0
pop ebx
pop edi
mov eax, 1
pop ebp
pop ecx
ret 8
push 0x80070057
call fcn.00404ef0
int3