Add warning about EA in FIPS mode (#15858)
* Add warning about EA in FIPS mode Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com> * Add changelog Signed-off-by: Alexander Scheel <alex.scheel@hashicorp.com>
This commit is contained in:
parent
770a91ab83
commit
dd6c339440
|
@ -0,0 +1,3 @@
|
||||||
|
```release-note:change
|
||||||
|
core/fips: Disable and warn about entropy augmentation in FIPS 140-2 Inside mode
|
||||||
|
```
|
|
@ -34,6 +34,7 @@ import (
|
||||||
config2 "github.com/hashicorp/vault/command/config"
|
config2 "github.com/hashicorp/vault/command/config"
|
||||||
"github.com/hashicorp/vault/command/server"
|
"github.com/hashicorp/vault/command/server"
|
||||||
"github.com/hashicorp/vault/helper/builtinplugins"
|
"github.com/hashicorp/vault/helper/builtinplugins"
|
||||||
|
"github.com/hashicorp/vault/helper/constants"
|
||||||
"github.com/hashicorp/vault/helper/metricsutil"
|
"github.com/hashicorp/vault/helper/metricsutil"
|
||||||
"github.com/hashicorp/vault/helper/namespace"
|
"github.com/hashicorp/vault/helper/namespace"
|
||||||
vaulthttp "github.com/hashicorp/vault/http"
|
vaulthttp "github.com/hashicorp/vault/http"
|
||||||
|
@ -424,6 +425,12 @@ func (c *ServerCommand) parseConfig() (*server.Config, []configutil.ConfigError,
|
||||||
config = config.Merge(current)
|
config = config.Merge(current)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if config.Entropy != nil && config.Entropy.Mode == configutil.EntropyAugmentation && constants.IsFIPS() {
|
||||||
|
c.UI.Warn("WARNING: Entropy Augmentation is not supported in FIPS 140-2 Inside mode; disabling from server configuration!\n")
|
||||||
|
config.Entropy = nil
|
||||||
|
}
|
||||||
|
|
||||||
return config, configErrors, nil
|
return config, configErrors, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue