Function at 0x47f520
Capabilities:
Check if file exists
Get file attributes
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4cfd2b
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
push ebx
push esi
push edi
mov eax, dword [0x50ac94]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
lea eax, [edi + 0x70]
xor ebx, ebx
push eax
mov dword [ebp - 4], ebx
call fcn.00482640
mov byte [ebp - 4], 1
call fcn.0049ff8a
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x47f577
push 0x80004005
call fcn.00421000
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [edi + 0x8c], eax
push ecx
mov byte [ebp - 4], 2
mov esi, esp
mov dword [ebp - 0x20], esp
mov dword [ebp - 0x24], esi
call fcn.0049ff8a
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x47f5b0
push 0x80004005
call fcn.00421000
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esi], eax
mov eax, str..dat
shr eax, 0x10
mov byte [ebp - 4], 3
mov dword [ebp - 0x1c], eax
cmp eax, ebx
jne 0x47f76f
mov ecx, str..dat
movzx ebx, cx
push ebx
call fcn.004a7eac
mov dword [ebp - 0x14], eax
test eax, eax
je 0x47f6bc
mov edx, ebx
shr edx, 4
inc edx
movzx ecx, dx
push 6
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindResourceW]
test eax, eax
je 0x47f6bc
mov edx, dword [ebp - 0x14]
push ebx
push eax
push edx
call fcn.004216d6
mov edx, eax
add esp, 0xc
mov dword [ebp - 0x14], edx
test edx, edx
je 0x47f6bc
mov eax, dword [esi]
movzx ebx, word [edx]
sub eax, 0x10
mov ecx, 1
sub ecx, dword [eax + 0xc]
mov eax, dword [eax + 8]
sub eax, ebx
or eax, ecx
jge 0x47f648
push ebx
mov ecx, esi
call fcn.004214f5
mov edx, dword [ebp - 0x14]
mov eax, dword [esi]
mov dword [ebp - 0x18], eax
movzx eax, word [edx]
lea ecx, [edx + 2]
mov dword [ebp - 0x14], ecx
cmp eax, 0xffffffff
jne 0x47f668
push ecx
call fcn.004ae67a
mov ecx, dword [ebp - 0x14]
add esp, 4
inc eax
add eax, eax
push eax
push ecx
mov ecx, dword [ebp - 0x18]
lea edx, [ebx + ebx]
push edx
push ecx
mov dword [ebp - 0x14], edx
call fcn.004ae100
add esp, 0x10
cmp eax, 0x50
ja case.0x47f856.1
movzx edx, byte [eax + 0x47fa74]
jmp dword [edx*4 + 0x47fa64]
call fcn.004a04f2
test ebx, ebx
jl 0x47f765
mov eax, dword [esi]
cmp ebx, dword [eax - 8]
jg 0x47f765
mov edx, dword [ebp - 0x14]
mov dword [eax - 0xc], ebx
mov eax, dword [esi]
xor ecx, ecx
mov word [edx + eax], cx
xor ebx, ebx
mov byte [ebp - 4], 4
mov eax, dword [ebp + 0xc]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x24], esp
mov esi, esp
push eax
call fcn.00424240
add eax, 0x10
mov dword [esi], eax
lea eax, [ebp - 0x10]
add esp, 4
push eax
mov byte [ebp - 4], 2
call fcn.00468a50
mov ecx, dword [ebp - 0x10]
add esp, 0xc
push ecx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
xor edx, edx
cmp eax, 0xffffffff
mov eax, dword [ebp - 0x10]
setne dl
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
mov esi, edx
mov edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x47f721
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp esi, ebx
je 0x47f9f4
push ecx
mov ecx, esp
mov dword [ebp - 0x24], esp
push str.constructor:_separate_data_file_found
push ecx
call fcn.00468700
add esp, 8
call fcn.0047f450
push ecx
mov esi, esp
mov dword [ebp - 0x24], esp
mov dword [ebp - 0x10], esi
call fcn.0049ff8a
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x47f78e
push 0x80004005
call fcn.00421000
push 0x80070057
call fcn.00421000
push str..dat
call fcn.004ae67a
add esp, 4
push eax
push str..dat
mov ecx, esi
call fcn.004241cf
jmp 0x47f6be
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [esi], eax
mov byte [ebp - 4], 5
cmp dword [ebp - 0x1c], ebx
jne 0x47f888
mov ecx, str..dat
movzx esi, cx
push esi
call fcn.004a7eac
mov ebx, eax
test ebx, ebx
je 0x47f8a2
mov edx, esi
shr edx, 4
inc edx
movzx eax, dx
push 6
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_FindResourceW]
test eax, eax
je 0x47f8a2
push esi
push eax
push ebx
call fcn.004216d6
mov ebx, eax
add esp, 0xc
test ebx, ebx
je 0x47f8a2
mov edx, dword [ebp - 0x10]
mov eax, dword [edx]
movzx esi, word [ebx]
sub eax, 0x10
mov ecx, 1
sub ecx, dword [eax + 0xc]
mov eax, dword [eax + 8]
sub eax, esi
or eax, ecx
jge 0x47f818
push esi
mov ecx, edx
call fcn.004214f5
mov edx, dword [ebp - 0x10]
movzx eax, word [ebx]
mov ecx, dword [edx]
add ebx, 2
mov dword [ebp - 0x1c], ecx
cmp eax, 0xffffffff
jne 0x47f832
push ebx
call fcn.004ae67a
add esp, 4
inc eax
lea edx, [eax + eax]
mov eax, dword [ebp - 0x1c]
push edx
lea ecx, [esi + esi]
push ebx
push ecx
push eax
mov dword [ebp - 0x18], ecx
call fcn.004ae100
add esp, 0x10
cmp eax, 0x50
ja case.0x47f856.1
movzx ecx, byte [eax + 0x47fad8]
jmp dword [ecx*4 + 0x47fac8]
call fcn.004a052a
test esi, esi
jl 0x47f765
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx]
cmp esi, dword [eax - 8]
jg 0x47f765
mov dword [eax - 0xc], esi
mov edx, dword [ecx]
mov ecx, dword [ebp - 0x18]
xor eax, eax
mov word [ecx + edx], ax
jmp 0x47f8a2
push str..dat
call fcn.004ae67a
add esp, 4
push eax
push str..dat
mov ecx, esi
call fcn.004241cf
mov byte [ebp - 4], 6
mov eax, dword [ebp + 0xc]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x20], esp
mov esi, esp
push eax
call fcn.00424240
add eax, 0x10
lea edx, [ebp - 0x14]
add esp, 4
mov dword [esi], eax
push edx
mov byte [ebp - 4], 2
call fcn.00468a50
add esp, 0xc
mov byte [ebp - 4], 7
mov ecx, dword [eax]
mov esi, dword [edi + 0x8c]
lea ebx, [edi + 0x8c]
lea eax, [ecx - 0x10]
sub esi, 0x10
cmp eax, esi
je 0x47f933
cmp dword [esi + 0xc], 0
jl 0x47f927
mov edx, dword [eax]
cmp edx, dword [esi]
jne 0x47f927
push eax
call fcn.00424240
mov dword [ebp - 0x1c], eax
add esp, 4
lea eax, [esi + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x47f91d
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
mov ecx, dword [ebp - 0x1c]
add ecx, 0x10
mov dword [ebx], ecx
jmp 0x47f933
mov eax, dword [ecx - 0xc]
push eax
push ecx
mov ecx, ebx
call fcn.004241cf
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x47f956
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor ebx, ebx
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp + 0x14]
lea ecx, [edi + 0x40]
push ecx
mov dword [edi], 0xffffffff
mov dword [edi + 4], ebx
mov dword [edi + 8], ebx
mov dword [edi + 0xc], ebx
mov dword [edi + 0x10], edx
mov dword [edi + 0x68], ebx
mov dword [edi + 0x6c], ebx
mov dword [edi + 0x18], ebx
mov dword [edi + 0x1c], ebx
mov dword [edi + 0x20], ebx
mov dword [edi + 0x28], ebx
mov dword [edi + 0x2c], ebx
mov dword [edi + 0x30], ebx
mov dword [edi + 0x34], ebx
mov dword [edi + 0x88], ebx
mov dword [edi + 0x38], ebx
mov dword [edi + 0x3c], eax
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov ecx, dword [edi + 0x5c]
xor edx, edx
mov eax, 0x400000
div ecx
imul eax, ecx
mov dword [edi + 0x64], eax
call fcn.00480050
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 0xc]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x47f9de
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x10
mov eax, dword [ebp + 0xc]
mov esi, dword [edi + 0x8c]
lea ecx, [edi + 0x8c]
add eax, 0xfffffff0
sub esi, 0x10
cmp eax, esi
je 0x47f958
cmp dword [esi + 0xc], ebx
jl 0x47fa52
mov edx, dword [eax]
cmp edx, dword [esi]
jne 0x47fa52
push eax
call fcn.00424240
mov dword [ebp - 0x1c], eax
add esp, 4
lea eax, [esi + 0xc]
or ecx, 0xffffffff
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x47fa41
mov ecx, dword [esi]
mov edx, dword [ecx]
mov eax, dword [edx + 4]
push esi
call eax
mov ecx, dword [ebp - 0x1c]
add ecx, 0x10
mov dword [edi + 0x8c], ecx
jmp 0x47f958
mov eax, dword [ebp + 0xc]
mov edx, dword [eax - 0xc]
push edx
push eax
call fcn.004241cf
jmp 0x47f958