UserAuthorizationOptional may return the roles and scope used for authorization. Depends on the ExtractAPIKey handler.
(ctx context.Context)
| 100 | // UserAuthorizationOptional may return the roles and scope used for |
| 101 | // authorization. Depends on the ExtractAPIKey handler. |
| 102 | func UserAuthorizationOptional(ctx context.Context) (rbac.Subject, bool) { |
| 103 | return dbauthz.ActorFromContext(ctx) |
| 104 | } |
| 105 | |
| 106 | // UserAuthorization returns the roles and scope used for authorization. Depends |
| 107 | // on the ExtractAPIKey handler. |