Delete dead function TlsConnection::SetEncryptionSecretCallback

Delete dead code, no behavior change

PiperOrigin-RevId: 314787863
Change-Id: I069c4872fe869889fce5b597233d7a7f40e80951
diff --git a/quic/core/crypto/tls_connection.cc b/quic/core/crypto/tls_connection.cc
index 75d28c5..8e4d391 100644
--- a/quic/core/crypto/tls_connection.cc
+++ b/quic/core/crypto/tls_connection.cc
@@ -114,28 +114,6 @@
     TlsConnection::SendAlertCallback};
 
 // static
-int TlsConnection::SetEncryptionSecretCallback(
-    SSL* ssl,
-    enum ssl_encryption_level_t level,
-    const uint8_t* read_key,
-    const uint8_t* write_key,
-    size_t key_length) {
-  // TODO(nharper): replace these vectors and memcpys with spans (which
-  // unfortunately doesn't yet exist in quic/platform/api).
-  std::vector<uint8_t> read_secret(key_length), write_secret(key_length);
-  memcpy(read_secret.data(), read_key, key_length);
-  memcpy(write_secret.data(), write_key, key_length);
-  TlsConnection::Delegate* delegate = ConnectionFromSsl(ssl)->delegate_;
-  const SSL_CIPHER* cipher = SSL_get_pending_cipher(ssl);
-  delegate->SetWriteSecret(QuicEncryptionLevel(level), cipher, write_secret);
-  if (!delegate->SetReadSecret(QuicEncryptionLevel(level), cipher,
-                               read_secret)) {
-    return 0;
-  }
-  return 1;
-}
-
-// static
 int TlsConnection::SetReadSecretCallback(SSL* ssl,
                                          enum ssl_encryption_level_t level,
                                          const SSL_CIPHER* cipher,
diff --git a/quic/core/crypto/tls_connection.h b/quic/core/crypto/tls_connection.h
index d65f63c..15a4f4f 100644
--- a/quic/core/crypto/tls_connection.h
+++ b/quic/core/crypto/tls_connection.h
@@ -101,11 +101,6 @@
   static const SSL_QUIC_METHOD kSslQuicMethod;
 
   // The following static functions make up the members of kSslQuicMethod:
-  static int SetEncryptionSecretCallback(SSL* ssl,
-                                         enum ssl_encryption_level_t level,
-                                         const uint8_t* read_key,
-                                         const uint8_t* write_key,
-                                         size_t key_length);
   static int SetReadSecretCallback(SSL* ssl,
                                    enum ssl_encryption_level_t level,
                                    const SSL_CIPHER* cipher,