On Thu, Apr 26, 2001 at 12:06:52AM -0700, Aaron Voisine wrote:
> er... yeah... I knew the data was encrypted. I didn't realize that the 
> encryption rendered the data mostly random. I suppose that makes sense, 
> recognizable patterns can't be good for security. I guess the only way to 
> do it then would be to compress that data prior to encryption. This would 
> have the added benefit of reducing the size of file in datastores as well.
>   Of course this would not be a backwards compatible change. It would still 
> be beneficial to have freenet nodes automagically zlib compress files 
> prior to insertion. The other problem would be that the algorithm can't be 
> changed in the future without breaking freenet.
> 
> What if the first part of the unencrypted file were:
> Compression=zlib:
> Followed by the compressed data. This way "none" could be chosen for 
> already compressed files and new algorithms could be added in the future. 
> If the file does not start with Compression=<algorithm>:, it could be 
> assumed that this file was inserted prior to the compression feature, 
> allowing for backwards compatibility.

This probably won't have all that much of an effect on total storage
capacity. The files that take up the most space, movies, mp3s, images,
(usually jpg) kernels etc. are already compressed a lot and won't
compress any more. The rest of the stuff, html and text, compresses
very well but there really isn't very much of it. Quite simply %90 of
the space is consumed by files that you can't compress any
further. You'll have to put in code to regognize if you can compress a
file before attempting to do so, compressing a mp3 only wastes time
and can even make it bigger.

Go ahead and do it I guess but you're not going to get very much out
of doing this and you'll make inserting large files slower.

-- 
GCS d s+:-- a--- C++++ UL++++ P L+++ E W++ N- o K- w-- O- M 
V- PS+ PE+ Y+ PGP+++ t 5 X R+ tv-- b+ DI+ D++ G e- h! r-- y--
[EMAIL PROTECTED] http://retep.tripod.com 

PGP signature

Reply via email to