Remove SSL_CIPHER_get_rfc_name
This was replaced with the upstream-compatible SSL_CIPHER_standard_name
in https://boringssl-review.googlesource.com/17324. It looks like we've
since migrated everything off the old name, so let's just remove it.
Update-Note: SSL_CIPHER_get_rfc_name calls can be replaced with
SSL_CIPHER_standard_name, which is also more efficient as it avoids an
allocation and copy. If anyone's using this function and can't easily
migrate, let us know and we can put this back for a little longer.
Change-Id: I6bce40a8a146671429641a5dbff6f614006a9a1c
Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/58665
Reviewed-by: Bob Beck <bbe@google.com>
Auto-Submit: David Benjamin <davidben@google.com>
Commit-Queue: Bob Beck <bbe@google.com>
diff --git a/include/openssl/ssl.h b/include/openssl/ssl.h
index a3b6a86..b4d669a 100644
--- a/include/openssl/ssl.h
+++ b/include/openssl/ssl.h
@@ -4528,13 +4528,6 @@
// SSL_CIPHER_get_version returns the string "TLSv1/SSLv3".
OPENSSL_EXPORT const char *SSL_CIPHER_get_version(const SSL_CIPHER *cipher);
-// SSL_CIPHER_get_rfc_name returns a newly-allocated string containing the
-// result of |SSL_CIPHER_standard_name| or NULL on error. The caller is
-// responsible for calling |OPENSSL_free| on the result.
-//
-// Use |SSL_CIPHER_standard_name| instead.
-OPENSSL_EXPORT char *SSL_CIPHER_get_rfc_name(const SSL_CIPHER *cipher);
-
typedef void COMP_METHOD;
typedef struct ssl_comp_st SSL_COMP;
diff --git a/ssl/ssl_cipher.cc b/ssl/ssl_cipher.cc
index 391944a..b08eb20 100644
--- a/ssl/ssl_cipher.cc
+++ b/ssl/ssl_cipher.cc
@@ -1531,14 +1531,6 @@
}
}
-char *SSL_CIPHER_get_rfc_name(const SSL_CIPHER *cipher) {
- if (cipher == NULL) {
- return NULL;
- }
-
- return OPENSSL_strdup(SSL_CIPHER_standard_name(cipher));
-}
-
int SSL_CIPHER_get_bits(const SSL_CIPHER *cipher, int *out_alg_bits) {
if (cipher == NULL) {
return 0;
diff --git a/ssl/ssl_test.cc b/ssl/ssl_test.cc
index f51c11e..a731e41 100644
--- a/ssl/ssl_test.cc
+++ b/ssl/ssl_test.cc
@@ -1037,10 +1037,6 @@
ASSERT_TRUE(cipher);
EXPECT_STREQ(t.standard_name, SSL_CIPHER_standard_name(cipher));
- bssl::UniquePtr<char> rfc_name(SSL_CIPHER_get_rfc_name(cipher));
- ASSERT_TRUE(rfc_name);
- EXPECT_STREQ(t.standard_name, rfc_name.get());
-
EXPECT_EQ(t.cipher_nid, SSL_CIPHER_get_cipher_nid(cipher));
EXPECT_EQ(t.digest_nid, SSL_CIPHER_get_digest_nid(cipher));
EXPECT_EQ(t.kx_nid, SSL_CIPHER_get_kx_nid(cipher));