Function at 0x416f50
Capabilities:
Check mutex and terminate process on windows
Check mutex on windows
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov dword [ebp - 8], 0
push 0
call dword [sym.imp.ole32.dll_CoInitialize]
mov dword [ebp - 4], eax
cmp dword [ebp + 0x10], 0
je 0x41714c
mov eax, dword [ebp + 0x10]
movzx ecx, word [eax]
test ecx, ecx
je 0x41714c
push str.SAProc.mutex
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x41714c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x4170fd
call dword [sym.imp.USER32.dll_GetDesktopWindow]
mov dword [ebp - 0xc], eax
push 5
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.USER32.dll_GetWindow]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x4170fb
push 8
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.USER32.dll_GetWindowLongW]
cmp eax, 0xab2dfc02
jne 0x4170e2
push str._exit
mov edx, dword [ebp + 0x10]
push edx
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
jne 0x41708d
mov eax, dword [ebp - 0xc]
push eax
call fcn.00409200
add esp, 4
push str._mode:3
mov ecx, dword [ebp + 0x10]
push ecx
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
je 0x41702d
mov dword [ebp - 0x1c], 3
jmp 0x417067
push str._mode:2
mov edx, dword [ebp + 0x10]
push edx
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
test eax, eax
je 0x417049
mov dword [ebp - 0x20], 2
jmp 0x417061
push str._mode:1
mov eax, dword [ebp + 0x10]
push eax
call dword [sym.imp.SHLWAPI.dll_StrStrIW]
neg eax
sbb eax, eax
neg eax
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x20]
mov dword [ebp - 0x1c], ecx
mov edx, dword [ebp - 0x1c]
mov dword [ebp - 0x10], edx
cmp dword [ebp - 0x10], 0
je 0x41708b
mov eax, dword [ebp - 0x10]
push eax
push 0x82b
push 0x111
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.USER32.dll_PostMessageW]
jmp 0x4170e0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
lea edx, [ebp - 0x18]
push edx
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
test eax, eax
je 0x4170d0
mov ecx, dword [ebp - 0x18]
push ecx
push 1
push 1
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x4170d0
push 0
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
cmp dword [ebp - 0x14], 0
je 0x4170e0
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4170fb
push 2
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.USER32.dll_GetWindow]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x416fd7
jmp 0x41714c
call fcn.00419830
push 0
push 0
push 0
push 0
call dword [sym.imp.USER32.dll_DefWindowProcW]
push 0xff
call fcn.00418250
add esp, 4
push 0
mov edx, dword [ebp + 8]
push edx
push 0
mov ecx, 0x448a70
call fcn.00418280
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
call fcn.00416ca0
add esp, 8
mov ecx, 0x448a70
call fcn.004183d0
cmp dword [ebp - 8], 0
je 0x41715c
mov edx, dword [ebp - 8]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
call dword [sym.imp.ole32.dll_CoUninitialize]
mov eax, dword [ebp - 4]
mov esp, ebp
pop ebp
ret 0x10