Where is the code that makes MOUNTDEV_UNIQUE_ID a disk signature + Partition offset?

All development related issues welcome

Moderator: Moderator Team

Post Reply
Terrydaktal
Posts: 1
Joined: Tue Jun 28, 2022 11:48 am

Where is the code that makes MOUNTDEV_UNIQUE_ID a disk signature + Partition offset?

Post by Terrydaktal »

When I looked at the mountmgr source code, I saw that it writes the unique ID to MountedDevices, which it takes from QueryDeviceInformation which gets it from IOCTL_MOUNTDEV_QUERY_UNIQUE_ID IRP, which im guessing is handled by partition.c which poses as volmgr, but when you go to case IOCTL_MOUNTDEV_QUERY_UNIQUE_ID, it gets the unique ID from partExt->VolumeInterfaceName.Buffer, which is taken only from IoRegisterDeviceInterface, which is always going to be a STORAGE#VOLUME STORAGE#REMOVABLEMEDIA or whatever string taken from InstancePath. There seems to be no check in partition.c as to whether disk is fixed, removable, superfloppy whatever, yet mysteriously my FAT C:\ volume has signature + offset in MountedDevices
Post Reply

Who is online

Users browsing this forum: No registered users and 7 guests