util

package
v0.0.0-...-30cd2f9 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2020 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AbsolutePath

func AbsolutePath(aPath string) string

func Compress

func Compress(in []byte) []byte

func CompressString

func CompressString(in string) string

func Decompress

func Decompress(in []byte) []byte

func DecompressString

func DecompressString(in string) string

func ID

func ID() string

UUID generate a new V4 UUID

func LoadCertificate

func LoadCertificate(certPath string) (string, error)

LoadCertificate from file system

func SignString

func SignString(toSign string, privateKeyPath string) (string, error)

Types

type Signer

type Signer interface {
	// Sign returns raw signature for the given data. This method
	// will apply the hash specified for the keytype to the data.
	Sign(data []byte) ([]byte, error)
}

A Signer is can create signatures that verify against a public key.

Jump to

Keyboard shortcuts

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