Function at 0x4c3630
Capabilities:
Get common file path
Get disk information via ioctl

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xb00
mov eax, dword [0x718924]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
push 0x50
mov dword [ebp - 0xb00], eax
lea eax, [ebp - 0x90]
push 0
push eax
call fcn.004e30c0
xor eax, eax
mov dword [ebp - 0x14], 0
add esp, 0xc
mov dword [ebp - 0x8d8], eax
mov dword [ebp - 0x8d4], eax
mov dword [ebp - 0x8d0], eax
mov dword [ebp - 0x8cc], eax
mov dword [ebp - 0x8c8], eax
mov dword [ebp - 0x8c4], eax
lea eax, [ebp - 0x298]
push 0x104
push eax
mov byte [ebp - 0x10], 0
mov dword [ebp - 0xc], 0
mov byte [ebp - 8], 0
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
jne 0x4c36e6
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetSystemDirectory___Error:__ld_n
push 2
call fcn.004f99a9
add esp, 4
push eax
call fcn.00494780
add esp, 0xc
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004cb998
mov esp, ebp
pop ebp
ret
movzx eax, word [ebp - 0x298]
push eax
push str.._c:
lea eax, [ebp - 0x4a0]
push 0x104
push eax
call fcn.00462310
add esp, 0x10
lea eax, [ebp - 0x4a0]
push 0
push 0
push 3
push 0
push 3
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4c3754
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.CreateFile___Error:__ld_n
push 2
call fcn.004f99a9
add esp, 4
push eax
call fcn.00494780
add esp, 0xc
or ebx, 0xffffffff
jmp 0x4c37aa
push 0
lea eax, [ebp - 0xaf8]
push eax
push 0xc
lea eax, [ebp - 0x8e4]
push eax
push 0
push 0
push 0x2d1080
push esi
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
jne 0x4c37a1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.IOCTL_STORAGE_GET_DEVICE_NUMBER_Error:__ld_n
push 2
call fcn.004f99a9
add esp, 4
push eax
call fcn.00494780
add esp, 0xc
push esi
call edi
or ebx, 0xffffffff
jmp 0x4c37aa
push esi
call edi
mov ebx, dword [ebp - 0x8e0]
cmp ebx, 0xffffffff
je 0x4c3a16
push ebx
push str..PhysicalDrive_d
lea eax, [ebp - 0x90]
push 0x50
push eax
call fcn.004622e0
add esp, 0x10
lea eax, [ebp - 0x90]
push 0
push 0
push 3
push 0
push 3
push 0xc0000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
mov dword [ebp - 0xaf8], esi
cmp esi, 0xffffffff
je 0x4c3a16
push 0
lea eax, [ebp - 0xafc]
push eax
push 0x18
lea eax, [ebp - 0x8d8]
push eax
push 0
push 0
push 0x74080
push esi
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x4c3a13
test byte [ebp - 0x8d4], 1
je 0x4c3a13
xor eax, eax
push 0x210
push eax
mov dword [ebp - 0x8c0], eax
mov dword [ebp - 0x8bc], eax
mov dword [ebp - 0x8b8], eax
mov dword [ebp - 0x8b4], eax
mov dword [ebp - 0x8b0], eax
mov dword [ebp - 0x8ac], eax
mov dword [ebp - 0x8a8], eax
mov dword [ebp - 0x8a4], eax
lea eax, [ebp - 0xaf4]
push eax
call fcn.004e30c0
mov al, bl
mov ecx, ebx
and al, 1
add esp, 0xc
or al, 0xfa
shl al, 4
mov byte [ebp - 0x8b7], al
mov eax, 0x10
sar eax, cl
test dword [ebp - 0x8d4], eax
jne 0x4c3a13
push 0
lea eax, [ebp - 0xafc]
mov byte [ebp - 0x8b6], 0xec
push eax
push 0x210
lea eax, [ebp - 0xaf4]
mov byte [ebp - 0x8b4], bl
push eax
push 0x20
lea eax, [ebp - 0x8c0]
mov word [ebp - 0x8bb], 0x101
push eax
push 0x7c088
push esi
mov dword [ebp - 0x8c0], 0x200
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x4c3a13
lea eax, [ebp - 0x40]
mov ecx, 0xa
lea esi, [ebp - 0xaae]
lea edi, [ebp - 0x40]
push 0x28
rep movsd dword es:[edi], dword [esi]
push eax
mov byte [ebp - 0x18], 0
call fcn.004bc280
push 4
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x14]
push 5
push eax
call fcn.004f9582
mov eax, dword [ebp - 0xab6]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0xab2]
mov dword [ebp - 0x3c], eax
lea eax, [ebp - 0x40]
push 8
push eax
mov byte [ebp - 0x10], 0
mov byte [ebp - 0x38], 0
call fcn.004bc280
push 4
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0xc]
push 5
push eax
call fcn.004f9582
mov eax, dword [ebp - 0xad0]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0xacc]
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp - 0xac8]
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0xac4]
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0xac0]
mov dword [ebp - 0x30], eax
lea eax, [ebp - 0x40]
push 0x14
push eax
mov byte [ebp - 8], 0
mov byte [ebp - 0x2c], 0
call fcn.004bc280
push 0x400
lea eax, [ebp - 0x8a0]
push 0
push eax
call fcn.004e30c0
add esp, 0x44
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x14]
push eax
push 0x688df8
lea eax, [ebp - 0x8a0]
push 0x400
push eax
call fcn.004622e0
lea edx, [ebp - 0x8a0]
add esp, 0x18
lea ecx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x4c39d5
sub edx, ecx
lea eax, [ebp - 0x8a0]
mov ecx, dword [ebp - 0xb00]
push edx
push eax
call fcn.0045d850
push dword [ebp - 0xaf8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
mov eax, 1
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004cb998
mov esp, ebp
pop ebp
ret
push esi
call edi
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004cb998
mov esp, ebp
pop ebp
ret