* add proptests for invalid forms of input
* apply proptests to each valid block we have
* start moving equihash logic to BlockHeader
* provide an error based interface
* cleanup logging in dependent crate
* use is_equihash_solution_valid everywhere
* switch to proper equihash crate branch
This change brings in the `equihash` crate from librustzcash and uses it to add a basic `is_valid` test for `EquihashSolutions`.
Co-authored-by: Jane Lusby <jane@zfnd.org>
Verify the value of the equihash solution size field in block headers.
This field isn't stored in the BlockHeader struct, so we need to verify
it at parse time.
Part of #477.
Closes#158.
As discussed on the issue, this makes it possible to safely serialize
data into hashes, and encourages serializable data to make illegal
states unrepresentable.