Function at 0x508080
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff8
push ebx
push esi
push edi
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
test byte [edi + 0x18], 1
jne 0x50809f
mov eax, 0x2d5
jmp 0x5082a5
cmp dword [ebp + 0x14], 0
je 0x5080b0
cmp dword [ebp + 0x10], 0
jne 0x5080b0
xor edx, edx
mov dword [edi + 8], edx
mov ax, word [esi + 4]
cmp ax, 0x30
ja 0x5080e1
mov edx, dword [edi + 4]
mov ecx, dword [edx + 0x22c]
cmp ecx, dword [esi + 0x18]
jb 0x5080e1
movzx eax, ax
movzx edx, word [esi + 6]
add edx, edx
add eax, edx
add eax, 7
and eax, 0xfffffff8
movzx ecx, word [esi + 0x14]
cmp eax, ecx
je 0x5080eb
mov eax, 0x5e9
jmp 0x5082a5
xor edx, edx
mov dword [ebp - 8], edx
mov ax, word [esi + 0x14]
test ax, ax
je 0x508107
mov edx, dword [edi + 4]
mov ecx, dword [edx + 0x22c]
cmp ecx, dword [esi + 0x18]
jae 0x508111
mov eax, 0x5e9
jmp 0x5082a5
movzx edx, ax
mov ebx, edx
mov dword [ebp - 4], edx
add ebx, esi
jmp 0x50823f
mov eax, ebx
sub eax, esi
mov dword [ebp - 4], eax
mov edx, dword [esi + 0x18]
sub edx, 8
cmp edx, dword [ebp - 4]
jbe 0x50815a
mov ecx, dword [edi + 4]
mov eax, dword [ecx + 0x22c]
sub eax, 8
cmp eax, dword [ebp - 4]
jbe 0x50815a
cmp word [ebx + 4], 0x10
jb 0x50815a
mov edx, dword [edi + 4]
mov cx, word [edx + 0x22c]
cmp cx, word [ebx + 4]
jae 0x508164
mov eax, 0x5e9
jmp 0x5082a5
cmp byte [ebx + 8], 1
jbe 0x508174
mov eax, 0x60a
jmp 0x5082a5
cmp dword [ebx], 0x20
jne 0x5081a5
cmp dword [ebp + 0x10], 0
je 0x508189
mov eax, 0x608
jmp 0x5082a5
cmp dword [ebp + 0x14], 0
je 0x5081a5
mov dword [edi + 8], ebx
push edi
call fcn.005082ac
pop ecx
test eax, eax
jne 0x5082a5
or dword [edi + 0x18], 0x20
xor eax, eax
mov al, byte [ebx + 9]
add eax, eax
cmp byte [ebx + 8], 0
jne 0x5081e3
movzx edx, word [ebx + 0x14]
lea ecx, [eax + 7]
and ecx, 0xfffffff8
add ecx, 0x18
cmp edx, ecx
jne 0x5081d9
mov edx, dword [ebx + 0x10]
add edx, 7
and edx, 0xfffffff8
add eax, edx
add eax, 0x18
movzx ecx, word [ebx + 4]
cmp eax, ecx
jbe 0x508214
mov eax, 0x5e9
jmp 0x5082a5
movzx edx, word [ebx + 0x20]
lea ecx, [eax + 0x40]
cmp edx, ecx
jb 0x50820a
test eax, eax
je 0x508200
movzx edx, word [ebx + 0xa]
add eax, edx
movzx ecx, word [ebx + 0x20]
cmp eax, ecx
ja 0x50820a
mov ax, word [ebx + 0x20]
cmp ax, word [ebx + 4]
jbe 0x508214
mov eax, 0x5e9
jmp 0x5082a5
mov eax, dword [ebx]
cmp eax, dword [ebp - 8]
jae 0x508225
mov eax, 0x609
jmp 0x5082a5
mov dx, word [ebx + 0xe]
cmp dx, word [esi + 0x28]
jb 0x508236
mov eax, 0x60e
jmp 0x5082a5
mov dword [ebp - 8], eax
movzx edx, word [ebx + 4]
add ebx, edx
cmp dword [ebx], 0xffffffff
jne 0x508120
mov ecx, dword [ebp - 4]
add ecx, 8
cmp ecx, dword [esi + 0x18]
jbe 0x50825a
mov eax, 0x5e9
jmp 0x5082a5
cmp dword [ebp + 0x10], 0
je 0x5082a3
push esi
call fcn.0050b920
pop ecx
test eax, eax
je 0x50829c
cmp word [esi + 0x24], 0
jne 0x50829c
mov edx, dword [edi + 0x14]
cmp edx, dword [esi + 0x20]
jne 0x50829c
cmp dword [edi + 0x3c], 0
jne 0x50828f
push 0x698e57
call fcn.004adfc8
pop ecx
xor ecx, ecx
jmp 0x508292
mov ecx, dword [edi + 0x34]
mov ax, word [ecx + 0x10]
cmp ax, word [esi + 0x26]
je 0x5082a3
mov eax, 0x5f0
jmp 0x5082a5
xor eax, eax
pop edi
pop esi
pop ebx
pop ecx
pop ecx
pop ebp
ret