Function at 0x462be0
Capabilities:
Check mutex on windows
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x868
mov eax, dword [0x4ea5e0]
xor eax, ebp
mov dword [ebp - 4], eax
push edi
push str.winvnc.cpp_:__DBG___WinVNCAPPMain_n
mov eax, 9
mov ecx, 0x4ecb00
call fcn.00403230
push 4
call fcn.004a90a2
add esp, 8
test eax, eax
je 0x462c26
mov edi, eax
mov dword [eax], 0
mov dword [ebp - 0x864], edi
jmp 0x462c36
mov dword [ebp - 0x864], 0
mov edi, dword [ebp - 0x864]
cmp dword [0x5447c0], 0
jne 0x462cab
push str.WinVNC_Win32_Instance_Mutex
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov dword [edi], eax
test eax, eax
je 0x462c61
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x462cab
push 0x518ac0
push str.winvnc.cpp_:__s____exiting_n
mov eax, 9
mov ecx, 0x4ecb00
call fcn.00403230
add esp, 8
cmp dword [0x5447a4], 0
jne 0x462c9a
push 0x4d8a6c
push 0x518ac0
xor eax, eax
call fcn.00409310
add esp, 8
xor eax, eax
pop edi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a8a2f
mov esp, ebp
pop ebp
ret
push ebx
push esi
lea ebx, [ebp - 0x860]
call fcn.00458b30
mov eax, dword [ebp - 0x758]
test eax, eax
je 0x462cd5
push eax
call fcn.004aa14e
add esp, 4
mov dword [ebp - 0x758], 0
push 0x4d8a6c
call fcn.004aa83c
mov dword [ebp - 0x758], eax
push str.winvnc.cpp_:_server_created_ok_n
xor eax, eax
mov ecx, 0x4ecb00
call fcn.00403230
mov eax, dword [0x5447a4]
mov esi, dword [sym.imp.KERNEL32.dll_OpenEventA]
add esp, 8
push str.GlobalSessionEventUltra
push 0
push 0x1f0003
mov dword [ebp - 0x28], eax
call esi
push str.GlobalSessionEventUltraCad
push 0
push 2
mov dword [0x5447ac], eax
call esi
mov dword [0x5447b0], eax
mov eax, dword [0x5447ac]
test eax, eax
je 0x462d3a
push eax
call dword [sym.imp.KERNEL32.dll_ResetEvent]
push str.winvnc.cpp_:__SDEvent_created__n
xor eax, eax
mov ecx, 0x4ecb00
call fcn.00403230
add esp, 4
cmp byte [0x544753], 0
mov dword [0x518a3c], 0xffffffff
jne 0x462dc0
mov ebx, dword [sym.imp.KERNEL32.dll_CreateThread]
mov edi, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea ecx, [ecx]
lea ecx, [ebp - 0x868]
push ecx
push 0
lea edx, [ebp - 0x860]
push edx
push 0x462790
push 0
push 0
call ebx
mov esi, eax
test esi, esi
je 0x462d9d
push 0xffffffffffffffff
push esi
call edi
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push str.winvnc.cpp_:__Closing_Imp_Thread_n
xor eax, eax
mov ecx, 0x4ecb00
call fcn.00403230
add esp, 4
cmp byte [0x544753], 0
je 0x462d70
mov edi, dword [ebp - 0x864]
pop esi
pop ebx
test edi, edi
je 0x462de5
mov eax, dword [edi]
test eax, eax
je 0x462ddc
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
mov eax, dword [edi]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call fcn.004a9046
add esp, 4
mov eax, dword [0x5447ac]
test eax, eax
je 0x462df5
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x5447b0]
test eax, eax
je 0x462e05
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push str.winvnc.cpp_:__SHUTING_DOWN_SERVER__n
xor eax, eax
mov ecx, 0x4ecb00
call fcn.00403230
mov eax, dword [0x5447a8]
add esp, 4
test eax, eax
je 0x462e35
push eax
call fcn.004a9011
add esp, 4
mov dword [0x5447a8], 0
lea ecx, [ebp - 0x860]
push ecx
call 0x458ef0
mov ecx, dword [ebp - 4]
xor ecx, ebp
mov eax, 1
pop edi
call fcn.004a8a2f
mov esp, ebp
pop ebp
ret