package
0.0.0-20240917120716-8843776e9f3a
Repository: https://github.com/cossacklabs/acra.git
Documentation: pkg.go.dev

# Packages

Package filesystem implements keystores that write and reads keys from file system.
Package lru implements simple LRU cache used by Keystore.

# Functions

GenerateSymmetricKey return new generated symmetric key that must used in keystore as master key and will comply our requirements.
GetKeyContextFromContext return byte context depending on provided options.
GetMasterKeyFromEnvironment return master key from environment variable with name AcraMasterKeyVarName.
GetMasterKeyFromEnvironmentVariable return master key from specified environment variable.
NewClientIDKeyContext create new key context with key purpose and clientID.
NewEmptyKeyContext create new empty key context.
NewKeyContext create new key context with key purpose and pure context.
NewSCellKeyEncryptor creates new SCellKeyEncryptor object with masterKey using Themis Secure Cell in Seal mode.
PrintKeysTable prints table which describes keys in a human readable format into the writer.
PrintRotatedKeysTable prints table which describes keys in a readable format into the writer.
ValidateID checks that clientID length is within required limits and clientID contains only valid chars (digits, letters, -, _, ' ').
ValidateMasterKey do validation of symmetric master key and return nil if pass check.

# Constants

KeyStore-related constants.
DefaultCacheSize default cache size.
DefaultKeyDirShort.
Use as marker to say Backuper to read all keys from keystore.
Export private and public key data.
Export only public key data.
InfiniteCacheSize unlimited size.
Set of values for KeyOwnerType.
Key kind constants:.
Key kind constants:.
Key kind constants:.
Key kind constants:.
Key kind constants:.
Key kind constants:.
Key kind constants:.
Key kind constants:.
Key kind constants:.
KeyStore-related constants.
KeyStore-related constants.
KeyStore-related constants.
Supported key purposes.
Supported key purposes.
Supported key purposes.
Supported key purposes.
Supported key purposes.
Supported key purposes.
Supported key purposes.
Supported key purposes.
Supported key purposes.
Supported key purposes.
StateCurrent represent current KeyState.
StateCurrent represent current KeyState.
SymmetricKeyLength in bytes for master key.
KeyStore-related constants.
WithoutCache means not using cache at all.

# Variables

Errors returned during accessing to client id or master key.
Errors returned during accessing to client id or master key.
Errors returned during accessing to client id or master key.
ErrKeysNotFound used if can't find key or keys.
Errors returned during accessing to client id or master key.
KeyPurposeToKeyKind mapping between KeyPurpose and KeyKind.

# Structs

ExportID represent KeyKind and KeyContext for Exporter.
Key struct store content of keypair or some symmetric key.
KeyContext contains generic key context for key operation.
KeyDescription describes a key in the keystore.
KeysBackup struct that store keys for poison records and all client's keys.
NoCache is cache implementation for case when keystore should not to use any cache.
SCellKeyEncryptor uses Themis Secure Cell with provided master key to encrypt and decrypt keys.

# Interfaces

AuditLogKeyGenerator is able to generate keys for AuditLogKeyStore.
AuditLogKeyStore keeps symmetric keys for audit log signtures.
Backup interface for export/import KeyStore.
Cache that used by FilesystemKeystore to cache loaded keys from filesystem.
DataEncryptorKeyStore interface with required methods for CryptoHandlers.
DecryptionKeyStore enables AcraStruct decryption.
Exporter interface for acra-keys export command.
HmacKeyGenerator is able to generate keys for HmacKeyStore.
HmacKeyStore interface to fetch keys for hma calculation.
Importer interface for acra-keys import command.
KeyEncryptor describes Encrypt and Decrypt interfaces.
KeyMaking enables keystore initialization.
PoisonKeyGenerator is responsible for generation of poison keys.
PoisonKeyStorageAndGenerator has all methods to create and retrieve various keys dedicated to poison records.
PoisonKeyStore provides access to poison record key pairs.
PrivateKeyStore provides access to storage private keys, used to decrypt stored data.
PublicKeyStore provides access to storage public keys, used to encrypt data for storage.
RecordProcessorKeyStore interface with required methods for RecordProcessor.
ServerKeyStore enables AcraStruct encryption, decryption, and secure communication of acra-server with other services.
StorageKeyCreation enables creation of new storage key pairs and rotation of existing ones.
StorageKeyDestruction enables destruction of created keys.
StorageKeyGenerator is able to generate keys for Acra CE and Acra EE.
StorageRotatedKeyDestruction enables destruction of created rotated keys.
SymmetricEncryptionKeyStore interface describe access methods to encryption symmetric keys.
SymmetricEncryptionKeyStoreGenerator interface methods responsible for generation encryption symmetric keys.
TranslationKeyStore enables AcraStruct translation.
TransportKeyStore provides access to transport keys.

# Type aliases

ExportMode constants describe which data to export from key storage.
KeyOwnerType define type key owners.
KeyPurpose describe usage of specific key.
KeyState set key state for KeyDescription (current/rotated).