hash

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2020 License: GPL-3.0 Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Hash32Repo

type Hash32Repo interface {
	Sum(s string) string
	SumBytes(b []byte) string
	SumTimes(s string, times uint) string
	SumBytesTimes(b []byte, times uint) string
	Sum32(b []byte) (uint32, error)
}

Hash32Repo hash32 functions manager

func NewCRC32

func NewCRC32(tab *crc32.Table) Hash32Repo

NewCRC32 get crc32 hash32repo

func NewCRCIEEE

func NewCRCIEEE() Hash32Repo

NewCRCIEEE get ieee hash32repo

type Repo

type Repo interface {
	Sum(s string) string
	SumBytes(b []byte) string
	SumTimes(s string, times uint) string
	SumBytesTimes(b []byte, times uint) string
}

Repo hash functions manager

func NewHashRepo

func NewHashRepo(h crypto.Hash) Repo

NewHashRepo get hash repo by crypto type

func NewMD5

func NewMD5() Repo

NewMD5 get md5 hash repo

func NewSHA1

func NewSHA1() Repo

NewSHA1 get sha1 hash repo

func NewSHA224

func NewSHA224() Repo

NewSHA224 get SHA224 hash repo

func NewSHA256

func NewSHA256() Repo

NewSHA256 get SHA256 hash repo

func NewSHA384

func NewSHA384() Repo

NewSHA384 get SHA384 hash repo

func NewSHA512

func NewSHA512() Repo

NewSHA512 get SHA512 hash repo

func NewSHA512_224

func NewSHA512_224() Repo

NewSHA512_224 get SHA512_224 hash repo

func NewSHA512_256

func NewSHA512_256() Repo

NewSHA512_256 get SHA512_256 hash repo

Jump to

Keyboard shortcuts

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