Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Verify checksums for files downloaded from Apache mirrors #11

Open
keith-turner opened this issue Dec 20, 2017 · 5 comments
Open

Verify checksums for files downloaded from Apache mirrors #11

keith-turner opened this issue Dec 20, 2017 · 5 comments

Comments

@keith-turner
Copy link
Contributor

The docker build file downloads Hadoop, Zookeeper, and Accumulo from Apache mirrors. It would be nice to directly download the expected checksums directly from Apache (using https) and verify the files.

@blueshift-brasil
Copy link
Contributor

Just a question about this.
Do you think we can use the md5 file downloaded from Apache website or check in hardcoded way like this:
RUN curl -sSL -o redis.tar.gz \ http://download.redis.io/releases/redis-3.0.1.tar.gz \ && echo "fe1d06599042bfe6a0e738542f302ce9533dde88 *redis.tar.gz" \ | sha1sum -c -

@ctubbsii
Copy link
Member

I kind of like the hard-coded way best. We declare a specific version, so we should know what the expected checksum is for that particular version. This is what https://github.com/astralway/uno does, and it's a similar strategy to the W3C's subresource integrity checks for utilizing resources from CDNs: https://w3c.github.io/webappsec-subresource-integrity/

@ctubbsii
Copy link
Member

Oh, also, the hardcoded solution saves us from accessing the apache.org site when not needed, which is the whole point of utilizing the mirrors.

@keith-turner
Copy link
Contributor Author

I think the hardcoded solution is ok.

@blueshift-brasil
Copy link
Contributor

Done!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants