| Index: net/quic/crypto/p256_key_exchange_openssl.cc
|
| diff --git a/net/quic/crypto/p256_key_exchange_openssl.cc b/net/quic/crypto/p256_key_exchange_openssl.cc
|
| index f5ca0633ea4c88bf46464d1e9402a9a35f21391f..7a9707e308d1a09483d5cfae8c0f6e3e0bb27701 100644
|
| --- a/net/quic/crypto/p256_key_exchange_openssl.cc
|
| +++ b/net/quic/crypto/p256_key_exchange_openssl.cc
|
| @@ -15,7 +15,7 @@ using std::string;
|
|
|
| namespace net {
|
|
|
| -P256KeyExchange::P256KeyExchange(EC_KEY* private_key, const uint8* public_key)
|
| +P256KeyExchange::P256KeyExchange(EC_KEY* private_key, const uint8_t* public_key)
|
| : private_key_(private_key) {
|
| memcpy(public_key_, public_key, sizeof(public_key_));
|
| }
|
| @@ -29,7 +29,7 @@ P256KeyExchange* P256KeyExchange::New(StringPiece key) {
|
| return nullptr;
|
| }
|
|
|
| - const uint8* keyp = reinterpret_cast<const uint8*>(key.data());
|
| + const uint8_t* keyp = reinterpret_cast<const uint8_t*>(key.data());
|
| crypto::ScopedEC_KEY private_key(
|
| d2i_ECPrivateKey(nullptr, &keyp, key.size()));
|
| if (!private_key.get() || !EC_KEY_check_key(private_key.get())) {
|
| @@ -37,7 +37,7 @@ P256KeyExchange* P256KeyExchange::New(StringPiece key) {
|
| return nullptr;
|
| }
|
|
|
| - uint8 public_key[kUncompressedP256PointBytes];
|
| + uint8_t public_key[kUncompressedP256PointBytes];
|
| if (EC_POINT_point2oct(EC_KEY_get0_group(private_key.get()),
|
| EC_KEY_get0_public_key(private_key.get()),
|
| POINT_CONVERSION_UNCOMPRESSED, public_key,
|
| @@ -62,8 +62,8 @@ string P256KeyExchange::NewPrivateKey() {
|
| DVLOG(1) << "Can't convert private key to string";
|
| return string();
|
| }
|
| - scoped_ptr<uint8[]> private_key(new uint8[key_len]);
|
| - uint8* keyp = private_key.get();
|
| + scoped_ptr<uint8_t[]> private_key(new uint8_t[key_len]);
|
| + uint8_t* keyp = private_key.get();
|
| if (!i2d_ECPrivateKey(key.get(), &keyp)) {
|
| DVLOG(1) << "Can't convert private key to string.";
|
| return string();
|
| @@ -89,14 +89,14 @@ bool P256KeyExchange::CalculateSharedKey(const StringPiece& peer_public_value,
|
| if (!point ||
|
| !EC_POINT_oct2point(/* also test if point is on curve */
|
| EC_KEY_get0_group(private_key_.get()), point.get(),
|
| - reinterpret_cast<const uint8*>(
|
| + reinterpret_cast<const uint8_t*>(
|
| peer_public_value.data()),
|
| peer_public_value.size(), nullptr)) {
|
| DVLOG(1) << "Can't convert peer public value to curve point.";
|
| return false;
|
| }
|
|
|
| - uint8 result[kP256FieldBytes];
|
| + uint8_t result[kP256FieldBytes];
|
| if (ECDH_compute_key(result, sizeof(result), point.get(), private_key_.get(),
|
| nullptr) != sizeof(result)) {
|
| DVLOG(1) << "Can't compute ECDH shared key.";
|
|
|