Function at 0x52591c
Capabilities:
Get storage device properties

Disassembly:
push ebp
mov ebp, esp
push ecx
mov ecx, 0x30
push 0
push 0
dec ecx
jne 0x525925
xchg dword [ebp - 4], ecx
push ebx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x525ce9
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, 0x525d04
call fcn.0049839c
mov byte [ebp - 0xd], 0
cmp byte [0x614154], 0
je 0x525cbe
lea eax, [ebp - 0x14]
call fcn.00405108
lea eax, [ebp - 0x14e]
xor ecx, ecx
mov edx, 0x121
call fcn.0040345c
lea eax, [ebp - 0x2d]
xor ecx, ecx
mov edx, 0xd
call fcn.0040345c
push 0
lea eax, [ebp - 0x20]
push eax
push 0x121
lea eax, [ebp - 0x14e]
push eax
push 0xd
lea eax, [ebp - 0x2d]
push eax
push 0x2d1400
mov eax, dword [ebp - 4]
push eax
call sub.KERNEL32.DLL_DeviceIoControl
test eax, eax
je 0x525c69
mov eax, dword [ebp - 0x132]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0x158]
call fcn.0040a3c4
mov ecx, dword [ebp - 0x158]
lea eax, [ebp - 0x154]
mov edx, 0x525d1c
call fcn.00405414
mov eax, dword [ebp - 0x154]
call fcn.0049839c
cmp dword [ebp - 0x132], 7
je 0x525cbe
xor eax, eax
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
add eax, 0xffffffec
sub eax, 0x14
jb 0x525a14
add eax, 0xfffffffa
sub eax, 0x30
jae 0x525a20
mov eax, dword [ebp - 0xc]
mov edx, dword [ebp - 0x1c]
mov byte [eax + edx], 0x20
jmp 0x525a2a
mov eax, dword [ebp - 0xc]
mov edx, dword [ebp - 0x1c]
mov byte [eax + edx], 0
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 0x200
jne 0x525a01
mov eax, dword [ebp - 0xc]
mov byte [eax + 3], 1
mov eax, dword [ebp - 0xc]
mov byte [eax + 0xa4], 1
lea edx, [ebp - 0x160]
mov eax, dword [ebp - 8]
call fcn.0040a2d8
mov ecx, dword [ebp - 0x160]
lea eax, [ebp - 0x15c]
mov edx, 0x525d38
call fcn.00405414
mov eax, dword [ebp - 0x15c]
push eax
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x14e]
mov ecx, 0x14
mov edx, dword [ebp - 0x13a]
call fcn.00500a2c
mov dword [ebp - 0x1c], 0x2e
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp - 0x1c]
mov al, byte [eax + edx - 0x2e]
mov edx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x1c]
mov byte [edx + ecx], al
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 0x36
jne 0x525a93
lea edx, [ebp - 0x164]
mov eax, dword [ebp - 0x14]
call fcn.00409de4
mov edx, dword [ebp - 0x164]
lea eax, [ebp - 0x14]
call fcn.004051a0
mov eax, dword [ebp - 0x14]
call fcn.004053c8
cmp eax, 0xa
jle 0x525aee
lea eax, [ebp - 0x14]
push eax
mov ecx, 0xa
mov edx, 1
mov eax, dword [ebp - 0x14]
call fcn.00405628
lea eax, [ebp - 0x14]
mov edx, 0x525d4c
call fcn.004053d0
push dword [ebp - 0x14]
push 0x525d58
lea edx, [ebp - 0x16c]
mov eax, dword [ebp - 8]
call fcn.0040a2d8
push dword [ebp - 0x16c]
lea eax, [ebp - 0x168]
mov edx, 3
call fcn.00405488
mov eax, dword [ebp - 0x168]
push eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x14e]
mov ecx, 0x14
mov edx, dword [ebp - 0x13a]
call fcn.00500b78
mov dword [ebp - 0x1c], 0x14
mov eax, dword [ebp - 0x18]
mov edx, dword [ebp - 0x1c]
mov al, byte [eax + edx - 0x14]
mov edx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x1c]
mov byte [edx + ecx], al
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 0x28
jne 0x525b4f
push 0
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x14e]
mov ecx, 8
mov edx, dword [ebp - 0x142]
call fcn.00500a2c
push 0x525d68
lea eax, [ebp - 0x170]
push eax
lea eax, [ebp - 0x14e]
mov ecx, 0x28
mov edx, dword [ebp - 0x13e]
call fcn.00500a2c
mov edx, dword [ebp - 0x170]
lea eax, [ebp - 0x14]
call fcn.004053d0
lea edx, [ebp - 0x174]
mov eax, dword [ebp - 0x14]
call fcn.00409de4
mov edx, dword [ebp - 0x174]
lea eax, [ebp - 0x14]
call fcn.004051a0
mov eax, dword [ebp - 0x14]
call fcn.004053c8
cmp eax, 0x27
jg 0x525bf9
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x14]
mov edx, 0x525d7c
call fcn.004053d0
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 0x28
jne 0x525be3
mov dword [ebp - 0x1c], 0x36
mov eax, dword [ebp - 0x14]
mov edx, dword [ebp - 0x1c]
mov al, byte [eax + edx - 0x36]
mov edx, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x1c]
mov byte [edx + ecx], al
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 0x5e
jne 0x525c00
lea eax, [ebp - 0x14]
call fcn.00405108
xor eax, eax
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 0x178]
mov edx, dword [ebp - 0x1c]
mov dl, byte [ebp + edx - 0x12d]
call fcn.004052f0
mov edx, dword [ebp - 0x178]
lea eax, [ebp - 0x14]
call fcn.004053d0
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 0x100
jne 0x525c29
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0x14]
call fcn.0040515c
mov byte [ebp - 0xd], 1
jmp 0x525c8b
call sub.KERNEL32.DLL_GetLastError
xor edx, edx
push edx
push eax
lea eax, [ebp - 0x17c]
call fcn.0040a3c4
mov edx, dword [ebp - 0x17c]
mov eax, dword [ebp + 8]
call fcn.0040515c
lea ecx, [ebp - 0x184]
mov eax, dword [ebp + 8]
mov eax, dword [eax]
mov dl, 1
call fcn.0048e818
mov ecx, dword [ebp - 0x184]
lea eax, [ebp - 0x180]
mov edx, 0x525d88
call fcn.00405414
mov eax, dword [ebp - 0x180]
call fcn.0049839c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x525cf0
lea eax, [ebp - 0x184]
mov edx, 0xd
call fcn.0040512c
lea eax, [ebp - 0x18]
mov edx, 2
call fcn.0040512c
ret