mirror of
https://github.com/pomerium/pomerium.git
synced 2025-08-03 16:59:22 +02:00
databroker: add encryption for records (#1168)
This commit is contained in:
parent
8cae3f27bb
commit
29fb96a955
8 changed files with 332 additions and 7 deletions
|
@ -15,6 +15,7 @@ var (
|
|||
type serverConfig struct {
|
||||
deletePermanentlyAfter time.Duration
|
||||
btreeDegree int
|
||||
secret []byte
|
||||
storageType string
|
||||
storageConnectionString string
|
||||
}
|
||||
|
@ -49,6 +50,13 @@ func WithDeletePermanentlyAfter(dur time.Duration) ServerOption {
|
|||
}
|
||||
}
|
||||
|
||||
// WithSecret sets the secret in the config.
|
||||
func WithSecret(secret []byte) ServerOption {
|
||||
return func(cfg *serverConfig) {
|
||||
cfg.secret = secret
|
||||
}
|
||||
}
|
||||
|
||||
// WithStorageType sets the storage type.
|
||||
func WithStorageType(typ string) ServerOption {
|
||||
return func(cfg *serverConfig) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue