Documentation
¶
Index ¶
Constants ¶
View Source
const ( HKDF_INFO_SIGNING = "services.mozilla.com/tokenlib/v1/signing" HKDF_INFO_DERIVE = "services.mozilla.com/tokenlib/v1/derive/" )
Variables ¶
View Source
var TokenPayloadDecodingErr = errors.New("TokenPayloadDecodingErr")
View Source
var TokenSignatureMismatchErr = errors.New("TokenSignatureMismatchErr")
Functions ¶
This section is empty.
Types ¶
type Token ¶
type Token struct {
Payload TokenPayload
Token string
DerivedSecret string
}
type TokenPayload ¶
type TokenPayload struct {
Salt string `json:"salt"`
Uid uint64 `json:"uid"`
Node string `json:"node"`
Expires float64 `json:"expires"`
// fields added in https://github.com/mozilla-services/tokenserver/pull/93
FxaUID string `json:"fxa_uid"`
DeviceId string `json:"device_id"`
}
func (*TokenPayload) UidString ¶
func (t *TokenPayload) UidString() string
Click to show internal directories.
Click to hide internal directories.