Remove extern c wrapping for openssl headers (#28360)

pull/28372/head
Denny C. Dai 3 years ago committed by GitHub
parent 46b1e755d2
commit c485b94ed7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 10
      src/core/lib/security/credentials/jwt/json_token.cc
  2. 10
      src/core/lib/security/credentials/jwt/jwt_verifier.cc
  3. 6
      src/core/tsi/ssl/session_cache/ssl_session.h
  4. 8
      src/core/tsi/ssl/session_cache/ssl_session_cache.h
  5. 20
      src/core/tsi/ssl_transport_security.cc
  6. 6
      src/core/tsi/ssl_transport_security.h
  7. 5
      test/core/end2end/h2_ssl_cert_test.cc
  8. 10
      test/core/tsi/ssl_transport_security_test.cc

@ -22,6 +22,10 @@
#include <string.h>
#include <openssl/bio.h>
#include <openssl/evp.h>
#include <openssl/pem.h>
#include <grpc/grpc_security.h>
#include <grpc/support/alloc.h>
#include <grpc/support/log.h>
@ -33,12 +37,6 @@
#include "src/core/lib/security/util/json_util.h"
#include "src/core/lib/slice/b64.h"
extern "C" {
#include <openssl/bio.h>
#include <openssl/evp.h>
#include <openssl/pem.h>
}
using grpc_core::Json;
/* --- Constants. --- */

@ -23,17 +23,15 @@
#include <limits.h>
#include <string.h>
#include <openssl/bn.h>
#include <openssl/pem.h>
#include <openssl/rsa.h>
#include <grpc/support/alloc.h>
#include <grpc/support/log.h>
#include <grpc/support/string_util.h>
#include <grpc/support/sync.h>
extern "C" {
#include <openssl/bn.h>
#include <openssl/pem.h>
#include <openssl/rsa.h>
}
#include "src/core/lib/gpr/string.h"
#include "src/core/lib/gprpp/manual_constructor.h"
#include "src/core/lib/http/httpcli.h"

@ -21,11 +21,9 @@
#include <grpc/support/port_platform.h>
#include <grpc/slice.h>
extern "C" {
#include <openssl/ssl.h>
}
#include <grpc/slice.h>
#include "src/core/lib/gprpp/ref_counted.h"

@ -21,14 +21,12 @@
#include <grpc/support/port_platform.h>
#include <grpc/slice.h>
#include <grpc/support/sync.h>
#include <map>
extern "C" {
#include <openssl/ssl.h>
}
#include <map>
#include <grpc/slice.h>
#include <grpc/support/sync.h>
#include "src/core/lib/gprpp/memory.h"
#include "src/core/lib/gprpp/ref_counted.h"

@ -35,6 +35,15 @@
#include <string>
#include <openssl/bio.h>
#include <openssl/crypto.h> /* For OPENSSL_free */
#include <openssl/engine.h>
#include <openssl/err.h>
#include <openssl/ssl.h>
#include <openssl/tls1.h>
#include <openssl/x509.h>
#include <openssl/x509v3.h>
#include "absl/strings/match.h"
#include "absl/strings/string_view.h"
@ -45,17 +54,6 @@
#include <grpc/support/sync.h>
#include <grpc/support/thd_id.h>
extern "C" {
#include <openssl/bio.h>
#include <openssl/crypto.h> /* For OPENSSL_free */
#include <openssl/engine.h>
#include <openssl/err.h>
#include <openssl/ssl.h>
#include <openssl/tls1.h>
#include <openssl/x509.h>
#include <openssl/x509v3.h>
}
#include "src/core/lib/gpr/useful.h"
#include "src/core/tsi/ssl/session_cache/ssl_session_cache.h"
#include "src/core/tsi/ssl_types.h"

@ -21,16 +21,14 @@
#include <grpc/support/port_platform.h>
#include <openssl/x509.h>
#include "absl/strings/string_view.h"
#include <grpc/grpc_security_constants.h>
#include "src/core/tsi/transport_security_interface.h"
extern "C" {
#include <openssl/x509.h>
}
/* Value for the TSI_CERTIFICATE_TYPE_PEER_PROPERTY property for X509 certs. */
#define TSI_X509_CERTIFICATE_TYPE "X509"

@ -20,6 +20,7 @@
#include <string.h>
#include <gtest/gtest.h>
#include <openssl/crypto.h>
#include <grpc/support/alloc.h>
#include <grpc/support/log.h>
@ -37,10 +38,6 @@
#include "test/core/util/port.h"
#include "test/core/util/test_config.h"
extern "C" {
#include <openssl/crypto.h>
}
static std::string test_server1_key_id;
namespace grpc {

@ -22,6 +22,10 @@
#include <stdio.h>
#include <string.h>
#include <openssl/crypto.h>
#include <openssl/err.h>
#include <openssl/pem.h>
#include <grpc/grpc.h>
#include <grpc/support/alloc.h>
#include <grpc/support/log.h>
@ -35,12 +39,6 @@
#include "test/core/tsi/transport_security_test_lib.h"
#include "test/core/util/test_config.h"
extern "C" {
#include <openssl/crypto.h>
#include <openssl/err.h>
#include <openssl/pem.h>
}
#define SSL_TSI_TEST_ALPN1 "foo"
#define SSL_TSI_TEST_ALPN2 "toto"
#define SSL_TSI_TEST_ALPN3 "baz"

Loading…
Cancel
Save