Attributes of the file which can not be overwritten
ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
What are the attributes of a file ,which, if changed would spoil the integrity of the file.
Say a user writes some thing to the file but modifies the last write time, but still the file is valid when we try to read the file and we cant perform any cross check to find this out.
are there any attributes for which such kind of cross check can be made.
I'd think that invalidity would speak for itself. If you don't want a file that's all null characters, then finding one would be a faulty file. If it doesn't matter, then it's obviously of no concern. I suppose if you had a modification date of "100 March -256" that would be out of the ordinary, but I don't know if file times utilize all bits. That depends on the file system, I'm sure.
A bad link count would be a file system error, as I suppose an "invalidated" file would be. Normally fsck corrects that sort of thing. I guess changing the file's size to something that it isn't would be another way. Again, this all has to do with the file system itself, as the only way to truly corrupt a file is to alter the data it contains.
ta0kira
Link count does not have anything to do with the integrity of a file.
Very true. But none if the information in the inode has anything to do with file integrity. Hence, I had somehow assumed the OP was talking about the inode's integrity.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.