crypt

package
v0.9.18 Latest Latest
Warning

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

Go to latest
Published: Feb 20, 2024 License: AGPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateFile added in v0.7.3

func CreateFile(path string) (dbFile *os.File, err error)

CreateFiles creates the temporary directory and database file

func GetPrivateKeyPath

func GetPrivateKeyPath(conf *cfg.Config) (string, error)

func GetPublicKeyPath

func GetPublicKeyPath(conf *cfg.Config) (string, error)

GetPublicKeyPath returns the absolute path to the public key

Types

type Keys

type Keys struct {
	Identifier uuid.UUID
	Private    *age.X25519Identity
	Public     *age.X25519Recipient
}

Keys holds the information used for volatile identification of a particular user

func GenerateKeys

func GenerateKeys() (k Keys, e error)

@function GenerateKeys @description Generates a (volatile) public and private key pair to be used for intermediary encryption in the frontend @returns Keys, error NOTE: should probably also expect some persistent key based identification to be passed as a parameter to make impersonation harder

Jump to

Keyboard shortcuts

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