Documentation ¶
Index ¶
- func InitConfig(adminUsername string, adminPassword string) error
- func UnwrapAccounts(waccs []WrappedAccount) []apitypes.Account
- func UnwrapSecrets(secrets []WrappedSecret, st *AppState) []apitypes.ExposedSecret
- type AppState
- func (s *AppState) ApplyAccountCreated(e *domain.AccountCreated) error
- func (s *AppState) ApplyAccountDeleted(e *domain.AccountDeleted) error
- func (s *AppState) ApplyAccountDescriptionChanged(e *domain.AccountDescriptionChanged) error
- func (s *AppState) ApplyAccountExternalTokenAdded(e *domain.AccountExternalTokenAdded) error
- func (s *AppState) ApplyAccountFolderCreated(e *domain.AccountFolderCreated) error
- func (s *AppState) ApplyAccountFolderDeleted(e *domain.AccountFolderDeleted) error
- func (s *AppState) ApplyAccountFolderMoved(e *domain.AccountFolderMoved) error
- func (s *AppState) ApplyAccountFolderRenamed(e *domain.AccountFolderRenamed) error
- func (s *AppState) ApplyAccountKeylistAdded(e *domain.AccountKeylistAdded) error
- func (s *AppState) ApplyAccountMoved(e *domain.AccountMoved) error
- func (s *AppState) ApplyAccountOtpTokenAdded(e *domain.AccountOtpTokenAdded) error
- func (s *AppState) ApplyAccountPasswordAdded(e *domain.AccountPasswordAdded) error
- func (s *AppState) ApplyAccountRenamed(e *domain.AccountRenamed) error
- func (s *AppState) ApplyAccountSecretDeleted(e *domain.AccountSecretDeleted) error
- func (s *AppState) ApplyAccountSecretNoteAdded(e *domain.AccountSecretNoteAdded) error
- func (s *AppState) ApplyAccountSecretUsed(e *domain.AccountSecretUsed) error
- func (s *AppState) ApplyAccountSshKeyAdded(e *domain.AccountSshKeyAdded) error
- func (s *AppState) ApplyAccountUrlChanged(e *domain.AccountUrlChanged) error
- func (s *AppState) ApplyAccountUsernameChanged(e *domain.AccountUsernameChanged) error
- func (s *AppState) ApplyDatabaseMasterPasswordChanged(e *domain.DatabaseMasterPasswordChanged) error
- func (s *AppState) ApplyDatabaseS3IntegrationConfigured(e *domain.DatabaseS3IntegrationConfigured) error
- func (s *AppState) ApplyDatabaseUnsealed(e *domain.DatabaseUnsealed) error
- func (s *AppState) ApplySessionSignedIn(e *domain.SessionSignedIn) error
- func (s *AppState) ApplyUserAccessTokenAdded(e *domain.UserAccessTokenAdded) error
- func (s *AppState) ApplyUserCreated(e *domain.UserCreated) error
- func (s *AppState) ApplyUserPasswordUpdated(e *domain.UserPasswordUpdated) error
- func (s *AppState) ApplyUserU2FTokenRegistered(e *domain.UserU2FTokenRegistered) error
- func (s *AppState) ApplyUserU2FTokenUsed(e *domain.UserU2FTokenUsed) error
- func (s *AppState) Close()
- func (s *AppState) GetJwtSigningKey() []byte
- func (s *AppState) GetJwtValidationKey() []byte
- func (s *AppState) GetMacSigningKey() string
- func (s *AppState) GetMasterPassword() string
- func (s *AppState) HandleUnknownEvent(e event.Event) error
- func (s *AppState) IsUnsealed() bool
- func (s *AppState) NextFreeUserId() string
- func (s *AppState) SetMasterPassword(password string)
- func (s *AppState) SetSealed(sealed bool)
- type Config
- type SensitiveUser
- type Statefile
- type U2FToken
- type UserStorage
- func (s *UserStorage) FolderById(id string) *apitypes.Folder
- func (s *UserStorage) SubfoldersByParentId(id string) []apitypes.Folder
- func (s *UserStorage) WrappedAccountById(id string) *WrappedAccount
- func (s *UserStorage) WrappedAccountsByFolder(id string) []WrappedAccount
- func (s *UserStorage) WrappedSecretById(accountId string, secretId string) *WrappedSecret
- type WrappedAccount
- type WrappedSecret
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitConfig ¶
func UnwrapAccounts ¶
func UnwrapAccounts(waccs []WrappedAccount) []apitypes.Account
func UnwrapSecrets ¶
func UnwrapSecrets(secrets []WrappedSecret, st *AppState) []apitypes.ExposedSecret
Types ¶
type AppState ¶
type AppState struct { DB *Statefile EventLog eventlog.Log S3ExportBucket string S3ExportApiKey string S3ExportSecret string // contains filtered or unexported fields }
func NewTesting ¶
func NewTesting() *AppState
func (*AppState) ApplyAccountCreated ¶
func (s *AppState) ApplyAccountCreated(e *domain.AccountCreated) error
func (*AppState) ApplyAccountDeleted ¶
func (s *AppState) ApplyAccountDeleted(e *domain.AccountDeleted) error
func (*AppState) ApplyAccountDescriptionChanged ¶
func (s *AppState) ApplyAccountDescriptionChanged(e *domain.AccountDescriptionChanged) error
func (*AppState) ApplyAccountExternalTokenAdded ¶
func (s *AppState) ApplyAccountExternalTokenAdded(e *domain.AccountExternalTokenAdded) error
func (*AppState) ApplyAccountFolderCreated ¶
func (s *AppState) ApplyAccountFolderCreated(e *domain.AccountFolderCreated) error
func (*AppState) ApplyAccountFolderDeleted ¶
func (s *AppState) ApplyAccountFolderDeleted(e *domain.AccountFolderDeleted) error
func (*AppState) ApplyAccountFolderMoved ¶
func (s *AppState) ApplyAccountFolderMoved(e *domain.AccountFolderMoved) error
func (*AppState) ApplyAccountFolderRenamed ¶
func (s *AppState) ApplyAccountFolderRenamed(e *domain.AccountFolderRenamed) error
func (*AppState) ApplyAccountKeylistAdded ¶
func (s *AppState) ApplyAccountKeylistAdded(e *domain.AccountKeylistAdded) error
func (*AppState) ApplyAccountMoved ¶
func (s *AppState) ApplyAccountMoved(e *domain.AccountMoved) error
func (*AppState) ApplyAccountOtpTokenAdded ¶
func (s *AppState) ApplyAccountOtpTokenAdded(e *domain.AccountOtpTokenAdded) error
func (*AppState) ApplyAccountPasswordAdded ¶
func (s *AppState) ApplyAccountPasswordAdded(e *domain.AccountPasswordAdded) error
func (*AppState) ApplyAccountRenamed ¶
func (s *AppState) ApplyAccountRenamed(e *domain.AccountRenamed) error
func (*AppState) ApplyAccountSecretDeleted ¶
func (s *AppState) ApplyAccountSecretDeleted(e *domain.AccountSecretDeleted) error
func (*AppState) ApplyAccountSecretNoteAdded ¶
func (s *AppState) ApplyAccountSecretNoteAdded(e *domain.AccountSecretNoteAdded) error
func (*AppState) ApplyAccountSecretUsed ¶
func (s *AppState) ApplyAccountSecretUsed(e *domain.AccountSecretUsed) error
func (*AppState) ApplyAccountSshKeyAdded ¶
func (s *AppState) ApplyAccountSshKeyAdded(e *domain.AccountSshKeyAdded) error
func (*AppState) ApplyAccountUrlChanged ¶
func (s *AppState) ApplyAccountUrlChanged(e *domain.AccountUrlChanged) error
func (*AppState) ApplyAccountUsernameChanged ¶
func (s *AppState) ApplyAccountUsernameChanged(e *domain.AccountUsernameChanged) error
func (*AppState) ApplyDatabaseMasterPasswordChanged ¶
func (s *AppState) ApplyDatabaseMasterPasswordChanged(e *domain.DatabaseMasterPasswordChanged) error
func (*AppState) ApplyDatabaseS3IntegrationConfigured ¶
func (s *AppState) ApplyDatabaseS3IntegrationConfigured(e *domain.DatabaseS3IntegrationConfigured) error
func (*AppState) ApplyDatabaseUnsealed ¶
func (s *AppState) ApplyDatabaseUnsealed(e *domain.DatabaseUnsealed) error
func (*AppState) ApplySessionSignedIn ¶
func (s *AppState) ApplySessionSignedIn(e *domain.SessionSignedIn) error
func (*AppState) ApplyUserAccessTokenAdded ¶
func (s *AppState) ApplyUserAccessTokenAdded(e *domain.UserAccessTokenAdded) error
func (*AppState) ApplyUserCreated ¶
func (s *AppState) ApplyUserCreated(e *domain.UserCreated) error
func (*AppState) ApplyUserPasswordUpdated ¶
func (s *AppState) ApplyUserPasswordUpdated(e *domain.UserPasswordUpdated) error
func (*AppState) ApplyUserU2FTokenRegistered ¶
func (s *AppState) ApplyUserU2FTokenRegistered(e *domain.UserU2FTokenRegistered) error
func (*AppState) ApplyUserU2FTokenUsed ¶
func (s *AppState) ApplyUserU2FTokenUsed(e *domain.UserU2FTokenUsed) error
func (*AppState) GetJwtSigningKey ¶
func (*AppState) GetJwtValidationKey ¶
func (*AppState) GetMacSigningKey ¶
func (*AppState) GetMasterPassword ¶
for Keepass export
func (*AppState) IsUnsealed ¶
func (*AppState) NextFreeUserId ¶
func (*AppState) SetMasterPassword ¶
type SensitiveUser ¶
type Statefile ¶
type Statefile struct { UserScope map[string]*UserStorage // keyed by id AuditLog []apitypes.AuditlogEntry }
func NewStatefile ¶
func NewStatefile() *Statefile
type UserStorage ¶
type UserStorage struct { SensitiveUser SensitiveUser WrappedAccounts []WrappedAccount Folders []apitypes.Folder U2FTokens []*U2FToken }
func NewUserStorage ¶
func NewUserStorage(sensitiveUser SensitiveUser) *UserStorage
func (*UserStorage) FolderById ¶
func (s *UserStorage) FolderById(id string) *apitypes.Folder
func (*UserStorage) SubfoldersByParentId ¶
func (s *UserStorage) SubfoldersByParentId(id string) []apitypes.Folder
func (*UserStorage) WrappedAccountById ¶
func (s *UserStorage) WrappedAccountById(id string) *WrappedAccount
func (*UserStorage) WrappedAccountsByFolder ¶
func (s *UserStorage) WrappedAccountsByFolder(id string) []WrappedAccount
func (*UserStorage) WrappedSecretById ¶
func (s *UserStorage) WrappedSecretById(accountId string, secretId string) *WrappedSecret
type WrappedAccount ¶
type WrappedAccount struct { Account apitypes.Account Secrets []WrappedSecret }
FIXME: this has the same name as with apitypes.WrappedAccount
type WrappedSecret ¶
Click to show internal directories.
Click to hide internal directories.