MCPcopy Create free account
hub / github.com/golang/appengine / SignBytes

Function SignBytes

identity.go:128–136  ·  view source on GitHub ↗

SignBytes signs bytes using a private key unique to your application.

(c context.Context, bytes []byte)

Source from the content-addressed store, hash-verified

126
127// SignBytes signs bytes using a private key unique to your application.
128func SignBytes(c context.Context, bytes []byte) (keyName string, signature []byte, err error) {
129 req := &pb.SignForAppRequest{BytesToSign: bytes}
130 res := &pb.SignForAppResponse{}
131
132 if err := internal.Call(c, "app_identity_service", "SignForApp", req, res); err != nil {
133 return "", nil, err
134 }
135 return res.GetKeyName(), res.GetSignatureBytes(), nil
136}
137
138func init() {
139 internal.RegisterErrorCodeMap("app_identity_service", pb.AppIdentityServiceError_ErrorCode_name)

Callers

nothing calls this directly

Calls 3

GetKeyNameMethod · 0.95
GetSignatureBytesMethod · 0.95
CallFunction · 0.92

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…