LWN.net Logo

File uploads

File uploads

Posted Dec 13, 2012 23:20 UTC (Thu) by man_ls (subscriber, #15091)
In reply to: A hash-based DOS attack on Btrfs by masoncl
Parent article: A hash-based DoS attack on Btrfs

You are describing basically a server with file upload enabled, for example to upload user avatars. If the file already exists, just append .1 at the end and use that modified name as the key instead.

I would discard the original name and use a random filename, unless for some reason the original name was valuable for anything (e.g. for later user selection). Such use cases do exist, and besides there are many software packages that work this way. That using a new shiny filesystem would automatically convert them from ugly software to DoS targets is not admissible IMO.


(Log in to post comments)

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds