Documentation
¶
Index ¶
- type AuthRepository
- func (ar AuthRepository) DeleteJwtToken(ownerID, token string) error
- func (ar AuthRepository) ExistsAndNotExpired(ownerID, token string, now time.Time) error
- func (ar AuthRepository) FindRevokeTokenBy(ctx context.Context, userID, token string) (*models.RevokeToken, error)
- func (ar AuthRepository) GetRevokeToken(ctx context.Context, ownerID string) string
- func (ar AuthRepository) StoreJwtToken(ownerID, token string, expr time.Time) error
- func (ar AuthRepository) StoreRevokeToken(ctx context.Context, ownerID, revokeToken string) error
- func (ar AuthRepository) Update(ctx context.Context, token *models.RevokeToken) (*models.RevokeToken, error)
- type TokenCache
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthRepository ¶
type AuthRepository struct {
// contains filtered or unexported fields
}
func NewRepository ¶
func NewRepository(bdb *badger.DB, db *sql.DB) AuthRepository
func (AuthRepository) DeleteJwtToken ¶
func (ar AuthRepository) DeleteJwtToken(ownerID, token string) error
func (AuthRepository) ExistsAndNotExpired ¶
func (ar AuthRepository) ExistsAndNotExpired(ownerID, token string, now time.Time) error
func (AuthRepository) FindRevokeTokenBy ¶
func (ar AuthRepository) FindRevokeTokenBy(ctx context.Context, userID, token string) (*models.RevokeToken, error)
func (AuthRepository) GetRevokeToken ¶
func (ar AuthRepository) GetRevokeToken(ctx context.Context, ownerID string) string
func (AuthRepository) StoreJwtToken ¶
func (ar AuthRepository) StoreJwtToken(ownerID, token string, expr time.Time) error
func (AuthRepository) StoreRevokeToken ¶
func (ar AuthRepository) StoreRevokeToken(ctx context.Context, ownerID, revokeToken string) error
func (AuthRepository) Update ¶
func (ar AuthRepository) Update(ctx context.Context, token *models.RevokeToken) (*models.RevokeToken, error)
type TokenCache ¶
Click to show internal directories.
Click to hide internal directories.