MCPcopy Create free account
hub / github.com/cloudflare/cfssl / NewServerTLS

Function NewServerTLS

api/client/client.go:59–78  ·  view source on GitHub ↗

NewServerTLS is the TLS version of NewServer

(addr string, tlsConfig *tls.Config)

Source from the content-addressed store, hash-verified

57
58// NewServerTLS is the TLS version of NewServer
59func NewServerTLS(addr string, tlsConfig *tls.Config) Remote {
60 addrs := strings.Split(addr, ",")
61
62 var remote Remote
63
64 if len(addrs) > 1 {
65 remote, _ = NewGroup(addrs, tlsConfig, StrategyOrderedList)
66 } else {
67 u, err := normalizeURL(addrs[0])
68 if err != nil {
69 log.Errorf("bad url: %v", err)
70 return nil
71 }
72 srv := newServer(u, tlsConfig)
73 if srv != nil {
74 remote = srv
75 }
76 }
77 return remote
78}
79
80func (srv *server) Hosts() []string {
81 return []string{srv.URL}

Callers 9

NewCFSSLFunction · 0.92
setRemoteAndAuthMethod · 0.92
NewCFSSLProviderFunction · 0.92
remoteOpMethod · 0.92
getInfoFromRemoteFunction · 0.92
TestNewMutualTLSServerFunction · 0.85
NewTLSServerGroupFunction · 0.85
NewServerFunction · 0.85
NewAuthServerFunction · 0.85

Calls 4

ErrorfFunction · 0.92
NewGroupFunction · 0.85
normalizeURLFunction · 0.85
newServerFunction · 0.85

Tested by 2

TestNewMutualTLSServerFunction · 0.68
NewTLSServerGroupFunction · 0.68

Used in the wild real call sites across dependent graphs

searching dependent graphs…