Function at 0x40c8f0
Capabilities:
Enumerate pe sections

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x2c
mov cx, word [eax + 4]
push ebx
push ebp
push esi
push edi
mov di, word [eax + 6]
mov eax, dword [esp + 0x50]
and eax, 0xff
and eax, 0x800000ff
jns 0x40c91a
dec eax
or eax, 0xffffff00
inc eax
mov edx, dword [esp + 0x44]
mov esi, dword [esp + 0x48]
mov byte [esp + 0x50], al
mov eax, dword [edx]
cmp eax, esi
jle 0x40c934
sub eax, esi
mov dword [esp + 0x44], eax
jmp 0x40c93c
mov dword [esp + 0x44], 0
mov eax, dword [edx + 8]
mov ebx, ecx
and ebx, 0xffff
mov dword [esp + 0x20], ebx
lea ecx, [ebx + esi]
cmp eax, ecx
jge 0x40c95a
sub eax, esi
mov dword [esp + 0x48], eax
jmp 0x40c95e
mov dword [esp + 0x48], ebx
mov eax, dword [esp + 0x48]
mov ecx, dword [esp + 0x44]
cmp ecx, eax
jge 0x40cb0f
mov ecx, dword [edx + 4]
mov eax, dword [esp + 0x4c]
cmp ecx, eax
jle 0x40c97d
sub ecx, eax
jmp 0x40c97f
xor ecx, ecx
mov edx, dword [edx + 0xc]
and edi, 0xffff
mov dword [esp + 0x28], edi
lea ebp, [edi + eax]
cmp edx, ebp
jge 0x40c997
sub edx, eax
jmp 0x40c999
mov edx, edi
add eax, ecx
mov ebp, dword [esp + 0x44]
imul eax, dword [0x557ce4]
shr ebx, 1
mov dword [esp + 0x1c], ebx
mov ebx, edi
shr ebx, 1
add eax, ebp
mov dword [esp + 0x24], ebx
mov ebx, dword [esp + 0x40]
add eax, esi
mov esi, dword [0xc32ffc]
lea edi, [ebx + edi*2 + 8]
lea ebx, [esi + eax*2]
mov eax, dword [esp + 0x50]
and eax, 0xff
mov dword [esp + 0x2c], edi
shl eax, 2
cmp ecx, edx
mov esi, dword [eax + 0x56e888]
mov ebp, dword [eax + 0x56ec88]
mov dword [esp + 0x30], esi
jge 0x40cb0f
mov eax, ebp
mov edi, esi
imul edi, dword [esp + 0x44]
imul eax, ecx
add eax, edi
mov dword [esp + 0x50], eax
mov eax, esi
neg eax
imul esi, ecx
mov dword [esp + 0x38], eax
mov eax, ebp
imul eax, dword [esp + 0x44]
sub eax, esi
sub edx, ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], edx
mov edi, dword [esp + 0x48]
mov ecx, dword [esp + 0x44]
mov esi, eax
mov eax, dword [esp + 0x50]
mov dword [esp + 0x34], ebx
mov dword [esp + 0x4c], esi
mov dword [esp + 0x10], eax
sub edi, ecx
mov ecx, dword [esp + 0x1c]
sar esi, 0x10
add esi, ecx
js 0x40cab9
cmp esi, dword [esp + 0x20]
jge 0x40cab9
mov ecx, eax
mov eax, dword [esp + 0x24]
sar ecx, 0x10
sub eax, ecx
js 0x40cab9
cmp eax, dword [esp + 0x28]
jge 0x40cab9
mov ecx, dword [esp + 0x40]
xor edx, edx
mov dx, word [ecx + eax*2 + 8]
mov eax, dword [esp + 0x2c]
lea eax, [eax + edx*2]
mov dx, word [eax]
mov cx, word [eax + 2]
add eax, 2
add eax, 2
test cx, cx
je 0x40cab9
and edx, 0xffff
sub esi, edx
js 0x40cab9
and ecx, 0xffff
cmp esi, ecx
jl 0x40cab2
mov dx, word [eax + ecx*2]
lea eax, [eax + ecx*2]
add eax, 2
sub esi, ecx
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x40ca85
jmp 0x40cab9
mov cx, word [eax + esi*2]
mov word [ebx], cx
mov esi, dword [esp + 0x4c]
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x30]
add esi, ebp
add eax, ecx
add ebx, 2
dec edi
mov dword [esp + 0x4c], esi
mov dword [esp + 0x10], eax
jne 0x40ca3d
mov edx, dword [0x557ce4]
mov eax, dword [esp + 0x34]
mov esi, dword [esp + 0x38]
mov ecx, dword [esp + 0x18]
lea ebx, [eax + edx*2]
mov eax, dword [esp + 0x14]
mov edx, dword [esp + 0x50]
add eax, esi
add edx, ebp
dec ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x50], edx
mov dword [esp + 0x18], ecx
jne 0x40ca21
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x2c
ret