vault: Default key size to 256bit.
This commit is contained in:
parent
3ee434a783
commit
e6fd2f2ce5
|
@ -120,7 +120,8 @@ func (b *AESGCMBarrier) Initialize(key []byte) error {
|
|||
|
||||
// GenerateKey is used to generate a new key
|
||||
func (b *AESGCMBarrier) GenerateKey() ([]byte, error) {
|
||||
buf := make([]byte, aes.BlockSize)
|
||||
// Generate a 256bit key
|
||||
buf := make([]byte, 2*aes.BlockSize)
|
||||
_, err := rand.Read(buf)
|
||||
return buf, err
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue