Function at 0x40a100
Capabilities:
Check os version
Get storage device properties

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x422360
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
mov eax, dword [0x42e008]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], 0
mov dword [ebp - 4], 0
call fcn.0040b780
mov edi, eax
test edi, edi
je 0x40a4b7
mov eax, dword [edi]
mov esi, dword [eax + 0xc]
mov ecx, esi
call dword [0x4232ec]
mov ecx, edi
call esi
add eax, 0x10
mov dword [ebp - 0x38], eax
xorps xmm0, xmm0
mov dword [ebp - 4], 1
xor ebx, ebx
movq qword [ebp - 0x1c], xmm0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x20], ebx
call dword [sym.imp.KERNEL32.dll_GetVersion]
push dword [ebp + 8]
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x38]
push 0x424ae8
push eax
call fcn.00409ff0
mov edi, dword [ebp - 0x38]
add esp, 0xc
push ebx
push ebx
push 3
push ebx
push 3
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
or esi, 0xffffffff
mov dword [ebp - 0x44], eax
cmp eax, esi
jne 0x40a1c7
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x2c], eax
jmp 0x40a46e
push 0x1001
call fcn.00415196
mov ebx, eax
add esp, 4
mov dword [ebp - 0x40], ebx
test ebx, ebx
jne 0x40a1e9
mov dword [ebp - 0x2c], 8
jmp 0x40a465
push 0x1001
push 0
push ebx
call fcn.00411ee0
add esp, 0xc
mov dword [ebp - 0x1c], 0
lea eax, [ebp - 0x20]
mov dword [ebp - 0x18], 0
push 0
push eax
push 0x1000
push ebx
push 0xc
lea eax, [ebp - 0x1c]
push eax
push 0x2d1400
push dword [ebp - 0x44]
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
jne 0x40a239
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x2c], eax
jmp 0x40a465
mov ecx, dword [ebx + 0x18]
test ecx, ecx
je 0x40a45e
cmp ecx, dword [ebp - 0x20]
jae 0x40a45e
mov eax, dword [ebp - 0x28]
cmp al, 6
ja 0x40a41b
jne 0x40a265
shr eax, 8
cmp al, 2
jae 0x40a41b
mov byte [ebp - 4], 2
call fcn.0040b780
mov dword [ebp - 0x28], eax
test eax, eax
je 0x40a4c1
mov eax, dword [eax]
mov esi, dword [eax + 0xc]
mov ecx, esi
call dword [0x4232ec]
mov ecx, dword [ebp - 0x28]
call esi
lea esi, [eax + 0x10]
mov dword [ebp - 0x3c], esi
mov edx, dword [ebp - 0x20]
sub edx, dword [ebx + 0x18]
mov byte [ebp - 4], 3
js 0x40a4cb
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
sub eax, edx
or eax, ecx
jge 0x40a2be
push edx
lea ecx, [ebp - 0x3c]
call fcn.0040c8c0
mov esi, dword [ebp - 0x3c]
mov eax, dword [ebx + 0x18]
push esi
add eax, ebx
push 1
push eax
call fcn.0040cdd0
add esp, 0xc
lea ebx, [esi - 0x10]
mov dword [ebp - 0x28], ebx
test esi, esi
jne 0x40a2dd
xor eax, eax
jmp 0x40a2f1
push dword [ebx + 8]
push esi
call fcn.00415637
add esp, 8
test eax, eax
js 0x40a4cb
cmp eax, dword [ebx + 8]
jg 0x40a4cb
mov edx, dword [ebp - 0x30]
mov dword [ebx + 4], eax
mov byte [eax + esi], 0
mov ecx, dword [edx]
sub ecx, 0x10
mov dword [ebp - 0x34], ecx
cmp ebx, ecx
je 0x40a3e2
lea eax, [ecx + 0xc]
mov dword [ebp - 0x48], eax
mov eax, dword [eax]
shr eax, 0x1f
test al, al
jne 0x40a3d7
mov eax, dword [ebx]
mov dword [ebp - 0x24], eax
cmp eax, dword [ecx]
jne 0x40a3d7
mov eax, dword [eax]
mov esi, dword [eax + 0x10]
mov ecx, esi
call dword [0x4232ec]
mov ecx, dword [ebp - 0x24]
call esi
mov ecx, dword [ebx + 0xc]
lea edx, [ebx + 0xc]
shr ecx, 0x1f
mov dword [ebp - 0x24], eax
test cl, cl
jne 0x40a362
cmp eax, dword [ebx]
jne 0x40a362
mov dword [ebp - 0x24], ebx
lock inc dword [edx]
jmp 0x40a3a1
mov eax, dword [eax]
push 1
push dword [ebx + 4]
mov esi, dword [eax]
mov ecx, esi
call dword [0x4232ec]
mov ecx, dword [ebp - 0x24]
call esi
mov esi, eax
mov dword [ebp - 0x24], esi
test esi, esi
je 0x40a4d5
mov eax, dword [ebx + 4]
lea ecx, [esi + 0x10]
mov dword [esi + 4], eax
lea eax, [ebx + 0x10]
mov edx, dword [ebx + 4]
inc edx
push edx
push eax
push edx
push ecx
call fcn.0040cfb0
add esp, 0x10
mov ecx, dword [ebp - 0x48]
or eax, 0xffffffff
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x40a3ca
mov ecx, dword [ebp - 0x34]
push ecx
mov ebx, dword [ecx]
mov eax, dword [ebx]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x4232ec]
mov ecx, ebx
call esi
mov ebx, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x30]
mov eax, dword [ebp - 0x24]
add eax, 0x10
mov dword [ecx], eax
jmp 0x40a3e2
push dword [ebx + 4]
mov ecx, edx
push esi
call fcn.0040cb70
or esi, 0xffffffff
mov byte [ebp - 4], 1
mov eax, esi
lock xadd dword [ebx + 0xc], eax
dec eax
test eax, eax
jg 0x40a40e
mov ebx, dword [ebx]
push dword [ebp - 0x28]
mov eax, dword [ebx]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x4232ec]
mov ecx, ebx
call esi
or esi, 0xffffffff
mov ecx, dword [ebp - 0x30]
mov ebx, dword [ebp - 0x40]
call fcn.0040cc50
jmp 0x40a465
lea edx, [ecx + ebx]
test edx, edx
jne 0x40a438
xor ecx, ecx
push ecx
mov ecx, dword [ebp - 0x30]
push edx
call fcn.0040cb70
mov ecx, dword [ebp - 0x30]
call fcn.0040cc50
jmp 0x40a465
mov ecx, edx
lea eax, [ecx + 1]
mov dword [ebp - 0x34], eax
mov al, byte [ecx]
inc ecx
test al, al
jne 0x40a440
sub ecx, dword [ebp - 0x34]
push ecx
mov ecx, dword [ebp - 0x30]
push edx
call fcn.0040cb70
mov ecx, dword [ebp - 0x30]
call fcn.0040cc50
jmp 0x40a465
mov dword [ebp - 0x2c], 0xd
push dword [ebp - 0x44]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call fcn.00415191
add esp, 4
lea ecx, [edi - 0x10]
lock xadd dword [ecx + 0xc], esi
dec esi
test esi, esi
jg 0x40a498
mov edi, dword [ecx]
push ecx
mov eax, dword [edi]
mov esi, dword [eax + 4]
mov ecx, esi
call dword [0x4232ec]
mov ecx, edi
call esi
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00410bbe
mov esp, ebp
pop ebp
ret
push 0x80004005
call fcn.00409da0
push 0x80004005
call fcn.00409da0
push 0x80070057
call fcn.00409da0
call fcn.0040cc40
int3