MCPcopy
hub / github.com/grpc/grpc-go / WithTransportCredentials

Function WithTransportCredentials

dialoptions.go:439–443  ·  view source on GitHub ↗

WithTransportCredentials returns a DialOption which configures a connection level security credentials (e.g., TLS/SSL). This should not be used together with WithCredentialsBundle.

(creds credentials.TransportCredentials)

Source from the content-addressed store, hash-verified

437// level security credentials (e.g., TLS/SSL). This should not be used together
438// with WithCredentialsBundle.
439func WithTransportCredentials(creds credentials.TransportCredentials) DialOption {
440 return newFuncDialOption(func(o *dialOptions) {
441 o.copts.TransportCredentials = creds
442 })
443}
444
445// WithPerRPCCredentials returns a DialOption which sets credentials and places
446// auth state on each outbound RPC.

Calls 1

newFuncDialOptionFunction · 0.85