aboutsummaryrefslogtreecommitdiffhomepage
path: root/vendor/golang.org/x/crypto
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/golang.org/x/crypto')
-rw-r--r--vendor/golang.org/x/crypto/bcrypt/bcrypt.go4
-rw-r--r--vendor/golang.org/x/crypto/openpgp/keys.go3
2 files changed, 3 insertions, 4 deletions
diff --git a/vendor/golang.org/x/crypto/bcrypt/bcrypt.go b/vendor/golang.org/x/crypto/bcrypt/bcrypt.go
index 202fa8a..aeb73f8 100644
--- a/vendor/golang.org/x/crypto/bcrypt/bcrypt.go
+++ b/vendor/golang.org/x/crypto/bcrypt/bcrypt.go
@@ -241,11 +241,11 @@ func (p *hashed) Hash() []byte {
241 n = 3 241 n = 3
242 } 242 }
243 arr[n] = '$' 243 arr[n] = '$'
244 n += 1 244 n++
245 copy(arr[n:], []byte(fmt.Sprintf("%02d", p.cost))) 245 copy(arr[n:], []byte(fmt.Sprintf("%02d", p.cost)))
246 n += 2 246 n += 2
247 arr[n] = '$' 247 arr[n] = '$'
248 n += 1 248 n++
249 copy(arr[n:], p.salt) 249 copy(arr[n:], p.salt)
250 n += encodedSaltSize 250 n += encodedSaltSize
251 copy(arr[n:], p.hash) 251 copy(arr[n:], p.hash)
diff --git a/vendor/golang.org/x/crypto/openpgp/keys.go b/vendor/golang.org/x/crypto/openpgp/keys.go
index 68b14c6..744e293 100644
--- a/vendor/golang.org/x/crypto/openpgp/keys.go
+++ b/vendor/golang.org/x/crypto/openpgp/keys.go
@@ -325,9 +325,8 @@ func ReadEntity(packets *packet.Reader) (*Entity, error) {
325 if e.PrivateKey, ok = p.(*packet.PrivateKey); !ok { 325 if e.PrivateKey, ok = p.(*packet.PrivateKey); !ok {
326 packets.Unread(p) 326 packets.Unread(p)
327 return nil, errors.StructuralError("first packet was not a public/private key") 327 return nil, errors.StructuralError("first packet was not a public/private key")
328 } else {
329 e.PrimaryKey = &e.PrivateKey.PublicKey
330 } 328 }
329 e.PrimaryKey = &e.PrivateKey.PublicKey
331 } 330 }
332 331
333 if !e.PrimaryKey.PubKeyAlgo.CanSign() { 332 if !e.PrimaryKey.PubKeyAlgo.CanSign() {