rust-bitcoin-unsafe-fast/hashes/src
merge-script e45bc0056c
Merge rust-bitcoin/rust-bitcoin#3981: Do not implement `Default` for `HmacEngine`
18619a6d0b api: Run just check-api (Tobin C. Harding)
1eb8f1f9e0 Add a Hmac::engine function (Tobin C. Harding)
c352d376ed Do not implement Default for HmacEngine (Tobin C. Harding)

Pull request description:

  The `HmacEngine` should be created using a key. Currently we are providing a `Default` impl that uses `&[]` as the key. This is, I believe, a hangover from when we had a `Default` trait bound somewhere else. It is incorrect and an API footgun - remove it.

  Note this PR includes changes to the bench code in `hmac` that highlights the footgun - pity the poor user we even shot ourselves.

  Patch 2 adds a constructor `Hmac::engine` and uses it in the bench code.

ACKs for top commit:
  Kixunil:
    ACK 18619a6d0b
  apoelstra:
    ACK 18619a6d0b0bca7b7e3603e260b254b4aae6cebf; successfully ran local tests

Tree-SHA512: c96640e7ffba52d5b13b76a6dd9e1381788efcf56ee76300c5111541466bab8018d2546bcecf237c42dbd82e9372a0e43e1ecec37147508e879365d92a4c1451
2025-01-31 20:29:55 +00:00
..
cmp.rs Remove the SliceIndex implementation from hash types 2024-10-02 10:18:45 +10:00
error.rs Remove usage of impl_from_infallible in leaf crates 2025-01-02 07:51:21 +11:00
hash160.rs Merge rust-bitcoin/rust-bitcoin#3584: Standardize constructor type function docs 2024-11-06 16:05:24 +00:00
hkdf.rs Remove test_ prefix from unit tests 2025-01-02 10:06:50 +11:00
hmac.rs Add a Hmac::engine function 2025-01-31 11:15:42 +11:00
internal_macros.rs hashes: Make hex dependency optional 2024-11-14 09:36:55 +11:00
lib.rs Remove unnecessary doc(hidden) 2025-01-20 17:23:12 +11:00
macros.rs hashes: Hide both macros 2024-12-29 08:23:39 +11:00
ripemd160.rs Merge rust-bitcoin/rust-bitcoin#3584: Standardize constructor type function docs 2024-11-06 16:05:24 +00:00
sha1.rs Merge rust-bitcoin/rust-bitcoin#3584: Standardize constructor type function docs 2024-11-06 16:05:24 +00:00
sha256.rs hashes: Add additional must_use 2024-12-10 10:58:11 +11:00
sha256d.rs Merge rust-bitcoin/rust-bitcoin#3584: Standardize constructor type function docs 2024-11-06 16:05:24 +00:00
sha256t.rs hashes: Remove sha256t::Hash Default impl 2025-01-29 12:27:48 +11:00
sha384.rs Replace `creates` with `constructs` 2024-11-05 12:47:28 +00:00
sha512.rs Merge rust-bitcoin/rust-bitcoin#3584: Standardize constructor type function docs 2024-11-06 16:05:24 +00:00
sha512_256.rs Replace `creates` with `constructs` 2024-11-05 12:47:28 +00:00
siphash24.rs Remove test_ prefix from unit tests 2025-01-02 10:06:50 +11:00