| 529 | } |
| 530 | |
| 531 | Hash cn::get_block_hash(const BlockHeader &bh, const BlockBodyProxy &body_proxy) { |
| 532 | // get_object_hash prepends array size before hashing. |
| 533 | // this was a mistake of initial cryptonote developers |
| 534 | Hash ha2 = get_object_hash(seria::to_binary(bh, BlockSeriaType::BLOCKHASH, body_proxy), nullptr); |
| 535 | // std::cout << "ha: " << ha2 << " ba: " << common::to_hex(seria::to_binary(bh, BlockSeriaType::BLOCKHASH, |
| 536 | // body_proxy)) << std::endl; |
| 537 | return ha2; |
| 538 | } |
| 539 | |
| 540 | Hash cn::get_block_header_prehash(const BlockHeader &bh, const BlockBodyProxy &body_proxy) { |
| 541 | // get_object_hash prepends array size before hashing. |
nothing calls this directly
no test coverage detected