usercenter

package
v0.2.0-alpha.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 30, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	DefaultLRUSize = 1000
	// AccessTokenExpire is the expiration time for the access token.
	AccessTokenExpire = time.Hour * 2
	// RefreshTokenExpire is the expiration time for the refresh token.
	RefreshTokenExpire = time.Hour * 24
)
View Source
const (
	// User has submitted registration information, the account is in a pending.
	// The user needs to complete email/phone number verification steps to transition to an active state.
	// The OneX project does not currently use this.
	UserStatusRegistered = "registered"
	// The user has registered and been verified, and can use the system normally.
	// Most user operations are performed in this state.
	UserStatusActived = "actived"
	// The user has entered the incorrect password too many times, and the account has been locked by the system.
	// The user needs to recover the password or contact the administrator to unlock the account.
	UserStatusLocked = "locked"
	// The user has been added to the system blacklist due to serious misconduct.
	// Blacklisted users cannot register new accounts or use the system.
	UserStatusBlacklisted = "blacklisted"
	// The administrator has manually disabled the user account, and the user cannot log in after being disabled.
	// This may be due to user misconduct or other reasons.
	UserStatusDisabled = "disabled"
	// The user has actively deleted their own account, or the administrator has deleted the user account.
	// The deleted account can be chosen to be soft-deleted (with some data retained) or completely deleted.
	UserStatusDeleted = "deleted"
)

Define user status.

View Source
const (
	// UserStatusNeedActive informs onex-nightwatch that the user needs to be activated.
	UserStatusNeedActive = "need_active"
	// UserStatusNeedDisable informs onex-nightwatch that the user needs to be disabled.
	UserStatusNeedDisable = "need_disable"
)

Define need status. We can directly update the database to the "Need" state to inform onex-nightwatch of what needs to be done. These statuses are only used for operation and maintenance purposes.

View Source
const (
	SecretStatusDisabled = iota // Status used for disabling a secret.
	SecretStatusNormal          // Status used for enabling a secret.
)

Define secret status.

View Source
const MaxSecretCount = 10
View Source
const (
	TemporaryKeyName = "_onex.io/temporary_key"
)

Variables

This section is empty.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL