Function at 0x480300
Capabilities:
Lock the desktop
Shutdown system

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54b15b
mov eax, dword fs:[0]
push eax
sub esp, 0x11c
mov eax, dword [0x5b0008]
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 edi, ecx
movzx ecx, word [ebp + 8]
lea eax, [edi + 0x2c8]
movzx ebx, word [ebp + 8]
mov esi, dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
push eax
mov dword [ebp - 0x118], ecx
mov dword [ebp - 0x120], eax
mov dword [ebp - 0x11c], 0x28
call esi
lea eax, [edi + 0x1c]
mov dword [ebp - 4], 0
push eax
mov dword [ebp - 0x128], eax
mov dword [ebp - 0x124], 0x29
call esi
mov byte [ebp - 4], 1
mov ecx, dword [edi + 0xb4]
mov esi, dword [ecx]
cmp esi, ecx
je 0x48039e
nop word [eax + eax]
cmp word [esi + 8], bx
je 0x4803c0
mov eax, dword [esi]
mov esi, eax
cmp eax, ecx
jne 0x480390
mov ecx, dword [edi + 0xbc]
mov esi, dword [ecx]
cmp esi, ecx
je 0x480435
nop
cmp word [esi + 8], bx
je 0x4803e8
mov eax, dword [esi]
mov esi, eax
cmp eax, ecx
jne 0x4803b0
jmp 0x480435
push str.vncServer::RemoveClient_:_removing_unauthorised_client_n
push 9
push 0x5b0d48
call fcn.0041cc90
mov ecx, dword [esi + 4]
mov eax, dword [esi]
mov dword [ecx], eax
mov ecx, dword [esi]
mov eax, dword [esi + 4]
mov dword [ecx + 4], eax
dec dword [edi + 0xb8]
jmp 0x48040e
push str.vncServer::RemoveClient_:_removing_authorised_client_n
push 9
push 0x5b0d48
call fcn.0041cc90
mov ecx, dword [esi + 4]
mov eax, dword [esi]
mov dword [ecx], eax
mov ecx, dword [esi]
mov eax, dword [esi + 4]
mov dword [ecx + 4], eax
dec dword [edi + 0xc0]
push 0xc
push esi
call fcn.0051949c
mov eax, 0x1ff
add esp, 0x14
cmp word [ebp - 0x118], ax
ja 0x480435
movsx eax, bx
mov dword [edi + eax*4 + 0xc4], 0
mov ecx, dword [edi + 0x2e0]
call fcn.004bfea0
lea eax, [edi + 0x1c]
mov byte [ebp - 4], 0
mov ebx, dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
push eax
call ebx
cmp dword [edi + 0xc0], 0
jne 0x480591
cmp dword [edi + 0xa8], 0
je 0x480591
push str.vncServer::RemoveClient_:_deleting_desktop_server_n
push 0
push 0x5b0d48
call fcn.0041cc90
mov eax, dword [0x5be08c]
add esp, 0xc
cmp dword [eax + 0xe28], 0
jne 0x480554
cmp byte [edi + 0x88], 0
jne 0x480554
mov ecx, dword [eax + 0x778]
cmp ecx, 1
je 0x48051c
cmp dword [eax + 0x78c], 0
jne 0x48051c
cmp ecx, 1
jle 0x480527
lea ecx, [ebp - 0x114]
call fcn.00425b90
mov ecx, 0x569fe8
lea eax, [ebp - 0x114]
nop dword [eax]
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x4804f0
test dl, dl
je 0x4804ec
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x4804f0
add eax, 2
add ecx, 2
test dl, dl
jne 0x4804d0
xor eax, eax
jmp 0x4804f5
sbb eax, eax
or eax, 1
test eax, eax
je 0x480522
push 0
push 0
call dword [sym.imp.USER32.dll_ExitWindowsEx]
test eax, eax
jne 0x480522
push str.vncServer::RemoveClient_:_client_disconnect___failed_to_logoff_user__n
push eax
push 0x5b0d48
call fcn.0041cc90
add esp, 0xc
jmp 0x480522
call dword [sym.imp.USER32.dll_LockWorkStation]
mov eax, dword [0x5be08c]
cmp dword [eax + 0xe20], 0
je 0x480554
cmp dword [eax + 0xa54], 0
je 0x480554
push str.vncServer::RemoveClient_:_last_client_disconnect___restart_server_for_rdpmode_n
push 0
push 0x5b0d48
mov byte [0x5b31af], 1
call fcn.0041cc90
add esp, 0xc
mov esi, dword [edi + 0xa8]
test esi, esi
je 0x480573
mov ecx, esi
call fcn.0044d170
push 0xe9b8
push esi
call fcn.0051949c
add esp, 8
push str.vncServer::RemoveClient_:_desktop_deleted_n
push 0
push 0x5b0d48
mov dword [edi + 0xa8], 0
call fcn.0041cc90
add esp, 0xc
mov eax, dword [edi]
mov ecx, edi
push 0
push 0
push 0x8004
call dword [eax + 0x84]
push str.vncServer::RemoveClient_:_RemoveClient___done_n
push 9
push 0x5b0d48
call fcn.0041cc90
add esp, 0xc
lea eax, [edi + 0x2c8]
push eax
call ebx
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.00519459
mov esp, ebp
pop ebp
ret 4