Replace rust-crypto with RustCrypto#1573
Conversation
|
Indeed, it could be a problem with But looks like there's no better choice so far. The I see https://github.com/rust-bitcoin/rust-bitcoin/blob/master/Cargo.toml#L26 I'm not against this replacement, just want to inform these info 😃 |
|
I have a bad idea: we clone Anybody second me? |
|
@garyyu there should another branch in the new crypto lib repo where all the new stuff is, and that's likely what we should use. IIRC |
What do you mean |
|
Sorry, I just added confusion and realize I don't know what this is all
about. I do think there was a discussion about crypto libs and that we'll
need to swap something for something else, and that apoelstra recommended a
lib that is at least "nearly there" with some needed features, but I guess
this PR is not really related to that discussion.
Please, if someone can add 1-2 lines explaining the rationale for this
change. Good practice also so future grin-devs can go back through PR
history and understand. cc @quentinlesceller etc :)
|
|
It's just that rust-crypto relies on old dependencies and is unmaintained since two years. |
I think the idea is to migrate to https://github.com/rust-bitcoin/bitcoin_hashes once it's ready (according to this) |
|
@mcdallas good catch - I knew we'd discussed something as a replacement but couldn't remember where/what it was... |
|
So, we'd better open an issue and leave it there to remind us this https://github.com/rust-bitcoin/bitcoin_hashes . But I feel this Again, nobody second me to clone |
|
I don't see the issue with using RustCrypto/Hashes/HMac instead of rust-crypto. And I don't see why bitcoin_hashes would be better a better replacement (except maybe less dependencies). |
|
bitcoin_hashes is worked on by @apoelstra et al (ping!)
Before forking rust-crypto or waiting passively for bitcoin_hashes, can we
again restate which functions we need to add / update / maintain for the
various possible packages. Maybe also try to get an estimate from
maintainers what effort would be required. If nothing else, I suspect
bitcoin_hashes is the nicest option longer term, and maybe we can scare up
some more rust programmers to finish off the missing parts there.
|
|
I just need @TheBlueMatt (nudge, nudge) to merge the open PRs on bitcoin_hashes, then I think it will be done and in maintenance mode. |
This reasoning should be written in the commit message, not only in the PR history. |
|
@garyyu that's a lot of risky code to maintain when we only use a fraction of it. This PR is a net improvement, possibly with more improvements to come. So let's merge. |
* Replace rust-crypto with RustCrypto
Replace the unmaintained rust-crypto crates with https://github.com/RustCrypto/hashes, https://github.com/RustCrypto/MACs and https://github.com/RustCrypto/traits.