Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrInitializationFailed = errors.New("initialization failed") ErrEncryptionFailed = errors.New("encryption failed") ErrDecryptionFailed = errors.New("decryption failed") ErrCiphertextTooLarge = errors.New("ciphertext too large") ErrInvalidSaltNonceLength = errors.New("invalid salt/nonce length") ErrBadMagic = errors.New("bad magic") ErrUnsupportedVersion = errors.New("unsupported version") )
Functions ¶
This section is empty.
Types ¶
type AES256GCMService ¶
type AES256GCMService struct {
// contains filtered or unexported fields
}
AES256GCMService implements AES-256-GCM encryption.
func NewAES256GCMService ¶
func NewAES256GCMService(masterKey []byte) *AES256GCMService
NewAES256GCMService creates a new AES-256-GCM encryption service.
type Service ¶ added in v0.5.1
type Service interface {
// Encrypt encrypts a stream using AES-256-GCM with streaming support
Encrypt(ctx context.Context, r io.Reader, w io.Writer) error
// Decrypt decrypts a stream using AES-256-GCM with streaming support
Decrypt(ctx context.Context, r io.Reader, w io.Writer) error
}
Service defines the interface for encryption operations.
Click to show internal directories.
Click to hide internal directories.