Reputation: 1386
I am trying to read some data from the MBR using CreateFile, but I cannot get it to work without admin rights.
The code I am using is like this:
hDevice = CreateFile("\\.\PhysicalDrive0", GENERIC_READ, FILE_SHARE_READ Or FILE_SHARE_WRITE, 0, OPEN_EXISTING, 0, 0)
Is it possible to read data from the MBR without admin rights?
Upvotes: 1
Views: 1436
Reputation: 106609
No, you cannot access the physical drive directly without administrative privileges. (Specifically, I think you need SeBackupPrivilege) (Consider what you could do if this was allowed, you could circumvent access control lists saying you were not allowed to read a file)
Upvotes: 6