Function at 0x4522a0
Capabilities:
Check mutex on windows
Get common file path
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x63480f
mov eax, dword fs:[0]
push eax
push ecx
sub esp, 0x254
mov eax, dword [0x721970]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x220], ecx
mov eax, 1
mov ecx, dword [ebp - 0x220]
mov word [ecx + 0x1c], ax
push 0x66b1f8
lea ecx, [ebp - 0x258]
call fcn.00418d40
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0x220]
add edx, 0x10
push edx
lea ecx, [ebp - 0x258]
call fcn.00419090
mov dword [ebp - 0x23c], 0x104
xor eax, eax
mov word [ebp - 0x21c], ax
push 0x206
push 0
lea ecx, [ebp - 0x21a]
push ecx
call fcn.0060f700
add esp, 0xc
lea edx, [ebp - 0x21c]
push edx
mov eax, dword [ebp - 0x23c]
push eax
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
jbe 0x45236b
lea ecx, [ebp - 0x21c]
push ecx
mov ecx, dword [ebp - 0x220]
add ecx, 0x44
call fcn.00418f40
jmp 0x45237e
push 0x66b204
mov ecx, dword [ebp - 0x220]
add ecx, 0x44
call fcn.00418f40
push str._TMP
lea ecx, [ebp - 0x264]
call fcn.00418d40
mov byte [ebp - 4], 1
lea edx, [ebp - 0x264]
push edx
mov ecx, dword [ebp - 0x220]
add ecx, 0x44
call fcn.00419090
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x264]
call fcn.00418cc0
mov eax, dword [ebp - 0x220]
add eax, 0x10
push eax
mov ecx, dword [ebp - 0x220]
add ecx, 0x44
call fcn.00419090
push str.MUTEX_
lea ecx, [ebp - 0x24c]
call fcn.00418d40
mov byte [ebp - 4], 2
mov ecx, dword [ebp - 0x220]
add ecx, 0x10
push ecx
lea ecx, [ebp - 0x24c]
call fcn.00419090
mov dword [ebp - 0x228], 0
mov dword [ebp - 0x224], 0xffffffff
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x258]
call fcn.00419160
push eax
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov dword [ebp - 0x228], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x22c], eax
cmp dword [ebp - 0x22c], 0xb7
jne 0x452455
push 0x7d0
mov edx, dword [ebp - 0x228]
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea ecx, [ebp - 0x24c]
call fcn.00419160
push eax
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov ecx, dword [ebp - 0x220]
mov dword [ecx + 0x50], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x22c], eax
cmp dword [ebp - 0x22c], 0xb7
jne 0x452596
push 0
push 2
push 3
push 0
push 0
push SysReAllocStringLen
mov ecx, dword [ebp - 0x220]
add ecx, 0x44
call fcn.00419160
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0xffffffff
je 0x452506
mov dword [ebp - 0x234], 0
push 0
lea edx, [ebp - 0x234]
push edx
push 2
mov eax, dword [ebp - 0x220]
add eax, 0x1c
push eax
mov ecx, dword [ebp - 0x224]
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov edx, dword [ebp - 0x224]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x224], 0xffffffff
mov eax, dword [ebp - 0x220]
mov cx, word [eax + 0x1c]
add cx, 1
mov edx, dword [ebp - 0x220]
mov word [edx + 0x1c], cx
push 0
push 2
push 3
push 0
push 0
push 0x40000000
mov ecx, dword [ebp - 0x220]
add ecx, 0x44
call fcn.00419160
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0xffffffff
je 0x452594
mov dword [ebp - 0x240], 0
push 0
lea eax, [ebp - 0x240]
push eax
push 2
mov ecx, dword [ebp - 0x220]
add ecx, 0x1c
push ecx
mov edx, dword [ebp - 0x224]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [ebp - 0x224]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x224], 0xffffffff
jmp 0x45260c
push 0
push 2
push 2
push 0
push 0
push 0x40000000
mov ecx, dword [ebp - 0x220]
add ecx, 0x44
call fcn.00419160
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x224], eax
cmp dword [ebp - 0x224], 0xffffffff
je 0x45260c
mov dword [ebp - 0x238], 0
push 0
lea ecx, [ebp - 0x238]
push ecx
push 2
mov edx, dword [ebp - 0x220]
add edx, 0x1c
push edx
mov eax, dword [ebp - 0x224]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, dword [ebp - 0x224]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x224], 0xffffffff
jmp 0x452614
mov dword [ebp - 4], 2
jmp 0x452624
cmp dword [ebp - 0x228], 0
je 0x452647
mov edx, dword [ebp - 0x228]
push edx
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [ebp - 0x228]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x224], 0xffffffff
je 0x452667
mov ecx, dword [ebp - 0x224]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x224], 0xffffffff
mov edx, dword [ebp - 0x220]
mov ax, word [edx + 0x1c]
mov word [ebp - 0x22e], ax
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x24c]
call fcn.00418cc0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x258]
call fcn.00418cc0
mov ax, word [ebp - 0x22e]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0060f7c8
mov esp, ebp
pop ebp
ret