Function at 0x421058
Capabilities:
Check os version

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffde8
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 0x218], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov ebx, eax
lea eax, [ebp - 0x1d4]
mov edx, dword [0x40e17c]
call fcn.0040ad58
lea eax, [ebp - 0x214]
mov edx, dword [0x40e17c]
call fcn.0040ad58
xor eax, eax
push ebp
push 0x421522
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x14]
mov edx, dword [0x410fb4]
call fcn.0040b450
lea eax, [ebp - 0x18]
mov edx, dword [0x410fb4]
call fcn.0040b450
mov byte [ebp - 0xd], 0
xor eax, eax
mov dword [ebp - 0x38], eax
lea eax, [ebp - 0x34]
push eax
lea ecx, [ebp - 0x30]
lea edx, [ebp + 0x14]
lea eax, [ebp + 0x18]
call fcn.0041ec08
test al, al
je 0x4214c5
call fcn.00423eb4
call fcn.004146e8
mov eax, dword [ebp - 0xc]
or eax, 8
and eax, 0xffffffef
cmp eax, 0xffffffed
je 0x421118
cmp eax, 0xffffffec
je 0x421118
cmp eax, 0xffffffeb
jne 0x421484
call sub.KERNEL32.dll_GetVersion
test eax, 0x80000000
jne 0x421147
call fcn.004118fc
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
jne 0x42113e
push 5
call sub.KERNEL32.dll_SetLastError
jmp 0x4214c5
mov eax, dword [ebp - 0x20]
push eax
call sub.KERNEL32.dll_CloseHandle
mov esi, dword [ebp - 0xc]
or esi, 8
and esi, 0xffffffef
cmp esi, 0xffffffeb
jne 0x421166
call sub.KERNEL32.dll_GetCurrentProcess
lea edx, [ebp - 0x3c]
call fcn.004149bc
test al, al
jne 0x42116b
xor eax, eax
mov dword [ebp - 0x3c], eax
cmp dword [ebp - 0x3c], 0
je 0x421178
mov eax, dword [ebp - 0x3c]
mov eax, dword [eax]
jmp 0x42117a
xor eax, eax
cmp esi, 0xffffffec
je 0x421186
mov dword [ebp - 8], 0xffffffff
push eax
mov eax, dword [ebp - 8]
push eax
test byte [ebp - 0xc], 0x10
setne al
push eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x29]
push eax
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp + 0x18]
mov eax, ebx
call fcn.0041de60
mov byte [ebp - 0xd], al
cmp dword [ebp - 0x3c], 0
je 0x4211ba
mov eax, dword [ebp - 0x3c]
push eax
call sub.KERNEL32.dll_LocalFree
call sub.KERNEL32.dll_GetVersion
test eax, 0x80000000
sete al
and al, byte [ebp - 0x29]
je 0x4211eb
lea ecx, [ebp - 0x214]
lea edx, [ebp - 0x1d4]
lea eax, [ebp - 0x191]
call fcn.004209b0
test al, al
jne 0x4211eb
mov byte [ebp - 0x29], 0
cmp byte [0x429c18], 0
jne 0x4214c5
mov byte [ebp - 0x3d], 0
xor eax, eax
mov dword [ebp - 0x44], eax
cmp byte [ebp - 0x3d], 0
je 0x42120e
push 0xa
call sub.KERNEL32.dll_Sleep
mov byte [ebp - 0x3d], 0
mov byte [ebp - 0x22], 1
lea eax, [ebp - 0x14]
call fcn.004115a4
mov eax, dword [ebp - 0x14]
call fcn.0040b288
push eax
lea eax, [ebp - 0x1c]
mov ecx, 1
mov edx, dword [0x40be1c]
call fcn.0040b444
add esp, 4
mov eax, dword [ebp - 0x14]
call fcn.0040b290
test eax, eax
jl 0x421423
inc eax
mov dword [ebp - 0x48], eax
xor ebx, ebx
mov eax, dword [ebp - 0x1c]
xor edx, edx
mov dword [eax + ebx*4], edx
lea eax, [ebp - 0x218]
mov edx, ebx
add edx, edx
mov ecx, dword [ebp - 0x14]
mov edx, dword [ecx + edx*8 + 4]
call fcn.0040a784
mov eax, dword [ebp - 0x218]
call fcn.0041f2e4
mov byte [ebp - 0x21], al
mov eax, dword [ebp - 0x18]
call fcn.0040b290
test eax, eax
jl 0x4212ae
inc eax
xor edx, edx
mov ecx, edx
add ecx, ecx
mov esi, dword [ebp - 0x18]
mov ecx, dword [esi + ecx*8]
mov esi, ebx
add esi, esi
mov edi, dword [ebp - 0x14]
cmp ecx, dword [edi + esi*8]
jne 0x4212aa
mov byte [ebp - 0x21], 0
jmp 0x4212ae
inc edx
dec eax
jne 0x42128e
cmp byte [ebp - 0x21], 0
je 0x421419
call sub.KERNEL32.dll_GetCurrentProcessId
mov edx, ebx
add edx, edx
mov ecx, dword [ebp - 0x14]
cmp eax, dword [ecx + edx*8]
jne 0x4212d3
test byte [ebp - 0xc], 8
je 0x421419
mov byte [ebp - 0x22], 0
mov eax, ebx
add eax, eax
mov edx, dword [ebp - 0x14]
mov eax, dword [edx + eax*8]
push eax
push 0
push 0x47a
call sub.KERNEL32.dll_OpenProcess
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x4213f2
mov eax, dword [ebp - 0x20]
call fcn.0041b964
test al, al
jne 0x4213e7
cmp byte [ebp - 0x29], 0
je 0x421343
call sub.KERNEL32.dll_GetVersion
test eax, 0x80000000
jne 0x421343
lea eax, [ebp - 0x1d4]
push eax
lea eax, [ebp - 0x214]
push eax
mov eax, ebx
add eax, eax
mov edx, dword [ebp - 0x14]
mov edx, dword [edx + eax*8]
lea ecx, [ebp - 0x191]
mov eax, dword [ebp - 0x20]
call fcn.00420efc
mov eax, dword [ebp - 0xc]
or eax, 8
and eax, 0xffffffef
cmp eax, 0xffffffeb
jne 0x421368
mov eax, ebx
add eax, eax
mov edx, dword [ebp - 0x14]
mov edx, dword [edx + eax*8 + 0xc]
mov eax, dword [ebp - 0x20]
call fcn.0041ba88
test al, al
je 0x4213e7
test byte [ebp - 0xc], 0x10
jne 0x421385
mov eax, ebx
add eax, eax
mov edx, dword [ebp - 0x14]
mov edx, dword [edx + eax*8 + 0xc]
mov eax, dword [ebp - 0x20]
call fcn.0041b850
test al, al
jne 0x4213e7
mov eax, dword [ebp - 0xc]
or eax, 8
and eax, 0xffffffef
cmp eax, 0xffffffec
jne 0x4213cd
mov eax, ebx
add eax, eax
mov edx, dword [ebp - 0x14]
mov eax, dword [edx + eax*8]
call fcn.0041b9d0
cmp eax, dword [ebp - 8]
je 0x4213cd
mov esi, ebx
add esi, esi
mov eax, dword [ebp - 0x14]
mov eax, dword [eax + esi*8]
call fcn.0041b9d0
test eax, eax
jne 0x4213e7
mov eax, dword [ebp - 0x14]
mov edx, dword [eax + esi*8 + 0xc]
mov eax, dword [ebp - 0x20]
call fcn.0041b850
test al, al
je 0x4213e7
push ebp
mov eax, ebx
add eax, eax
mov edx, dword [ebp - 0x14]
mov edx, dword [edx + eax*8]
mov eax, dword [ebp - 0x1c]
lea ecx, [eax + ebx*4]
mov eax, dword [ebp - 0x20]
call fcn.0041fde4
pop ecx
mov eax, dword [ebp - 0x20]
push eax
call sub.KERNEL32.dll_CloseHandle
jmp 0x421419
call sub.KERNEL32.dll_GetLastError
mov dword [ebp - 0x20], eax
mov eax, ebx
add eax, eax
mov edx, dword [ebp - 0x14]
cmp dword [edx + eax*8], 0
je 0x421419
cmp dword [ebp - 0x20], 5
je 0x421419
mov edx, dword [ebp - 0x14]
xor ecx, ecx
mov dword [edx + eax*8], ecx
mov byte [ebp - 0x3d], 1
inc ebx
dec dword [ebp - 0x48]
jne 0x421253
cmp dword [ebp - 0x38], 0
jne 0x421431
call sub.KERNEL32.dll_GetTickCount
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x1c]
call fcn.0040b290
test eax, eax
jl 0x42145e
inc eax
mov dword [ebp - 0x48], eax
xor ebx, ebx
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax + ebx*4]
test eax, eax
je 0x421458
mov ecx, dword [ebp - 0x38]
mov edx, dword [ebp + 0x10]
call fcn.0041f270
inc ebx
dec dword [ebp - 0x48]
jne 0x421443
lea eax, [ebp - 0x18]
mov edx, dword [ebp - 0x14]
mov ecx, dword [0x410fb4]
call fcn.0040b48c
inc dword [ebp - 0x44]
cmp byte [ebp - 0x22], 0
jne 0x4214c5
cmp dword [ebp - 0x44], 5
jne 0x421201
jmp 0x4214c5
push ebp
mov eax, dword [ebp - 0xc]
push eax
call fcn.00413138
mov edx, eax
lea ecx, [ebp - 0x20]
mov eax, dword [ebp - 0xc]
call fcn.0041fde4
pop ecx
test al, al
je 0x4214bc
cmp dword [ebp - 0x20], 0
je 0x4214c0
call sub.KERNEL32.dll_GetTickCount
mov ecx, eax
mov edx, dword [ebp + 0x10]
mov eax, dword [ebp - 0x20]
call fcn.0041f270
test al, al
jne 0x4214c0
xor eax, eax
jmp 0x4214c2
mov al, 1
mov byte [ebp - 0xd], al
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x421529
lea eax, [ebp - 0x218]
call fcn.0040a508
lea eax, [ebp - 0x214]
mov edx, dword [0x40e17c]
mov ecx, 2
call fcn.0040ae68
lea eax, [ebp - 0x34]
mov edx, 2
call fcn.0040a52c
lea eax, [ebp - 0x1c]
mov edx, dword [0x40be1c]
call fcn.0040b450
lea eax, [ebp - 0x18]
mov edx, dword [0x410fb4]
mov ecx, 2
call fcn.0040ae68
ret