From 0d7a417f332a57fb3e89250a1ce250b929d0b2f7 Mon Sep 17 00:00:00 2001 From: Luca Casonato Date: Thu, 30 Sep 2021 09:26:15 +0200 Subject: feat(tls): custom in memory CA certificates (#12219) This adds support for using in memory CA certificates for `Deno.startTLS`, `Deno.connectTLS` and `Deno.createHttpClient`. `certFile` is deprecated in `startTls` and `connectTls`, and removed from `Deno.createHttpClient`. --- cli/tests/unit/http_test.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cli/tests/unit/http_test.ts') diff --git a/cli/tests/unit/http_test.ts b/cli/tests/unit/http_test.ts index 7cca8d89e..fe6f1aba2 100644 --- a/cli/tests/unit/http_test.ts +++ b/cli/tests/unit/http_test.ts @@ -233,8 +233,8 @@ unitTest( listener.close(); })(); - const caData = Deno.readTextFileSync("cli/tests/testdata/tls/RootCA.pem"); - const client = Deno.createHttpClient({ caData }); + const caCert = Deno.readTextFileSync("cli/tests/testdata/tls/RootCA.pem"); + const client = Deno.createHttpClient({ caCerts: [caCert] }); const resp = await fetch(`https://${hostname}:${port}/`, { client, headers: { "connection": "close" }, -- cgit v1.2.3