Documentation ¶
Index ¶
- Variables
- type Private
- func (*Private) Descriptor() ([]byte, []int)deprecated
- func (x *Private) GetAccessToken() string
- func (x *Private) GetIdToken() string
- func (x *Private) GetRefreshToken() string
- func (*Private) ProtoMessage()
- func (x *Private) ProtoReflect() protoreflect.Message
- func (x *Private) Reset()
- func (x *Private) String() string
- type Session
- func (*Session) Descriptor() ([]byte, []int)deprecated
- func (x *Session) GetAdditionalScopes() []string
- func (x *Session) GetClosed() *timestamppb.Timestamp
- func (x *Session) GetCreated() *timestamppb.Timestamp
- func (x *Session) GetEmail() string
- func (x *Session) GetEncryptedPrivate() []byte
- func (x *Session) GetGeneration() int32
- func (x *Session) GetLastRefresh() *timestamppb.Timestamp
- func (x *Session) GetName() string
- func (x *Session) GetNextRefresh() *timestamppb.Timestamp
- func (x *Session) GetPicture() string
- func (x *Session) GetState() State
- func (x *Session) GetSub() string
- func (*Session) ProtoMessage()
- func (x *Session) ProtoReflect() protoreflect.Message
- func (x *Session) Reset()
- func (x *Session) String() string
- type State
Constants ¶
This section is empty.
Variables ¶
View Source
var ( State_name = map[int32]string{ 0: "STATE_UNDEFINED", 1: "STATE_OPEN", 2: "STATE_CLOSED", 3: "STATE_REVOKED", } State_value = map[string]int32{ "STATE_UNDEFINED": 0, "STATE_OPEN": 1, "STATE_CLOSED": 2, "STATE_REVOKED": 3, } )
Enum value maps for State.
Functions ¶
This section is empty.
Types ¶
type Private ¶
type Private struct { RefreshToken string `protobuf:"bytes,1,opt,name=refresh_token,json=refreshToken,proto3" json:"refresh_token,omitempty"` AccessToken string `protobuf:"bytes,2,opt,name=access_token,json=accessToken,proto3" json:"access_token,omitempty"` IdToken string `protobuf:"bytes,3,opt,name=id_token,json=idToken,proto3" json:"id_token,omitempty"` // contains filtered or unexported fields }
Private contains data that is stored in the encrypted form in the session.
The encryption key is part of the session cookie and not stored in the backend storage.
func (*Private) Descriptor
deprecated
func (*Private) GetAccessToken ¶
func (*Private) GetIdToken ¶
func (*Private) GetRefreshToken ¶
func (*Private) ProtoMessage ¶
func (*Private) ProtoMessage()
func (*Private) ProtoReflect ¶
func (x *Private) ProtoReflect() protoreflect.Message
type Session ¶
type Session struct { State State `protobuf:"varint,1,opt,name=state,proto3,enum=luci.server.encryptedcookies.session.State" json:"state,omitempty"` // identifies where the session is in its lifecycle Generation int32 `protobuf:"varint,2,opt,name=generation,proto3" json:"generation,omitempty"` // incremented during each mutation Created *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=created,proto3" json:"created,omitempty"` // when the session was created LastRefresh *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=last_refresh,json=lastRefresh,proto3" json:"last_refresh,omitempty"` // last time it was refreshed NextRefresh *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=next_refresh,json=nextRefresh,proto3" json:"next_refresh,omitempty"` // next refresh time Closed *timestamppb.Timestamp `protobuf:"bytes,6,opt,name=closed,proto3" json:"closed,omitempty"` // when it was closed/revoked Sub string `protobuf:"bytes,7,opt,name=sub,proto3" json:"sub,omitempty"` // user ID from "sub" ID token claim Email string `protobuf:"bytes,8,opt,name=email,proto3" json:"email,omitempty"` // user email from "email" ID token claim Name string `protobuf:"bytes,9,opt,name=name,proto3" json:"name,omitempty"` // user name from "name" ID token claim Picture string `protobuf:"bytes,10,opt,name=picture,proto3" json:"picture,omitempty"` // profile picture URL from "picture" ID token claim // the scopes that were requested in the authorization request, in addition // to the default scopes (openid email profile). AdditionalScopes []string `protobuf:"bytes,12,rep,name=additional_scopes,json=additionalScopes,proto3" json:"additional_scopes,omitempty"` EncryptedPrivate []byte `protobuf:"bytes,11,opt,name=encrypted_private,json=encryptedPrivate,proto3" json:"encrypted_private,omitempty"` // wire-serialized and encrypted Private proto // contains filtered or unexported fields }
Session is what is actually stored in the session storage.
func (*Session) Descriptor
deprecated
func (*Session) GetAdditionalScopes ¶
func (*Session) GetClosed ¶
func (x *Session) GetClosed() *timestamppb.Timestamp
func (*Session) GetCreated ¶
func (x *Session) GetCreated() *timestamppb.Timestamp
func (*Session) GetEncryptedPrivate ¶
func (*Session) GetGeneration ¶
func (*Session) GetLastRefresh ¶
func (x *Session) GetLastRefresh() *timestamppb.Timestamp
func (*Session) GetNextRefresh ¶
func (x *Session) GetNextRefresh() *timestamppb.Timestamp
func (*Session) GetPicture ¶
func (*Session) ProtoMessage ¶
func (*Session) ProtoMessage()
func (*Session) ProtoReflect ¶
func (x *Session) ProtoReflect() protoreflect.Message
type State ¶
type State int32
func (State) Descriptor ¶
func (State) Descriptor() protoreflect.EnumDescriptor
func (State) EnumDescriptor
deprecated
func (State) Number ¶
func (x State) Number() protoreflect.EnumNumber
func (State) Type ¶
func (State) Type() protoreflect.EnumType
Click to show internal directories.
Click to hide internal directories.