Function at 0x404840
Capabilities:
Get storage device properties

Disassembly:
mov eax, 0x37c8
call fcn.0043c4d0
mov eax, dword [0x46eb88]
xor eax, esp
mov dword [esp + 0x37c4], eax
push ebx
push ebp
mov ebp, dword [0x45732c]
push esi
xor ebx, ebx
push edi
mov dword [esp + 0x10], ebx
xor edi, edi
lea ebx, [ebx]
push edi
lea eax, [esp + 0x28]
push str..PhysicalDrive_d
push eax
call fcn.0043c40b
add esp, 0xc
push ebx
push ebx
push 3
push ebx
push 3
push ebx
lea ecx, [esp + 0x3c]
push ecx
call dword [0x457330]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4048c5
cmp dword [0x471108], ebx
je 0x404b50
lea edx, [esp + 0x24]
push edx
push 0x275
push str._n_d_ReadPhysicalDriveInNTWithZeroRights_ERROR_nCreateFile__s__returned_INVALID_HANDLE_VALUE_n
call fcn.0043c346
add esp, 0xc
jmp 0x404b50
xor eax, eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
push 0x2710
mov dword [esp + 0x24], eax
lea eax, [esp + 0x10c8]
push ebx
push eax
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], ebx
call fcn.0043b3f0
add esp, 0xc
push ebx
lea ecx, [esp + 0x18]
push ecx
push 0x2710
lea edx, [esp + 0x10d0]
push edx
push 0xc
lea eax, [esp + 0x2c]
push eax
push 0x2d1400
push esi
call ebp
test eax, eax
je 0x404b35
cmp dword [0x471108], ebx
je 0x40499f
mov ecx, dword [esp + 0x10e4]
mov edx, dword [esp + 0x10e0]
mov eax, dword [esp + 0x10dc]
push ecx
push edx
push eax
push eax
mov eax, dword [esp + 0x10e8]
push eax
push eax
mov eax, dword [esp + 0x10ec]
movzx ecx, byte [esp + 0x10e6]
push eax
push eax
mov eax, dword [esp + 0x10f0]
push eax
push eax
movzx eax, byte [esp + 0x10f7]
push eax
mov eax, dword [esp + 0x10f8]
push ecx
mov ecx, dword [esp + 0x10f8]
movzx edx, ah
push edx
mov edx, dword [esp + 0x10f8]
movzx eax, al
push eax
push ecx
push edx
push edi
push 0x2a1
push str._n_d_STORAGE_DEVICE_DESCRIPTOR_contents_for_drive__d_n________________Version:__ld_n___________________Size:__ld_n_____________DeviceType:__02x_n_____DeviceTypeModifier:__02x_n_________RemovableMedia:__d_n________CommandQueueing:__d_n_________VendorIdOffset:__4ld__0x_02lx__n________ProductIdOffset:__4ld__0x_02lx__n__ProductRevisionOffset:__4ld__0x_02lx__n_____SerialNumberOffset:__4ld__0x_02lx__n________________BusType:__d_n____RawPropertiesLength:__ld_n
call fcn.0043c346
add esp, 0x4c
mov ecx, dword [esp + 0x10d0]
lea eax, [esp + 0xcdc]
push eax
push ebx
push ecx
lea edx, [esp + 0x10d0]
push edx
call fcn.004046e0
mov ecx, dword [esp + 0x10e4]
lea eax, [esp + 0x51c]
push eax
push ebx
push ecx
lea edx, [esp + 0x10e0]
push edx
call fcn.004046e0
mov ecx, dword [esp + 0x10f8]
lea eax, [esp + 0x914]
push eax
push ebx
push ecx
lea edx, [esp + 0x10f0]
push edx
call fcn.004046e0
mov ecx, dword [esp + 0x110c]
lea eax, [esp + 0x154]
push eax
push 1
push ecx
lea edx, [esp + 0x1100]
push edx
call fcn.004046e0
add esp, 0x40
cmp byte [0x470d08], bl
jne 0x404a8a
movsx eax, byte [esp + 0x124]
push eax
call fcn.0043c0c5
add esp, 4
test eax, eax
jne 0x404a4d
movsx ecx, byte [esp + 0x137]
push ecx
call fcn.0043c0c5
add esp, 4
test eax, eax
je 0x404a8a
xor eax, eax
nop
mov cl, byte [esp + eax + 0x124]
mov byte [eax + 0x470d08], cl
inc eax
cmp cl, bl
jne 0x404a50
xor eax, eax
jmp 0x404a70
mov cl, byte [esp + eax + 0x50c]
mov byte [eax + 0x470908], cl
inc eax
cmp cl, bl
jne 0x404a70
mov dword [esp + 0x10], 1
lea edx, [esp + 0x124]
push edx
lea eax, [esp + 0x8f8]
push eax
lea ecx, [esp + 0x514]
push ecx
lea edx, [esp + 0xce8]
push edx
push edi
push str._n_STORAGE_DEVICE_DESCRIPTOR_for_drive__d__nVendor_Id____s__nProduct_Id____s__nProduct_Revision____s__nSerial_Number____s__n
call fcn.0043c346
push 0x2710
lea eax, [esp + 0x10e0]
push ebx
push eax
call fcn.0043b3f0
add esp, 0x24
push ebx
lea ecx, [esp + 0x18]
push ecx
push 0x2710
lea edx, [esp + 0x10d0]
push edx
push ebx
push ebx
push 0x700a0
push esi
call ebp
test eax, eax
jne 0x404b00
cmp dword [0x471108], ebx
je 0x404b49
lea eax, [esp + 0x24]
push eax
push str._n_d_ReadPhysicalDriveInNTWithZeroRights_ERRORnDeviceIoControl__s__IOCTL_DISK_GET_DRIVE_GEOMETRY_EX__returned_0
jmp 0x404b41
cmp dword [esp + 0x10cc], 0xc
mov eax, 0x457f28
je 0x404b14
mov eax, str._NOT
mov ecx, dword [esp + 0x10e0]
mov edx, dword [esp + 0x10dc]
push ecx
push edx
push eax
push edi
push str._n_DISK_GEOMETRY_EX_for_drive__d__nDisk_is_s_fixed_nDiskSize___I64d_n
call fcn.0043c346
add esp, 0x14
jmp 0x404b49
call dword [0x457334]
push eax
push 0x4583b0
call fcn.0043c346
add esp, 8
push esi
call dword [0x457338]
inc edi
cmp edi, 0x10
jl 0x404870
mov ecx, dword [esp + 0x37d4]
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0043b3d4
add esp, 0x37c8
ret