Function at 0x4277f0
Capabilities:
Get disk information
Get disk information via ioctl
Get disk size

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4c2461
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
sub esp, 0x5d4
mov eax, dword [0x4f66e0]
mov dword [ebp - 0x1c], eax
push ebx
push esi
push edi
mov dword [ebp - 0x10], esp
mov dword [ebp - 0x5e0], ecx
push 0
mov ecx, dword [ebp - 0x5e0]
add ecx, 0x1e40
call fcn.00474c30
mov ecx, dword [ebp - 0x5e0]
call fcn.00427ce0
lea eax, [ebp - 0x120]
mov dword [ebp - 0x14], eax
lea ecx, [ebp - 0x120]
push ecx
push 0x80
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
jle 0x427cbf
mov edx, dword [ebp - 0x14]
lea eax, [ebp - 0x120]
sub edx, eax
sar edx, 1
cmp edx, dword [ebp - 0x18]
jge 0x427c95
mov ecx, dword [ebp - 0x14]
push ecx
lea ecx, [ebp - 0x12c]
call fcn.00401e40
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0x12c]
mov eax, dword [edx - 0xc]
mov dword [ebp - 0x590], eax
mov ecx, dword [ebp - 0x590]
mov edx, dword [ebp - 0x14]
lea eax, [edx + ecx*2 + 2]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x12c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetDriveTypeW]
cmp eax, 3
je 0x4278da
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x12c]
call fcn.0044e670
jmp 0x427869
push 0
push 0x5c
lea ecx, [ebp - 0x12c]
call fcn.00430640
mov dword [ebp - 0x124], eax
mov dword [ebp - 0x144], 0xffffffff
cmp dword [ebp - 0x124], 0
jl 0x427952
mov edx, dword [ebp - 0x124]
push edx
lea eax, [ebp - 0x56c]
push eax
lea ecx, [ebp - 0x12c]
call fcn.00419330
mov dword [ebp - 0x5e4], eax
mov ecx, dword [ebp - 0x5e4]
mov dword [ebp - 0x5a4], ecx
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x5a4]
push edx
lea ecx, [ebp - 0x12c]
call fcn.00402240
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x56c]
call fcn.0044e670
lea eax, [ebp - 0x12c]
push eax
push 0x4cd7ac
lea ecx, [ebp - 0x130]
push ecx
call fcn.00401950
add esp, 0xc
mov byte [ebp - 4], 2
push 0
push 0x20000080
push 3
push 0
push 3
push 0
mov edx, dword [ebp - 0x130]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x140], eax
cmp dword [ebp - 0x140], 0xffffffff
je 0x427c6f
push 0
lea eax, [ebp - 0x128]
push eax
push 0xc
lea ecx, [ebp - 0x13c]
push ecx
push 0
push 0
push 0x2d1080
mov edx, dword [ebp - 0x140]
push edx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x4279dd
mov eax, dword [ebp - 0x138]
mov dword [ebp - 0x144], eax
jmp 0x427a5e
lea ecx, [ebp - 0x548]
mov dword [ebp - 0x148], ecx
push 0
lea edx, [ebp - 0x128]
push edx
push 0x400
mov eax, dword [ebp - 0x148]
push eax
push 0
push 0
push 0x560000
mov ecx, dword [ebp - 0x140]
push ecx
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x427a5e
mov dword [ebp - 0x54c], 0
jmp 0x427a33
mov edx, dword [ebp - 0x54c]
add edx, 1
mov dword [ebp - 0x54c], edx
mov eax, dword [ebp - 0x148]
mov ecx, dword [ebp - 0x54c]
cmp ecx, dword [eax]
jae 0x427a5e
mov edx, dword [ebp - 0x54c]
imul edx, edx, 0x18
mov eax, dword [ebp - 0x148]
mov ecx, dword [eax + edx + 8]
mov dword [ebp - 0x144], ecx
jmp 0x427a24
cmp dword [ebp - 0x144], 0
jl 0x427c5b
push 0x80
call fcn.004b5cf0
add esp, 4
mov dword [ebp - 0x570], eax
mov edx, dword [ebp - 0x570]
mov dword [ebp - 0x550], edx
push 0x80
push 0
mov eax, dword [ebp - 0x550]
push eax
call fcn.00499140
add esp, 0xc
mov byte [ebp - 4], 3
xor ecx, ecx
jl 0x427ac0
mov edx, dword [ebp - 0x12c]
mov eax, dword [edx - 0xc]
mov dword [ebp - 0x5ac], eax
cmp dword [ebp - 0x5ac], 0
jge 0x427aca
push 0x80070057
call fcn.00401db0
xor ecx, ecx
shl ecx, 1
mov edx, dword [ebp - 0x12c]
mov ax, word [edx + ecx]
mov word [ebp - 0x5ae], ax
mov ecx, dword [ebp - 0x550]
mov dx, word [ebp - 0x5ae]
mov word [ecx + 2], dx
mov eax, dword [ebp - 0x550]
mov cl, byte [ebp - 0x144]
mov byte [eax], cl
push 0x4cd7a8
lea edx, [ebp - 0x12c]
push edx
lea eax, [ebp - 0x574]
push eax
call fcn.00401850
add esp, 0xc
mov dword [ebp - 0x5b4], eax
mov ecx, dword [ebp - 0x5b4]
mov edx, dword [ecx]
mov dword [ebp - 0x5b8], edx
push 0x14
mov eax, dword [ebp - 0x550]
add eax, 0x46
push eax
push 0
push 0
push 0
push 0x21
mov ecx, dword [ebp - 0x550]
add ecx, 4
push ecx
mov edx, dword [ebp - 0x5b8]
push edx
call dword [sym.imp.KERNEL32.dll_GetVolumeInformationW]
lea ecx, [ebp - 0x574]
call fcn.0044e670
push 0x4cd7a8
lea eax, [ebp - 0x12c]
push eax
lea ecx, [ebp - 0x57c]
push ecx
call fcn.00401850
add esp, 0xc
mov dword [ebp - 0x5c0], eax
mov edx, dword [ebp - 0x5c0]
mov eax, dword [edx]
mov dword [ebp - 0x5c4], eax
lea ecx, [ebp - 0x560]
push ecx
lea edx, [ebp - 0x558]
push edx
lea eax, [ebp - 0x568]
push eax
mov ecx, dword [ebp - 0x5c4]
push ecx
call dword [sym.imp.KERNEL32.dll_GetDiskFreeSpaceExW]
mov dword [ebp - 0x578], eax
lea ecx, [ebp - 0x57c]
call fcn.0044e670
cmp dword [ebp - 0x578], 0
je 0x427bfe
mov edx, dword [ebp - 0x550]
mov eax, dword [ebp - 0x568]
mov dword [edx + 0x70], eax
mov ecx, dword [ebp - 0x564]
mov dword [edx + 0x74], ecx
mov edx, dword [ebp - 0x550]
mov eax, dword [ebp - 0x558]
mov dword [edx + 0x78], eax
mov ecx, dword [ebp - 0x554]
mov dword [edx + 0x7c], ecx
mov edx, dword [ebp - 0x5e0]
add edx, 0x22b4
mov dword [ebp - 0x5d0], edx
mov eax, dword [ebp - 0x5d0]
mov ecx, dword [eax + 8]
mov dword [ebp - 0x5cc], ecx
lea edx, [ebp - 0x550]
push edx
mov eax, dword [ebp - 0x5cc]
push eax
mov ecx, dword [ebp - 0x5d0]
call fcn.004372b0
jmp 0x427c5b
mov dword [ebp - 4], 2
mov eax, dword [ebp - 0x140]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x130]
call fcn.0044e670
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x12c]
call fcn.0044e670
jmp 0x427869
mov ecx, dword [ebp - 0x5e0]
mov edx, dword [ecx + 0x22bc]
mov dword [ebp - 0x5dc], edx
mov eax, dword [ebp - 0x5dc]
push eax
mov ecx, dword [ebp - 0x5e0]
add ecx, 0x1e40
call fcn.00474c30
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
mov ecx, dword [ebp - 0x1c]
call fcn.00498784
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret