Documentation
¶
Index ¶
- type Repository
- func (s *Repository) AuthenticateBearer(ctx context.Context, secret string) (accounts.Principal, error)
- func (s *Repository) AuthenticateSession(ctx context.Context, secret string) (accounts.Principal, error)
- func (s *Repository) Cleanup(ctx context.Context) error
- func (s *Repository) CreateSession(ctx context.Context, token string) (string, time.Time, error)
- func (s *Repository) CreateToken(ctx context.Context, userID string, scopes []string, expires *time.Time) (accounts.Token, error)
- func (s *Repository) CreateUser(ctx context.Context, name string) (accounts.User, error)
- func (s *Repository) DisableUser(ctx context.Context, userID string) error
- func (s *Repository) EnsureDefault(ctx context.Context) error
- func (s *Repository) Logout(ctx context.Context, secret string) error
- func (s *Repository) ReprocessUser(ctx context.Context, userID string) (int64, error)
- func (s *Repository) Resume(ctx context.Context) error
- func (s *Repository) RevokeToken(ctx context.Context, id string) error
- type Storage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
func (*Repository) AuthenticateBearer ¶
func (*Repository) AuthenticateSession ¶
func (*Repository) Cleanup ¶
func (s *Repository) Cleanup(ctx context.Context) error
Cleanup removes expired credentials in bounded transactions. Revoked token IDs remain available to operators; evidence and datasets are never touched.
func (*Repository) CreateSession ¶
func (*Repository) CreateToken ¶
func (*Repository) CreateUser ¶
func (*Repository) DisableUser ¶
func (s *Repository) DisableUser(ctx context.Context, userID string) error
func (*Repository) EnsureDefault ¶
func (s *Repository) EnsureDefault(ctx context.Context) error
func (*Repository) ReprocessUser ¶
ReprocessUser resolves the operator's user ID to its server-owned dataset.
func (*Repository) Resume ¶
func (s *Repository) Resume(ctx context.Context) error
Resume completes only pending provisioning; disabled ready users stay disabled.
func (*Repository) RevokeToken ¶
func (s *Repository) RevokeToken(ctx context.Context, id string) error
Click to show internal directories.
Click to hide internal directories.