Function at 0x40efb0
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x8c
mov edx, dword [esp + 0xa4]
mov esi, dword [esp + 0xa0]
movzx ecx, word [edx]
mov word [esp + 0x40], cx
movzx eax, word [edx + 2]
lea edx, [esp + 0x44]
mov word [esp + 0x42], ax
mov eax, 6
lea esi, [esi]
lea edi, [edi]
mov word [edx], 0
add edx, 2
dec eax
jns 0x40eff0
mov ecx, dword [esp + 0xa4]
xor eax, eax
mov ebx, 6
add ecx, 4
mov dword [esp + 0x18], ecx
movzx edx, word [ecx]
test dl, 1
je 0x40f01b
or eax, 1
shr edx, 1
test al, 2
je 0x40f027
or edx, 0xffff8000
mov word [ecx], dx
add eax, eax
add ecx, 2
dec ebx
movzx eax, ax
jns 0x40f010
movzx ebp, word [esi + 6]
add esi, 0x10
mov ebx, dword [esp + 0xa4]
mov dword [esp + 0x10], esi
mov esi, dword [esp + 0xa4]
mov edi, 2
mov dword [esp + 0x1c], ebp
add ebx, 6
add esi, 0x10
mov dword [esp + 8], edi
mov dword [esp + 0xc], esi
mov dword [esp + 0x14], ebx
lea esi, [esi]
mov esi, dword [esp + 0xa4]
mov ebp, 0xffff
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x1c]
movzx ebx, word [esi + 4]
shl eax, 0x10
sub eax, ecx
movzx edx, word [esi + 6]
shl ebx, 0x10
lea edx, [ebx + edx]
cmp eax, edx
jb 0x40f0a6
mov eax, edx
xor edx, edx
div dword [esp + 0x1c]
movzx ebp, ax
mov word [esp + 0x2e], 0
mov esi, dword [esp + 0x10]
lea ebx, [esp + 0x30]
mov word [esp + 0x30], 0
mov edi, 5
jmp 0x40f0d2
sub ebx, 2
sub esi, 2
dec edi
mov word [ebx - 2], 0
js 0x40f10b
movzx eax, word [esi]
test ax, ax
je 0x40f0c3
movzx edx, word [ebx]
movzx ecx, ax
imul ecx, ebp
sub esi, 2
movzx eax, cx
add eax, edx
mov word [ebx], ax
shr ecx, 0x10
sub ebx, 2
shr eax, 0x10
add eax, ecx
movzx ecx, word [ebx]
add eax, ecx
mov word [ebx], ax
shr eax, 0x10
dec edi
mov word [ebx - 2], ax
jns 0x40f0d2
mov edx, 2
movzx edi, word [esp + edx*2 + 0x20]
mov word [esp + edx*2 + 0x60], di
inc edx
cmp edx, 8
jle 0x40f110
mov ecx, dword [esp + 0x18]
lea esi, [esp + 0x64]
mov ebx, 2
lea esi, [esi]
movzx edx, word [ecx]
add ecx, 2
movzx eax, word [esi]
add esi, 2
cmp ax, dx
jne 0x40f223
inc ebx
cmp ebx, 8
jle 0x40f130
mov ecx, dword [esp + 0xc]
lea esi, [esp + 0x70]
xor edi, edi
mov ebx, 6
lea esi, [esi]
movzx edx, word [esi]
movzx eax, word [ecx]
sub eax, edx
sub eax, edi
mov word [ecx], ax
test eax, 0x10000
setne dl
sub esi, 2
sub ecx, 2
dec ebx
movzx edi, dl
jns 0x40f160
mov esi, dword [esp + 8]
mov ebx, 5
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x14]
mov word [esp + esi*2 + 0x40], bp
mov esi, esi
lea edi, [edi]
movzx ebp, word [edx]
add edx, 2
mov word [ecx], bp
add ecx, 2
dec ebx
jns 0x40f1a0
inc dword [esp + 8]
mov eax, dword [esp + 0x18]
cmp dword [esp + 8], 8
mov word [eax + 0xc], 0
jle 0x40f070
mov edx, eax
xor ebx, ebx
mov ecx, 6
jmp 0x40f1e0
movzx edi, word [edx]
add edx, 2
or ebx, edi
dec ecx
jns 0x40f1e0
test ebx, ebx
je 0x40f1f4
mov ebx, 1
xor edx, edx
lea esi, [esi]
lea edi, [edi]
movzx eax, word [esp + edx*2 + 0x40]
mov ecx, dword [esp + 0xa4]
mov word [ecx + edx*2], ax
inc edx
cmp edx, 8
jle 0x40f200
add esp, 0x8c
mov eax, ebx
pop ebx
pop esi
pop edi
pop ebp
ret
movzx ebx, word [ecx - 2]
cmp word [esi - 2], bx
jbe 0x40f14b
mov ecx, dword [esp + 0x10]
lea esi, [ebp - 1]
xor edi, edi
movzx ebp, si
lea ebx, [esp + 0x70]
mov esi, 6
lea esi, [esi]
lea edi, [edi]
movzx edx, word [ecx]
movzx eax, word [ebx]
sub eax, edx
sub eax, edi
mov word [ebx], ax
test eax, 0x10000
setne dl
sub ecx, 2
sub ebx, 2
dec esi
movzx edi, dl
jns 0x40f250
lea esi, [esp + 0x64]
mov ecx, dword [esp + 0x18]
mov ebx, 2
movzx edi, word [ecx]
movzx eax, word [esi]
add ecx, 2
add esi, 2
cmp ax, di
jne 0x40f2aa
inc ebx
cmp ebx, 8
jg 0x40f14b
movzx edi, word [ecx]
add ecx, 2
movzx eax, word [esi]
add esi, 2
cmp ax, di
je 0x40f28f
movzx ebx, word [ecx - 2]
cmp word [esi - 2], bx
jbe 0x40f14b
lea ecx, [ebp - 1]
xor edi, edi
movzx ebp, cx
mov ecx, dword [esp + 0x10]
lea ebx, [esp + 0x70]
mov esi, 6
movzx edx, word [ecx]
movzx eax, word [ebx]
sub eax, edx
sub eax, edi
mov word [ebx], ax
test eax, 0x10000
setne dl
sub ecx, 2
sub ebx, 2
dec esi
movzx edi, dl
jns 0x40f2cd
jmp 0x40f14b