4 ms·
Unix filesystems can typically have filenames containing any bytes except "\0" and "/". I believe you can also have newline characters in NTFS, although Window
by i80and 4y ago
Unix filesystems can typically have filenames containing any bytes except "\0" and "/".
I believe you can also have newline characters in NTFS, although Windows Explorer appears to prevent creating a file with them.
- mcculley 4y agoI have been using the filename "meeting-notes:10/1 \n Unix & Windows.txt" to test various apps. It tends to expose just how brittle modern computing still is.
- benibela 4y agoI made a whole collection: https://github.com/benibela/nasty-files https://github.com/benibela/nasty-files
- asddubs 4y ago"--no-preserve-root" made me laugh. for testing unescaped calls to rm?
- jamal-kumar 4y agoIt's a bypass against a mitigation for an old trick which worked back in the day where you could watch someone self-nuke themselves off of IRC by convincing them to type rm -rf /
- benibela 4y agoIt is to mess with people calling rm * / in the directory Good thing there is not really any reason to call rm like that
- asddubs 4y agooh does that actually work? the * expanding a filename to an argument? I guess it all just ends up in argv
- unqueued 4y agoOh cool! I use nasty-files as a submodule with some of my tests. I can't believe how long I went without without testing against the filename corner cases. I've found so much software that doesn't properly handle nasty filenames, I think it should be tested for more.
- PokestarFan 4y agoLol that broke git for me