sha256

package
v0.0.0-...-e61308d Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2017 License: MIT Imports: 4 Imported by: 3

Documentation

Overview

Package sha256 implements the SHA224 and SHA256 hash algorithms in FIPS 180-2.

Index

Constants

View Source
const (
	// The size of a SHA256 checksum in bytes.
	Size = C.SHA256_DIGEST_LENGTH

	// The size of a SHA224 checksum in bytes.
	Size224 = C.SHA224_DIGEST_LENGTH

	// The blocksize of SHA256 and SHA224 in bytes.
	BlockSize = 64
)

Variables

This section is empty.

Functions

func New

func New() hash.Hash

New returns a new sha256 hash.Hash if the returned hash is empty, then make a call to sslerr.Error()

func New224

func New224() hash.Hash

func Sum224

func Sum224(data []byte) (sum224 [Size224]byte)

Sum224 returns the SHA224 checksum of the data.

func Sum256

func Sum256(data []byte) (sum256 [Size]byte)

Sum256 returns the SHA256 checksum of the data.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL