hash

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Apr 6, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Hasher

type Hasher interface {
	Hash(str string) (string, error)
}

Hasher interface to hash function

func NewHasher

func NewHasher(hasherName string) (Hasher, error)

type SHA1

type SHA1 struct {
}

func NewSHA1

func NewSHA1() *SHA1

NewSHA1 sha1 hash function

func (*SHA1) Hash

func (s *SHA1) Hash(str string) (string, error)

type SHA256

type SHA256 struct {
}

func NewSHA256

func NewSHA256() *SHA256

NewSHA256 sha256 hash function

func (*SHA256) Hash

func (s *SHA256) Hash(str string) (string, error)

type SHA512

type SHA512 struct {
}

func NewSHA512

func NewSHA512() *SHA512

NewSHA512 sha512 hash function

func (*SHA512) Hash

func (s *SHA512) Hash(str string) (string, error)

Directories

Path Synopsis
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

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