Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 1.0.0b4

Request #13360 Why don't include Hash file?
Submitted: 2008-03-10 07:39 UTC
From: darizotas Assigned:
Status: Wont fix Package: HTTP_Upload (version 0.9.1)
PHP Version: 5.2.1 OS: Windows XP SP2
Roadmaps: (Not assigned)    
Subscription  


 [2008-03-10 07:39 UTC] darizotas (Dario Borreguero)
Description: ------------ I think it would be a great idea to include a new member in HTTP_Upload_File where to save the hash of the uploaded file.

Comments

 [2009-08-16 14:38 UTC] cweiske (Christian Weiske)
-Status: Open +Status: Wont fix
Which type of hash would you like? md5, sha-1, sha-256? maybe a different one? What is so hard about computing it yourself? Many people don't need this, so always calculating the hash would be wasted CPU time for most.
 [2009-08-17 01:41 UTC] darizotas (Dario Borreguero)
Sorry for bothering you with such nonsenses. Thanks for your "kind" response. I've already done it by myself, but I think that HTTP_Upload would improve its API offering this new feature. Therefore, it seems quite useful to contain the hash and the file in the same object "for free", doesn't it? But as I said before, I've already done it.
 [2009-08-17 02:45 UTC] cweiske (Christian Weiske)
You still did not tell us what kind of hash you would like to have - and how you would go about the possibility that other people would need different types of hashes. How would you do that?
 [2009-08-17 03:24 UTC] darizotas (Dario Borreguero)
There are two reasons why to implement it: 1. The administrator could be able to check the integrity of the file in the server once uploaded. 2. The application Web user could be able to check the integrity of the selected file to download. Therefore, this new feature would improve the security of the application Web. Of course, this checking has an impact in the performance. I'm currently using sha1 (see the function sha1_file), but I'd like to move to sha256. I haven't studied it yet. I'd never use md5.