// Copyright 2009 The Go Authors. All rights reserved. // Use of this source code is governed by a BSD-style // license that can be found in the LICENSE file. // SHA256 hash algorithm. See FIPS 180-2. package sha256 import ( "bytes" "crypto/rand" "encoding" "fmt" "hash" "io" "testing" ) type sha256Test struct { out string in string halfState string // marshaled hash state after first half of in written, used by TestGoldenMarshal } var golden = []sha256Test{ {"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", "", "sha\x03j\t\xe6g\xbbg\xae\x85