Function at 0x52cf80
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
push ecx
push esi
push edi
push 0x36
mov esi, ecx
call fcn.005261a0
mov ecx, dword [ebp + 8]
add esp, 4
add ecx, 4
mov dword [esi + 4], eax
mov dword [ebp + 8], ecx
push 0x36
mov edx, dword [ecx]
push eax
call dword [edx]
mov edx, dword [esi + 4]
mov edi, 0x100
movzx ecx, byte [edx]
movzx eax, byte [edx + 1]
imul ecx, edi
add cx, ax
mov word [esi + 8], cx
movzx ecx, byte [edx + 5]
movzx eax, byte [edx + 4]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 3]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 2]
shl ecx, 8
add ecx, eax
mov dword [esi + 0xc], ecx
movzx ecx, byte [edx + 7]
movzx eax, byte [edx + 6]
imul ecx, edi
add cx, ax
mov word [esi + 0x10], cx
movzx ecx, byte [edx + 9]
movzx eax, byte [edx + 8]
imul ecx, edi
add cx, ax
mov word [esi + 0x12], cx
movzx ecx, byte [edx + 0xd]
movzx eax, byte [edx + 0xc]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0xb]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0xa]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x14], ecx
movzx ecx, byte [edx + 0x11]
movzx eax, byte [edx + 0x10]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0xf]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0xe]
shl ecx, 8
add eax, ecx
mov dword [esi + 0x18], eax
cmp eax, 0x28
je 0x52d06f
push str.Error_parsing_v3.x_header___file_is_probably_corrupt.
push 0x1297040
call fcn.004342ce
push eax
call fcn.0046a3cf
add esp, 0xc
xor eax, eax
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4
movzx ecx, byte [edx + 0x15]
shl ecx, 8
movzx eax, byte [edx + 0x14]
add ecx, eax
movzx eax, byte [edx + 0x13]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x12]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x1c], ecx
movzx ecx, byte [edx + 0x19]
shl ecx, 8
movzx eax, byte [edx + 0x18]
add ecx, eax
movzx eax, byte [edx + 0x17]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x16]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x20], ecx
movzx ecx, byte [edx + 0x1b]
imul ecx, edi
movzx eax, byte [edx + 0x1a]
add cx, ax
mov word [esi + 0x24], cx
movzx ecx, byte [edx + 0x1d]
movzx eax, byte [edx + 0x1c]
imul ecx, edi
add cx, ax
mov word [esi + 0x26], cx
movzx ecx, byte [edx + 0x21]
movzx eax, byte [edx + 0x20]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x1f]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x1e]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x28], ecx
movzx ecx, byte [edx + 0x25]
movzx eax, byte [edx + 0x24]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x23]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x22]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x2c], ecx
movzx ecx, byte [edx + 0x29]
movzx eax, byte [edx + 0x28]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x27]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x26]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x30], ecx
movzx ecx, byte [edx + 0x2d]
movzx eax, byte [edx + 0x2c]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x2b]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x2a]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x34], ecx
movzx ecx, byte [edx + 0x31]
movzx eax, byte [edx + 0x30]
shl ecx, 8
add ecx, eax
shl ecx, 8
movzx eax, byte [edx + 0x2f]
add ecx, eax
movzx eax, byte [edx + 0x2e]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x38], ecx
movzx ecx, byte [edx + 0x35]
movzx eax, byte [edx + 0x34]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x33]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x32]
shl ecx, 8
add ecx, eax
cmp dword [esi + 0x38], 0
mov dword [esi + 0x3c], ecx
jne 0x52d209
movzx ecx, word [esi + 0x26]
cmp ecx, 0x10
jae 0x52d209
mov edx, dword [esi + 0x14]
mov eax, 1
sub edx, 0x36
shl eax, cl
shr edx, 2
mov dword [esi + 0x50], edx
cmp edx, eax
je 0x52d209
push edx
push 0x821ef0
push 0
push str._WARNING:__Calculated_number_of_Palette_entries___Colors_Used__using_calculated__mColorsUsed_:_mPaletteEntries___
push 0x1296f90
call fcn.004342ce
add esp, 8
mov ecx, eax
call fcn.004b3be3
push eax
call fcn.004342ce
add esp, 8
mov ecx, eax
call fcn.004b3cec
push eax
call fcn.0046a3cf
mov eax, dword [esi + 0x50]
add esp, 4
mov dword [esi + 0x38], eax
movzx ecx, word [esi + 0x26]
cmp ecx, 0x10
jae 0x52d2b0
mov eax, 1
push ebx
mov ebx, dword [esi + 0x50]
shl eax, cl
cmp ebx, eax
je 0x52d228
mov ebx, dword [esi + 0x38]
xor ecx, ecx
lea edi, [ebx*4]
mov eax, ebx
mov edx, 4
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.005261a0
mov dword [esi + 0x4c], eax
mov eax, edi
imul eax, ebx
push eax
call fcn.005261a0
mov ecx, dword [ebp + 8]
add esp, 8
mov dword [ebp - 4], eax
mov edx, dword [ecx]
push edi
mov edi, eax
push edi
call dword [edx]
xor edx, edx
test ebx, ebx
jle 0x52d2a3
nop dword [eax]
mov ecx, dword [esi + 0x4c]
movzx eax, byte [edi + edx*4]
mov byte [ecx + edx*4], al
mov ecx, dword [esi + 0x4c]
movzx eax, byte [edi + edx*4 + 1]
mov byte [ecx + edx*4 + 1], al
mov ecx, dword [esi + 0x4c]
movzx eax, byte [edi + edx*4 + 2]
mov byte [ecx + edx*4 + 2], al
mov ecx, dword [esi + 0x4c]
movzx eax, byte [edi + edx*4 + 3]
mov byte [ecx + edx*4 + 3], al
inc edx
cmp edx, ebx
jl 0x52d270
push edi
mov dword [esi + 0x50], ebx
call fcn.00529880
add esp, 4
pop ebx
mov eax, dword [esi + 0x20]
test eax, eax
jns 0x52d2c9
neg eax
mov dword [esi + 0x20], eax
mov eax, 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret 4
pop edi
mov byte [esi + 0x44], 0
mov eax, 1
pop esi
mov esp, ebp
pop ebp
ret 4