util

package
v0.0.0-...-c9a28c5 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExitOnError

func ExitOnError(msg string, errs ...error)

ExitOnError and print error message if we encountered a problem

func LoadPrivateKey

func LoadPrivateKey(data []byte) (interface{}, bool)

LoadPrivateKey loads a private key from JWKs or PEM/DER data.

func LoadPublicKey

func LoadPublicKey(data []byte) interface{}

LoadPublicKey loads a public key from JWKs or PEM/DER data.

func ReadInput

func ReadInput(path string) []byte

ReadInput from file or stdin

func WriteAsJSON

func WriteAsJSON(path string, object interface{})

WriteAsJSON writes the object as a JSON

func WriteOutput

func WriteOutput(path string, data []byte)

WriteOutput to file or stdin

Types

This section is empty.

Jump to

Keyboard shortcuts

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