From af64e10400f8533a0c48ecdf5ab9b7fbf329e14e Mon Sep 17 00:00:00 2001 From: Daniel J Walsh Date: Mon, 26 Mar 2018 18:26:55 -0400 Subject: Vendor in lots of kubernetes stuff to shrink image size Signed-off-by: Daniel J Walsh Closes: #554 Approved by: mheon --- .../golang.org/x/crypto/openpgp/packet/symmetric_key_encrypted.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'vendor/golang.org/x/crypto/openpgp/packet/symmetric_key_encrypted.go') diff --git a/vendor/golang.org/x/crypto/openpgp/packet/symmetric_key_encrypted.go b/vendor/golang.org/x/crypto/openpgp/packet/symmetric_key_encrypted.go index 4b1105b6f..744c2d2c4 100644 --- a/vendor/golang.org/x/crypto/openpgp/packet/symmetric_key_encrypted.go +++ b/vendor/golang.org/x/crypto/openpgp/packet/symmetric_key_encrypted.go @@ -88,10 +88,10 @@ func (ske *SymmetricKeyEncrypted) Decrypt(passphrase []byte) ([]byte, CipherFunc return nil, ske.CipherFunc, errors.UnsupportedError("unknown cipher: " + strconv.Itoa(int(cipherFunc))) } plaintextKey = plaintextKey[1:] - if l := len(plaintextKey); l == 0 || l%cipherFunc.blockSize() != 0 { - return nil, cipherFunc, errors.StructuralError("length of decrypted key not a multiple of block size") + if l, cipherKeySize := len(plaintextKey), cipherFunc.KeySize(); l != cipherFunc.KeySize() { + return nil, cipherFunc, errors.StructuralError("length of decrypted key (" + strconv.Itoa(l) + ") " + + "not equal to cipher keysize (" + strconv.Itoa(cipherKeySize) + ")") } - return plaintextKey, cipherFunc, nil } -- cgit v1.2.3-54-g00ecf