keys

package
v0.0.0-...-f661f07 Latest Latest
Warning

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

Go to latest
Published: Dec 14, 2013 License: MIT Imports: 6 Imported by: 6

Documentation

Overview

Some helpers for converting keys between formats

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadBytes

func LoadBytes(path string) []byte

trivial read all helper

func LoadKey

func LoadKey(path string) *msgs.PublicKey

Load key from file

func LoadPrivateKey

func LoadPrivateKey(path string) *msgs.PrivateKey

Load key from file

func PackKey

func PackKey(k *rsa.PublicKey) *msgs.PublicKey

rsa -> msg

func PackPrivateKey

func PackPrivateKey(k *rsa.PrivateKey) *msgs.PrivateKey

rsa -> msg

func StringKey

func StringKey(k *msgs.PublicKey) string

Serialize a public key to a string (useful for using keys as map keys)

func UnpackKey

func UnpackKey(k *msgs.PublicKey) *rsa.PublicKey

msg -> rsa

func UnpackPrivateKey

func UnpackPrivateKey(k *msgs.PrivateKey) *rsa.PrivateKey

msg -> rsa

Types

This section is empty.

Jump to

Keyboard shortcuts

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