Code Comments
Programming Forum and web based access to our favorite programming groups.Good morning! 1. Is there any software which tries to determine which compression method is used in some file? Such utility can contains a lot of unpacking libraries (arj,zip,gzip,lzo,compress,rar,etc) and try to use various unpacking functions with the different file offsets.. It can also analyze "randomness" of the file to guess which compression method is used and so on.. 2. Does the world need such utility? Best regards, Vadim.
Post Follow-up to this messagevk@tvcom.ru (Vadim Kolontsov) wrote in message news:<f09e4ffd.0411100153.1cc29ce5@posting.g oogle.com>... > Good morning! > > 1. Is there any software which tries to determine which compression > method is used in some file? Such utility can contains a lot of > unpacking libraries (arj,zip,gzip,lzo,compress,rar,etc) and try to use > various unpacking functions with the different file offsets.. It can > also analyze "randomness" of the file to guess which compression > method is used and so on.. > > 2. Does the world need such utility? No, and no, IMO. The reasons are 1. many "rippers" already exist that can detect and extract archive formats; 2. it is possible with some routines to "decompress" any file -- you get gibberish of course, but no error is generated; 3. analyzing "randomness" to determine the archive format and/or compression method is pretty much impossible without knowing the characteristics of the source material beforehand.
Post Follow-up to this messagetrixter@despammed.com (Jim Leonard) wrote in message news:<f93aad69.0411101152.7fd095af@pos ting.google.com>... > No, and no, IMO. The reasons are 1. many "rippers" already exist that > can detect and extract archive formats; 2. it is possible with some > routines to "decompress" any file -- you get gibberish of course, but > no error is generated; 1. As far as I know, such rippers tries to find specific signatures of archivers (headers and so on). They can't find just compressed stream with unknown header. Am I wrong? 2. a) Well, it seems that such situtation is possible, but rare enough. "Wrong" stream usually brokes decompression routine. b) Human [almost] always can determine if decompressed output is a garbage or not. Best regards, Vadim.
Post Follow-up to this messagevk@tvcom.ru (Vadim Kolontsov) wrote in message news:<f09e4ffd.0411110248.74a0e245@posting.g oogle.com>... > trixter@despammed.com (Jim Leonard) wrote in message news:<f93aad69.041110 1152.7fd095af@posting.google.com>... > > 1. As far as I know, such rippers tries to find specific signatures of > archivers (headers and so on). They can't find just compressed stream > with unknown header. Am I wrong? You are not wrong, but usually the entire archive structure is necessary for proper decompression of the files. For example, in a "solid" stream (like the kind RAR produces), how would you know if you were finished with one file and beginning another? > 2. a) Well, it seems that such situtation is possible, but rare > enough. "Wrong" stream usually brokes decompression routine. It depends on the decompression routine. The main point is that you would need something to compare decompressed output against in order to determine if you had the right method, and because you won't know that beforehand, it would be pretty pointless to try. Just my opinion, you're welcome to do whatever you want :-)
Post Follow-up to this message
Show a Printable Version
Email This Page to Someone!
Receive updates to this thread
Powered by vBulletin
Copyright 2000-2006 Jelsoft Enterprises Limited.