Function at 0x40d1fc
Capabilities:
Check os version
Get system information on windows

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffebc
push ebx
push esi
push edi
mov esi, edx
mov ebx, eax
lea edi, [ebp - 0x144]
xor eax, eax
mov dword [ebp - 4], eax
xor edx, edx
push ebp
push 0x40d63a
push dword fs:[edx]
mov dword fs:[edx], esp
mov dword [edi], 0x11c
push edi
call sub.kernel32.dll_GetVersionExW
test eax, eax
jne 0x40d24f
mov dword [edi], 0x114
push edi
call sub.kernel32.dll_GetVersionExW
test eax, eax
jne 0x40d24f
call sub.rtl120.bpl__System__TryFinallyExit_qqrv
jmp 0x40d641
cmp dword [edi + 0x10], 2
je 0x40d25f
call sub.rtl120.bpl__System__TryFinallyExit_qqrv
jmp 0x40d641
test ebx, ebx
je 0x40d26d
movzx eax, word [edi + 0x118]
mov word [ebx], ax
test esi, esi
je 0x40d27a
movzx eax, byte [edi + 0x11a]
mov byte [esi], al
cmp dword [0x411208], 0
je 0x40d295
mov eax, dword [0x411208]
mov dword [ebp - 4], eax
call sub.rtl120.bpl__System__TryFinallyExit_qqrv
jmp 0x40d641
lea eax, [ebp - 0x28]
mov edx, 0x24
call fcn.0040143c
push 0x40d64c
push 0x40d674
call sub.kernel32.dll_GetModuleHandleW_1
push eax
call fcn.00401370
test eax, eax
je 0x40d2c3
lea edx, [ebp - 0x28]
push edx
call eax
jmp 0x40d2cc
lea eax, [ebp - 0x28]
push eax
call sub.kernel32.dll_GetSystemInfo
cmp dword [edi + 4], 5
jne 0x40d2e1
cmp dword [edi + 8], 1
jne 0x40d2e1
cmp byte [edi + 0x11a], 1
je 0x40d2f6
cmp dword [edi + 4], 5
jne 0x40d335
cmp dword [edi + 8], 2
jne 0x40d335
cmp byte [edi + 0x11a], 1
jne 0x40d335
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d311
sub ax, 5
je 0x40d329
sub ax, 3
je 0x40d31d
jmp 0x40d624
mov dword [ebp - 4], 1
jmp 0x40d624
mov dword [ebp - 4], 2
jmp 0x40d624
mov dword [ebp - 4], 4
jmp 0x40d624
cmp dword [edi + 4], 6
jne 0x40d389
cmp dword [edi + 8], 0
jne 0x40d389
cmp byte [edi + 0x11a], 1
jne 0x40d389
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d365
sub ax, 5
je 0x40d37d
sub ax, 3
je 0x40d371
jmp 0x40d624
mov dword [ebp - 4], 8
jmp 0x40d624
mov dword [ebp - 4], 0x10
jmp 0x40d624
mov dword [ebp - 4], 0x20
jmp 0x40d624
cmp dword [edi + 4], 6
jne 0x40d3dd
cmp dword [edi + 8], 1
jne 0x40d3dd
cmp byte [edi + 0x11a], 1
jne 0x40d3dd
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d3b9
sub ax, 5
je 0x40d3d1
sub ax, 3
je 0x40d3c5
jmp 0x40d624
mov dword [ebp - 4], 0x40
jmp 0x40d624
mov dword [ebp - 4], 0x80
jmp 0x40d624
mov dword [ebp - 4], pe_nt_image_headers32
jmp 0x40d624
cmp dword [edi + 4], 6
jne 0x40d431
cmp dword [edi + 8], 2
jne 0x40d431
cmp byte [edi + 0x11a], 1
jne 0x40d431
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d40d
sub ax, 5
je 0x40d425
sub ax, 3
je 0x40d419
jmp 0x40d624
mov dword [ebp - 4], 0x200
jmp 0x40d624
mov dword [ebp - 4], 0x400
jmp 0x40d624
mov dword [ebp - 4], 0x800
jmp 0x40d624
cmp dword [edi + 4], 6
jne 0x40d485
cmp dword [edi + 8], 3
jne 0x40d485
cmp byte [edi + 0x11a], 1
jne 0x40d485
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d461
sub ax, 5
je 0x40d479
sub ax, 3
je 0x40d46d
jmp 0x40d624
mov dword [ebp - 4], 0x200000
jmp 0x40d624
mov dword [ebp - 4], 0x400000
jmp 0x40d624
mov dword [ebp - 4], 0x800000
jmp 0x40d624
cmp dword [edi + 4], 6
jne 0x40d4d9
cmp dword [edi + 8], 4
jne 0x40d4d9
cmp byte [edi + 0x11a], 1
jne 0x40d4d9
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d4b5
sub ax, 5
je 0x40d4cd
sub ax, 3
je 0x40d4c1
jmp 0x40d624
mov dword [ebp - 4], 0x1000000
jmp 0x40d624
mov dword [ebp - 4], 0x2000000
jmp 0x40d624
mov dword [ebp - 4], 0x4000000
jmp 0x40d624
cmp dword [edi + 4], 0xa
jne 0x40d52d
cmp dword [edi + 8], 0
jne 0x40d52d
cmp byte [edi + 0x11a], 1
jne 0x40d52d
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d509
sub ax, 5
je 0x40d521
sub ax, 3
je 0x40d515
jmp 0x40d624
mov dword [ebp - 4], 0x1000000
jmp 0x40d624
mov dword [ebp - 4], 0x2000000
jmp 0x40d624
mov dword [ebp - 4], 0x4000000
jmp 0x40d624
cmp dword [edi + 4], 5
jne 0x40d581
cmp dword [edi + 8], 2
jne 0x40d581
cmp byte [edi + 0x11a], 1
je 0x40d581
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d55d
sub ax, 5
je 0x40d575
sub ax, 3
je 0x40d569
jmp 0x40d624
mov dword [ebp - 4], 0x1000
jmp 0x40d624
mov dword [ebp - 4], 0x2000
jmp 0x40d624
mov dword [ebp - 4], 0x4000
jmp 0x40d624
cmp dword [edi + 4], 6
jne 0x40d596
cmp dword [edi + 8], 0
jne 0x40d596
cmp byte [edi + 0x11a], 1
jne 0x40d5ab
cmp dword [edi + 4], 6
jne 0x40d5de
cmp dword [edi + 8], 1
jne 0x40d5de
cmp byte [edi + 0x11a], 1
je 0x40d5de
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d5c3
sub ax, 5
je 0x40d5d5
sub ax, 3
je 0x40d5cc
jmp 0x40d624
mov dword [ebp - 4], 0x8000
jmp 0x40d624
mov dword [ebp - 4], 0x10000
jmp 0x40d624
mov dword [ebp - 4], 0x20000
jmp 0x40d624
cmp dword [edi + 4], 6
jne 0x40d624
cmp dword [edi + 8], 2
jne 0x40d624
cmp byte [edi + 0x11a], 1
je 0x40d624
movzx eax, word [ebp - 0x28]
sub ax, 1
jb 0x40d60b
sub ax, 5
je 0x40d61d
sub ax, 3
je 0x40d614
jmp 0x40d624
mov dword [ebp - 4], 0x40000
jmp 0x40d624
mov dword [ebp - 4], 0x80000
jmp 0x40d624
mov dword [ebp - 4], 0x100000
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40d641
mov eax, dword [ebp - 4]
mov dword [0x411208], eax
ret
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret