open-vault/sdk/logical
Alexander Scheel 6930568076
Add path based primary write forwarding (PBPWF) - OSS (#18735)
* Add WriteForwardedStorage to sdk's plugin, logical in OSS

This should allow backends to specify paths to forward write
(storage.Put(...) and storage.Delete(...)) operations for.

Notably, these semantics are subject to change and shouldn't yet be
relied on.

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Collect paths for write forwarding in OSS

This adds a path manager to Core, allowing tracking across all Vault
versions of paths which could use write forwarding if available. In
particular, even on OSS offerings, we'll need to template {{clusterId}}
into the paths, in the event of later upgrading to Enterprise. If we
didn't, we'd end up writing paths which will no longer be accessible
post-migration, due to write forwarding now replacing the sentinel with
the actual cluster identifier.

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Add forwarded writer implementation to OSS

Here, for paths given to us, we determine if we need to do cluster
translation and perform local writing. This is the OSS variant.

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Wire up mount-specific request forwarding in OSS

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Clarify that state lock needs to be held to call HAState in OSS

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Move cluster sentinel constant to sdk/logical

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Expose ClusterID to Plugins via SystemView

This will let plugins learn what the Cluster's ID is, without having to
resort to hacks like writing a random string to its cluster-prefixed
namespace and then reading it once it has replicated.

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

* Add GRPC ClusterID implementation

For any external plugins which wish to use it.

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>

Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
2023-01-20 16:36:18 -05:00
..
audit.go Allow plugins to submit audit requests/responses via extended SystemView (#6777) 2019-05-22 18:52:53 -04:00
auth.go oss changes (#15487) 2022-05-18 09:16:13 -07:00
connection.go Add remote_port in the audit logs when it is available (#12790) 2022-01-26 15:47:15 -08:00
controlgroup.go Create sdk/ and api/ submodules (#6583) 2019-04-12 17:54:35 -04:00
error.go Return errInvalidCredentials when wrong credentials is provided for existent users (#17104) 2022-09-27 16:49:14 -07:00
event.pb.go Use schema for events in event broker (#18693) 2023-01-20 10:18:23 -08:00
event.proto Use schema for events in event broker (#18693) 2023-01-20 10:18:23 -08:00
events.go Use schema for events in event broker (#18693) 2023-01-20 10:18:23 -08:00
identity.pb.go Link OSS (#18228) 2022-12-08 15:02:18 -05:00
identity.proto Login MFA (#14025) 2022-02-17 13:08:51 -08:00
lease.go Create sdk/ and api/ submodules (#6583) 2019-04-12 17:54:35 -04:00
lease_test.go Create sdk/ and api/ submodules (#6583) 2019-04-12 17:54:35 -04:00
logical.go Add path based primary write forwarding (PBPWF) - OSS (#18735) 2023-01-20 16:36:18 -05:00
logical_storage.go Create sdk/ and api/ submodules (#6583) 2019-04-12 17:54:35 -04:00
managed_key.go Add ManagedKeyRandomSource interface to SDK. (#18269) 2022-12-08 14:17:41 -06:00
plugin.pb.go Link OSS (#18228) 2022-12-08 15:02:18 -05:00
plugin.proto Adds Vault version prerelease and metadata to logical.PluginEnvironment (#14851) 2022-04-04 22:31:01 -07:00
request.go update gofumpt to 0.3.1 and reformat the repo (#17055) 2022-09-07 17:31:20 -07:00
response.go VAULT-8719 Support data array for alias clash error response so UI/machines can understand error (#17459) 2022-10-17 14:46:25 -04:00
response_util.go VAULT-8719 Support data array for alias clash error response so UI/machines can understand error (#17459) 2022-10-17 14:46:25 -04:00
response_util_test.go Return errInvalidCredentials when wrong credentials is provided for existent users (#17104) 2022-09-27 16:49:14 -07:00
secret.go Create sdk/ and api/ submodules (#6583) 2019-04-12 17:54:35 -04:00
storage.go Add path based primary write forwarding (PBPWF) - OSS (#18735) 2023-01-20 16:36:18 -05:00
storage_inmem.go Add user configurable password policies available to secret engines (#8637) 2020-05-27 12:28:00 -06:00
storage_inmem_test.go Create sdk/ and api/ submodules (#6583) 2019-04-12 17:54:35 -04:00
storage_test.go Run a more strict formatter over the code (#11312) 2021-04-08 09:43:39 -07:00
storage_view.go Run a more strict formatter over the code (#11312) 2021-04-08 09:43:39 -07:00
system_view.go Add path based primary write forwarding (PBPWF) - OSS (#18735) 2023-01-20 16:36:18 -05:00
testing.go Move version out of SDK. (#14229) 2022-12-07 13:29:51 -05:00
token.go SSCT Tokens Feature [OSS] (#14109) 2022-02-17 11:43:07 -08:00
token_test.go VAULT-1564 report in-flight requests (#13024) 2021-12-08 17:34:42 -05:00
translate_response.go Login MFA (#14025) 2022-02-17 13:08:51 -08:00
version.pb.go Link OSS (#18228) 2022-12-08 15:02:18 -05:00
version.proto Add plugin version to GRPC interface (#17088) 2022-09-15 16:37:59 -07:00
version_grpc.pb.go Add plugin version to GRPC interface (#17088) 2022-09-15 16:37:59 -07:00