Documentation
¶
Index ¶
- type Datastore
- func (d *Datastore) AddHostToPack(hid, pid uint) error
- func (d *Datastore) AddLabelToPack(lid, pid uint, opts ...kolide.OptionalArg) error
- func (d *Datastore) AppConfig() (*kolide.AppConfig, error)
- func (d *Datastore) AuthenticateHost(nodeKey string) (*kolide.Host, error)
- func (d *Datastore) Begin() (kolide.Transaction, error)
- func (d *Datastore) CleanupDistributedQueryCampaigns(now time.Time) (expired uint, err error)
- func (ds *Datastore) ConfirmPendingEmailChange(uid uint, token string) (string, error)
- func (d *Datastore) CountHostsInTargets(hostIDs, labelIDs []uint, now time.Time) (kolide.TargetMetrics, error)
- func (d *Datastore) DeleteHost(hid uint) error
- func (d *Datastore) DeleteInvite(id uint) error
- func (d *Datastore) DeletePasswordResetRequest(req *kolide.PasswordResetRequest) error
- func (d *Datastore) DeletePasswordResetRequestsForUser(userID uint) error
- func (d *Datastore) DeleteQueries(ids []uint) (uint, error)
- func (d *Datastore) DestroyAllSessionsForUser(id uint) error
- func (d *Datastore) DestroySession(session *kolide.Session) error
- func (d *Datastore) DistributedQueryCampaign(id uint) (*kolide.DistributedQueryCampaign, error)
- func (d *Datastore) DistributedQueryCampaignTargetIDs(id uint) (hostIDs []uint, labelIDs []uint, err error)
- func (d *Datastore) Drop() error
- func (d *Datastore) EnrollHost(osQueryHostID, nodeKey, secretName string) (*kolide.Host, error)
- func (d *Datastore) FindPassswordResetByID(id uint) (*kolide.PasswordResetRequest, error)
- func (d *Datastore) FindPassswordResetByToken(token string) (*kolide.PasswordResetRequest, error)
- func (d *Datastore) FindPassswordResetByTokenAndUserID(token string, userID uint) (*kolide.PasswordResetRequest, error)
- func (d *Datastore) FindPassswordResetsByUserID(userID uint) ([]*kolide.PasswordResetRequest, error)
- func (d *Datastore) GenerateHostStatusStatistics(now time.Time) (online, offline, mia, new uint, err error)
- func (d *Datastore) Host(id uint) (*kolide.Host, error)
- func (d *Datastore) Initialize() error
- func (d *Datastore) Invite(id uint) (*kolide.Invite, error)
- func (d *Datastore) InviteByEmail(email string) (*kolide.Invite, error)
- func (d *Datastore) InviteByToken(token string) (*kolide.Invite, error)
- func (d *Datastore) Label(lid uint) (*kolide.Label, error)
- func (d *Datastore) LabelQueriesForHost(host *kolide.Host, cutoff time.Time) (map[string]string, error)
- func (d *Datastore) ListExplicitHostsInPack(pid uint, opt kolide.ListOptions) ([]uint, error)
- func (d *Datastore) ListHosts(opt kolide.HostListOptions) ([]*kolide.Host, error)
- func (d *Datastore) ListHostsInLabel(lid uint, opt kolide.ListOptions) ([]kolide.Host, error)
- func (d *Datastore) ListHostsInPack(pid uint, opt kolide.ListOptions) ([]uint, error)
- func (d *Datastore) ListInvites(opt kolide.ListOptions) ([]*kolide.Invite, error)
- func (d *Datastore) ListLabels(opt kolide.ListOptions) ([]*kolide.Label, error)
- func (d *Datastore) ListLabelsForHost(hid uint) ([]kolide.Label, error)
- func (d *Datastore) ListLabelsForPack(pid uint) ([]*kolide.Label, error)
- func (d *Datastore) ListPacks(opt kolide.ListOptions) ([]*kolide.Pack, error)
- func (d *Datastore) ListQueries(opt kolide.ListOptions) ([]*kolide.Query, error)
- func (d *Datastore) ListSessionsForUser(id uint) ([]*kolide.Session, error)
- func (d *Datastore) ListUniqueHostsInLabels(labels []uint) ([]kolide.Host, error)
- func (d *Datastore) ListUsers(opt kolide.ListOptions) ([]*kolide.User, error)
- func (d *Datastore) MarkHostSeen(host *kolide.Host, t time.Time) error
- func (d *Datastore) MarkSessionAccessed(session *kolide.Session) error
- func (d *Datastore) MigrateData() error
- func (d *Datastore) MigrateTables() error
- func (m *Datastore) MigrationStatus() (kolide.MigrationStatus, error)
- func (d *Datastore) Name() string
- func (d *Datastore) NewAppConfig(info *kolide.AppConfig) (*kolide.AppConfig, error)
- func (d *Datastore) NewDistributedQueryCampaign(camp *kolide.DistributedQueryCampaign) (*kolide.DistributedQueryCampaign, error)
- func (d *Datastore) NewDistributedQueryCampaignTarget(target *kolide.DistributedQueryCampaignTarget) (*kolide.DistributedQueryCampaignTarget, error)
- func (d *Datastore) NewHost(host *kolide.Host) (*kolide.Host, error)
- func (d *Datastore) NewInvite(invite *kolide.Invite) (*kolide.Invite, error)
- func (d *Datastore) NewLabel(label *kolide.Label, opts ...kolide.OptionalArg) (*kolide.Label, error)
- func (d *Datastore) NewPack(pack *kolide.Pack, opts ...kolide.OptionalArg) (*kolide.Pack, error)
- func (d *Datastore) NewPasswordResetRequest(req *kolide.PasswordResetRequest) (*kolide.PasswordResetRequest, error)
- func (d *Datastore) NewQuery(query *kolide.Query, opts ...kolide.OptionalArg) (*kolide.Query, error)
- func (d *Datastore) NewSession(session *kolide.Session) (*kolide.Session, error)
- func (d *Datastore) NewUser(user *kolide.User) (*kolide.User, error)
- func (d *Datastore) Pack(id uint) (*kolide.Pack, error)
- func (d *Datastore) PackByName(name string, opts ...kolide.OptionalArg) (*kolide.Pack, bool, error)
- func (ds *Datastore) PendingEmailChange(uid uint, newEmail, token string) error
- func (d *Datastore) Query(id uint) (*kolide.Query, error)
- func (d *Datastore) RecordLabelQueryExecutions(host *kolide.Host, results map[uint]bool, t time.Time) error
- func (d *Datastore) RemoveHostFromPack(hid, pid uint) error
- func (d *Datastore) RemoveLabelFromPack(lid, pid uint) error
- func (d *Datastore) SaveAppConfig(info *kolide.AppConfig) error
- func (d *Datastore) SaveDistributedQueryCampaign(camp *kolide.DistributedQueryCampaign) error
- func (d *Datastore) SaveHost(host *kolide.Host) error
- func (d *Datastore) SaveInvite(invite *kolide.Invite) error
- func (d *Datastore) SaveLabel(label *kolide.Label) (*kolide.Label, error)
- func (d *Datastore) SavePack(pack *kolide.Pack) error
- func (d *Datastore) SavePasswordResetRequest(req *kolide.PasswordResetRequest) error
- func (d *Datastore) SaveQuery(query *kolide.Query) error
- func (d *Datastore) SaveUser(user *kolide.User) error
- func (d *Datastore) SearchHosts(query string, omit ...uint) ([]*kolide.Host, error)
- func (d *Datastore) SearchLabels(query string, omit ...uint) ([]kolide.Label, error)
- func (d *Datastore) SessionByID(id uint) (*kolide.Session, error)
- func (d *Datastore) SessionByKey(key string) (*kolide.Session, error)
- func (d *Datastore) User(username string) (*kolide.User, error)
- func (d *Datastore) UserByEmail(email string) (*kolide.User, error)
- func (d *Datastore) UserByID(id uint) (*kolide.User, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Datastore ¶
type Datastore struct { Driver string // Embedded interface to avoid implementing new methods for (now // deprecated) inmem. kolide.Datastore // contains filtered or unexported fields }
func (*Datastore) AddHostToPack ¶
func (*Datastore) AddLabelToPack ¶
func (d *Datastore) AddLabelToPack(lid, pid uint, opts ...kolide.OptionalArg) error
func (*Datastore) AuthenticateHost ¶
func (*Datastore) CleanupDistributedQueryCampaigns ¶
func (*Datastore) ConfirmPendingEmailChange ¶
func (*Datastore) CountHostsInTargets ¶
func (*Datastore) DeleteHost ¶
func (*Datastore) DeleteInvite ¶
DeleteInvite deletes an invitation.
func (*Datastore) DeletePasswordResetRequest ¶
func (d *Datastore) DeletePasswordResetRequest(req *kolide.PasswordResetRequest) error
func (*Datastore) DeletePasswordResetRequestsForUser ¶
func (*Datastore) DeleteQueries ¶
DeleteQueries deletes the existing query objects with the provided IDs. The number of deleted queries is returned along with any error.
func (*Datastore) DestroyAllSessionsForUser ¶
func (*Datastore) DestroySession ¶
func (*Datastore) DistributedQueryCampaign ¶
func (d *Datastore) DistributedQueryCampaign(id uint) (*kolide.DistributedQueryCampaign, error)
func (*Datastore) DistributedQueryCampaignTargetIDs ¶
func (*Datastore) EnrollHost ¶
func (*Datastore) FindPassswordResetByID ¶
func (d *Datastore) FindPassswordResetByID(id uint) (*kolide.PasswordResetRequest, error)
func (*Datastore) FindPassswordResetByToken ¶
func (d *Datastore) FindPassswordResetByToken(token string) (*kolide.PasswordResetRequest, error)
func (*Datastore) FindPassswordResetByTokenAndUserID ¶
func (*Datastore) FindPassswordResetsByUserID ¶
func (d *Datastore) FindPassswordResetsByUserID(userID uint) ([]*kolide.PasswordResetRequest, error)
func (*Datastore) GenerateHostStatusStatistics ¶
func (*Datastore) Initialize ¶
func (*Datastore) InviteByEmail ¶
InviteByEmail retrieves an invite for a specific email address.
func (*Datastore) InviteByToken ¶
InviteByToken retrieves an invite given the invite token.
func (*Datastore) LabelQueriesForHost ¶
func (*Datastore) ListExplicitHostsInPack ¶
func (*Datastore) ListHostsInLabel ¶
func (*Datastore) ListHostsInPack ¶
func (*Datastore) ListInvites ¶
Invites lists all invites in the datastore.
func (*Datastore) ListLabels ¶
func (*Datastore) ListLabelsForHost ¶
func (*Datastore) ListLabelsForPack ¶
func (*Datastore) ListQueries ¶
func (*Datastore) ListSessionsForUser ¶
func (*Datastore) ListUniqueHostsInLabels ¶
func (*Datastore) MarkHostSeen ¶
func (*Datastore) MarkSessionAccessed ¶
func (*Datastore) MigrateData ¶
func (*Datastore) MigrateTables ¶
func (*Datastore) MigrationStatus ¶
func (m *Datastore) MigrationStatus() (kolide.MigrationStatus, error)
func (*Datastore) NewAppConfig ¶
func (*Datastore) NewDistributedQueryCampaign ¶
func (d *Datastore) NewDistributedQueryCampaign(camp *kolide.DistributedQueryCampaign) (*kolide.DistributedQueryCampaign, error)
func (*Datastore) NewDistributedQueryCampaignTarget ¶
func (d *Datastore) NewDistributedQueryCampaignTarget(target *kolide.DistributedQueryCampaignTarget) (*kolide.DistributedQueryCampaignTarget, error)
func (*Datastore) NewPasswordResetRequest ¶
func (d *Datastore) NewPasswordResetRequest(req *kolide.PasswordResetRequest) (*kolide.PasswordResetRequest, error)
func (*Datastore) NewSession ¶
func (*Datastore) PackByName ¶
func (*Datastore) PendingEmailChange ¶
func (*Datastore) RecordLabelQueryExecutions ¶
func (*Datastore) RemoveHostFromPack ¶
func (*Datastore) RemoveLabelFromPack ¶
func (*Datastore) SaveDistributedQueryCampaign ¶
func (d *Datastore) SaveDistributedQueryCampaign(camp *kolide.DistributedQueryCampaign) error
func (*Datastore) SaveInvite ¶
SaveInvite saves an invitation in the datastore.
func (*Datastore) SavePasswordResetRequest ¶
func (d *Datastore) SavePasswordResetRequest(req *kolide.PasswordResetRequest) error
func (*Datastore) SearchHosts ¶
func (*Datastore) SearchLabels ¶
func (*Datastore) SessionByKey ¶
Click to show internal directories.
Click to hide internal directories.