[Cryptography] Can crypto implement OS/FS protections ?

Jerry Leichter leichter at lrw.com
Tue Nov 22 22:45:32 EST 2022

>> You can certainly control *read* access by encryption (though there are 
>> limits to the protection - e.g., suppose I want to say that if you don’t 
>> have read access to a file, you can’t even tell if it’s been changed 
>> since you last looked).
> Unless I've misunderstood you, under *Nix you don't need read access to a 
> file to access its metadata (the inode); you merely need to be able to 
> access it from its parent directly.  In the case above, you "stat" the 
> file and examine "st_mtime".
> For example, on my FreeBSD box (this one):
>    aneurin% ls -l /etc/master.passwd 
>    -rw-------  1 root  wheel  2785 Nov  3 15:07 /etc/master.passwd
> I can't read it, but I can see that it was last changed on 3rd November.
Yes, Unix has that limitation, but that's because protection for the metadata is essentially provided by protection on the containing directory:  If you didn't have read access to /etc you couldn't play this game.

All I was saying was that an OS *could* choose to protect the metadata in the same way it protects the file - and that's something pure cryptographic protection could not emulate.  Note that *memory* protection works this way (though that's a bit of a cheat because there is no metadata associated with a memory page).  Still, it would be considered a serious bug if a process could determine if another process had modified a page of its private memory space.

                                                        -- Jerry

More information about the cryptography mailing list