| Index: net/quic/core/quic_crypto_server_stream.cc
|
| diff --git a/net/quic/core/quic_crypto_server_stream.cc b/net/quic/core/quic_crypto_server_stream.cc
|
| index e08827bdd79972ebb50852cec5a298356dda865b..49894819aa420964a646eefe214d591859864c49 100644
|
| --- a/net/quic/core/quic_crypto_server_stream.cc
|
| +++ b/net/quic/core/quic_crypto_server_stream.cc
|
| @@ -6,7 +6,6 @@
|
|
|
| #include <memory>
|
|
|
| -#include "crypto/secure_hash.h"
|
| #include "net/quic/core/crypto/crypto_protocol.h"
|
| #include "net/quic/core/crypto/crypto_utils.h"
|
| #include "net/quic/core/crypto/quic_crypto_server_config.h"
|
| @@ -18,6 +17,7 @@
|
| #include "net/quic/core/quic_session.h"
|
| #include "net/quic/platform/api/quic_logging.h"
|
| #include "net/quic/platform/api/quic_text_utils.h"
|
| +#include "third_party/boringssl/src/include/openssl/sha.h"
|
|
|
| using base::StringPiece;
|
| using std::string;
|
| @@ -417,11 +417,9 @@ bool QuicCryptoServerStream::GetBase64SHA256ClientChannelID(
|
| }
|
|
|
| const string& channel_id(crypto_negotiated_params_->channel_id);
|
| - std::unique_ptr<crypto::SecureHash> hash(
|
| - crypto::SecureHash::Create(crypto::SecureHash::SHA256));
|
| - hash->Update(channel_id.data(), channel_id.size());
|
| - uint8_t digest[32];
|
| - hash->Finish(digest, sizeof(digest));
|
| + uint8_t digest[SHA256_DIGEST_LENGTH];
|
| + SHA256(reinterpret_cast<const uint8_t*>(channel_id.data()), channel_id.size(),
|
| + digest);
|
|
|
| QuicTextUtils::Base64Encode(digest, arraysize(digest), output);
|
| return true;
|
|
|