From 71194a5266396df0ab8bd930b8aac73e4e2d4528 Mon Sep 17 00:00:00 2001 From: chahatsagarmain Date: Sun, 8 Dec 2024 01:18:21 +0530 Subject: [PATCH] missing test case Signed-off-by: chahatsagarmain --- .../app/handler/zipkin_receiver_tls_test.go | 22 +++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/cmd/collector/app/handler/zipkin_receiver_tls_test.go b/cmd/collector/app/handler/zipkin_receiver_tls_test.go index 3c8252f273d..108a1023150 100644 --- a/cmd/collector/app/handler/zipkin_receiver_tls_test.go +++ b/cmd/collector/app/handler/zipkin_receiver_tls_test.go @@ -143,6 +143,28 @@ func TestSpanCollectorZipkinTLS(t *testing.T) { expectZipkinClientErr: true, expectServerFail: false, }, + { + name: "should fail with TLS client with cert to trusted TLS server with incorrect TLS min", + serverTLS: configtls.ServerConfig{ + ClientCAFile: testCertKeyLocation + "/example-CA-cert.pem", + Config: configtls.Config{ + CertFile: testCertKeyLocation + "/example-server-cert.pem", + KeyFile: testCertKeyLocation + "/example-server-key.pem", + MinVersion: "1.5", + }, + }, + clientTLS: configtls.ClientConfig{ + Config: configtls.Config{ + CAFile: testCertKeyLocation + "/example-CA-cert.pem", + CertFile: testCertKeyLocation + "/example-client-cert.pem", + KeyFile: testCertKeyLocation + "/example-client-key.pem", + }, + ServerName: "example.com", + }, + expectTLSClientErr: true, + expectServerFail: true, + expectZipkinClientErr: false, + }, } for _, test := range testCases {