Skip to content

Commit eb0bbdd

Browse files
committed
fix lint
1 parent fddda40 commit eb0bbdd

File tree

2 files changed

+1
-4
lines changed

2 files changed

+1
-4
lines changed

cns/service.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,6 @@ func getTLSConfig(tlsSettings localtls.TlsSettings, errChan chan<- error) (*tls.
158158

159159
// verifyPeerCertificate verifies the client certificate's subject name matches the expected subject name.
160160
func verifyPeerCertificate(rawCerts [][]byte, clientSubjectName string) error {
161-
162161
if len(rawCerts) == 0 {
163162
return errors.New("no client certificate provided")
164163
}

cns/service_test.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import (
1212
"crypto/x509"
1313
"crypto/x509/pkix"
1414
"encoding/pem"
15-
"fmt"
1615
"math/big"
1716
"net/http"
1817
"os"
@@ -176,7 +175,7 @@ func TestNewService(t *testing.T) {
176175
},
177176
}
178177

179-
tlsURL := fmt.Sprintf("https://localhost:%s", tlsSettings.TLSPort)
178+
tlsURL := "https://localhost:" + tlsSettings.TLSPort
180179
// TLS listener
181180
req, err := http.NewRequestWithContext(context.TODO(), http.MethodGet, tlsURL, http.NoBody)
182181
require.NoError(t, err)
@@ -206,7 +205,6 @@ func TestNewService(t *testing.T) {
206205

207206
// Cleanup
208207
svc.Uninitialize()
209-
210208
}
211209
runMutualTLSTest(TLSSetting, false)
212210
runMutualTLSTest(TLSSettingWithDisallowedClientSN, true)

0 commit comments

Comments
 (0)