mirror of
https://github.com/optim-enterprises-bv/vault.git
synced 2025-11-01 02:57:59 +00:00
Add stub enterprise logical system backend and init (#26712)
This is used so that Enterprise code can do additional initialization and store additional state in the logical `SystemBackend`.
This commit is contained in:
committed by
GitHub
parent
7a10a095a2
commit
e7ada1e35c
@@ -248,6 +248,7 @@ func NewSystemBackend(core *Core, logger log.Logger, config *logical.BackendConf
|
|||||||
b.Backend.Invalidate = sysInvalidate(b)
|
b.Backend.Invalidate = sysInvalidate(b)
|
||||||
b.Backend.InitializeFunc = sysInitialize(b)
|
b.Backend.InitializeFunc = sysInitialize(b)
|
||||||
b.Backend.Clean = sysClean(b)
|
b.Backend.Clean = sysClean(b)
|
||||||
|
b.entInit()
|
||||||
return b
|
return b
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -267,6 +268,7 @@ func (b *SystemBackend) rawPaths() []*framework.Path {
|
|||||||
// prefix. Conceptually it is similar to procfs on Linux.
|
// prefix. Conceptually it is similar to procfs on Linux.
|
||||||
type SystemBackend struct {
|
type SystemBackend struct {
|
||||||
*framework.Backend
|
*framework.Backend
|
||||||
|
entSystemBackend
|
||||||
Core *Core
|
Core *Core
|
||||||
db *memdb.MemDB
|
db *memdb.MemDB
|
||||||
logger log.Logger
|
logger log.Logger
|
||||||
|
|||||||
@@ -7,6 +7,10 @@ package vault
|
|||||||
|
|
||||||
//go:generate go run github.com/hashicorp/vault/tools/stubmaker
|
//go:generate go run github.com/hashicorp/vault/tools/stubmaker
|
||||||
|
|
||||||
|
type entSystemBackend struct{}
|
||||||
|
|
||||||
func entUnauthenticatedPaths() []string {
|
func entUnauthenticatedPaths() []string {
|
||||||
return []string{}
|
return []string{}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (s *SystemBackend) entInit() {}
|
||||||
|
|||||||
Reference in New Issue
Block a user