aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/core/bad_ssl
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2016-03-28 12:43:02 -0700
committerGravatar Craig Tiller <ctiller@google.com>2016-03-28 12:43:02 -0700
commit3bd96959398d0671fee3785d4b2aee6042649b15 (patch)
treeabc5288b8a4a95b3fb1d5a922bf3b1b75c5bddbc /test/core/bad_ssl
parentc65ed870ed45522194c0fcb884c9098672ac35ba (diff)
parente5cc05b5c6cee7026a0d28d39925621451506820 (diff)
Merge github.com:grpc/grpc into idempotent
Diffstat (limited to 'test/core/bad_ssl')
-rw-r--r--test/core/bad_ssl/bad_ssl_test.c12
-rw-r--r--test/core/bad_ssl/servers/alpn.c2
-rw-r--r--test/core/bad_ssl/servers/cert.c8
3 files changed, 14 insertions, 8 deletions
diff --git a/test/core/bad_ssl/bad_ssl_test.c b/test/core/bad_ssl/bad_ssl_test.c
index a78a0798ae..013b8eaf13 100644
--- a/test/core/bad_ssl/bad_ssl_test.c
+++ b/test/core/bad_ssl/bad_ssl_test.c
@@ -1,6 +1,6 @@
/*
*
- * Copyright 2015, Google Inc.
+ * Copyright 2015-2016, Google Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -31,8 +31,8 @@
*
*/
-#include <string.h>
#include <stdio.h>
+#include <string.h>
#include <grpc/grpc.h>
#include <grpc/grpc_security.h>
@@ -41,9 +41,10 @@
#include <grpc/support/log.h>
#include <grpc/support/string_util.h>
#include <grpc/support/subprocess.h>
-#include "src/core/support/string.h"
-#include "test/core/util/port.h"
+#include "src/core/lib/support/env.h"
+#include "src/core/lib/support/string.h"
#include "test/core/end2end/cq_verifier.h"
+#include "test/core/util/port.h"
#include "test/core/util/test_config.h"
static void *tag(intptr_t t) { return (void *)t; }
@@ -144,6 +145,9 @@ int main(int argc, char **argv) {
} else {
strcpy(root, ".");
}
+ if (argc == 2) {
+ gpr_setenv("GRPC_DEFAULT_SSL_ROOTS_FILE_PATH", argv[1]);
+ }
/* figure out our test name */
tmp = lunder - 1;
while (*tmp != '_') tmp--;
diff --git a/test/core/bad_ssl/servers/alpn.c b/test/core/bad_ssl/servers/alpn.c
index c8cc83b134..98dcd1c0ca 100644
--- a/test/core/bad_ssl/servers/alpn.c
+++ b/test/core/bad_ssl/servers/alpn.c
@@ -38,7 +38,7 @@
#include <grpc/support/log.h>
#include <grpc/support/useful.h>
-#include "src/core/transport/chttp2/alpn.h"
+#include "src/core/lib/transport/chttp2/alpn.h"
#include "test/core/bad_ssl/server_common.h"
#include "test/core/end2end/data/ssl_test_data.h"
diff --git a/test/core/bad_ssl/servers/cert.c b/test/core/bad_ssl/servers/cert.c
index 4edef50b67..7307682821 100644
--- a/test/core/bad_ssl/servers/cert.c
+++ b/test/core/bad_ssl/servers/cert.c
@@ -38,7 +38,7 @@
#include <grpc/support/log.h>
#include <grpc/support/useful.h>
-#include "src/core/support/load_file.h"
+#include "src/core/lib/support/load_file.h"
#include "test/core/bad_ssl/server_common.h"
#include "test/core/end2end/data/ssl_test_data.h"
@@ -56,9 +56,11 @@ int main(int argc, char **argv) {
grpc_init();
- cert_slice = gpr_load_file("src/core/tsi/test_creds/badserver.pem", 1, &ok);
+ cert_slice =
+ gpr_load_file("src/core/lib/tsi/test_creds/badserver.pem", 1, &ok);
GPR_ASSERT(ok);
- key_slice = gpr_load_file("src/core/tsi/test_creds/badserver.key", 1, &ok);
+ key_slice =
+ gpr_load_file("src/core/lib/tsi/test_creds/badserver.key", 1, &ok);
GPR_ASSERT(ok);
pem_key_cert_pair.private_key = (const char *)GPR_SLICE_START_PTR(key_slice);
pem_key_cert_pair.cert_chain = (const char *)GPR_SLICE_START_PTR(cert_slice);