Documentation ¶
Overview ¶
Package vault utilizes age package for secure data encryption and decryption.
Index ¶
Constants ¶
View Source
const ( Perm600 = 0o600 // For secret files. Perm700 = 0o700 // For sensitive files or directories. )
Variables ¶
View Source
var ( File = "vault" // Default vault file name. Dir = ".skunk" // Default vault directory. )
Functions ¶
func Decode ¶
Decode decrypts the specified file using the given passphrase. It returns the decrypted data as a byte slice. It returns error if the decryption or file operations fail.
func Encode ¶
Encode encrypts given value and writes it to the specified file using the given passphrase. It returns an error if the encryption or file operations fail.
func IsVaultExist ¶
IsVaultExist checks if the vault file exists and returns the path.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.