crytic / solc-select

Manage and switch between Solidity compiler versions
GNU Affero General Public License v3.0
758 stars 103 forks source link

Add sha256 checksum to `solc-select install` #67

Closed 0xicingdeath closed 3 years ago

0xicingdeath commented 3 years ago

After downloading the solc binary, this code uses python to calculate the sha256 of the local binary, and compares the hash to the one provided by soliditylang. 🥳 If there is a mismatch, the code throws an error.

TODO:

Closes #44

0xicingdeath commented 3 years ago

dcf8238 Removes checksum check for Linux binaries 0.4.0 - 0.4.10, because they aren't currently in the list.json we have in the repo:

h̶t̶t̶p̶s̶:̶/̶/̶g̶i̶t̶h̶u̶b̶.̶c̶o̶m̶/̶c̶r̶y̶t̶i̶c̶/̶s̶o̶l̶c̶/̶b̶l̶o̶b̶/̶l̶i̶s̶t̶-̶j̶s̶o̶n̶/̶l̶i̶n̶u̶x̶/̶a̶m̶d̶6̶4̶/̶l̶i̶s̶t̶.̶j̶s̶o̶n̶ https://raw.githubusercontent.com/crytic/solc/new-list-json/linux/amd64/list.json (Could change branch to master later).

0xicingdeath commented 3 years ago

lgtm 🎉