Function at 0x40cde8
Capabilities:
Get storage device properties

Disassembly:
mov eax, 0x449c
call fcn.0041e670
push ebx
push ebp
push esi
mov ebp, ecx
push edi
lea ecx, [esp + 0x80]
mov esi, edx
call fcn.00405a51
push 6
pop ecx
xor ebx, ebx
xor eax, eax
push 7
lea edi, [esp + 0x6c]
mov dword [esp + 0x64], ebx
rep stosd dword es:[edi], eax
pop ecx
mov dword [esp + 0x18], ebx
lea edi, [esp + 0x1c]
rep stosd dword es:[edi], eax
push 0x20f
stosb byte es:[edi], al
lea eax, [esp + 0x29d]
push ebx
push eax
mov byte [esp + 0x2a4], bl
call fcn.004127c0
add esp, 0xc
lea eax, [esp + 0x4a9]
push 0x3fff
push ebx
push eax
mov byte [esp + 0x4b4], bl
call fcn.004127c0
mov eax, dword [esi + 4]
add esp, 0xc
mov dword [esp + 0x10], ebx
mov dword [esi + 8], ebx
test eax, eax
je 0x40ce72
xor ecx, ecx
mov word [eax], cx
test ebp, ebp
je 0x40d110
movzx eax, word [ebp]
push eax
lea eax, [esp + 0x84]
push 0x441658
push eax
call fcn.0040940c
mov ebp, dword [sym.imp.KERNEL32.DLL_CreateFileW]
add esp, 0xc
push ebx
push ebx
push 3
push ebx
push 3
push ebx
push dword [esp + 0x9c]
call ebp
mov edi, eax
cmp edi, 0xffffffff
je 0x40cee3
push ebx
lea eax, [esp + 0x14]
push eax
push 0x20
lea eax, [esp + 0x6c]
push eax
push ebx
push ebx
push 0x560000
push edi
call dword [sym.imp.KERNEL32.DLL_DeviceIoControl]
push edi
test eax, eax
jne 0x40cedd
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
jmp 0x40d110
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
push dword [esp + 0x68]
lea eax, [esp + 0x84]
push str..PHYSICALDRIVE_d
push eax
call fcn.0040940c
add esp, 0xc
push ebx
push ebx
push 3
push ebx
push 3
push 0xc0000000
push dword [esp + 0x9c]
call ebp
mov ebp, eax
cmp ebp, 0xffffffff
je 0x40cfe2
xor eax, eax
mov byte [esp + 0x48], bl
lea edi, [esp + 0x49]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
push ebx
stosb byte es:[edi], al
mov edi, dword [sym.imp.KERNEL32.DLL_DeviceIoControl]
lea eax, [esp + 0x18]
push eax
push 0x18
lea eax, [esp + 0x54]
push eax
push ebx
push ebx
push 0x74080
push ebp
mov dword [esp + 0x34], ebx
call edi
test eax, eax
je 0x40cfdb
cmp byte [esp + 0x4b], bl
jbe 0x40cfdb
push ebx
push ebx
push ebx
push ebp
call dword [sym.imp.KERNEL32.DLL_SetFilePointer]
mov eax, dword [esp + 0x68]
mov byte [esp + 0x24], al
and al, 1
or al, 0xfa
shl al, 4
push ebx
mov byte [esp + 0x25], al
lea eax, [esp + 0x14]
push eax
push 0x210
lea eax, [esp + 0x2a4]
push eax
push 0x21
lea eax, [esp + 0x2c]
push eax
push 0x7c088
push ebp
mov dword [esp + 0x38], 0x200
mov byte [esp + 0x42], 0xec
mov dword [esp + 0x3d], 0x101
mov byte [esp + 0x3c], bl
call edi
test eax, eax
je 0x40cfdb
mov eax, dword [esp + 0x10]
cmp eax, 0x100
jb 0x40cfdb
lea edx, [esp + 0x298]
push esi
add edx, eax
lea ecx, [esp + 0x2c0]
call fcn.0040d26d
pop ecx
push ebp
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
cmp dword [esi + 8], ebx
jne 0x40d10d
push ebx
push ebx
push 3
push ebx
push 3
push ebx
push dword [esp + 0x9c]
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
mov ebp, eax
cmp ebp, 0xffffffff
je 0x40d083
xor eax, eax
lea edi, [esp + 0x3c]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov edi, 0x4000
push edi
lea eax, [esp + 0x4ac]
push ebx
push eax
call fcn.004127c0
add esp, 0xc
lea eax, [esp + 0x10]
push ebx
push eax
push edi
lea eax, [esp + 0x4b4]
push eax
push 0xc
lea eax, [esp + 0x50]
push eax
push 0x2d1400
push ebp
mov dword [esp + 0x5c], ebx
mov dword [esp + 0x60], ebx
call dword [sym.imp.KERNEL32.DLL_DeviceIoControl]
test eax, eax
je 0x40d07c
mov eax, dword [esp + 0x10]
cmp eax, 0x28
jb 0x40d07c
lea ecx, [esp + 0x4a8]
add ecx, dword [esp + 0x4c0]
lea edx, [esp + 0x4a8]
push esi
add edx, eax
call fcn.0040d26d
pop ecx
push ebp
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
cmp dword [esi + 8], ebx
jne 0x40d10d
push ebx
push ebx
push 3
push ebx
push 3
push ebx
push dword [esp + 0x9c]
call dword [sym.imp.KERNEL32.DLL_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x40d10a
push 0x4000
lea eax, [esp + 0x4ac]
push ebx
push eax
call fcn.004127c0
add esp, 0xc
lea eax, [esp + 0x10]
push ebx
push eax
push 0x4000
lea eax, [esp + 0x4b4]
push eax
push ebx
push ebx
push 0x2d0c10
push edi
call dword [sym.imp.KERNEL32.DLL_DeviceIoControl]
test eax, eax
je 0x40d103
mov eax, dword [esp + 0x10]
cmp eax, 0x14
jb 0x40d103
lea edx, [esp + 0x4a8]
push esi
add edx, eax
lea ecx, [esp + 0x4bc]
call fcn.0040d26d
pop ecx
push edi
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
cmp dword [esi + 8], ebx
seta bl
pop edi
pop esi
pop ebp
mov al, bl
pop ebx
add esp, 0x449c
ret