cksum

package
v0.0.0-...-a6dfa66 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2024 License: MIT Imports: 6 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 struct {
	// contains filtered or unexported fields
}

func NewFromChecksumString

func NewFromChecksumString(v string) (*Hasher, error)

func NewHasher

func NewHasher() *Hasher

func (Hasher) SumToChecksumString

func (h Hasher) SumToChecksumString(b []byte) string

SumToChecksumString sums and encodes the checksum as a string that can be used as a subresource integrity.

See https://developer.mozilla.org/en-US/docs/Web/Security/Subresource_Integrity for format.

func (Hasher) Write

func (h Hasher) Write(p []byte) (n int, err error)

Jump to

Keyboard shortcuts

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