1
0
Fork 0

Merge current v2.11 into v3.0

This commit is contained in:
mmatur 2024-03-12 10:38:29 +01:00
commit 05be441027
No known key found for this signature in database
GPG key ID: 2FFE42FC256CFF8E
156 changed files with 5826 additions and 8436 deletions

View file

@ -9,6 +9,7 @@ import (
"net"
"net/http"
"reflect"
"slices"
"strings"
"sync"
"time"
@ -241,12 +242,9 @@ func (k *KerberosRoundTripper) RoundTrip(request *http.Request) (*http.Response,
}
func containsNTLMorNegotiate(h []string) bool {
for _, s := range h {
if strings.HasPrefix(s, "NTLM") || strings.HasPrefix(s, "Negotiate") {
return true
}
}
return false
return slices.ContainsFunc(h, func(s string) bool {
return strings.HasPrefix(s, "NTLM") || strings.HasPrefix(s, "Negotiate")
})
}
func createRootCACertPool(rootCAs []types.FileOrContent) *x509.CertPool {