Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,13 @@ linters:
- misspell
- modernize
- revive
# Correctness linters (low-noise, no findings on the current tree).
- copyloopvar
- durationcheck
- gocritic
- makezero
- unconvert
- wastedassign
exclusions:
generated: strict
presets:
Expand All @@ -23,6 +30,13 @@ linters:
exclude-functions:
# Used in HTTP handlers, any error is handled by the server itself.
- (net/http.ResponseWriter).Write
govet:
enable-all: true
disable:
# Struct field ordering is not worth the churn/readability cost.
- fieldalignment
# err shadowing is idiomatic and used throughout the codebase.
- shadow
revive:
rules:
# https://github.com/mgechev/revive/blob/master/RULES_DESCRIPTIONS.md#unused-parameter
Expand Down
2 changes: 1 addition & 1 deletion web/tls_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ func (t *TLSConfig) VerifyPeerCertificate(rawCerts [][]byte, _ [][]*x509.Certifi
}

// Build up a slice of strings with all Subject Alternate Name values
sanValues := append(cert.DNSNames, cert.EmailAddresses...)
sanValues := slices.Concat(cert.DNSNames, cert.EmailAddresses)

for _, ip := range cert.IPAddresses {
sanValues = append(sanValues, ip.String())
Expand Down