opentofu/internal/encryption
Christian Mesh b2bf39802a
Implement the first part of RFC 20250303-linter-policy (#2577)
Signed-off-by: Christian Mesh <christianmesh1@gmail.com>
2025-03-10 13:16:27 -04:00
..
compliancetest [State Encryption] Compliance tests (#1377) 2024-03-14 15:53:40 +01:00
config Improve encryption internals and fix a few bugs therein (#2551) 2025-03-06 12:51:09 -05:00
enctest allow static evaluations in encryption configuration (#1728) 2024-06-24 10:18:16 -04:00
keyprovider Implement the first part of RFC 20250303-linter-policy (#2577) 2025-03-10 13:16:27 -04:00
method Implement the first part of RFC 20250303-linter-policy (#2577) 2025-03-10 13:16:27 -04:00
registry [State Encryption] Compliance tests (#1377) 2024-03-14 15:53:40 +01:00
base.go Implement the first part of RFC 20250303-linter-policy (#2577) 2025-03-10 13:16:27 -04:00
default_registry.go Fixes #2337: External encryption method (#2367) 2025-01-31 12:13:18 -05:00
dual_custody_test.go Force state change if encryption used fallback (#2232) 2024-12-03 17:44:30 -05:00
encryption.go Improve encryption internals and fix a few bugs therein (#2551) 2025-03-06 12:51:09 -05:00
example_test.go Force state change if encryption used fallback (#2232) 2024-12-03 17:44:30 -05:00
keyprovider.go Implement the first part of RFC 20250303-linter-policy (#2577) 2025-03-10 13:16:27 -04:00
keyprovider_meta_change_test.go Force state change if encryption used fallback (#2232) 2024-12-03 17:44:30 -05:00
methods.go Improve encryption internals and fix a few bugs therein (#2551) 2025-03-06 12:51:09 -05:00
plan.go Force state change if encryption used fallback (#2232) 2024-12-03 17:44:30 -05:00
README.md Documentation updates for 1.7.0-alpha1 (state encryption) (#1396) 2024-03-14 15:05:05 +01:00
state.go Force state change if encryption used fallback (#2232) 2024-12-03 17:44:30 -05:00
targets.go Implement the first part of RFC 20250303-linter-policy (#2577) 2025-03-10 13:16:27 -04:00
targets_test.go Improve encryption internals and fix a few bugs therein (#2551) 2025-03-06 12:51:09 -05:00

OpenTofu State and Plan encryption

Warning

This file is not an end-user documentation, it is intended for developers. Please follow the user documentation on the OpenTofu website unless you want to work on the encryption code.

This folder contains the code for state and plan encryption. For a quick example on how to use this package, please take a look at the example_test.go file.

Structure

The current folder contains the top level API. It requires a registry for holding the available key providers and encryption methods, which is located in the registry folder. The key providers are located in the keyprovider folder, while the encryption methods are located in the method folder. You can also find the configuration struct and its related functions in the config folder.

Further reading

For a detailed design document on state encryption, please read this document.