Function at 0x515a76
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x3c
mov ebx, dword [esp + 0x50]
mov eax, dword [esp + 0x58]
mov edx, dword [esp + 0x5c]
mov ebp, dword [esp + 0x54]
mov esi, dword [ebx + 0x30]
mov ecx, dword [ebx + 0x38]
mov byte [esp + 0x1c], al
mov byte [esp + 0x18], dl
xor edx, edx
mov edi, dword [ebx + 0x34]
mov eax, esi
add eax, ecx
setb dl
mov byte [esp + 0x2e], ah
mov byte [esp + 0x2f], al
cmp edx, 1
sbb edi, 0xffffffff
mov edx, edi
mov dword [esp + 0x10], edi
shr edx, 0x18
mov byte [esp + 0x28], dl
mov edx, dword [esp + 0x10]
shr edx, 0x10
mov byte [esp + 0x29], dl
mov edx, dword [esp + 0x10]
mov byte [esp + 0x2a], dh
mov byte [esp + 0x2b], dl
mov edx, eax
shr edx, 0x18
mov byte [esp + 0x2c], dl
mov edx, eax
shr edx, 0x10
cmp ecx, 0x1b8
mov byte [esp + 0x2d], dl
je 0x515e56
cmp ecx, 0x1b7
jg 0x515d86
test ecx, ecx
je 0x515d76
sub eax, 0x1b8
mov dword [ebx + 0x30], eax
mov eax, 0x1b8
mov dword [esp + 4], 0x4c0c20
sub eax, ecx
mov dword [esp], ebx
mov dword [esp + 8], eax
sar eax, 0x1f
mov dword [esp + 0xc], eax
call fcn.00515516
lea ecx, [esp + 0x18]
mov dword [esp + 8], 8
mov dword [esp + 0xc], 0
mov dword [esp], ebx
mov dword [esp + 4], ecx
call fcn.00515516
mov edi, dword [ebx + 0x30]
sub edi, 8
mov eax, dword [ebx + 0x38]
sub edi, 0x40
lea esi, [ebx + 0x40]
mov dword [ebx + 0x30], edi
mov ecx, eax
sar ecx, 3
test ecx, ecx
je 0x515b96
mov edi, 0x40
sub edi, ecx
add ecx, esi
cmp edi, 8
jbe 0x515de6
and eax, 0xfffffff8
mov esi, ecx
mov edx, 8
add eax, 0x40
lea edi, [esp + 0x28]
jmp 0x515ba4
lea edi, [esp + 0x28]
mov eax, 0x40
mov edx, 8
mov ecx, dword [edi]
mov dword [esi], ecx
mov ecx, dword [edi + edx - 4]
mov dword [esi + edx - 4], ecx
lea ecx, [esi + 4]
and ecx, 0xfffffffc
sub esi, ecx
add edx, esi
sub edi, esi
and edx, 0xfffffffc
cmp edx, 4
jb 0x515c98
mov dword [esp + 0x10], edx
lea esi, [edx - 1]
mov edx, dword [edi]
shr esi, 2
mov dword [ecx], edx
and esi, 7
mov edx, 4
cmp edx, dword [esp + 0x10]
jae 0x515c98
test esi, esi
je 0x515c51
cmp esi, 1
je 0x515c42
cmp esi, 2
je 0x515c39
cmp esi, 3
je 0x515c30
cmp esi, 4
je 0x515c27
cmp esi, 5
je 0x515c1e
cmp esi, 6
je 0x515c15
mov esi, dword [edi + 4]
mov edx, 8
mov dword [ecx + 4], esi
mov esi, dword [edi + edx]
mov dword [ecx + edx], esi
add edx, 4
mov esi, dword [edi + edx]
mov dword [ecx + edx], esi
add edx, 4
mov esi, dword [edi + edx]
mov dword [ecx + edx], esi
add edx, 4
mov esi, dword [edi + edx]
mov dword [ecx + edx], esi
add edx, 4
mov esi, dword [edi + edx]
mov dword [ecx + edx], esi
add edx, 4
mov esi, dword [edi + edx]
mov dword [ecx + edx], esi
add edx, 4
cmp edx, dword [esp + 0x10]
jae 0x515c98
mov esi, dword [edi + edx]
mov dword [ecx + edx], esi
mov esi, dword [edi + edx + 4]
mov dword [ecx + edx + 4], esi
mov esi, dword [edi + edx + 8]
mov dword [ecx + edx + 8], esi
mov esi, dword [edi + edx + 0xc]
mov dword [ecx + edx + 0xc], esi
mov esi, dword [edi + edx + 0x10]
mov dword [ecx + edx + 0x10], esi
mov esi, dword [edi + edx + 0x14]
mov dword [ecx + edx + 0x14], esi
mov esi, dword [edi + edx + 0x18]
mov dword [ecx + edx + 0x18], esi
mov esi, dword [edi + edx + 0x1c]
mov dword [ecx + edx + 0x1c], esi
add edx, 0x20
cmp edx, dword [esp + 0x10]
jb 0x515c51
mov dword [ebx + 0x38], eax
mov ecx, dword [ebx]
shr ecx, 0x18
mov byte [ebp], cl
mov edx, dword [ebx]
shr edx, 0x10
mov byte [ebp + 1], dl
mov eax, dword [ebx]
mov byte [ebp + 2], ah
mov ecx, dword [ebx]
mov byte [ebp + 3], cl
movzx edx, byte [ebx + 7]
mov byte [ebp + 4], dl
movzx eax, word [ebx + 6]
mov byte [ebp + 5], al
mov ecx, dword [ebx + 4]
mov byte [ebp + 6], ch
mov edx, dword [ebx + 4]
mov byte [ebp + 7], dl
movzx eax, byte [ebx + 0xb]
mov byte [ebp + 8], al
movzx ecx, word [ebx + 0xa]
mov byte [ebp + 9], cl
mov edx, dword [ebx + 8]
mov byte [ebp + 0xa], dh
mov eax, dword [ebx + 8]
mov byte [ebp + 0xb], al
movzx ecx, byte [ebx + 0xf]
mov byte [ebp + 0xc], cl
movzx edx, word [ebx + 0xe]
mov byte [ebp + 0xd], dl
mov eax, dword [ebx + 0xc]
mov byte [ebp + 0xe], ah
mov ecx, dword [ebx + 0xc]
mov byte [ebp + 0xf], cl
movzx edx, byte [ebx + 0x13]
mov byte [ebp + 0x10], dl
movzx eax, word [ebx + 0x12]
mov byte [ebp + 0x11], al
mov ecx, dword [ebx + 0x10]
mov byte [ebp + 0x12], ch
mov edx, dword [ebx + 0x10]
mov byte [ebp + 0x13], dl
movzx eax, byte [ebx + 0x17]
mov byte [ebp + 0x14], al
movzx ecx, word [ebx + 0x16]
mov byte [ebp + 0x15], cl
mov edx, dword [ebx + 0x14]
mov byte [ebp + 0x16], dh
mov eax, dword [ebx + 0x14]
mov byte [ebp + 0x17], al
movzx ecx, byte [ebx + 0x1b]
mov byte [ebp + 0x18], cl
movzx edx, word [ebx + 0x1a]
mov byte [ebp + 0x19], dl
mov eax, dword [ebx + 0x18]
mov byte [ebp + 0x1a], ah
mov ecx, dword [ebx + 0x18]
mov byte [ebp + 0x1b], cl
movzx edx, byte [ebx + 0x1f]
mov byte [ebp + 0x1c], dl
movzx eax, word [ebx + 0x1e]
mov byte [ebp + 0x1d], al
mov ecx, dword [ebx + 0x1c]
mov byte [ebp + 0x1e], ch
mov ebx, dword [ebx + 0x1c]
mov byte [ebp + 0x1f], bl
add esp, 0x3c
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [ebx + 0x3c], 1
jmp 0x515b0b
mov esi, 0x200
sub eax, 0x200
sub esi, ecx
mov dword [ebx + 0x30], eax
mov dword [esp + 4], 0x4c0c20
mov dword [esp + 8], esi
sar esi, 0x1f
mov dword [esp], ebx
mov dword [esp + 0xc], esi
call fcn.00515516
sub dword [ebx + 0x30], 0x1b8
mov dword [esp + 8], 0x1b8
mov dword [esp + 0xc], 0
mov dword [esp + 4], 0x4c0c21
mov dword [esp], ebx
call fcn.00515516
mov dword [ebx + 0x3c], 1
jmp 0x515b35
lea eax, [esp + 0x28]
mov dword [esp + 8], edi
mov dword [esp], ecx
mov dword [esp + 4], eax
call fcn.00587fb6
add dword [ebx + 0x30], 0x200
jne 0x515e07
add dword [ebx + 0x34], 1
mov dword [esp + 4], esi
mov dword [esp], ebx
call fcn.005148c6
lea ecx, [edi*8]
mov eax, 0x40
mov dword [esp + 0x10], ecx
sar ecx, 0x1f
mov dword [esp + 0x14], ecx
xor ecx, ecx
sub eax, dword [esp + 0x10]
sbb ecx, dword [esp + 0x14]
mov edx, eax
mov dword [esp + 0x10], eax
mov eax, ecx
mov dword [esp + 0x14], ecx
or eax, edx
jne 0x515e84
mov dword [ebx + 0x38], 0
jmp 0x515c9b
lea edx, [esp + 0x1c]
sub esi, 8
mov dword [ebx + 0x30], esi
mov dword [esp + 8], 8
mov dword [esp + 0xc], 0
mov dword [esp + 4], edx
mov dword [esp], ebx
call fcn.00515516
mov edi, dword [ebx + 0x30]
jmp 0x515b5b
lea eax, [esp + 0x28]
shrd edx, ecx, 3
add edi, eax
mov eax, dword [esp + 0x10]
cmp edx, 4
jae 0x515ba4
test edx, edx
je 0x515c98
movzx ecx, byte [edi]
test dl, 2
mov byte [esi], cl
je 0x515c98
movzx edi, word [edi + edx - 2]
mov word [esi + edx - 2], di
jmp 0x515c98