You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ivy-user@ant.apache.org by Jim Garrison <ji...@troux.com> on 2011/06/30 23:16:16 UTC
Ivy confused about sha1 vs md5 checksums?
We just started getting the following error when resolving from a local repository:
[ivy:resolve] :: problems summary ::
[ivy:resolve] :::: WARNINGS
[ivy:resolve] [FAILED ] commons-io#commons-io;1.4!commons-io.jar: invalid sha1: expected=<!doctype computed=a8762d07e76cfde2395257a5da47ba7c1dbd3dce (827ms)
[ivy:resolve] [FAILED ] commons-io#commons-io;1.4!commons-io.jar: invalid sha1: expected=<!doctype computed=a8762d07e76cfde2395257a5da47ba7c1dbd3dce (827ms)
[ivy:resolve] ==== public: tried
[ivy:resolve] http://devmaster:8081/nexus/content/groups/public/commons-io/commons-io/1.4/commons-io-1.4.jar
devmaster is a local caching Nexus server.
commons-io.jar has only md5 checksums in Maven Central, not sha1. I purged the locally cached copy from devmaster and tried again but got the same error.
After a little digging through the Ivy docs, I added the following line to ivysettings.xml:
<property name="ivy.checksums" value="md5,sha1"/>
to force Ivy to try md5 first, which fixed the problem.
It looks like Ivy is somehow being fooled into thinking it needs to verify an sha1 sum when no such checksum exists. Known problem?
RE: Ivy confused about sha1 vs md5 checksums?
Posted by Jim Garrison <ji...@troux.com>.
> -----Original Message-----
> From: Maarten Coene [mailto:maarten_coene@yahoo.com]
> Sent: Thursday, June 30, 2011 4:29 PM
> To: ivy-user@ant.apache.org
> Subject: Re: Ivy confused about sha1 vs md5 checksums?
>
> My guess is that
> http://devmaster:8081/nexus/content/groups/public/commons-
> io/commons-io/1.4/commons-io-1.4.sha1 doesn't return an HTTP 404, but a
> nice looking html saying the resource doesn't exist?
You're on the right track, but it's much more bizarre than that. I captured the network traffic with Wireshark and found that Ivy issues a GET to
http://devmaster:8081/nexus/content/groups/public/commons-io/commons-io/1.4/commons-io-1.4.jar.sha1
which looks right. However, the returned data looked really weird, so I entered that URL in a browser and got..... the HTML for Oracle's home page (not the home page, but the HTML source displayed in the browser).
I will pursue this further on the nexus list.
Re: Ivy confused about sha1 vs md5 checksums?
Posted by Maarten Coene <ma...@yahoo.com>.
My guess is that http://devmaster:8081/nexus/content/groups/public/commons-io/commons-io/1.4/commons-io-1.4.sha1 doesn't return an HTTP 404, but a nice looking html saying the resource doesn't exist?
Maarten
________________________________
From: Jim Garrison <ji...@troux.com>
To: "ivy-user@ant.apache.org" <iv...@ant.apache.org>
Sent: Thursday, June 30, 2011 11:16 PM
Subject: Ivy confused about sha1 vs md5 checksums?
We just started getting the following error when resolving from a local repository:
[ivy:resolve] :: problems summary ::
[ivy:resolve] :::: WARNINGS
[ivy:resolve] [FAILED ] commons-io#commons-io;1.4!commons-io.jar: invalid sha1: expected=<!doctype computed=a8762d07e76cfde2395257a5da47ba7c1dbd3dce (827ms)
[ivy:resolve] [FAILED ] commons-io#commons-io;1.4!commons-io.jar: invalid sha1: expected=<!doctype computed=a8762d07e76cfde2395257a5da47ba7c1dbd3dce (827ms)
[ivy:resolve] ==== public: tried
[ivy:resolve] http://devmaster:8081/nexus/content/groups/public/commons-io/commons-io/1.4/commons-io-1.4.jar
devmaster is a local caching Nexus server.
commons-io.jar has only md5 checksums in Maven Central, not sha1. I purged the locally cached copy from devmaster and tried again but got the same error.
After a little digging through the Ivy docs, I added the following line to ivysettings.xml:
<property name="ivy.checksums" value="md5,sha1"/>
to force Ivy to try md5 first, which fixed the problem.
It looks like Ivy is somehow being fooled into thinking it needs to verify an sha1 sum when no such checksum exists. Known problem?
RE: Ivy confused about sha1 vs md5 checksums?
Posted by Jim Garrison <ji...@troux.com>.
> -----Original Message-----
> From: Jim Garrison [mailto:jim.garrison@troux.com]
> Sent: Thursday, June 30, 2011 4:16 PM
> To: ivy-user@ant.apache.org
> Subject: Ivy confused about sha1 vs md5 checksums?
>
> We just started getting the following error when resolving from a local
> repository:
[snip]
Forgot to include versions: Ivy is 2.1.0 on Win7 invoked from Ant 1.8.2, Nexus is 1.9.1.1 on Fedora 14