Standard library / crypto/sha512
crypto/sha512.Sum512_256()
Compute the SHA512/256 digest of a complete byte slice. A digest alone does not authenticate data; use HMAC or a signature where appropriate. Not a password hashing scheme. Expected stdout: '53048e2681941ef99b2e29b76b4c7dabe4c2d0c634fc6d46e0e2f13107e7af23\n'.
Formal Syntax & Structure
go syntaxgo
func Sum512_256(data []byte) [Size256]byteParameters & Attributes
| Name | Type | Description |
|---|---|---|
| data | []byte | Exact input bytes to hash. |
Return Value
[Size256]byte
Fixed-size SHA512/256 digest.
Working Example
Example Snippetgo
package main
import ( "crypto/sha512" "fmt")
func main() { fmt.Printf("%x\n", sha512.Sum512_256([]byte("abc"))) }