Exemple #1
0
// Returns the SHA512Half hash for the admin block
func (b *AdminBlock) BackReferenceHash() (interfaces.IHash, error) {
	var binaryAB []byte
	binaryAB, err := b.MarshalBinary()
	if err != nil {
		return nil, err
	}
	return primitives.Sha512Half(binaryAB), nil
}
Exemple #2
0
// Build the SHA512Half hash for the admin block
func (b *AdminBlock) BuildFullBHash() (err error) {
	var binaryAB []byte
	binaryAB, err = b.MarshalBinary()
	if err != nil {
		return
	}
	b.fullHash = primitives.Sha512Half(binaryAB)
	return
}