Function at 0x4946b0
Capabilities:
Check if file exists
Check os version

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4dbc0d
mov eax, dword fs:[0]
push eax
sub esp, 0x138
mov eax, dword [0x511070]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x140], ecx
mov eax, dword [ebp + 0xc]
xor edi, edi
mov ebx, dword [ebp + 0x10]
mov dword [ebp - 0x13c], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x138], eax
mov dword [ebp - 0x144], edi
call fcn.0041bed0
mov ecx, eax
test ecx, ecx
jne 0x494716
push 0x80004005
call fcn.0041cdf0
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x134], eax
push 0x118
lea eax, [ebp - 0x128]
mov dword [ebp - 4], 0
push 0
push eax
call fcn.004a8960
add esp, 0xc
mov dword [ebp - 0x12c], 0x11c
lea eax, [ebp - 0x12c]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
or esi, 0xffffffff
test eax, eax
jne 0x494766
xor edi, edi
jmp 0x49497e
call fcn.0048a560
test eax, eax
je 0x4947ac
call fcn.0048a150
lea ecx, [ebp - 0x130]
mov edx, ebx
test eax, eax
je 0x494796
push str.X64_ev.sys
call fcn.0041c010
add esp, 4
mov byte [ebp - 4], 1
jmp 0x4948b5
push str.X64.sys
call fcn.0041c010
add esp, 4
mov byte [ebp - 4], 2
jmp 0x4948b5
call fcn.0048a150
lea ecx, [ebp - 0x130]
mov edx, ebx
test eax, eax
je 0x4947d3
push str._ev.sys
call fcn.0041c010
add esp, 4
mov byte [ebp - 4], 3
jmp 0x4948b5
cmp dword [ebp - 0x128], 5
jne 0x4948a4
push str.XP.sys
call fcn.0041c010
add esp, 4
push eax
lea ecx, [ebp - 0x134]
mov byte [ebp - 4], 4
call fcn.0041c6d0
mov byte [ebp - 4], 0
mov eax, esi
mov edx, dword [ebp - 0x130]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x49481e
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [ebp - 0x138]
mov edx, dword [ebp - 0x13c]
lea eax, [ebp - 0x134]
push ecx
mov ecx, esp
push eax
call fcn.00421dd0
mov ecx, dword [ebp - 0x140]
add esp, 4
call fcn.00494e70
mov eax, dword [ebp - 0x138]
push dword [eax]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x494863
mov edi, 1
jmp 0x49497e
mov ecx, dword [ebp - 0x138]
call fcn.0041ca30
push str..sys
mov edx, ebx
lea ecx, [ebp - 0x130]
call fcn.0041c010
add esp, 4
push eax
lea ecx, [ebp - 0x134]
mov byte [ebp - 4], 5
call fcn.0041c6d0
lea ecx, [ebp - 0x130]
mov byte [ebp - 4], 0
call fcn.0041cdd0
jmp 0x4948e5
push str..sys
call fcn.0041c010
add esp, 4
mov byte [ebp - 4], 6
push eax
lea ecx, [ebp - 0x134]
call fcn.0041c6d0
mov byte [ebp - 4], 0
or esi, 0xffffffff
mov edx, dword [ebp - 0x130]
mov eax, esi
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x4948e5
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
cmp dword [ebp + 8], 0
je 0x494901
call fcn.0048a560
test eax, eax
je 0x494901
xor ecx, ecx
call fcn.0048b2d0
mov dword [ebp - 0x144], eax
mov ebx, dword [ebp - 0x138]
lea eax, [ebp - 0x134]
mov edx, dword [ebp - 0x13c]
push ebx
push ecx
mov ecx, esp
push eax
call fcn.00421dd0
mov ecx, dword [ebp - 0x140]
add esp, 4
call fcn.00494e70
push dword [ebx]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
mov ecx, 1
cmovne edi, ecx
cmp dword [ebp - 0x144], 0
je 0x49497e
mov eax, dword [0x515c64]
test eax, eax
jne 0x49497a
push str.Kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test eax, eax
je 0x494971
push str.Wow64EnableWow64FsRedirection
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x515c64], eax
jmp 0x494976
mov eax, dword [0x515c64]
test eax, eax
je 0x49497e
push 1
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x134]
add eax, 0xfffffff0
lock xadd dword [eax + 0xc], esi
dec esi
test esi, esi
jg 0x4949a0
mov ecx, dword [eax]
push eax
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004a5d13
mov esp, ebp
pop ebp
ret 0x10