Function at 0x440821
Capabilities:
Lock the desktop

Disassembly:
mov eax, 0x481e20
call fcn.0047bf90
sub esp, 0x38
and dword [ebp - 0x1c], 0
push ebx
push esi
mov esi, ecx
push edi
mov dword [ebp - 0x20], esi
cmp byte [esi + 0x30], 0
mov dword [ebp - 0x10], esp
jne 0x440848
call fcn.0041d4aa
movsx eax, word [esi + 0x84]
push eax
mov ebx, str.S:Ammyy_sources_targetTrClient.cpp
push str.TrClient::Run__1_id_d
push ebx
mov edi, 0x4aea90
push 2
push edi
call fcn.0041c87e
mov eax, dword [esi + 0xc]
add esp, 0x14
mov dword [esi + 0x214], eax
mov dword [esi + 0xcc], eax
mov eax, dword [0x4aeedc]
and dword [ebp - 4], 0
mov dword [esi + 0xd0], eax
lea eax, [esi + 0x38]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x18]
push eax
mov al, byte [esi + 0x30]
push eax
mov ecx, esi
call fcn.0041d234
push dword [ebp - 0x24]
mov eax, dword [ebp - 0x18]
mov dword [esi + 0x70], eax
push str.ReadInitMsg___remoteId_u
push ebx
push 2
push edi
call fcn.0041c87e
mov eax, dword [esi]
add esp, 0x14
mov ecx, esi
push 4
call dword [eax + 0x10]
mov ecx, 0x4ae9b0
mov byte [ebp - 4], 1
call fcn.004211b2
jmp 0x4408f5
and dword [ebp - 4], 0
cmp byte [esi + 0x30], 0
je 0x44090c
mov eax, dword [esi + 0xc]
mov ecx, esi
push dword [eax + 8]
call fcn.0041cb1f
mov ecx, esi
call fcn.0043fdae
mov ecx, esi
call fcn.00440425
test al, al
je 0x440c6b
push 0x4aea68
lea ecx, [esi + 0x4c]
call fcn.0042c0ad
mov eax, dword [esi]
push 5
mov ecx, esi
call dword [eax + 0x10]
mov ecx, esi
call fcn.004405e7
and byte [ebp - 0x11], 0
and byte [ebp - 0x12], 0
call fcn.00442760
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x12]
mov ecx, esi
push eax
call fcn.0041d189
mov bl, al
cmp bl, 0x18
mov byte [ebp - 0x18], bl
jne 0x4409a2
mov ecx, dword [esi + 0xc]
lea edx, [ebp - 0x17]
push 2
push edx
mov eax, dword [ecx]
call dword [eax + 4]
movzx eax, word [ebp - 0x17]
push eax
push str.get_close_message_with_code_d
push str.S:Ammyy_sources_targetTrClient.cpp
push 2
push edi
call fcn.0041c87e
mov byte [esi + 0xc4], 1
add esp, 0x14
mov dword [esi + 0x210], 1
jmp 0x440c1f
cmp bl, 0x2f
jne 0x4409b3
mov ecx, esi
call fcn.00440d5a
jmp 0x440c1f
cmp bl, 0x30
jne 0x4409c1
mov ecx, esi
call fcn.0044003f
jmp 0x44094f
cmp bl, 0x31
jne 0x4409d2
mov ecx, esi
call fcn.0044021a
jmp 0x440c1f
cmp bl, 0x2d
je 0x4409eb
cmp bl, 0x34
je 0x4409eb
cmp bl, 0x2e
je 0x4409eb
cmp bl, 0xe
je 0x4409eb
cmp bl, 0x28
jne 0x440a0d
cmp byte [ebp - 0x11], 0
jne 0x440a02
push 0
lea ecx, [esi + 0x240]
mov byte [ebp - 0x11], 1
call fcn.00442791
lea ecx, [esi + 0x240]
call fcn.004428b0
movzx eax, bl
cmp eax, 0x33
jg 0x440b2f
je 0x440b00
cmp eax, 0x2a
jg 0x440a81
je 0x440a75
mov ecx, eax
sub ecx, 0xa
je 0x44094f
sub ecx, 3
je 0x440a69
dec ecx
je 0x440a5d
sub ecx, 0x1a
je 0x440a51
dec ecx
jne 0x440b97
mov ecx, esi
call fcn.00440f54
jmp 0x44094f
mov ecx, esi
call fcn.00440e14
jmp 0x44094f
mov ecx, esi
call fcn.00441391
jmp 0x44094f
mov ecx, esi
call fcn.00440c7a
jmp 0x44094f
mov ecx, esi
call fcn.00440f95
jmp 0x44094f
mov ecx, eax
sub ecx, 0x2b
je 0x440af4
dec ecx
je 0x440ae8
dec ecx
je 0x440ad9
dec ecx
je 0x440acd
sub ecx, 4
jne 0x440b97
cmp byte [esi + 0x69], 0
jne 0x440abe
lea eax, [ebp - 0x34]
push str.aaPopupAmmyy_is_forbidden
push eax
call fcn.0042783a
pop ecx
lea eax, [ebp - 0x34]
pop ecx
push 0x48e404
push eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, 0x4ae3c8
call fcn.004078aa
jmp 0x44094f
mov ecx, esi
call fcn.004411bf
jmp 0x44094f
push dword [ebp - 0x18]
mov ecx, esi
call fcn.00441084
jmp 0x44094f
mov ecx, esi
call fcn.00440ff8
jmp 0x44094f
mov ecx, esi
call fcn.00440fc5
jmp 0x44094f
cmp byte [esi + 0x69], 0
jne 0x440b24
lea eax, [ebp - 0x3c]
push str.aaComputerLock_is_forbidden
push eax
call fcn.0042783a
pop ecx
lea eax, [ebp - 0x3c]
pop ecx
push 0x48e404
push eax
call sub.MSVCRT.dll__CxxThrowException
call dword [sym.imp.USER32.dll_LockWorkStation]
jmp 0x44094f
cmp eax, 0x40
jg 0x440b87
je 0x440b7b
mov ecx, eax
sub ecx, 0x34
je 0x440ad9
sub ecx, 8
je 0x440b6f
dec ecx
je 0x440b63
dec ecx
je 0x440b57
dec ecx
jne 0x440b97
mov ecx, esi
call fcn.0044a6c6
jmp 0x44094f
mov ecx, esi
call fcn.0044a362
jmp 0x44094f
mov ecx, esi
call fcn.0044a571
jmp 0x44094f
mov ecx, esi
call fcn.00449d9d
jmp 0x44094f
mov ecx, esi
call fcn.0044add8
jmp 0x44094f
mov ecx, eax
sub ecx, 0x41
je 0x440bd5
dec ecx
je 0x440bc7
dec ecx
je 0x440bc3
dec ecx
je 0x440bb7
push eax
lea eax, [ebp - 0x44]
push str.invalid_message_received_:__u
push eax
call fcn.0042783a
add esp, 0xc
lea eax, [ebp - 0x44]
push 0x48e404
push eax
call sub.MSVCRT.dll__CxxThrowException
mov ecx, esi
call fcn.0044b0cb
jmp 0x44094f
push 1
jmp 0x440bc9
push 0
mov ecx, esi
call fcn.0044acab
jmp 0x44094f
mov ecx, esi
call fcn.0044a922
jmp 0x44094f
or dword [ebp - 4], 0xffffffff
cmp dword [ebp - 0x1c], 0
je 0x440c4e
push dword [ebp - 0x1c]
call dword [sym.imp.USER32.dll_SetThreadDesktop]
test eax, eax
jne 0x440c4e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push dword [ebp - 0x1c]
push str.ERROR_SetThreadDesktop__u___u
push edi
call fcn.004287df
add esp, 0x10
movsx eax, word [esi + 0x84]
push eax
push str.TrClient::Run__end_id_d
push str.S:Ammyy_sources_targetTrClient.cpp
push 2
push edi
call fcn.0041c87e
add esp, 0x14
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret