nus-cs2113-AY2324S1 / forum

0 stars 0 forks source link

Can hashing be implemented to detect tampering of saved text file? #54

Closed Cazh1 closed 9 months ago

Cazh1 commented 10 months ago

Current implementation is that hashing is used to detect tampering by tester. Once tampering is detected, the user is warned to either revert the change or existing data will be overwritten by the new instance of the application. Does this violate the constraint laid out by https://nus-cs2113-ay2324s1.github.io/website/admin/tp-constraints.html#constraint-human-editable-file? If this violates the constraint, what implementation of hashing would be more desirable?

okkhoy commented 10 months ago

this is a nice approach.. but you should still allow editing the file with valid data. so it is not easy to handle by hashing alone.. you need to use it in conjunction with some exception handling mechanism you can explore more robust mechanisms considering this "still allow editing the file with valid data."

Cazh1 commented 9 months ago

Thank you!