mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 18:47:32 +00:00
38 lines
675 B
Go
38 lines
675 B
Go
![]() |
package federatedlogout
|
||
|
|
||
|
type Index int
|
||
|
|
||
|
const (
|
||
|
IndexUnspecified Index = iota
|
||
|
IndexRequestID
|
||
|
)
|
||
|
|
||
|
type FederatedLogout struct {
|
||
|
InstanceID string
|
||
|
FingerPrintID string
|
||
|
SessionID string
|
||
|
IDPID string
|
||
|
UserID string
|
||
|
PostLogoutRedirectURI string
|
||
|
State State
|
||
|
}
|
||
|
|
||
|
// Keys implements cache.Entry
|
||
|
func (c *FederatedLogout) Keys(i Index) []string {
|
||
|
if i == IndexRequestID {
|
||
|
return []string{Key(c.InstanceID, c.SessionID)}
|
||
|
}
|
||
|
return nil
|
||
|
}
|
||
|
|
||
|
func Key(instanceID, sessionID string) string {
|
||
|
return instanceID + "-" + sessionID
|
||
|
}
|
||
|
|
||
|
type State int
|
||
|
|
||
|
const (
|
||
|
StateCreated State = iota
|
||
|
StateRedirected
|
||
|
)
|