Pkg
Crypt

Crypt

Explore the following sections to learn more:

crypt

import "github.com/gemini-oss/rego/pkg/common/crypt"

pkg/common/crypt/crypt.go

Index

func DecryptAES

func DecryptAES(data string, passphrase []byte) ([]byte, error)

DecryptAES decrypts data encrypted with AES-GCM using a passphrase

func EncryptAES

func EncryptAES(data []byte, passphrase []byte) (string, error)

EncryptAES encrypts data using AES-GCM with a passphrase

func SecureRandomInt

func SecureRandomInt(max int) (int, error)

func ValidPassphrase

func ValidPassphrase(passphrase []byte) error

type PassphraseError

type PassphraseError struct {
    Issues []string
}

func (*PassphraseError) Error

func (e *PassphraseError) Error() string

Generated by gomarkdoc