func GenerateIV(rand io.Reader, blockCipher cipher.Block) (iv []byte, err error) {
	iv = make([]byte, blockCipher.BlockSize())
	if _, err = rand.Read(iv); err != nil {
		err = fmt.Errorf("Error reading from random while generating AES initialization vector: %s", err)
		return
	}
	return
}
// GenerateIV generates an initialization vector with the block size of the cipher
GenerateIV generates an initialization vector with the block size of the cipher
// GenerateIV generates an initialization vector with the block size of the cipher
func GenerateIV(rand io.Reader, blockCipher cipher.Block) (iv []byte, err error) {
	iv = make([]byte, blockCipher.BlockSize())
	if _, err = rand.Read(iv); err != nil {
		err = fmt.Errorf("Error reading from random while generating AES initialization vector: %s", err)
		return
	}
	return
}
func GenerateIV ( rand io . Reader , blockCipher cipher . Block ) ( iv [ ] byte , err error ) { iv = make ( [ ] byte , blockCipher . BlockSize ( ) ) if _ , err = rand . Read ( iv ) ; err != nil { err = fmt . Errorf ( " " , err ) return } return }
GenerateIV generates an initialization vector with the block size of the cipher
GenerateIV generates an initialization vector with the block size of the cipher