Re: gzip file ftp'ed as ascii...
- From: aslanski2002@xxxxxxxxx
- Date: 17 Aug 2005 19:42:15 -0700
Willem yazdi:
> aslanski2002@xxxxxxxxx wrote:
> ) aslanski2002@xxxxxxxxx yazdi:
> )> Do not give up so fast. Yes we have a problem when we encounter CR or
> )> LF, but excluding those two, all of the other bytes has been
> )> transformed as they are. That's a valuable information. And when we see
> )> CR+LF most of the times, it could be a LF (Unix text file case). If it
> )> is a bytes in a binary file or in a header it could be CR or LF. If it
> )> is critical data, it is worth giving a try!
>
> Still, there are 11000 locations that may or may not have been altered.
> That's still a lot of info.
>
> Now, if the gzip format had, say, a crc every 32 kilobytes or so,
> the story might be entirely different.
>
> ) I forgot to add that the last four byte of the file is the size of the
> ) deflated data. So comparing it with the new size of the file we can get
> ) some info about the number of CR and LF bytes in the original file! So
> ) we can find out how many "CR/LF to CR+LF" substitutions occurred!
>
> Assuming there's roughly a 1/256 chance that a 0D is followed by a 00 in
> the original, this extra information means that the number of ways to put
> 00 bytes after 0D bytes is in the order of 40-choose-11000.
>
> That's still very roughly 500 bits of 'lost information'. Or, to put it
> differently, 2^500 possible ways to try and put back a 00 after a 0D.
>
We have another useful information. It is a gzipped tar file. So the
first 512 bytes is (or should be) a tar header with file name, file
size and the CRC of the tar header. Using file size we can find out the
position of the next tar header if we decode the header successfully.
So when decoding the first file, possibilities are reduced! How many OD
bytes would we have when we decode the first file in the tar archive
for example?
>
> SaSW, Willem
> --
> Disclaimer: I am in no way responsible for any of the statements
> made in the above text. For all I know I might be
> drugged or something..
> No I'm not paranoid. You all think I'm paranoid, don't you !
> #EOT
.
- Follow-Ups:
- Re: gzip file ftp'ed as ascii...
- From: Sachin Garg
- Re: gzip file ftp'ed as ascii...
- References:
- gzip file ftp'ed as ascii...
- From: James
- Re: gzip file ftp'ed as ascii...
- From: James
- Re: gzip file ftp'ed as ascii...
- From: Willem
- Re: gzip file ftp'ed as ascii...
- From: aslanski2002
- Re: gzip file ftp'ed as ascii...
- From: aslanski2002
- Re: gzip file ftp'ed as ascii...
- From: Willem
- gzip file ftp'ed as ascii...
- Prev by Date: Re: Compression of very large images
- Next by Date: Re: gzip file ftp'ed as ascii...
- Previous by thread: Re: gzip file ftp'ed as ascii...
- Next by thread: Re: gzip file ftp'ed as ascii...
- Index(es):
Relevant Pages
|
|