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

Function getSecurityLevel

test/insecure_creds_test.go:50–57  ·  view source on GitHub ↗
(ai credentials.AuthInfo)

Source from the content-addressed store, hash-verified

48}
49
50func getSecurityLevel(ai credentials.AuthInfo) credentials.SecurityLevel {
51 if c, ok := ai.(interface {
52 GetCommonAuthInfo() credentials.CommonAuthInfo
53 }); ok {
54 return c.GetCommonAuthInfo().SecurityLevel
55 }
56 return credentials.InvalidSecurityLevel
57}
58
59// TestInsecureCreds tests the use of insecure creds on the server and client
60// side, and verifies that expect security level and auth info are returned.

Callers 1

TestInsecureCredsMethod · 0.70

Calls 1

GetCommonAuthInfoMethod · 0.65

Tested by

no test coverage detected