Function at 0x40601a
Capabilities:
Check mutex on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
push edi
xor eax, eax
mov edi, ecx
push 0x4022e0
push 1
push eax
mov esi, eax
mov byte [ebp - 1], al
mov byte [ebp - 2], al
call dword [sym.imp.KERNEL32.dll_CreateMutexW]
mov dword [0x411850], eax
test eax, eax
je 0x406066
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x406066
push 0x2710
push dword [0x411850]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0x402298
call dword [sym.imp.USER32.dll_RegisterWindowMessageW]
push 4
push dword [0x411038]
lea ecx, [ebp - 0x14]
mov dword [0x411858], eax
mov dword [ebp - 0x14], 0x67727473
mov dword [ebp - 0x10], 0x4118b8
call fcn.0040f6d6
push dword [ebp - 0x10]
push 0x402314
call dword [sym.imp.USER32.dll_FindWindowW]
mov ebx, eax
test ebx, ebx
je 0x4060f1
and dword [ebp - 8], esi
lea eax, [ebp - 8]
push eax
push ebx
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
push dword [ebp - 8]
call dword [sym.imp.USER32.dll_AllowSetForegroundWindow]
lea eax, [ebp - 0xc]
push eax
push 0x2710
push 2
push 0
push 0
push dword [0x411858]
push ebx
call dword [sym.imp.USER32.dll_SendMessageTimeoutW]
test eax, eax
je 0x4060f1
cmp dword [ebp - 0xc], 0x77636364
jne 0x4060f1
mov esi, 0x800700b7
mov byte [ebp - 2], 1
or dword [edi + 0x28], 0x14000004
mov dword [edi + 0x34], 0x64
test esi, esi
js 0x4066a1
push 0xa8
call fcn.0040fbc4
mov esi, eax
lea ebx, [edi + 0x64]
pop ecx
test esi, esi
je 0x406132
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 5
push 0x64
call fcn.0040a2d3
mov dword [esi], 0x4018f4
jmp 0x406134
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xa8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x40616e
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0xf
push 0x69
call fcn.0040a2d3
mov dword [esi], 0x4018c0
jmp 0x406170
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xcc
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x4061c2
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x226
push 0x221
push 0x21c
push 0x64
push 0x5f
push 0x5a
push 0x55
push 0x9b
call fcn.0040b613
mov dword [esi], 0x4015b8
jmp 0x4061c4
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xec
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x40620d
push 0
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x228
push 0x22b
push 0x6e
push 0xa0
call fcn.0040bb31
mov dword [esi], 0x40156c
jmp 0x40620f
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xa8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x406249
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x14
push 0x6e
call fcn.0040a2d3
mov dword [esi], 0x4012c8
jmp 0x40624e
xor esi, esi
lea ebx, [edi + 0x64]
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xcc
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x4062a0
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x1fe
push 0x1f9
push 0x1f4
push 0x28
push 0x23
push 0x1e
push 0x19
push 0x87
call fcn.0040b613
mov dword [esi], 0x401784
jmp 0x4062a2
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xc8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x4062e6
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x226
push 0x203
push 0x32
push 0x78
call fcn.0040702a
mov dword [esi], fcn.00406f80
jmp 0x4062e8
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xcc
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x40633a
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x212
push 0x20d
push 0x208
push 0x46
push 0x41
push 0x3c
push 0x37
push 0x91
call fcn.0040b613
mov dword [esi], 0x401800
jmp 0x40633c
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xc8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x406383
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x227
push 0x217
push 0x50
push 0x82
call fcn.0040702a
mov dword [esi], fcn.00406f80
jmp 0x406388
xor esi, esi
lea ebx, [edi + 0x64]
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xe8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x4063d1
push 1
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x226
push 0x203
push 0x32
push 0x8c
call fcn.0040bb31
mov dword [esi], fcn.0040ac00
jmp 0x4063d3
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xe8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x40641c
push 1
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x227
push 0x217
push 0x50
push 0x96
call fcn.0040bb31
mov dword [esi], fcn.0040ac00
jmp 0x40641e
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xa8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x40645b
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x73
push 0xa5
call fcn.0040a2d3
mov dword [esi], 0x401614
jmp 0x40645d
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xcc
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x4064ae
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x229
push 0x24e
push 0x82
push 0xaf
call fcn.0040702a
and dword [esi + 0xc8], 0
mov dword [esi], 0x4016ac
jmp 0x4064b3
xor esi, esi
lea ebx, [edi + 0x64]
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xa8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x4064f0
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0x78
push 0xb4
call fcn.0040a2d3
mov dword [esi], 0x401894
jmp 0x4064f2
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0x108
call fcn.0040fbc4
pop ecx
test eax, eax
je 0x406520
push dword [edi + 0x6c]
mov ecx, eax
push ebx
call fcn.0040cd5e
jmp 0x406522
xor eax, eax
push eax
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xac
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x40655d
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0xd7
call fcn.0040a984
mov dword [esi], 0x401540
jmp 0x40655f
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xac
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x40659a
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0xdc
call fcn.0040a984
mov dword [esi], 0x401830
jmp 0x40659f
xor esi, esi
lea ebx, [edi + 0x64]
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
push 0xa8
call fcn.0040fbc4
mov esi, eax
pop ecx
test esi, esi
je 0x4065df
push dword [edi + 0x6c]
mov ecx, esi
push ebx
push 0xd2
push 0xe1
call fcn.0040a2d3
mov dword [esi], 0x401920
jmp 0x4065e1
xor esi, esi
push esi
mov ecx, edi
call fcn.004069bf
mov esi, eax
test esi, esi
js 0x4066a1
xor esi, esi
xor ebx, ebx
push dword [ebx + 0x401a10]
call dword [sym.imp.USER32.dll_RegisterWindowMessageW]
mov dword [ebx + 0x41185c], eax
test eax, eax
je 0x406617
add ebx, 4
cmp ebx, 4
jl 0x4065f7
jmp 0x40662c
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40662e
movzx esi, si
or esi, 0x80070000
test esi, esi
js 0x4066a1
lea eax, [edi + 0xe0]
push eax
call dword [sym.imp.mscms.dll_WcsGetCalibrationManagementState]
test eax, eax
jne 0x406667
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x406656
movzx esi, si
or esi, 0x80070000
push esi
mov edx, 0x13a
xor ecx, ecx
call fcn.0040e302
mov byte [ebp - 1], 1
test esi, esi
js 0x4066a1
push 0
call dword [sym.imp.mscms.dll_WcsSetCalibrationManagementState]
test eax, eax
jne 0x40669d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
test esi, esi
jle 0x40668c
movzx esi, si
or esi, 0x80070000
push esi
mov edx, 0x13c
xor ecx, ecx
call fcn.0040e302
mov byte [ebp - 1], 1
test esi, esi
jns 0x4066dd
mov eax, dword [0x411850]
test eax, eax
je 0x4066c4
push eax
call dword [sym.imp.KERNEL32.dll_ReleaseMutex]
push dword [0x411850]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
and dword [0x411850], 0
cmp byte [ebp - 1], 0
jne 0x4066dd
cmp byte [ebp - 2], 0
jne 0x4066dd
push esi
mov edx, 0x13e
xor ecx, ecx
call fcn.0040e302
lea ecx, [ebp - 0x14]
call fcn.0040f52d
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret