cryptlib

package module
v0.0.0-...-5fb3edf Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2018 License: MIT Imports: 14 Imported by: 0

README

Cryptlib

cryptlib is a small wrapper around some common (for me) symmetric encryption tasks. It can create recursive tar-bz archives, and encrypt a stream (optional pgp compression and armor).

import "github.com/pzl/cryptlib"

godoc.org/github.com/pzl/cryptlib

License

MIT (see LICENSE file)

Documentation

Index

Constants

This section is empty.

Variables

View Source
var NonMatchingPasswords = errors.New("Passwords did not match")

Functions

func Decrypt

func Decrypt(enc io.Reader) (io.Reader, error)

func DoublePrompt

func DoublePrompt(first string, second string) ([]byte, error)

func Encrypt

func Encrypt(plainText io.Reader, pass []byte, compress bool, asciiArmor bool) ([]byte, error)

func IsArmored

func IsArmored(data []byte) bool

func IsEncrypted

func IsEncrypted(filename string) (bool, error)

func IsTar

func IsTar(data []byte) bool

func PassPrompt

func PassPrompt(prompt string) ([]byte, error)

func Tarball

func Tarball(startDir string) (io.Reader, error)

func Untar

func Untar(source io.Reader) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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