Function at 0x453710
Capabilities:
Link many functions at runtime
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x3bc
mov eax, dword [0x5d60c4]
xor eax, esp
mov dword [esp + 0x3b8], eax
push ebx
push esi
push edi
push str.vncDesktop::InitWindow_:_InitWindow_called_n
push 0
push 0x5d6df8
mov esi, ecx
call fcn.0041d510
add esp, 0xc
push 0x400001cf
push 0
push 0
call dword [sym.imp.USER32.dll_OpenInputDesktop]
mov ebx, eax
mov ecx, str.vncDesktop::InitWindow_:_InitWindow:OpenInputdesktop_Error__n
mov eax, str.vncDesktop::InitWindow_:_InitWindow:OpenInputdesktop_OK_n
mov dword [esp + 0x5c], ebx
test ebx, ebx
cmovne ecx, eax
push ecx
push 0
push 0x5d6df8
call fcn.0041d510
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.USER32.dll_GetThreadDesktop]
mov edi, eax
lea eax, [esp + 0x90]
push eax
push 0x100
lea eax, [esp + 0x2c8]
mov dword [esp + 0x5c], edi
push eax
push 2
push ebx
call dword [sym.imp.USER32.dll_GetUserObjectInformationA]
test eax, eax
jne 0x4537bf
push str.vncDesktop::InitWindow_:_InitWindow:_GetUserObjectInformation__n
push eax
push 0x5d6df8
call fcn.0041d510
add esp, 0xc
push edi
push ebx
lea eax, [esp + 0x2c8]
push eax
push str.vncDesktop::InitWindow_:_InitWindow:SelectHDESK_to__s___x__from__x_n
push 0
push 0x5d6df8
call fcn.0041d510
mov eax, dword [sym.imp.USER32.dll_SetThreadDesktop]
add esp, 0x18
mov dword [esp + 0x58], eax
push ebx
call eax
test eax, eax
jne 0x453800
push str.vncDesktop::InitWindow_:_InitWindow:SelectHDESK:_SetThreadDesktop__n
push eax
push 0x5d6df8
call fcn.0041d510
add esp, 0xc
mov edi, dword [sym.imp.USER32.dll_ChangeWindowMessageFilter]
push 1
push dword [0x5e44fc]
call edi
push 1
push dword [0x5e44f0]
call edi
push 1
push dword [0x5e44f8]
call edi
push 1
push 0x12
call edi
push 1
push 0x8008
call edi
cmp word [0x5d960c], 0
jne 0x453902
mov eax, dword [0x5e1fcc]
push 0
mov dword [esp + 0x64], 0x30
mov dword [esp + 0x68], 0
mov dword [esp + 0x6c], 0x452bd0
mov dword [esp + 0x70], 0
mov dword [esp + 0x74], 0
mov dword [esp + 0x78], eax
mov dword [esp + 0x7c], 0
mov dword [esp + 0x80], 0
call dword [sym.imp.GDI32.dll_GetStockObject]
mov dword [esp + 0x80], eax
lea eax, [esp + 0x60]
push eax
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0x5ba1b0
mov dword [esp + 0x90], 0
call dword [sym.imp.USER32.dll_RegisterClassExA]
mov word [0x5d960c], ax
test ax, ax
jne 0x453902
push str.vncDesktop::InitWindow_:_failed_to_register_window_class_n
push 0
push 0x5d6df8
call fcn.0041d510
add esp, 0xc
push dword [esi + 0xe398]
call dword [sym.imp.KERNEL32.dll_SetEvent]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x3b8]
xor ecx, esp
call fcn.0052b789
mov esp, ebp
pop ebp
ret
push 0
push dword [0x5e1fcc]
push 0
push 0
push 0xc8
push 0x190
push accept
push accept
push 0xcf0000
push str.WinVNC
push 0x5ba1b0
push 0
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [esi + 0xe408], eax
test eax, eax
jne 0x45394a
push str.vncDesktop::InitWindow_:_failed_to_create_hook_window_n
jmp 0x4538d0
push 0
push 0x3e8
push 0x3e9
push eax
call dword [sym.imp.USER32.dll_SetTimer]
push esi
push 0xffffffffffffffeb
push dword [esi + 0xe408]
call dword [sym.imp.USER32.dll_SetWindowLongA]
push dword [esi + 0xe408]
mov byte [esi + 0xe410], 1
call dword [sym.imp.USER32.dll_SetClipboardViewer]
push str.vncDesktop::InitWindow_:_OOOOOOOOOOOO_load_hookdlls_n
push 0
push 0x5d6df8
mov dword [esi + 0xe40c], eax
mov byte [esi + 0xe410], 0
call fcn.0041d510
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [esp + 0xbc]
add esp, 0xc
mov dword [esi + 0xe908], 0
push 0x104
push eax
push 0
call edi
test eax, eax
je 0x4539fc
lea eax, [esp + 0xb0]
push 0x5c
push eax
call fcn.0052cf50
add esp, 8
test eax, eax
je 0x4538eb
push str._vnchooks.dll
mov byte [eax], 0
lea eax, [esp + 0xb4]
push 0x104
push eax
call fcn.00531998
add esp, 0xc
push 0x104
lea eax, [esp + 0x1bc]
mov dword [esi + 0xe90c], 0
push eax
push 0
call edi
test eax, eax
je 0x453a52
lea eax, [esp + 0x1b8]
push 0x5c
push eax
call fcn.0052cf50
add esp, 8
test eax, eax
je 0x4538eb
push str._schook_legacy.dll
mov byte [eax], 0
lea eax, [esp + 0x1bc]
push 0x104
push eax
call fcn.00531998
add esp, 0xc
mov edi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
lea eax, [esp + 0xb0]
push eax
mov dword [esi + 0xe914], 0
mov dword [esi + 0xe924], 0
mov dword [esi + 0xe920], 0
mov dword [esi + 0xe92c], 0
mov dword [esi + 0xe928], 0
mov dword [esi + 0xe910], 0
mov dword [esi + 0xe91c], 0
mov dword [esi + 0xe918], 0
call edi
mov dword [esi + 0xe908], eax
lea eax, [esp + 0x1b8]
push eax
call edi
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [esi + 0xe90c], eax
mov eax, dword [esi + 0xe908]
test eax, eax
je 0x453b1f
push str.UnSetHooks
push eax
call edi
push str.SetMouseFilterHook
push dword [esi + 0xe908]
mov dword [esi + 0xe914], eax
call edi
push str.SetKeyboardFilterHook
push dword [esi + 0xe908]
mov dword [esi + 0xe924], eax
call edi
push str.SetHooks
push dword [esi + 0xe908]
mov dword [esi + 0xe920], eax
call edi
mov dword [esi + 0xe910], eax
mov eax, dword [esi + 0xe90c]
test eax, eax
je 0x453b70
push str.UnSetHook
push eax
call edi
push str.SetHook
push dword [esi + 0xe90c]
mov dword [esi + 0xe91c], eax
call edi
push str.SetMouseFilterHook
push dword [esi + 0xe90c]
mov dword [esi + 0xe918], eax
call edi
push str.SetKeyboardFilterHook
push dword [esi + 0xe90c]
mov dword [esi + 0xe92c], eax
call edi
mov dword [esi + 0xe928], eax
push str.vncDesktop::InitWindow_:_OOOOOOOOOOOO_start_dispatch_n
push 0
push 0x5d6df8
call fcn.0041d510
mov ebx, dword [sym.imp.KERNEL32.dll_SetEvent]
add esp, 0xc
mov dword [esp + 0x18], ebx
push dword [esi + 0xe398]
call ebx
mov eax, dword [sym.imp.KERNEL32.dll_Sleep]
mov ecx, dword [sym.imp.USER32.dll_PeekMessageA]
mov edi, dword [sym.imp.USER32.dll_WaitMessage]
mov dword [esp + 0x24], eax
mov eax, dword [sym.imp.USER32.dll_TranslateMessage]
mov dword [esp + 0x4c], eax
mov eax, dword [sym.imp.USER32.dll_DispatchMessageA]
mov dword [esp + 0x50], eax
mov eax, dword [sym.imp.GDI32.dll_CreateRectRgn]
mov dword [esp + 0x40], eax
mov eax, dword [sym.imp.GDI32.dll_CombineRgn]
mov dword [esp + 0x44], eax
mov eax, dword [sym.imp.GDI32.dll_DeleteObject]
mov dword [esp + 0x10], ecx
mov dword [esp + 0x1c], edi
mov dword [esp + 0x48], eax
jmp 0x453bea
mov ebx, dword [esp + 0x18]
mov edi, dword [esp + 0x1c]
push 1
push 0
push 0
push 0
lea eax, [esp + 0xa4]
push eax
call ecx
test eax, eax
je 0x453e52
mov eax, dword [esp + 0x98]
cmp eax, 0x12
je 0x453e7f
cmp byte [0x5d960f], 0
jne 0x453e7f
cmp eax, 0x8008
je 0x453e5d
cmp eax, dword [0x5e44fc]
jne 0x453db3
push str.vnchook
push 0x10
push 0x5d9a10
call fcn.0053af67
mov ecx, dword [esp + 0x1c]
add esp, 0xc
cmp byte [esi + 0xe940], 0
je 0x453bea
push str.vncDesktop::InitWindow_:_RFB_SCREEN_UPDATE___n
push 0
push 0x5d6df8
call fcn.0041d510
mov eax, dword [esp + 0xa8]
add esp, 0xc
movsx edi, ax
shr eax, 0x10
movsx ebx, ax
mov eax, dword [esp + 0xa0]
movsx ecx, ax
shr eax, 0x10
movsx edx, ax
mov eax, dword [esi + 0x858]
sub ecx, eax
sub edi, eax
mov dword [esp + 0x14], ecx
mov eax, dword [esi + 0x85c]
sub ebx, eax
sub edx, eax
mov dword [esp + 0x28], edi
push edx
push ebx
push ecx
push edi
push str.vncDesktop::InitWindow_:_REct3__i__i__i__i___n
push 0
push 0x5d6df8
mov dword [esp + 0x4c], ecx
mov dword [esp + 0x48], ebx
mov dword [esp + 0x54], edx
mov dword [esp + 0x50], edx
call fcn.0041d510
lea edx, [esi + 0x898]
add esp, 0x1c
cmp edi, dword [edx]
lea eax, [esp + 0x28]
mov edi, dword [esp + 0x14]
lea ecx, [esp + 0x2c]
cmovl eax, edx
cmp ebx, dword [edx + 4]
mov eax, dword [eax]
mov dword [esp + 0x20], eax
lea eax, [edx + 4]
cmovl ecx, eax
cmp dword [edx + 8], edi
lea eax, [edx + 8]
mov ebx, dword [ecx]
lea ecx, [esp + 0x30]
cmovl ecx, eax
mov dword [esp + 0x3c], ebx
mov eax, dword [ecx]
lea ecx, [esp + 0x34]
mov dword [esp + 0x14], eax
lea eax, [edx + 0xc]
mov edx, dword [esp + 0x38]
cmp dword [eax], edx
cmovl ecx, eax
mov eax, dword [esp + 0x14]
mov edi, dword [ecx]
mov ecx, dword [esp + 0x10]
cmp dword [esp + 0x20], eax
jge 0x453be2
cmp ebx, edi
mov ebx, dword [esp + 0x18]
jge 0x453be6
cmp byte [esi + 0xe3a8], 0
je 0x453d5f
nop dword [eax]
push 5
call dword [esp + 0x28]
cmp byte [esi + 0xe3a8], 0
jne 0x453d50
push 0x5b9638
call fcn.0053a752
add esp, 4
mov ebx, eax
push edi
push dword [esp + 0x18]
push dword [esp + 0x44]
push dword [esp + 0x2c]
call dword [esp + 0x50]
mov ecx, dword [esi + 0xe3a0]
mov edi, eax
push 2
push edi
push ecx
push ecx
call dword [esp + 0x54]
push edi
call dword [esp + 0x4c]
push ebx
call fcn.0052fd09
mov ebx, dword [esp + 0x1c]
add esp, 4
push dword [esi + 0xe374]
call ebx
mov ecx, dword [esp + 0x10]
jmp 0x453be6
cmp eax, dword [0x5e44f8]
jne 0x453e16
cmp byte [esi + 0xe940], 0
mov ecx, dword [esp + 0x10]
je 0x453bea
push str.vncDesktop::InitWindow_:_RFB_MOUSE_UPDATE___n
push 0
push 0x5d6df8
call fcn.0041d510
mov ecx, dword [esp + 0xa8]
add esp, 0xc
test ecx, ecx
jne 0x453df3
mov ecx, dword [esi + 0xe894]
jmp 0x453dff
mov eax, dword [esi + 0xe88c]
mov dword [esi + 0xe890], eax
mov dword [esi + 0xe88c], ecx
push dword [esi + 0xe378]
call ebx
mov ecx, dword [esp + 0x10]
jmp 0x453bea
cmp eax, 0x403
jne 0x453e31
push str.vncDesktop::InitWindow_:_OOOOOOOOOOOO_called_wm_user3_n
push 0
push 0x5d6df8
call fcn.0041d510
add esp, 0xc
lea eax, [esp + 0x94]
push eax
call dword [esp + 0x50]
lea eax, [esp + 0x94]
push eax
call dword [esp + 0x54]
mov ecx, dword [esp + 0x10]
jmp 0x453bea
call edi
mov ecx, dword [esp + 0x10]
jmp 0x453bea
push str.vncDesktop::InitWindow_:_OOOOOOOOOOOO_called_wm_user4_n
push 0
push 0x5d6df8
call fcn.0041d510
add esp, 0xc
push dword [esi + 0xe408]
call dword [sym.imp.USER32.dll_DestroyWindow]
jmp 0x453ea7
push str.vncDesktop::InitWindow_:_OOOOOOOOOOOO_called_wm_quit_n
push 0
push 0x5d6df8
call fcn.0041d510
add esp, 0xc
push dword [esi + 0xe408]
call dword [sym.imp.USER32.dll_DestroyWindow]
push dword [esi + 0xe384]
call ebx
cmp dword [0x5d95ec], 0
je 0x453ec1
mov ebx, dword [esp + 0x24]
push 0x64
call ebx
cmp dword [0x5d95ec], 0
jne 0x453eb4
push 0x3e9
push dword [esi + 0xe408]
call dword [sym.imp.USER32.dll_KillTimer]
mov eax, dword [esi + 0xe908]
mov edi, dword [sym.imp.KERNEL32.dll_FreeLibrary]
test eax, eax
je 0x453ee5
push eax
call edi
mov eax, dword [esi + 0xe90c]
test eax, eax
je 0x453ef2
push eax
call edi
push dword [esp + 0x54]
call dword [esp + 0x5c]
push dword [esp + 0x5c]
call dword [sym.imp.USER32.dll_CloseDesktop]
push str.vncDesktop::InitWindow_:_OOOOOOOOOOOO_end_dispatch_n
push 0
push 0x5d6df8
call fcn.0041d510
mov ecx, dword [esp + 0x3d0]
add esp, 0xc
mov dword [esi + 0xe408], 0
mov eax, 1
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0052b789
mov esp, ebp
pop ebp
ret