mirror of
https://github.com/gravitational/teleport.git
synced 2026-10-24 12:30:12 +08:00
- Privilege tokens are obtained after a logged in user successfully re-authenticates with their second factor. This token allows access to protected actions and will last 5 minutes. - There is one exception where a user can obtain `PrivilegeException` token without re-authenticating if a user doesn't have any second factors. Currently used to allow users to add their first MFA devices for auth type optional. - Added web handlers
32 lines
979 B
Go
32 lines
979 B
Go
/*
|
|
Copyright 2020 Gravitational, Inc.
|
|
|
|
Licensed under the Apache License, Version 2.0 (the "License");
|
|
you may not use this file except in compliance with the License.
|
|
You may obtain a copy of the License at
|
|
|
|
http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
Unless required by applicable law or agreed to in writing, software
|
|
distributed under the License is distributed on an "AS IS" BASIS,
|
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
See the License for the specific language governing permissions and
|
|
limitations under the License.
|
|
*/
|
|
|
|
package ui
|
|
|
|
import "time"
|
|
|
|
// ResetPasswordToken describes a reset password token UI object.
|
|
type ResetPasswordToken struct {
|
|
// TokenID is token ID
|
|
TokenID string `json:"tokenId"`
|
|
// User is user name associated with this token
|
|
User string `json:"user"`
|
|
// QRCode is a QR code value
|
|
QRCode []byte `json:"qrCode,omitempty"`
|
|
// Expiry is token expiration time
|
|
Expiry time.Time `json:"expiry,omitempty"`
|
|
}
|