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

Function ClientHandshakeInfoFromContext

credentials/credentials.go:280–283  ·  view source on GitHub ↗

ClientHandshakeInfoFromContext returns the ClientHandshakeInfo struct stored in ctx. This API is experimental.

(ctx context.Context)

Source from the content-addressed store, hash-verified

278//
279// This API is experimental.
280func ClientHandshakeInfoFromContext(ctx context.Context) ClientHandshakeInfo {
281 chi, _ := icredentials.ClientHandshakeInfoFromContext(ctx).(ClientHandshakeInfo)
282 return chi
283}
284
285// CheckSecurityLevel checks if a connection's security level is greater than or equal to the specified one.
286// It returns success if 1) the condition is satisfied or 2) AuthInfo struct does not implement GetCommonAuthInfo() method

Callers 4

clusterNameFunction · 0.92
ClientHandshakeMethod · 0.92
ClientHandshakeMethod · 0.92

Calls

no outgoing calls

Tested by 3

ClientHandshakeMethod · 0.74
ClientHandshakeMethod · 0.74