Function at 0x4cfe40
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x868
mov eax, dword [0x506380]
xor eax, ebp
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp + 8]
push eax
push str.processId_d
push 9
call fcn.004ce850
add esp, 0xc
mov dword [ebp - 0xc], 0x400
mov dword [ebp - 8], 0x1000
mov dword [ebp - 4], 0
mov dword [ebp - 0x10], 0
jmp 0x4cfe8d
mov ecx, dword [ebp - 0x10]
add ecx, 1
mov dword [ebp - 0x10], ecx
cmp dword [ebp - 0x10], 2
jae 0x4cfeb2
cmp dword [ebp - 4], 0
jne 0x4cfeb2
mov edx, dword [ebp + 8]
push edx
push 0
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp + eax*4 - 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov dword [ebp - 4], eax
jmp 0x4cfe84
cmp dword [ebp - 4], 0
jne 0x4cfed2
push str.get_process_filename_:_1
push 9
call fcn.004ce850
add esp, 8
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4d0247
mov byte [ebp - 0x15], 0
push 0x4f8750
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov dword [ebp - 0x14], eax
push str.get_process_filename_:_2
push 9
call fcn.004ce850
add esp, 8
cmp dword [ebp - 0x14], 0
je 0x4d01e7
push str.get_process_filename_:_3
push 9
call fcn.004ce850
add esp, 8
push str.ZwQueryInformationProcess
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
je 0x4d01dd
push str.get_process_filename_:_4
push 9
call fcn.004ce850
add esp, 8
mov dword [ebp - 0x20], 0
lea eax, [ebp - 0x20]
push eax
push 0
push 0
push 0x1b
mov ecx, dword [ebp - 4]
push ecx
call dword [ebp - 0x1c]
mov dword [ebp - 0x24], eax
mov edx, dword [ebp - 0x24]
push edx
push 0x4f8820
push 9
call fcn.004ce850
add esp, 0xc
cmp dword [ebp - 0x24], 0xc0000004
jne 0x4d01dd
push str.get_process_filename_:_5
push 9
call fcn.004ce850
add esp, 8
mov eax, dword [ebp - 0x20]
push eax
call fcn.0041a7c6
add esp, 4
mov dword [ebp - 0x28], eax
lea ecx, [ebp - 0x20]
push ecx
mov edx, dword [ebp - 0x20]
push edx
mov eax, dword [ebp - 0x28]
push eax
push 0x1b
mov ecx, dword [ebp - 4]
push ecx
call dword [ebp - 0x1c]
mov dword [ebp - 0x24], eax
mov edx, dword [ebp - 0x24]
push edx
push str.get_process_filename_:_status_d
push 9
call fcn.004ce850
add esp, 0xc
cmp dword [ebp - 0x24], 0
jne 0x4d01d1
push str.get_process_filename_:_6
push 9
call fcn.004ce850
add esp, 8
mov byte [ebp - 0x15], 1
mov eax, dword [ebp - 0x28]
mov ecx, dword [eax + 4]
push ecx
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.0041ab6c
add esp, 0xc
xor ecx, ecx
mov word [ebp - 0x430], cx
lea edx, [ebp - 0x430]
push edx
push 0x1ff
call dword [sym.imp.KERNEL32.dll_GetLogicalDriveStringsW]
test eax, eax
je 0x4d01d1
push str.get_process_filename_:_7
push 9
call fcn.004ce850
add esp, 8
mov eax, dword [0x4f895c]
mov dword [ebp - 0x43c], eax
mov cx, word [0x4f8960]
mov word [ebp - 0x438], cx
lea edx, [ebp - 0x430]
mov dword [ebp - 0x434], edx
mov byte [ebp - 0x649], 0
push str.get_process_filename_:_8
push 9
call fcn.004ce850
add esp, 8
mov eax, dword [ebp - 0x434]
mov cx, word [eax]
mov word [ebp - 0x43c], cx
push 0x104
lea edx, [ebp - 0x648]
push edx
lea eax, [ebp - 0x43c]
push eax
call dword [sym.imp.KERNEL32.dll_QueryDosDeviceW]
test eax, eax
je 0x4d0197
push str.get_process_filename_:_9
push 9
call fcn.004ce850
add esp, 8
lea ecx, [ebp - 0x648]
mov dword [ebp - 0x85c], ecx
mov edx, dword [ebp - 0x85c]
add edx, 2
mov dword [ebp - 0x860], edx
mov eax, dword [ebp - 0x85c]
mov cx, word [eax]
mov word [ebp - 0x862], cx
add dword [ebp - 0x85c], 2
cmp word [ebp - 0x862], 0
jne 0x4d00b7
mov edx, dword [ebp - 0x85c]
sub edx, dword [ebp - 0x860]
sar edx, 1
mov dword [ebp - 0x868], edx
mov eax, dword [ebp - 0x868]
mov dword [ebp - 0x650], eax
cmp dword [ebp - 0x650], 0x104
jae 0x4d0197
push str.get_process_filename_:_10
push 9
call fcn.004ce850
add esp, 8
mov ecx, dword [ebp - 0x650]
push ecx
lea edx, [ebp - 0x648]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.0041c83c
add esp, 0xc
neg eax
sbb eax, eax
add eax, 1
mov byte [ebp - 0x649], al
movzx ecx, byte [ebp - 0x649]
test ecx, ecx
je 0x4d0197
push str.get_process_filename_:_11
push 9
call fcn.004ce850
add esp, 8
mov edx, dword [ebp - 0x650]
mov eax, dword [ebp + 0xc]
lea ecx, [eax + edx*2]
push ecx
lea edx, [ebp - 0x43c]
push edx
push 0x4f8a4c
lea eax, [ebp - 0x858]
push eax
call fcn.00404190
add esp, 0x10
lea ecx, [ebp - 0x858]
push ecx
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp + 0xc]
push eax
call fcn.0041ab6c
add esp, 0xc
mov ecx, dword [ebp - 0x434]
movzx edx, word [ecx]
mov eax, dword [ebp - 0x434]
add eax, 2
mov dword [ebp - 0x434], eax
test edx, edx
je 0x4d01b5
jmp 0x4d0197
movzx ecx, byte [ebp - 0x649]
test ecx, ecx
jne 0x4d01d1
mov edx, dword [ebp - 0x434]
movzx eax, word [edx]
test eax, eax
jne 0x4d004d
mov ecx, dword [ebp - 0x28]
push ecx
call fcn.0041a6e9
add esp, 4
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
movzx eax, byte [ebp - 0x15]
test eax, eax
jne 0x4d0239
push str.get_process_filename_:_12
push 9
call fcn.004ce850
add esp, 8
xor ecx, ecx
mov edx, dword [ebp + 0xc]
mov word [edx], cx
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
push 0
mov edx, dword [ebp - 4]
push edx
call sub.PSAPI.DLL_GetModuleFileNameExW
test eax, eax
jne 0x4d0239
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.get_process_filename_:_13__lasterror_d
push 9
call fcn.004ce850
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov al, 1
jmp 0x4d0249
xor al, al
mov ecx, dword [ebp - 0x2c]
xor ecx, ebp
call fcn.0041a0cf
mov esp, ebp
pop ebp
ret