Function at 0x405f00
Capabilities:
Check os version

Disassembly:
push 0xffffffffffffffff
push 0x41dea6
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x128
push ebx
push ebp
mov ebp, ecx
push esi
push edi
lea ecx, [esp + 0x10]
call fcn.0040b0b0
mov ecx, 0x25
xor eax, eax
lea edi, [esp + 0xa4]
xor ebx, ebx
rep stosd dword es:[edi], eax
lea eax, [esp + 0xa4]
mov dword [esp + 0x140], ebx
push eax
mov dword [esp + 0xa8], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
mov eax, dword [esp + 0xb4]
mov ecx, dword [esp + 0xa8]
mov edx, dword [esp + 0xac]
cmp eax, 2
mov dword [ebp + 8], ecx
mov dword [ebp + 0xc], edx
mov edi, 1
je 0x405f89
cmp eax, edi
jne 0x40626c
cmp eax, 2
jne 0x4060bf
cmp ecx, 3
mov dword [esp + 0x1c], 0x427584
mov dword [ebp], edi
jne 0x405fab
cmp edx, 0x33
je 0x40626c
lea ecx, [esp + 0x20]
lea edx, [esp + 0x14]
push ecx
push edx
call fcn.00408440
mov ecx, dword [esp + 0x1c]
mov eax, dword [esp + 0x28]
mov dword [ebp + 0x24], ecx
add esp, 8
lea ecx, [esp + 0x18]
mov dword [ebp + 0x20], eax
call fcn.0040b0b0
lea edx, [esp + 0x24]
push 0x80
push edx
push edi
push 0x4223f0
push 0x4223d4
push ebx
lea ecx, [esp + 0x30]
mov byte [esp + 0x158], 1
call fcn.0040b0d0
lea eax, [esp + 0x24]
push eax
call fcn.00413e60
add esp, 4
mov esi, 0x4223c8
lea eax, [esp + 0x24]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x406038
cmp cl, bl
je 0x406031
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x406038
add eax, 2
add esi, 2
cmp cl, bl
jne 0x406011
xor eax, eax
or esi, 0xffffffff
jmp 0x406041
sbb eax, eax
mov esi, 0xffffffff
sbb eax, esi
cmp eax, ebx
jne 0x40604c
mov dword [ebp + 0x1c], 1
push 0xe0000000
push ebx
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenSCManagerA]
cmp eax, ebx
je 0x40606b
push eax
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
mov dword [ebp + 0x18], 1
cmp dword [esp + 0xa8], 5
jne 0x406081
mov ecx, ebp
call fcn.00405ea0
mov dword [ebp + 0x14], eax
jmp 0x406089
cmp byte [0x427480], bl
jne 0x4060a8
lea ecx, [esp + 0x18]
mov dword [ebp + 0x10], ebx
mov byte [esp + 0x140], bl
call fcn.0040b0c0
mov dword [esp + 0x140], esi
jmp 0x406277
lea ecx, [esp + 0x18]
mov byte [esp + 0x140], bl
call fcn.0040b0c0
mov edi, 1
jmp 0x406131
push edi
call dword [sym.imp.USER32.dll_GetKeyboardType]
xor ecx, ecx
mov cl, ah
cmp cl, 0xd
jne 0x4060d2
mov dword [ebp + 0x1c], edi
mov eax, dword [ebp + 8]
mov dword [ebp], ebx
cmp eax, 4
jne 0x4060e5
cmp dword [ebp + 0xc], 0xa
jge 0x4060e7
cmp eax, eax
jle 0x4060ea
mov dword [ebp + 4], edi
call fcn.00408820
add eax, 0xc8a
cmp eax, 0xffff
jbe 0x4060fe
mov dword [ebp + 0x2c], edi
lea edx, [esp + 0x14]
push edx
push 4
push ebx
push 0x4223bc
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov esi, eax
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor ecx, ecx
cmp esi, 5
setne cl
mov dword [ebp + 0x18], ecx
or esi, 0xffffffff
cmp dword [esp + 0xb4], edi
jne 0x4061d0
lea edx, [esp + 0x24]
push 0x80
push edx
push edi
push 0x4223ac
push 0x422380
push ebx
lea ecx, [esp + 0x28]
call fcn.0040b0d0
lea edi, [esp + 0x24]
mov ecx, esi
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea eax, [esp + ecx + 0x24]
mov cl, byte [esp + ecx + 0x24]
cmp cl, 0x2e
je 0x406180
mov cl, byte [eax - 1]
dec eax
cmp cl, 0x2e
jne 0x406177
inc eax
push eax
call fcn.00413000
mov ecx, dword [ebp + 8]
add esp, 4
cmp ecx, 4
jne 0x4061a8
cmp eax, 0x3b6
jle 0x4061ad
mov dword [ebp + 0x10], ebx
mov dword [esp + 0x140], esi
jmp 0x406277
cmp eax, 0x3b6
jne 0x40620a
lea ecx, [esp + 0x14]
call fcn.0040b0b0
lea ecx, [esp + 0x14]
mov dword [ebp + 0x10], ebx
call fcn.0040b0c0
mov dword [esp + 0x140], esi
jmp 0x406277
lea edi, [esp + 0xb8]
mov ecx, esi
xor eax, eax
lea edx, [esp + 0x24]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x24]
push ecx
call fcn.00413b40
add esp, 4
lea esi, [esp + 0x24]
jmp 0x40620e
mov esi, dword [esp + 0x14]
push 0xd
push 0x422370
push esi
call fcn.00413b00
add esp, 0xc
test eax, eax
jne 0x406257
movsx edx, byte [esi + 0xd]
add esi, 0xd
push edx
call fcn.00413110
add esp, 4
test eax, eax
je 0x406248
movsx eax, byte [esi + 1]
inc esi
push eax
call fcn.00413110
add esp, 4
test eax, eax
jne 0x406236
mov edx, dword [esp + 0x1c]
mov cl, byte [esi]
cmp cl, byte [edx]
jl 0x406265
mov dword [ebp + 0x10], ebx
jmp 0x40626c
mov eax, dword [esp + 0x1c]
cmp byte [eax], 0x30
jne 0x406265
mov dword [ebp + 0x10], ebx
jmp 0x40626c
mov dword [ebp + 0x10], 1
mov dword [esp + 0x140], 0xffffffff
lea ecx, [esp + 0x10]
call fcn.0040b0c0
mov ecx, dword [esp + 0x138]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x134
ret