Files
opentf/internal/encryption/keyprovider/config.go
Janos a18e643a8d PBKDF2 passphrase key provider (#1310)
Signed-off-by: Janos <86970079+janosdebugs@users.noreply.github.com>
Signed-off-by: Christian Mesh <christianmesh1@gmail.com>
Co-authored-by: Christian Mesh <christianmesh1@gmail.com>
Co-authored-by: James Humphries <jamesh@spacelift.io>
2024-03-11 14:24:31 +01:00

17 lines
670 B
Go

// Copyright (c) The OpenTofu Authors
// SPDX-License-Identifier: MPL-2.0
// Copyright (c) 2023 HashiCorp, Inc.
// SPDX-License-Identifier: MPL-2.0
package keyprovider
// Config is a struct annotated with HCL (and preferably JSON) tags that OpenTofu reads the user-provided configuration
// into. The Build function assembles the configuration into a usable key provider.
type Config interface {
// Build provides a key provider and an empty JSON-tagged struct to read the decryption metadata into. If the
// configuration is invalid, it returns an error.
//
// If a key provider does not need metadata, it may return nil.
Build() (KeyProvider, KeyMeta, error)
}