Function at 0x4037c0
Capabilities:
Check mutex and terminate process on windows
Check mutex on windows
Create thread
Terminate process

Disassembly:
add al, 0xe7
inc eax
add byte [eax - 1], dl
salc
test eax, eax
mov dword [esp + 0x38], eax
jne 0x403698
mov ecx, 0xb
mov esi, str.Failed_get_pointer_to_a_setupapi.dll_function.
mov edi, 0x40f920
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
mov dword [esp + 0x10], 1
mov dword [esp + 0x1c], 6
movsb byte es:[edi], byte [esi]
jmp 0x4039c4
push str.haspds_Install
push ebx
call esi
push str.haspds_UnInstall
push ebx
mov edi, eax
call esi
push str.haspds_GetInfo
push ebx
mov dword [esp + 0x1c], eax
call esi
push str.haspds_GetVendorInfo
push ebx
mov dword [esp + 0x34], eax
call esi
push str.haspds_GetLastErrorMessage
push ebx
mov dword [esp + 0x38], eax
call esi
push str.haspds_GetVersion
push ebx
mov dword [0x412840], eax
call esi
push str.haspds_SetParameter
push ebx
mov dword [0x412838], eax
call esi
push str.haspds_GetLastError_Ex
push ebx
mov dword [esp + 0x20], eax
call esi
push str.haspds_GetLastError
push ebx
mov dword [0x41283c], eax
call esi
push str.haspds_ExitProcess
push ebx
mov dword [esp + 0x2c], eax
call esi
test edi, edi
mov dword [0x412844], eax
je 0x4039a5
mov ecx, dword [esp + 0x24]
test ecx, ecx
je 0x4039a5
mov ecx, dword [0x41283c]
test ecx, ecx
je 0x4039a5
mov ecx, dword [esp + 0x14]
test ecx, ecx
je 0x4039a5
mov ecx, dword [esp + 0x2c]
test ecx, ecx
je 0x4039a5
mov ecx, dword [esp + 0x30]
test ecx, ecx
je 0x4039a5
mov ecx, dword [0x412840]
test ecx, ecx
je 0x4039a5
mov ecx, dword [0x412838]
test ecx, ecx
je 0x4039a5
mov edx, dword [esp + 0x18]
test edx, edx
je 0x4039a5
test eax, eax
je 0x4039a5
call ecx
push 0x410ca8
mov dword [esp + 0x2c], eax
call fcn.00402330
mov esi, dword [ebp + 8]
mov ecx, dword [esi]
add esp, 4
test cl, 8
je 0x4037fe
mov eax, dword [esi + 8]
push 0
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
mov ecx, dword [esp + 0x28]
mov edx, dword [esi + 0xc]
push ecx
push edx
call fcn.00403460
mov eax, dword [esi + 8]
add esp, 8
test eax, eax
je 0x4037dd
push 0
push 0
push 2
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov dword [esi + 8], 0
mov esi, dword [esi + 0x10]
test esi, esi
je 0x4037ed
push 0
push esi
call dword [sym.imp.KERNEL32.dll_TerminateThread]
push 0
mov dword [0x412834], 0x10002
call fcn.0040471d
test cl, 2
je 0x40382f
mov eax, ecx
mov edx, ecx
and eax, 0xffffff00
shr edx, 7
shl eax, 0x17
and edx, 4
or eax, edx
and ecx, 1
or eax, ecx
push eax
call edi
mov esi, eax
mov dword [esp + 0x10], esi
call dword [esp + 0x24]
mov dword [esp + 0x1c], eax
jmp 0x403833
mov esi, dword [esp + 0x10]
mov edi, dword [ebp + 8]
mov ecx, dword [edi]
test cl, 0x84
jne 0x403842
test ch, 0x40
je 0x40387e
mov eax, ecx
shr eax, 5
and eax, 0x200
mov edx, ecx
and edx, 0x80
or eax, edx
mov edx, ecx
and edx, 0xffffff00
shr eax, 6
shl edx, 0x17
or eax, edx
and ecx, 1
or eax, ecx
push eax
call dword [esp + 0x18]
mov esi, eax
mov dword [esp + 0x10], esi
call dword [esp + 0x24]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x3c]
test eax, eax
je 0x4038ac
mov eax, dword [edi]
test ah, 0x10
je 0x403899
push 1
call dword [esp + 0x1c]
mov esi, eax
mov dword [esp + 0x10], esi
mov eax, dword [edi]
test ah, 0x20
je 0x4038ac
push 2
call dword [esp + 0x1c]
mov esi, eax
mov dword [esp + 0x10], esi
test byte [edi], 0x20
je 0x4039c8
lea eax, [esp + 0x14]
xor edi, edi
push eax
push edi
mov dword [esp + 0x20], edi
mov dword [esp + 0x1c], edi
call dword [esp + 0x34]
mov esi, eax
cmp esi, 3
mov dword [esp + 0x10], esi
jne 0x4038f5
mov ecx, dword [esp + 0x14]
push ecx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
lea edx, [esp + 0x14]
push edx
push eax
mov dword [esp + 0x20], eax
call dword [esp + 0x34]
mov esi, eax
mov dword [esp + 0x10], esi
call dword [esp + 0x24]
mov dword [esp + 0x1c], eax
lea eax, [esp + 0x14]
push eax
push 0
mov dword [esp + 0x1c], 0
call dword [esp + 0x38]
mov ecx, dword [esp + 0x14]
test ecx, ecx
je 0x403947
cmp eax, 3
jne 0x403947
push ecx
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
lea ecx, [esp + 0x14]
mov edi, eax
push ecx
push edi
call dword [esp + 0x38]
test eax, eax
je 0x403947
test edi, edi
mov esi, eax
mov dword [esp + 0x10], esi
je 0x403947
push edi
call dword [sym.imp.KERNEL32.dll_LocalFree]
test esi, esi
jne 0x40395d
mov edx, dword [ebp + 8]
mov eax, dword [edx + 8]
test eax, eax
je 0x40395d
push esi
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x18]
mov edx, dword [ebp + 8]
push eax
mov eax, dword [edx + 0xc]
push edi
push ecx
push eax
call fcn.00403420
mov ecx, dword [ebp + 8]
mov eax, dword [ecx + 0x10]
add esp, 0x10
test eax, eax
je 0x403994
mov edx, ecx
mov dword [0x412830], 1
mov dword [edx + 0x10], 0
mov eax, dword [esp + 0x18]
test eax, eax
je 0x4039c8
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x4039c8
mov ecx, 6
mov dword [esp + 0x10], 1
mov dword [esp + 0x1c], ecx
mov esi, str.Failed_to_unpack_drivers.
mov edi, 0x40f920
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
mov esi, dword [esp + 0x10]
mov edi, dword [ebp + 8]
mov eax, dword [edi]
test al, 0x10
jne 0x403b14
cmp esi, 7
ja 0x403a9a
jmp dword [esi*4 + 0x403798]
mov eax, dword [edi + 8]
test eax, eax
je 0x403b14
mov eax, dword [edi]
test al, 0x8e
jne 0x403ab5
test ah, 0x70
jne 0x403ab5
test al, 0x20
je 0x403b14
cmp esi, 1
jne 0x403b14
mov eax, dword [esp + 0x34]
and eax, 6
je 0x403ada
test esi, esi
jne 0x403ada
mov ecx, 0x20
mov esi, str.Installation_successful._nNote_that_the_Run_time_Environment_on_this_operating_system_only_supports_HASP_HL__HASP4_and_Hardlock.
mov edi, 0x40f920
rep movsd dword es:[edi], dword [esi]
mov esi, dword [esp + 0x10]
mov edi, dword [ebp + 8]
test eax, eax
je 0x403afe
cmp esi, 2
jne 0x403afe
mov ecx, 0x2b
mov esi, str.Operation_successfully_completed.Reboot_system_to_activate_new_drivers._nNote_that_the_Run_time_Environment_on_this_operating_system_only_supports_HASP_HL__HASP4_and_Hardlock.
mov edi, 0x40f920
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x10]
mov edi, dword [ebp + 8]
mov ecx, dword [esp + 0x28]
mov edx, dword [edi + 8]
push ecx
push 0x40f920
push edx
call fcn.00403050
add esp, 0xc
push 0x5dc
mov dword [0x412830], 1
call dword [sym.imp.KERNEL32.dll_Sleep]
test ebx, ebx
je 0x403b34
push ebx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
cmp word [esp + 0x148], 0
je 0x403b4d
lea eax, [esp + 0x148]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [edi + 8]
test eax, eax
je 0x403b61
push 0
push 0
push 2
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
test esi, esi
mov dword [edi + 4], esi
je 0x403b79
mov eax, dword [esp + 0x1c]
shl esi, 0x10
or esi, eax
mov dword [0x412834], esi
jmp 0x403b7f
mov esi, dword [0x412834]
test byte [edi], 0x50
jne 0x403b8b
push esi
call dword [sym.imp.KERNEL32.dll_ExitThread]
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [esp + 8]
mov edx, dword [esp + 4]
lea eax, [edx + ecx]
dec ecx
cmp ecx, 3
ja case.default.0x403f31
jmp dword [ecx*4 + 0x403ba8]
xor eax, eax
ret