Function at 0x401ff0
Capabilities:
Get disk information

Disassembly:
mov eax, 0x1038
call fcn.004453d0
mov ecx, dword [str..C:]
mov eax, dword [0x489e10]
mov dx, word [0x489e18]
mov dword [esp + 0x14], ecx
push ebx
xor ecx, ecx
push ebp
mov dword [esp + 0x14], eax
mov al, byte [0x489e1a]
push esi
mov dword [esp + 0x27], ecx
push edi
mov byte [esp + 0x20], 0
mov word [esp + 0x28], dx
mov byte [esp + 0x2a], al
mov dword [esp + 0x2f], ecx
mov dword [esp + 0x10], ecx
call dword [sym.imp.KERNEL32.dll_GetLogicalDrives]
mov ebx, dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ecx, 0x80
or eax, 0xffffffff
mov edi, 0x4a50f8
rep stosd dword es:[edi], eax
mov ecx, 0x80
or eax, 0xffffffff
mov edi, 0x4a4cf8
mov dword [esp + 0x18], 2
rep stosd dword es:[edi], eax
mov ebp, 0x4a4c90
mov dword [esp + 0x14], 0x4a4aa0
mov dl, byte [esp + 0x18]
lea eax, [esp + 0x1c]
add dl, 0x41
push eax
mov byte [esp + 0x20], dl
call dword [sym.imp.KERNEL32.dll_GetDriveTypeA]
cmp eax, 5
jne 0x402171
mov cl, byte [esp + 0x1c]
lea edi, [esp + 0x24]
mov byte [esp + 0x28], cl
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push eax
mov edx, ecx
mov esi, edi
mov edi, dword [esp + 0x18]
push eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push 3
push eax
and ecx, 3
push 1
lea eax, [esp + 0x38]
push 0xc0000000
push eax
rep movsb byte es:[edi], byte [esi]
call ebx
cmp eax, 0xffffffff
mov dword [ebp], eax
jne 0x4020f6
push 0
push 0
push 3
push 0
push 1
lea ecx, [esp + 0x38]
push SysReAllocStringLen
push ecx
call ebx
mov dword [ebp], eax
mov edx, dword [ebp]
cmp edx, 0xffffffff
je 0x402171
mov ecx, 0x400
xor eax, eax
lea edi, [esp + 0x48]
push eax
rep stosd dword es:[edi], eax
lea eax, [esp + 0x48]
lea ecx, [esp + 0x4c]
push eax
push 0x1000
push ecx
push 0
push 0
push 0x41018
push edx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x402171
mov eax, dword [esp + 0x4c]
mov edx, dword [esp + 0x4e]
mov ecx, dword [esp + 0x10]
and eax, 0xff
shl eax, 4
and edx, 0xff
add eax, edx
mov edx, dword [esp + 0x18]
shl eax, 2
mov dword [eax + 0x4a50f8], ecx
inc ecx
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0x14]
add ecx, 0xf
mov dword [eax + 0x4a4cf8], edx
mov dword [esp + 0x14], ecx
add ebp, 4
mov eax, dword [esp + 0x18]
inc eax
cmp eax, 0x1a
mov dword [esp + 0x18], eax
jl 0x402078
mov ecx, dword [esp + 0x10]
xor eax, eax
cmp ecx, eax
jne 0x402198
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1038
ret
mov ecx, dword [str..SCSI0:]
mov edx, dword [0x489e08]
mov dword [esp + 0x34], ecx
mov cx, word [0x489e0c]
mov dword [esp + 0x38], edx
mov dl, byte [0x489e0e]
mov dword [esp + 0x10], eax
mov word [esp + 0x3c], cx
mov byte [esp + 0x3e], dl
mov dword [esp + 0x3f], eax
mov dword [esp + 0x14], eax
mov ebp, 0x4a4c28
mov al, byte [esp + 0x10]
push 0
push 0
push 3
push 0
push 1
lea ecx, [esp + 0x48]
add al, 0x30
push 0xc0000000
push ecx
mov byte [esp + 0x58], al
call ebx
mov esi, eax
cmp esi, 0xffffffff
jne 0x402217
push 0
push 0
push 3
push 0
push 1
lea edx, [esp + 0x48]
push SysReAllocStringLen
push edx
call ebx
mov esi, eax
cmp esi, 0xffffffff
je 0x402280
mov ecx, 0x400
xor eax, eax
lea edi, [esp + 0x48]
push eax
rep stosd dword es:[edi], eax
lea eax, [esp + 0x48]
lea ecx, [esp + 0x4c]
push eax
push 0x1000
push ecx
push 0
push 0
push 0x4100c
push esi
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
mov cl, byte [esp + 0x48]
test eax, eax
je 0x402278
test cl, cl
je 0x402280
mov edi, dword [esp + 0x10]
mov eax, dword [esp + 0x50]
inc edi
test eax, eax
mov dword [esp + 0x10], edi
je 0x402269
mov eax, dword [esp + eax + 0x50]
test eax, eax
jne 0x402261
mov edx, dword [esp + 0x14]
mov dword [ebp], esi
inc edx
add ebp, 4
mov dword [esp + 0x14], edx
test cl, cl
jne 0x4021d3
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
mov byte [0x4a53e8], 1
pop ebx
add esp, 0x1038
ret