Function at 0x4c71da
Capabilities:
Enumerate disk volumes
Get disk information

Disassembly:
push ebp
mov ebp, esp
push edi
push ebx
sub esp, 0x450
mov dword [ebp - 0x22c], 0
lea edx, [ebp - 0x228]
mov eax, 0
mov ecx, 0x81
mov edi, edx
rep stosd dword es:[edi], eax
mov dword [ebp - 0x434], 0
lea edx, [ebp - 0x430]
mov eax, 0
mov ecx, 0x81
mov edi, edx
rep stosd dword es:[edi], eax
mov dword [ebp - 0x10], 0xffffffff
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0xc], 0xffffffff
mov dword [ebp - 0x1c], 0
mov dword [esp + 4], 0x104
lea eax, [ebp - 0x434]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_FindFirstVolumeW]
call eax
sub esp, 8
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0xffffffff
jne 0x4c72c4
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
mov dword [esp], eax
call sym._strerror
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x1c]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.FindFirstVolumeW_failed___u__s
mov dword [esp + 8], str.get_volume_names
mov dword [esp + 4], 0x5a1
mov dword [esp], str._root_wazuh_4.7.2_src_syscheckd_src_whodata_win_whodata.c
call dbg._mwarn
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_FindVolumeClose]
call eax
sub esp, 4
mov eax, dword [ebp - 0xc]
jmp 0x4c75d1
mov dword [esp + 4], 1
mov dword [esp], 0x104
call sym._calloc
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
jne 0x4c7329
mov eax, dword [sym.imp.msvcrt.dll__errno]
call eax
mov eax, dword [eax]
mov dword [esp], eax
call sym._strerror
mov ebx, eax
mov eax, dword [sym.imp.msvcrt.dll__errno]
call eax
mov eax, dword [eax]
mov dword [esp + 0x14], ebx
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0x50f154
mov dword [esp + 8], str.get_volume_names
mov dword [esp + 4], 0x5a6
mov dword [esp], str._root_wazuh_4.7.2_src_syscheckd_src_whodata_win_whodata.c
call dbg._merror_exit
mov dword [esp + 4], 1
mov dword [esp], 0x104
call sym._calloc
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
jne 0x4c738e
mov eax, dword [sym.imp.msvcrt.dll__errno]
call eax
mov eax, dword [eax]
mov dword [esp], eax
call sym._strerror
mov ebx, eax
mov eax, dword [sym.imp.msvcrt.dll__errno]
call eax
mov eax, dword [eax]
mov dword [esp + 0x14], ebx
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], 0x50f154
mov dword [esp + 8], str.get_volume_names
mov dword [esp + 4], 0x5a7
mov dword [esp], str._root_wazuh_4.7.2_src_syscheckd_src_whodata_win_whodata.c
call dbg._merror_exit
lea eax, [ebp - 0x434]
mov dword [esp], eax
call sym._wcslen
sub eax, 1
mov dword [ebp - 0x18], eax
mov dword [esp + 8], 0x104
lea eax, [ebp - 0x434]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x20]
mov dword [esp], eax
call sym._wcstombs
movzx eax, word [ebp - 0x434]
cmp ax, 0x5c
jne 0x4c7404
movzx eax, word [ebp - 0x432]
cmp ax, 0x5c
jne 0x4c7404
movzx eax, word [ebp - 0x430]
cmp ax, 0x3f
jne 0x4c7404
movzx eax, word [ebp - 0x42e]
cmp ax, 0x5c
jne 0x4c7404
mov eax, dword [ebp - 0x18]
movzx eax, word [ebp + eax*2 - 0x434]
cmp ax, 0x5c
je 0x4c7434
mov eax, dword [ebp - 0x20]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.Find_Volume_returned_a_bad_path:__s
mov dword [esp + 8], str.get_volume_names
mov dword [esp + 4], 0x5b7
mov dword [esp], str._root_wazuh_4.7.2_src_syscheckd_src_whodata_win_whodata.c
call dbg._mwarn
jmp 0x4c758e
mov eax, dword [ebp - 0x18]
mov word [ebp + eax*2 - 0x434], 0
mov dword [esp + 8], 0x104
lea eax, [ebp - 0x22c]
mov dword [esp + 4], eax
lea eax, [ebp - 0x434]
add eax, 8
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_QueryDosDeviceW]
call eax
sub esp, 0xc
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x18]
mov word [ebp + eax*2 - 0x434], 0x5c
cmp dword [ebp - 0x14], 0
jne 0x4c74c8
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
mov dword [esp], eax
call sym._strerror
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x1c]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.QueryDosDeviceW_failed___u__s
mov dword [esp + 8], str.get_volume_names
mov dword [esp + 4], 0x5c3
mov dword [esp], str._root_wazuh_4.7.2_src_syscheckd_src_whodata_win_whodata.c
call dbg._mwarn
jmp 0x4c758e
mov dword [esp + 8], 0x104
lea eax, [ebp - 0x22c]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x24]
mov dword [esp], eax
call sym._wcstombs
mov eax, dword [ebp - 0x24]
mov dword [esp], eax
call sym._strlen
mov edx, eax
mov eax, dword [ebp - 0x24]
add eax, edx
mov word [eax], 0x5c
mov eax, dword [ebp - 0x24]
mov dword [esp + 4], eax
lea eax, [ebp - 0x434]
mov dword [esp], eax
call dbg.get_drive_names
mov dword [esp + 8], 0x104
lea eax, [ebp - 0x434]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_FindNextVolumeW]
call eax
sub esp, 0xc
test eax, eax
jne 0x4c738e
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
call eax
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0x12
je 0x4c7587
mov eax, dword [ebp - 0x1c]
mov dword [esp], eax
call sym._strerror
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x1c]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.FindNextVolumeW_failed___u__s
mov dword [esp + 8], str.get_volume_names
mov dword [esp + 4], 0x5d3
mov dword [esp], str._root_wazuh_4.7.2_src_syscheckd_src_whodata_win_whodata.c
call dbg._mwarn
jmp 0x4c758e
mov dword [ebp - 0xc], 0
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
mov eax, dword [sym.imp.KERNEL32.dll_FindVolumeClose]
call eax
sub esp, 4
cmp dword [ebp - 0x24], 0
je 0x4c75b6
mov eax, dword [ebp - 0x24]
mov dword [esp], eax
call sym._free
mov dword [ebp - 0x24], 0
cmp dword [ebp - 0x20], 0
je 0x4c75ce
mov eax, dword [ebp - 0x20]
mov dword [esp], eax
call sym._free
mov dword [ebp - 0x20], 0
mov eax, dword [ebp - 0xc]
lea esp, [ebp - 8]
pop ebx
pop edi
pop ebp
ret