10 KiB
unreleased
-
Change the default display direction of for tagged hashes to forwards. #2707
Note please this usage if you need to display backward:
sha256t_hash_newtype! {
/// Test detailed explanation.
struct NewTypeTag = hash_str("tag");
/// A test hash.
#[hash_newtype(backward)]
struct NewTypeHash(_);
}
0.14.0 - 2024-03-21
- Bump MSRV to Rust version 1.56.1 #2188
API improvemnts
- Add support for SHA384 #2538
- Make from_hex inherent for byte-like types #2491
- Add
Hash::from_bytes_iterto construct hashes from iterators #2272 - Make some constructors
const#2446
Features/dependencies changes
Error handling improvements
0.13.0 - 2023-06-29
The main improvement in this version is removal of the hex module in favour of the new
hex-conservative crate (which we wrote). We also
bumped the Minimum Supported Rust Version across the rust-bitcoin ecosystem to v1.48
- Bump MSRV to 1.48.0 #1729.
- Depend on new
hex-conservativecrate and removehexmodule #1883. - Make
sha256t_hash_newtype!evocative of the output #1773. - Implement computing SHA256 in const context #1769.
- Add
from_bytes_refandfrom_bytes_mutto all hash types #1761. - Rename
crate::Errortocrate::FromSliceError#1873. - Add simd sha256 intrinsics for x86 machines #1962.
- Introduce the "small-hash" feature for
bitcoin_hashes#1990.
0.12.0 - 2023-03-05
0.12 is a significant release. We pulled the repository into the rust-bitcoin repo to improve our integration testing and to get more eyes on this crate. We began the process of replacing the hex functionality in this crate with a more performant, dedicated crate, and otherwise cleaning up the API as we look forward to 1.0.
- Remove
FromHeximplementation from all hashes and implementFromStrinstead. - Move crate from original repo to the
rust-bitcoinrepository. Commit history was lost during move, for commit history see the original repository. Tip of bitcoin_hashes:master at time of import: 54c16249e06cc6b7870c7fc07d90f489d82647c7 - Remove
Derefimpls for all hashes - Add
AsRefimpls for all hashes from fixed-size arrays - Add the
sha512_256hash - Remove the
ToHextrait in favor ofDisplayHexandfmt::Display - Remove the now-unused
HexWriterobject - nostd:
allocfeature no longer enablescore2 - Rewrite
hash_newtypemacro with new syntax - Rename
Hash::InnertoHash::Bytes, 'Hash::*_inner` and several related conversion methods
0.11.0 - 2022-06-25
The major change in this version is the increase of the Minimum Supported Rust Version (MSRV) from 1.29 to 1.41.1. This is a big change because it introduces Rust Edition 2018 to the codebase along with all the benefits that brings. We also did a bunch of optimisations to speed up encoding and decoding hex strings.
Breaking changes
New features/APIs
- Add
all_zerostoHashtrait - Implement
WriteonHmacEngine - Introduce
HexWriter, makes serialising hex faster - Implement
ReadonHexIterator, makes deserialising hex faster
Other improvements
- Use
rotate_leftinstead of custom macro - Enable clippy on CI
- Various docs fixes
- Improve feature test coverage
- Add a disabled
rustfmt.tomlto improve interaction with auto-formatting in editors
0.10.0 - 2021-07-05
- Increase
core2to released version of 0.3.0
0.9.7 - 2021-06-17
- Introduce
allocfeature andcore2dependency for nostd support (this feature has MSRV of 1.36 rather than 1.29)
0.9.6 - 2021-05-03
- Re-export
coreas_export::_core. This resolves an issue when calling several exported macros with thestdfeature.
0.9.5 - 2021-04-28
- Add
#[repr(transparent)]to all newtype wrappers - Add missing
#derives - Replace
fuzztargetfeature with use ofcfg(fuzzing) - Use
corerather thanstdand fixno_stdcompilation
Note that we have stopped re-exporting the core crate when compiling without std. This is technically a breaking change but it is hard to imagine what user might be affected.
0.9.4 - 2020-10-23
- Add
Hmac::from_inner_engines
0.9.3 - 2020-10-19
- More serde macro fixes
0.9.2 - 2020-10-18
- Fix rustc 1.29.0 downstream issues with serde macros
0.9.2 - 2020-10-16
- Fix visibility issue with serde macros
0.9.1 - 2020-10-07
- Add
FromStrimpl tosha256t::Hash - Fix
Hash::engine()implementation for hash newtypes - Add
sha256t_hash_newtype!macro for creating tagged hashes
0.9.0 - 2020-08-27
- Update MSRV to 1.29.0
0.8.0 - 2020-08-26
- Add
as_innermethod toHashtrait - Add
n_bytes_hashedtoHashEnginetrait
0.7.6 - 2020-04-05
- Support hash newtypes with reversed hex serialization.
0.7.5 - 2020-04-02
- Add
sha256tmodule for SHA-256-based tagged hashes. - Add
FromStrfor hash newtypes. - Add
from_hashfor hash newtypes.
0.7.3 - 2019-12-18
- Add
as_hash(&self) -> <inner>method to hash newtypes.
0.7.2 - 2019-11-29
- Make the inner variable of
sha256::Midstatpublic - Drop the
byteorderdependency in favor of manual endianness implementations (later this will be in stdlib so we can drop even that) - Fix the
hash_newtypemacro, which did not compile before
0.7.1 - 2019-08-14
- Add hash_newtype macro that allows third parties to create newtype structs.
0.7.0 - 2019-07-19
- Add
hex::Errortype for errors generated by thehexmodule.
0.6.0 - 2019-07-10
- Add
no_stdsupport, rearrange traits to not depend onio::Write
0.5.0 - 2019-06-28
- Fix panic when parsing hashes that contain multibyte characters
- Add
FromStrto all hashes which hex-parses them
0.4.0 - 2019-06-23
- Add
from_innermethod to all hashes - Update
FromHextrait to requirefrom_byte_itermethod rather thanfrom_hexbe implemented - Make
Hmacmidstate an actual HMAC midstate - Allow
Displayof truncated hashes - Require using a constructor for
HexIteratorand then clean up the internals - Strongly type
sha256::Midstateto allow independent serialization - Add siphash24 module
0.3.2 - 2019-03-20
- Implement the
FromHextrait on many more types
0.3.1 - 2019-03-04
0.3.0 - 2019-01-23
- Bump minimum required rustc version to 1.22.0
- Fixed serde deserialization into owned string that previously caused panics when doing round-trip (de)serialization
HashEngine::block_size()andHash::len()are now associated constantsHashEngine::BLOCK_SIZEandHash::LEN- Removed
block_size()method fromHashtrait. It is still available as<T as Hash>::Engine::BLOCK_SIZE
0.2.0 - 2019-01-15
- Add a constant-time comparison function
- Simplify
io::Write::writeimplementations by having them do only partial writes - Add fuzzing support
- Allow
Hashes to be borrowed as[u8] - Replace public
Hashinners withinto_innermethod
0.1.0 - 2018-12-08
- Initial release