Function at 0x404a8f
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push 0x3c
push 0x4015b8
call fcn.0041b130
xor ebx, ebx
mov dword [ebp - 0x2c], ebx
cmp dword [ebp + 8], ebx
je 0x404c6c
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x28], ebx
mov dword [0x424d84], ebx
mov dword [0x424d80], ebx
mov dword [0x424d7c], ebx
mov dword [0x424d78], ebx
mov dword [ebp - 4], ebx
push 0x424d60
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
xor edi, edi
inc edi
mov dword [0x424d78], edi
lea eax, [ebp - 0x24]
push eax
push edi
push ebx
push 0x401558
push 0x80000002
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
call esi
mov dword [ebp - 0x34], eax
cmp eax, ebx
jne 0x404b87
lea eax, [ebp - 0x20]
push eax
push 0x401544
push dword [ebp - 0x24]
call fcn.00418a26
test eax, eax
je 0x404b1c
mov dword [ebp - 0x20], ebx
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x44]
push eax
lea eax, [ebp - 0x1c]
push eax
push 0x401534
push dword [ebp - 0x24]
call fcn.00418996
test eax, eax
je 0x404b3c
mov dword [ebp - 0x1c], ebx
lea eax, [ebp - 0x30]
push eax
push edi
push ebx
push 0x401518
push dword [ebp - 0x24]
call esi
mov dword [ebp - 0x34], eax
cmp eax, ebx
jne 0x404b7e
lea eax, [ebp - 0x38]
push eax
push dword [0x4235cc]
call fcn.0041a663
push eax
push dword [ebp - 0x30]
call fcn.00418a26
test eax, eax
jne 0x404b75
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x20], eax
push dword [ebp - 0x30]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp - 0x1c]
cmp eax, ebx
je 0x404bdb
cmp word [eax], bx
je 0x404bd1
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ecx, dword [ebp - 0x1c]
lea eax, [ecx + eax*2]
push eax
push ecx
call dword [sym.imp.USER32.dll_CharPrevW]
movzx eax, word [eax]
mov dword [ebp - 0x48], eax
cmp ax, 0x5c
je 0x404bed
cmp ax, 0x2f
je 0x404bed
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
mov dword [ebp - 0x4c], eax
cmp eax, 0xffffffff
je 0x404bf0
test al, 0x10
je 0x404bf0
jmp 0x404bed
cmp eax, ebx
je 0x404bdb
push eax
call fcn.0041a398
push dword [0x4235d0]
call fcn.0041a3e9
mov dword [ebp - 0x1c], eax
cmp eax, ebx
je 0x404c5d
mov dword [ebp - 0x28], edi
cmp dword [ebp - 0x28], ebx
je 0x404c22
lea eax, [ebp - 0x3c]
push eax
push 0x4014fc
push dword [ebp - 0x1c]
call fcn.0040ce29
push dword [ebp - 0x1c]
test eax, eax
jne 0x404c17
call fcn.0041a398
mov dword [ebp - 0x1c], ebx
jmp 0x404c5d
call fcn.0041a398
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0x1c], eax
push dword [ebp - 0x1c]
call fcn.0041abac
and word [ebp - 0x1e], 0xf800
cmp byte [ebp - 0x20], bl
jne 0x404c39
or dword [ebp - 0x20], 0x20
test byte [ebp - 0x1f], 0xff
jne 0x404c43
or byte [ebp - 0x1f], 0x30
mov eax, dword [ebp - 0x20]
mov dword [0x424d80], eax
mov eax, dword [ebp - 0x1c]
mov dword [0x424d84], eax
mov dword [ebp - 0x1c], ebx
cmp eax, ebx
je 0x404c5d
mov dword [ebp - 0x2c], edi
or dword [ebp - 4], 0xffffffff
jmp 0x404c9b
mov eax, dword [0x424d84]
cmp eax, ebx
je 0x404c81
push eax
call fcn.0041a398
mov dword [0x424d84], ebx
cmp dword [0x424d78], ebx
je 0x404c94
push 0x424d60
call dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
mov dword [ebp - 0x2c], 1
mov eax, dword [ebp - 0x2c]
call fcn.0041b16b
ret 4