MCPcopy
hub / github.com/zitadel/oidc / AuthRequestByCode

Function AuthRequestByCode

pkg/op/token_code.go:125–134  ·  view source on GitHub ↗

AuthRequestByCode returns the AuthRequest previously created from Storage corresponding to the auth code or an error

(ctx context.Context, storage Storage, code string)

Source from the content-addressed store, hash-verified

123
124// AuthRequestByCode returns the AuthRequest previously created from Storage corresponding to the auth code or an error
125func AuthRequestByCode(ctx context.Context, storage Storage, code string) (AuthRequest, error) {
126 ctx, span := Tracer.Start(ctx, "AuthRequestByCode")
127 defer span.End()
128
129 authReq, err := storage.AuthRequestByCode(ctx, code)
130 if err != nil {
131 return nil, oidc.ErrInvalidGrant().WithDescription("invalid code").WithParent(err)
132 }
133 return authReq, nil
134}

Callers 2

AuthorizeCodeClientFunction · 0.85
CodeExchangeMethod · 0.85

Calls 5

StartMethod · 0.80
EndMethod · 0.80
WithParentMethod · 0.80
WithDescriptionMethod · 0.80
AuthRequestByCodeMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…