Fix crypto config

This commit is contained in:
Daniel 2019-05-22 16:10:27 +02:00
parent 6cf262aae9
commit ab05357b51
3 changed files with 32 additions and 32 deletions

View file

@ -24,7 +24,7 @@ func init() {
DefaultValue: 256,
ValidationRegex: "^[0-9]{3,5}$",
})
minFeedEntropy = config.GetAsInt("random/min_feed_entropy", 256)
minFeedEntropy = config.Concurrent.GetAsInt("random/min_feed_entropy", 256)
}
// The Feeder is used to feed entropy to the RNG.

View file

@ -5,7 +5,7 @@ import (
)
var (
fullFeedDuration = 1 * time.Millisecond
fullFeedDuration = 100 * time.Millisecond
)
func getFullFeedDuration() time.Duration {

View file

@ -32,9 +32,9 @@ func init() {
ExpertiseLevel: config.ExpertiseLevelDeveloper,
OptType: config.OptTypeInt,
DefaultValue: 360, // ten minutes
ValidationRegex: "^[0-9]{2,5}$",
ValidationRegex: "^[1-9][0-9]{1,5}$",
})
reseedAfterSeconds = config.GetAsInt("random/reseed_after_seconds", 360)
reseedAfterSeconds = config.Concurrent.GetAsInt("random/reseed_after_seconds", 360)
config.Register(&config.Option{
Name: "Reseed after x bytes",
@ -43,7 +43,7 @@ func init() {
ExpertiseLevel: config.ExpertiseLevelDeveloper,
OptType: config.OptTypeInt,
DefaultValue: 1000000, // one megabyte
ValidationRegex: "^[0-9]{0,9}$",
ValidationRegex: "^[1-9][0-9]{2,9}$",
})
reseedAfterBytes = config.GetAsInt("random/reseed_after_bytes", 1000000)