authorize: move impersonation into session/service account (#1765)

* move impersonation into session/service account

* replace frontend statik

* fix data race

* move JWT filling to separate function, break up functions

* maybe fix data race

* fix code climate issue
This commit is contained in:
Caleb Doxsey 2021-01-11 15:40:08 -07:00 committed by GitHub
parent 1466f4e5a0
commit a6bc9f492f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 328 additions and 162 deletions

View file

@ -8,6 +8,7 @@ import (
"github.com/golang/protobuf/ptypes"
"google.golang.org/protobuf/types/known/anypb"
"google.golang.org/protobuf/types/known/structpb"
"google.golang.org/protobuf/types/known/timestamppb"
"github.com/pomerium/pomerium/internal/identity"
"github.com/pomerium/pomerium/pkg/grpc/databroker"
@ -71,3 +72,8 @@ func (x *Session) SetRawIDToken(rawIDToken string) {
}
x.IdToken.Raw = rawIDToken
}
// GetIssuedAt returns the issued at timestamp for the id token.
func (x *Session) GetIssuedAt() *timestamppb.Timestamp {
return x.GetIdToken().GetIssuedAt()
}