[prev in list] [next in list] [prev in thread] [next in thread] 

List:       httpclient-users
Subject:    Re: Support for checksum with file download
From:       "Sabarivasan Viswanathan" <sabarivasan () gmail ! com>
Date:       2008-06-13 17:59:28
Message-ID: d6d4ea820806131059r7038829ds10a8aa81c5a0e0f2 () mail ! gmail ! com
[Download RAW message or body]


Thanks for the detailed responses. I control the server code as well. So I
can use DigestOutputStream or CheckedOuputStream to create the digest and
write the relevant code to compare it on the client.

That answers all my questions. Once again, thanks for the quick and detailed
responses.

Sabari

On Fri, Jun 13, 2008 at 10:45 AM, sebb <sebbaz@gmail.com> wrote:

> On 13/06/2008, Stephen J. Butler <stephen.butler@gmail.com> wrote:
> > On Fri, Jun 13, 2008 at 12:14 PM, sebb <sebbaz@gmail.com> wrote:
> >  > On 13/06/2008, Stephen J. Butler <stephen.butler@gmail.com> wrote:
> >  >> On Fri, Jun 13, 2008 at 11:29 AM, Sabarivasan Viswanathan
> >  >>  <sabarivasan@gmail.com> wrote:
> >  >>  > I will be doing a simple POST request to download a large file (of
> the order
> >  >>  > of a few tens of megabytes).
> >  >>  >
> >  >>  > In order to ensure that the file is not corrupted during
> transmission, I
> >  >>  > want to do a checksum on the client and compare it with the
> server's.
> >  >>  >
> >  >
> >  > What checksum does the server provide?
> >
> >
> > Ha! Good question. I hear checksum and always think CRC.
> >
> >  To make a preemptive comment, you can do the same thing with
> >  DigestInputStream that I did with CheckedInputStream. I believe the
> >  standard Inluded MessageDigestSpi includes MD5 and some versions of
> >  SHA.
> >
>
> All well and good.
>
> But what is the checksum to be compared against?
> i.e. how does the client get the expected checksum from the server?
>
> Perhaps the original poster can provide a bit more information on this.
>
> >
> >  ---------------------------------------------------------------------
> >  To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
> >  For additional commands, e-mail: httpclient-users-help@hc.apache.org
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: httpclient-users-unsubscribe@hc.apache.org
> For additional commands, e-mail: httpclient-users-help@hc.apache.org
>
>


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic