I'm in need for an add-on that can check attachments to a post and make sure they don't already exist in the database. If it does already exist it needs to give an error before the message is posted and the duplicate file needs to be deleted from the system after x minutes (to prevent constant uploading and removing, thus wasting bandwidth).
Ideally the system can compare file hashes so that even if the file name is changed, it is still recognized as being the same file. Upon uploading a new file the hash could be extrapolated and placed in the database. But if this is not possible, referencing file name, format and size will have to do.
Does this sound like a realistic idea for an add-on or would it be too resource intensive to check for this, especially on a forum with many attachments?