How to validate a block received from daemon API
If I take a getBlock response from the daemon API, it contains a blob, and the header details, including a hash.
How do I go about validating this block manually, or using copies of source code? Is result.block_header.hash a cryptonight hash of result.blob? I'm unable to validate it that way.
I've also tried running the result.blob hash through the embedded check_hash(hash,difficulty) method, using the difficulty provided in the header details, and I keep getting a false.
How can I take the data that comes from getBlock and validate it?