Skip to content

Commit

Permalink
Fix Userinfo (#63)
Browse files Browse the repository at this point in the history
This is purely a token introspection type now, we are no longer piggy
backing RBAC on it, instead prefering the ACL interface.  A vast part of
this is moving RBAC and authorization into identity to save pain and
suffering.  A little bit of coupling still exists in order to get access
to the request subject for auditing.
  • Loading branch information
spjmurray authored Jul 4, 2024
1 parent 924989b commit 87356b1
Show file tree
Hide file tree
Showing 12 changed files with 4 additions and 534 deletions.
4 changes: 2 additions & 2 deletions charts/core/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ description: A Helm chart for deploying Unikorn Core

type: application

version: v0.1.56
appVersion: v0.1.56
version: v0.1.57
appVersion: v0.1.57

icon: https://assets.unikorn-cloud.org/images/logos/dark-on-light/icon.svg

Expand Down
33 changes: 0 additions & 33 deletions pkg/authorization/constants/roles.go

This file was deleted.

72 changes: 0 additions & 72 deletions pkg/authorization/rbac/authorizer.go

This file was deleted.

53 changes: 0 additions & 53 deletions pkg/authorization/rbac/helpers.go

This file was deleted.

34 changes: 0 additions & 34 deletions pkg/authorization/rbac/interfaces.go

This file was deleted.

74 changes: 0 additions & 74 deletions pkg/authorization/rbac/types.go

This file was deleted.

27 changes: 0 additions & 27 deletions pkg/authorization/userinfo/rbac.go

This file was deleted.

7 changes: 1 addition & 6 deletions pkg/authorization/userinfo/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,6 @@ package userinfo

import (
"github.com/go-jose/go-jose/v3/jwt"

"github.com/unikorn-cloud/core/pkg/authorization/rbac"
)

type UserInfo struct {
jwt.Claims `json:",inline"`
RBAC *rbac.Permissions `json:"rbac,omitempty"`
}
type UserInfo jwt.Claims
File renamed without changes.
2 changes: 1 addition & 1 deletion pkg/server/middleware/cors/cors.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ import (

"github.com/spf13/pflag"

"github.com/unikorn-cloud/core/pkg/openapi"
"github.com/unikorn-cloud/core/pkg/server/errors"
"github.com/unikorn-cloud/core/pkg/server/middleware/openapi"
"github.com/unikorn-cloud/core/pkg/util"
)

Expand Down
30 changes: 0 additions & 30 deletions pkg/server/middleware/openapi/interfaces.go

This file was deleted.

Loading

0 comments on commit 87356b1

Please sign in to comment.