Function at 0x475c70
Capabilities:
Enumerate pe sections
Get file size
Read file on windows

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x50b3f5
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x30
mov eax, dword [0x542040]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, ecx
mov dword [ebp - 0x3c], eax
xorps xmm0, xmm0
xor edi, edi
movlpd qword [ebp - 0x20], xmm0
mov dword [ebp - 0x1c], edi
push edi
push 0x80
push 3
push edi
push 7
push SysReAllocString
push eax
mov dword [ebp - 4], edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
je 0x476084
push edi
push edi
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [ebp - 0x24], esi
mov dword [ebp - 0x20], esi
test esi, esi
jne 0x475d01
or eax, 0xffffffff
mov dword [ebp - 0x34], eax
jmp 0x475d1b
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 0x34], eax
cmp eax, 0xffffffff
jne 0x475d1b
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [ebp - 0x34]
push eax
call fcn.004ef75c
mov edi, eax
add esp, 4
mov dword [ebp - 0x38], edi
test edi, edi
je 0x476081
test esi, esi
je 0x476081
mov eax, dword [ebp - 0x34]
test eax, eax
jle 0x476081
push 0
lea ecx, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push ecx
push eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x476081
mov esi, dword [edi + 0x3c]
add esi, edi
mov dword [ebp - 0x18], esi
movzx ecx, word [esi + 4]
mov eax, ecx
mov dword [ebp - 0x40], eax
movzx eax, word [esi + 6]
lea edx, [eax + eax*2]
mov eax, 0x8664
shl edx, 4
add edx, 0x288
mov dword [ebp - 0x28], edx
push edx
cmp cx, ax
jne 0x475e61
lea eax, [esi + 0x108]
mov dword [ebp - 0x30], eax
call fcn.004ef75c
mov edx, eax
add esp, 4
mov dword [ebp - 0x2c], edx
test edx, edx
je 0x476081
mov eax, dword [ebp - 0x28]
mov ecx, 0x3c
mov dword [edx + 8], eax
mov dword [edx], 0
mov eax, dword [esi + 0x50]
mov dword [edx + 4], eax
movups xmm0, xmmword [edi]
movups xmmword [edx + 0x1c], xmm0
movups xmm0, xmmword [edi + 0x10]
movups xmmword [edx + 0x2c], xmm0
movups xmm0, xmmword [edi + 0x20]
movups xmmword [edx + 0x3c], xmm0
movups xmm0, xmmword [edi + 0x30]
lea edi, [edx + 0x154]
movups xmmword [edx + 0x4c], xmm0
mov eax, dword [esi]
mov dword [edx + 0x5c], eax
movups xmm0, xmmword [esi + 4]
movups xmmword [edx + 0x60], xmm0
mov eax, dword [esi + 0x14]
add esi, 0x18
mov dword [edx + 0x70], eax
xor eax, eax
rep movsd dword es:[edi], dword [esi]
mov edi, dword [ebp - 0x18]
lea ecx, [edx + 0x258]
mov dword [edx + 0xc], 1
cmp ax, word [edi + 6]
jae 0x475f27
mov esi, dword [ebp - 0x30]
xor edx, edx
movups xmm0, xmmword [esi]
inc edx
lea ecx, [ecx + 0x30]
lea esi, [esi + 0x28]
movups xmmword [ecx - 0x30], xmm0
movups xmm0, xmmword [esi - 0x18]
movups xmmword [ecx - 0x20], xmm0
movq xmm0, qword [esi - 8]
movq qword [ecx - 0x10], xmm0
mov eax, dword [ecx - 0x1c]
mov dword [ecx - 8], eax
mov eax, dword [ecx - 0x20]
mov dword [ecx - 4], eax
movzx eax, word [edi + 6]
cmp edx, eax
jl 0x475e28
jmp 0x475f24
lea eax, [esi + 0xf8]
mov dword [ebp - 0x30], eax
call fcn.004ef75c
mov edx, eax
add esp, 4
mov dword [ebp - 0x2c], edx
test edx, edx
je 0x476081
mov eax, dword [ebp - 0x28]
mov ecx, 0x38
mov dword [edx + 8], eax
mov dword [edx], 0
mov eax, dword [esi + 0x50]
mov dword [edx + 4], eax
movups xmm0, xmmword [edi]
movups xmmword [edx + 0x1c], xmm0
movups xmm0, xmmword [edi + 0x10]
movups xmmword [edx + 0x2c], xmm0
movups xmm0, xmmword [edi + 0x20]
movups xmmword [edx + 0x3c], xmm0
movups xmm0, xmmword [edi + 0x30]
lea edi, [edx + 0x74]
movups xmmword [edx + 0x4c], xmm0
mov eax, dword [esi]
mov dword [edx + 0x5c], eax
movups xmm0, xmmword [esi + 4]
movups xmmword [edx + 0x60], xmm0
mov eax, dword [esi + 0x14]
add esi, 0x18
mov dword [edx + 0x70], eax
xor eax, eax
rep movsd dword es:[edi], dword [esi]
mov edi, dword [ebp - 0x18]
lea ecx, [edx + 0x258]
mov dword [edx + 0xc], 0
cmp ax, word [edi + 6]
jae 0x475f27
mov esi, dword [ebp - 0x30]
xor edx, edx
nop dword [eax]
movups xmm0, xmmword [esi]
inc edx
lea ecx, [ecx + 0x30]
lea esi, [esi + 0x28]
movups xmmword [ecx - 0x30], xmm0
movups xmm0, xmmword [esi - 0x18]
movups xmmword [ecx - 0x20], xmm0
movq xmm0, qword [esi - 8]
movq qword [ecx - 0x10], xmm0
mov eax, dword [ecx - 0x1c]
mov dword [ecx - 8], eax
mov eax, dword [ecx - 0x20]
mov dword [ecx - 4], eax
movzx eax, word [edi + 6]
cmp edx, eax
jl 0x475ef0
mov edx, dword [ebp - 0x2c]
mov edi, dword [ebp - 0x38]
mov ecx, 0x8664
mov dword [edx + 0x10], 1
push 0x40
push 0x3000
mov esi, dword [edi + 0x3c]
add esi, edi
mov dword [ebp - 0x18], edi
lea eax, [esi + 6]
mov dword [ebp - 0x30], eax
mov eax, dword [esi + 0x50]
push eax
push 0
cmp word [esi + 4], cx
jne 0x475f75
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
push dword [esi + 0x54]
mov dword [ebp - 0x28], eax
push edi
push eax
call fcn.004def30
mov eax, dword [ebp - 0x30]
lea edx, [esi + 0x108]
jmp 0x475f91
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
push dword [esi + 0x54]
mov dword [ebp - 0x28], eax
push edi
push eax
call fcn.004def30
lea edx, [esi + 0xf8]
lea eax, [esi + 6]
movzx eax, word [eax]
lea ecx, [ebp - 0x18]
add esp, 0xc
push eax
push edx
push dword [ebp - 0x28]
call fcn.0047bd10
mov esi, dword [ebp - 0x2c]
mov edx, 0x8664
mov eax, dword [ebp - 0x28]
mov ecx, 0x52d798
cmp word [ebp - 0x40], dx
push dword [ebp - 0x3c]
mov dword [esi + 0x14], eax
mov eax, dword [ebp - 0x34]
mov dword [esi], eax
mov eax, 0x52d7f0
cmovne eax, ecx
mov dword [esi + 0x18], edi
push eax
lea eax, [ebp - 0x18]
push 0x52d7c0
push eax
call fcn.004483d0
add esp, 0x10
mov dword [ebp - 0x40], eax
mov byte [ebp - 4], 1
mov eax, dword [eax]
test eax, eax
je 0x476031
or esi, 0xffffffff
cmp dword [eax], 0xffffffff
cmovb esi, dword [eax]
mov ecx, esi
call fcn.00425b20
add esi, esi
mov edx, eax
xor eax, eax
mov dword [ebp - 0x3c], edx
mov edi, edx
push esi
lea ecx, [esi + 2]
shr ecx, 1
shr ecx, 1
rep stosd dword es:[edi], eax
adc ecx, ecx
rep stosw word es:[edi], ax
mov eax, dword [ebp - 0x40]
mov eax, dword [eax]
push dword [eax + 8]
push edx
call fcn.004def30
mov esi, dword [ebp - 0x2c]
add esp, 0xc
mov edi, dword [ebp - 0x38]
mov eax, dword [ebp - 0x3c]
mov dword [esi + 0x244], eax
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x476058
add dword [eax + 4], 0xffffffff
jne 0x476058
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x476058
push eax
call fcn.004eb01a
add esp, 4
mov dword [esi + 0x248], 0
mov dword [esi + 0x24c], 0
mov eax, dword [edi + 0x3c]
mov edi, dword [ebp - 0x24]
cdq
mov dword [esi + 0x250], eax
mov dword [esi + 0x254], edx
jmp 0x476086
mov edi, dword [ebp - 0x24]
xor esi, esi
test edi, edi
je 0x476091
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004dadd7
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret