Skip to content
Tech News
← Back to articles

Decayfmt – a file format that corrupts itself a little every time you open it

read original more articles
Why This Matters

Decayfmt introduces a novel file format that self-destructs with each access, highlighting potential risks in data integrity and emphasizing the importance of robust backup strategies in the tech industry. Its design serves as a provocative reminder of the vulnerabilities inherent in digital storage and the need for resilient data management practices for consumers and developers alike.

Key Takeaways

decayfmt

Featured in This Week in Rust #660.

A file format that corrupts itself a little every time you open it. Every open permanently damages the file on disk, by an amount baked into the filename, before it is ever shown to you. There is no recovery from the file alone. The file is the only copy that matters, and every read destroys a little more of it.

Two file types:

.idcy<x> for images (example: photo.idcy3 )

for images (example: ) .tdcy<x> for text (example: note.tdcy7 )

x is a positive integer in the filename, the instability parameter. Higher x means more corruption per open.

Watch it decay

The grid above is one image encoded at x=1 , x=3 , x=8 , and x=15 , each opened the same number of times. Same picture, four rates of decay. To follow a single instability value across individual opens instead, each open corrupting the file further on disk before it is ever shown, with no way back:

The clean original:

... continue reading