Compare commits

...

2 Commits

Author SHA1 Message Date
Bernd Schoolmann
ce6cb0503c
Merge pull request #127 from SuperSandro2000/patch-1
Cleanup duplicated import
2024-03-02 03:07:05 +01:00
Sandro
8839b33f8c
Cleanup duplicated import 2024-03-02 02:29:49 +01:00

View File

@ -6,7 +6,6 @@ import (
"crypto/cipher"
"crypto/hmac"
"crypto/rand"
cryptorand "crypto/rand"
"crypto/rsa"
"crypto/sha1"
"crypto/sha256"
@ -196,7 +195,7 @@ func EncryptWith(data []byte, encType EncStringType, key SymmetricEncryptionKey)
return s, err
}
s.IV = make([]byte, aes.BlockSize)
if _, err := io.ReadFull(cryptorand.Reader, s.IV); err != nil {
if _, err := io.ReadFull(rand.Reader, s.IV); err != nil {
return s, err
}
s.CT = make([]byte, len(data))