diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2011-12-07 01:11:29 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2011-12-07 01:11:29 +0000 |
commit | 9c63abc9a1d127f95162756467284cf76b47aff8 (patch) | |
tree | 84f27a6ab44d932e4b0455f18390b070b4de626e /libgo/go/crypto | |
parent | 374280238f934fa851273e2ee16ba53be890c6b8 (diff) | |
download | gcc-9c63abc9a1d127f95162756467284cf76b47aff8.zip gcc-9c63abc9a1d127f95162756467284cf76b47aff8.tar.gz gcc-9c63abc9a1d127f95162756467284cf76b47aff8.tar.bz2 |
libgo: Update to weekly 2011-11-09.
From-SVN: r182073
Diffstat (limited to 'libgo/go/crypto')
31 files changed, 38 insertions, 38 deletions
diff --git a/libgo/go/crypto/dsa/dsa.go b/libgo/go/crypto/dsa/dsa.go index 692d62a..a2adc7e 100644 --- a/libgo/go/crypto/dsa/dsa.go +++ b/libgo/go/crypto/dsa/dsa.go @@ -6,9 +6,9 @@ package dsa import ( - "big" "errors" "io" + "math/big" ) // Parameters represents the domain parameters for a key. These parameters can diff --git a/libgo/go/crypto/dsa/dsa_test.go b/libgo/go/crypto/dsa/dsa_test.go index deec08d..177aa44 100644 --- a/libgo/go/crypto/dsa/dsa_test.go +++ b/libgo/go/crypto/dsa/dsa_test.go @@ -5,8 +5,8 @@ package dsa import ( - "big" "crypto/rand" + "math/big" "testing" ) diff --git a/libgo/go/crypto/ecdsa/ecdsa.go b/libgo/go/crypto/ecdsa/ecdsa.go index b7f235b..2f19999 100644 --- a/libgo/go/crypto/ecdsa/ecdsa.go +++ b/libgo/go/crypto/ecdsa/ecdsa.go @@ -13,9 +13,9 @@ package ecdsa // http://www.secg.org/download/aid-780/sec1-v2.pdf import ( - "big" "crypto/elliptic" "io" + "math/big" ) // PublicKey represents an ECDSA public key. diff --git a/libgo/go/crypto/ecdsa/ecdsa_test.go b/libgo/go/crypto/ecdsa/ecdsa_test.go index d6b4039..22360b5 100644 --- a/libgo/go/crypto/ecdsa/ecdsa_test.go +++ b/libgo/go/crypto/ecdsa/ecdsa_test.go @@ -5,11 +5,11 @@ package ecdsa import ( - "big" "crypto/elliptic" - "crypto/sha1" "crypto/rand" + "crypto/sha1" "encoding/hex" + "math/big" "testing" ) diff --git a/libgo/go/crypto/elliptic/elliptic.go b/libgo/go/crypto/elliptic/elliptic.go index 3c3327f..b7232a2 100644 --- a/libgo/go/crypto/elliptic/elliptic.go +++ b/libgo/go/crypto/elliptic/elliptic.go @@ -14,8 +14,8 @@ package elliptic // reverse the transform than to operate in affine coordinates. import ( - "big" "io" + "math/big" "sync" ) diff --git a/libgo/go/crypto/elliptic/elliptic_test.go b/libgo/go/crypto/elliptic/elliptic_test.go index 9578364..a68a380 100644 --- a/libgo/go/crypto/elliptic/elliptic_test.go +++ b/libgo/go/crypto/elliptic/elliptic_test.go @@ -5,9 +5,9 @@ package elliptic import ( - "big" "crypto/rand" "fmt" + "math/big" "testing" ) diff --git a/libgo/go/crypto/hmac/hmac_test.go b/libgo/go/crypto/hmac/hmac_test.go index bcae63b..03431c9 100644 --- a/libgo/go/crypto/hmac/hmac_test.go +++ b/libgo/go/crypto/hmac/hmac_test.go @@ -5,8 +5,8 @@ package hmac import ( - "hash" "fmt" + "hash" "testing" ) diff --git a/libgo/go/crypto/ocsp/ocsp.go b/libgo/go/crypto/ocsp/ocsp.go index f697fa1..a04b5bd 100644 --- a/libgo/go/crypto/ocsp/ocsp.go +++ b/libgo/go/crypto/ocsp/ocsp.go @@ -8,12 +8,12 @@ package ocsp import ( - "asn1" "crypto" "crypto/rsa" _ "crypto/sha1" "crypto/x509" "crypto/x509/pkix" + "encoding/asn1" "time" ) diff --git a/libgo/go/crypto/openpgp/armor/armor.go b/libgo/go/crypto/openpgp/armor/armor.go index 707bdf3..3bbb5dc 100644 --- a/libgo/go/crypto/openpgp/armor/armor.go +++ b/libgo/go/crypto/openpgp/armor/armor.go @@ -151,7 +151,7 @@ func (r *openpgpReader) Read(p []byte) (n int, err error) { } // Decode reads a PGP armored block from the given Reader. It will ignore -// leading garbage. If it doesn't find a block, it will return nil, os.EOF. The +// leading garbage. If it doesn't find a block, it will return nil, io.EOF. The // given Reader is not usable after calling this function: an arbitrary amount // of data may have been read past the end of the block. func Decode(in io.Reader) (p *Block, err error) { diff --git a/libgo/go/crypto/openpgp/elgamal/elgamal.go b/libgo/go/crypto/openpgp/elgamal/elgamal.go index 2ed49f6..a553bde 100644 --- a/libgo/go/crypto/openpgp/elgamal/elgamal.go +++ b/libgo/go/crypto/openpgp/elgamal/elgamal.go @@ -13,11 +13,11 @@ package elgamal import ( - "big" "crypto/rand" "crypto/subtle" "errors" "io" + "math/big" ) // PublicKey represents an ElGamal public key. diff --git a/libgo/go/crypto/openpgp/elgamal/elgamal_test.go b/libgo/go/crypto/openpgp/elgamal/elgamal_test.go index 101121a..c4f99f5 100644 --- a/libgo/go/crypto/openpgp/elgamal/elgamal_test.go +++ b/libgo/go/crypto/openpgp/elgamal/elgamal_test.go @@ -5,9 +5,9 @@ package elgamal import ( - "big" "bytes" "crypto/rand" + "math/big" "testing" ) diff --git a/libgo/go/crypto/openpgp/packet/encrypted_key.go b/libgo/go/crypto/openpgp/packet/encrypted_key.go index d05103f..b24fa3a 100644 --- a/libgo/go/crypto/openpgp/packet/encrypted_key.go +++ b/libgo/go/crypto/openpgp/packet/encrypted_key.go @@ -5,13 +5,13 @@ package packet import ( - "big" "crypto/openpgp/elgamal" error_ "crypto/openpgp/error" "crypto/rand" "crypto/rsa" "encoding/binary" "io" + "math/big" "strconv" ) diff --git a/libgo/go/crypto/openpgp/packet/encrypted_key_test.go b/libgo/go/crypto/openpgp/packet/encrypted_key_test.go index b402245..2b8eff7 100644 --- a/libgo/go/crypto/openpgp/packet/encrypted_key_test.go +++ b/libgo/go/crypto/openpgp/packet/encrypted_key_test.go @@ -5,11 +5,11 @@ package packet import ( - "big" "bytes" "crypto/rand" "crypto/rsa" "fmt" + "math/big" "testing" ) diff --git a/libgo/go/crypto/openpgp/packet/packet.go b/libgo/go/crypto/openpgp/packet/packet.go index f7ed353..778df15 100644 --- a/libgo/go/crypto/openpgp/packet/packet.go +++ b/libgo/go/crypto/openpgp/packet/packet.go @@ -7,12 +7,12 @@ package packet import ( - "big" "crypto/aes" "crypto/cast5" "crypto/cipher" error_ "crypto/openpgp/error" "io" + "math/big" ) // readFull is the same as io.ReadFull except that reading zero bytes returns diff --git a/libgo/go/crypto/openpgp/packet/private_key.go b/libgo/go/crypto/openpgp/packet/private_key.go index 742ac51..c0ff82b4 100644 --- a/libgo/go/crypto/openpgp/packet/private_key.go +++ b/libgo/go/crypto/openpgp/packet/private_key.go @@ -5,7 +5,6 @@ package packet import ( - "big" "bytes" "crypto/cipher" "crypto/dsa" @@ -16,6 +15,7 @@ import ( "crypto/sha1" "io" "io/ioutil" + "math/big" "strconv" ) diff --git a/libgo/go/crypto/openpgp/packet/public_key.go b/libgo/go/crypto/openpgp/packet/public_key.go index af0bc22..7d71dc4 100644 --- a/libgo/go/crypto/openpgp/packet/public_key.go +++ b/libgo/go/crypto/openpgp/packet/public_key.go @@ -5,7 +5,6 @@ package packet import ( - "big" "crypto/dsa" "crypto/openpgp/elgamal" error_ "crypto/openpgp/error" @@ -15,6 +14,7 @@ import ( "fmt" "hash" "io" + "math/big" "strconv" ) diff --git a/libgo/go/crypto/openpgp/s2k/s2k_test.go b/libgo/go/crypto/openpgp/s2k/s2k_test.go index ec4012c..3a094a1 100644 --- a/libgo/go/crypto/openpgp/s2k/s2k_test.go +++ b/libgo/go/crypto/openpgp/s2k/s2k_test.go @@ -6,8 +6,8 @@ package s2k import ( "bytes" - "crypto/sha1" "crypto/rand" + "crypto/sha1" "encoding/hex" "testing" ) diff --git a/libgo/go/crypto/rand/util.go b/libgo/go/crypto/rand/util.go index 322da4a..b44ae98 100644 --- a/libgo/go/crypto/rand/util.go +++ b/libgo/go/crypto/rand/util.go @@ -5,8 +5,8 @@ package rand import ( - "big" "io" + "math/big" "os" ) diff --git a/libgo/go/crypto/rsa/pkcs1v15.go b/libgo/go/crypto/rsa/pkcs1v15.go index 901539d..d7b053f 100644 --- a/libgo/go/crypto/rsa/pkcs1v15.go +++ b/libgo/go/crypto/rsa/pkcs1v15.go @@ -5,11 +5,11 @@ package rsa import ( - "big" "crypto" "crypto/subtle" "errors" "io" + "math/big" ) // This file implements encryption and decryption using PKCS#1 v1.5 padding. diff --git a/libgo/go/crypto/rsa/pkcs1v15_test.go b/libgo/go/crypto/rsa/pkcs1v15_test.go index d69bacf..66188ac 100644 --- a/libgo/go/crypto/rsa/pkcs1v15_test.go +++ b/libgo/go/crypto/rsa/pkcs1v15_test.go @@ -5,7 +5,6 @@ package rsa import ( - "big" "bytes" "crypto" "crypto/rand" @@ -13,6 +12,7 @@ import ( "encoding/base64" "encoding/hex" "io" + "math/big" "testing" "testing/quick" ) diff --git a/libgo/go/crypto/rsa/rsa.go b/libgo/go/crypto/rsa/rsa.go index c9344ff..27ccf61 100644 --- a/libgo/go/crypto/rsa/rsa.go +++ b/libgo/go/crypto/rsa/rsa.go @@ -8,12 +8,12 @@ package rsa // TODO(agl): Add support for PSS padding. import ( - "big" "crypto/rand" "crypto/subtle" "errors" "hash" "io" + "math/big" ) var bigZero = big.NewInt(0) diff --git a/libgo/go/crypto/rsa/rsa_test.go b/libgo/go/crypto/rsa/rsa_test.go index c36bca1..0fb9875 100644 --- a/libgo/go/crypto/rsa/rsa_test.go +++ b/libgo/go/crypto/rsa/rsa_test.go @@ -5,10 +5,10 @@ package rsa import ( - "big" "bytes" "crypto/rand" "crypto/sha1" + "math/big" "testing" ) diff --git a/libgo/go/crypto/tls/conn.go b/libgo/go/crypto/tls/conn.go index 6312c34..f4178e3 100644 --- a/libgo/go/crypto/tls/conn.go +++ b/libgo/go/crypto/tls/conn.go @@ -471,7 +471,7 @@ Again: // RFC suggests that EOF without an alertCloseNotify is // an error, but popular web sites seem to do this, // so we can't make it an error. - // if err == os.EOF { + // if err == io.EOF { // err = io.ErrUnexpectedEOF // } if e, ok := err.(net.Error); !ok || !e.Temporary() { diff --git a/libgo/go/crypto/tls/generate_cert.go b/libgo/go/crypto/tls/generate_cert.go index 41206e2..c4463ff 100644 --- a/libgo/go/crypto/tls/generate_cert.go +++ b/libgo/go/crypto/tls/generate_cert.go @@ -8,14 +8,14 @@ package main import ( - "big" - "crypto/x509/pkix" "crypto/rand" "crypto/rsa" "crypto/x509" + "crypto/x509/pkix" "encoding/pem" "flag" "log" + "math/big" "os" "time" ) diff --git a/libgo/go/crypto/tls/handshake_messages_test.go b/libgo/go/crypto/tls/handshake_messages_test.go index dc68a12..87e8f7e 100644 --- a/libgo/go/crypto/tls/handshake_messages_test.go +++ b/libgo/go/crypto/tls/handshake_messages_test.go @@ -5,7 +5,7 @@ package tls import ( - "rand" + "math/rand" "reflect" "testing" "testing/quick" diff --git a/libgo/go/crypto/tls/handshake_server_test.go b/libgo/go/crypto/tls/handshake_server_test.go index f2b0a14..bc37979 100644 --- a/libgo/go/crypto/tls/handshake_server_test.go +++ b/libgo/go/crypto/tls/handshake_server_test.go @@ -5,12 +5,12 @@ package tls import ( - "big" "bytes" "crypto/rsa" "encoding/hex" "flag" "io" + "math/big" "net" "strconv" "strings" diff --git a/libgo/go/crypto/tls/key_agreement.go b/libgo/go/crypto/tls/key_agreement.go index ba34606..08fb852 100644 --- a/libgo/go/crypto/tls/key_agreement.go +++ b/libgo/go/crypto/tls/key_agreement.go @@ -5,7 +5,6 @@ package tls import ( - "big" "crypto" "crypto/elliptic" "crypto/md5" @@ -14,6 +13,7 @@ import ( "crypto/x509" "errors" "io" + "math/big" ) // rsaKeyAgreement implements the standard TLS key agreement where the client diff --git a/libgo/go/crypto/x509/pkcs1.go b/libgo/go/crypto/x509/pkcs1.go index 0d3ade3..31d0dd0 100644 --- a/libgo/go/crypto/x509/pkcs1.go +++ b/libgo/go/crypto/x509/pkcs1.go @@ -5,10 +5,10 @@ package x509 import ( - "asn1" - "big" - "errors" "crypto/rsa" + "encoding/asn1" + "errors" + "math/big" ) // pkcs1PrivateKey is a structure which mirrors the PKCS#1 ASN.1 for an RSA private key. diff --git a/libgo/go/crypto/x509/pkix/pkix.go b/libgo/go/crypto/x509/pkix/pkix.go index 332a394..b35274c 100644 --- a/libgo/go/crypto/x509/pkix/pkix.go +++ b/libgo/go/crypto/x509/pkix/pkix.go @@ -7,8 +7,8 @@ package pkix import ( - "asn1" - "big" + "encoding/asn1" + "math/big" "time" ) diff --git a/libgo/go/crypto/x509/x509.go b/libgo/go/crypto/x509/x509.go index da8b283..9ff7db9 100644 --- a/libgo/go/crypto/x509/x509.go +++ b/libgo/go/crypto/x509/x509.go @@ -6,17 +6,17 @@ package x509 import ( - "asn1" - "big" "bytes" "crypto" "crypto/dsa" "crypto/rsa" "crypto/sha1" "crypto/x509/pkix" + "encoding/asn1" "encoding/pem" "errors" "io" + "math/big" "time" ) diff --git a/libgo/go/crypto/x509/x509_test.go b/libgo/go/crypto/x509/x509_test.go index d113f85..c424715 100644 --- a/libgo/go/crypto/x509/x509_test.go +++ b/libgo/go/crypto/x509/x509_test.go @@ -5,16 +5,16 @@ package x509 import ( - "asn1" - "big" "bytes" "crypto/dsa" "crypto/rand" "crypto/rsa" "crypto/x509/pkix" + "encoding/asn1" "encoding/base64" "encoding/hex" "encoding/pem" + "math/big" "testing" "time" ) |