Documentation
¶
Overview ¶
Copyright 2025 Specter Ops, Inc.
Licensed under the Apache License, Version 2.0 you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
SPDX-License-Identifier: Apache-2.0
Copyright 2025 Specter Ops, Inc.
Licensed under the Apache License, Version 2.0 you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
SPDX-License-Identifier: Apache-2.0
Copyright 2026 Specter Ops, Inc.
Licensed under the Apache License, Version 2.0 you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
SPDX-License-Identifier: Apache-2.0
Index ¶
- Constants
- Variables
- func AllPaginationQueryParameters() []string
- func AssetGroupAssociations() []string
- func AssetGroupCollectionAssociations() []string
- func ErrIsGraphSchemaDuplicateError(err error) bool
- func FromDAWGSRelationship(includeProperties bool) func(*graph.Relationship) UnifiedEdge
- func GetAssetGroupMemberProperties(node *graph.Node) (primaryKind, displayName, objectId, envId string)
- func IgnoreFilters() []string
- func RoleAssociations() []string
- func SSOProviderIsStringField(field string) bool
- func SSOProviderSortableFields(field string) bool
- func SSOProviderValidFilterPredicates(field string) ([]string, error)
- func UserAssociations() []string
- func UserSessionAssociations() []string
- type ADDataQualityAggregation
- type ADDataQualityAggregations
- type ADDataQualityStat
- type ADDataQualityStats
- type AnalysisRequest
- type AnalysisRequestType
- type AssetGroup
- type AssetGroupCertification
- type AssetGroupCollection
- type AssetGroupCollectionEntries
- type AssetGroupCollectionEntry
- type AssetGroupCollections
- type AssetGroupExpansionMethod
- type AssetGroupHistory
- type AssetGroupHistoryAction
- type AssetGroupSelector
- type AssetGroupSelectorNode
- type AssetGroupSelectorNodeExpanded
- type AssetGroupSelectorNodeSource
- type AssetGroupSelectorNodes
- type AssetGroupSelectorSpec
- type AssetGroupSelectors
- type AssetGroupTag
- func (s AssetGroupTag) AuditData() AuditData
- func (s AssetGroupTag) GetExpansionMethod() AssetGroupExpansionMethod
- func (s AssetGroupTag) IsStringColumn(filter string) bool
- func (s AssetGroupTag) IsTierZero() bool
- func (s AssetGroupTag) KindName() string
- func (AssetGroupTag) TableName() string
- func (s AssetGroupTag) ToKind() graph.Kind
- func (s AssetGroupTag) ToType() string
- func (s AssetGroupTag) ValidFilters() map[string][]FilterOperator
- type AssetGroupTagCounts
- type AssetGroupTagCountsMap
- type AssetGroupTagSelector
- func (s AssetGroupTagSelector) AuditData() AuditData
- func (s AssetGroupTagSelector) IsSortable(criteria string) bool
- func (s AssetGroupTagSelector) IsStringColumn(filter string) bool
- func (AssetGroupTagSelector) TableName() string
- func (s AssetGroupTagSelector) ValidFilters() map[string][]FilterOperator
- type AssetGroupTagSelectors
- type AssetGroupTagType
- type AssetGroupTags
- type AssetGroups
- func (s AssetGroups) FindByName(name string) (AssetGroup, bool)
- func (s AssetGroups) GetFilterableColumns() []string
- func (s AssetGroups) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
- func (s AssetGroups) IsSortable(column string) bool
- func (s AssetGroups) IsString(column string) bool
- func (s AssetGroups) ValidFilters() map[string][]FilterOperator
- type AuditData
- type AuditEntry
- type AuditLog
- type AuditLogAction
- type AuditLogEntryStatus
- type AuditLogs
- type Auditable
- type AuditableURL
- type AuthSecret
- type AuthToken
- type AuthTokens
- func (s AuthTokens) GetFilterableColumns() []string
- func (s AuthTokens) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
- func (s AuthTokens) IDs() []uuid.UUID
- func (s AuthTokens) IsSortable(column string) bool
- func (s AuthTokens) IsString(column string) bool
- func (s AuthTokens) StripKeys() AuthTokens
- func (s AuthTokens) ValidFilters() map[string][]FilterOperator
- type AzureDataQualityAggregation
- type AzureDataQualityAggregations
- type AzureDataQualityStat
- type AzureDataQualityStats
- type AzureStatKinds
- type BaseADEntity
- type Basic
- type BigSerial
- type CSVWriter
- type CompletedTask
- type CustomNodeIcon
- type CustomNodeKind
- type CustomNodeKindConfig
- type CustomNodeKindMap
- type CustomNodeKinds
- type DataType
- type DatapipeStatus
- type DatapipeStatusWrapper
- type DomainCacheEntry
- type EdgeCompositionEdge
- type EdgeCompositionEdges
- type EdgeCompositionNode
- type EdgeCompositionNodes
- type EnvironmentInput
- type EnvironmentSelector
- type EnvironmentSelectors
- func (s EnvironmentSelectors) GetFilterCriteria(request *http.Request, environmentKinds []graph.Kind) (graph.Criteria, error)
- func (s EnvironmentSelectors) GetFilterableColumns() []string
- func (s EnvironmentSelectors) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
- func (s EnvironmentSelectors) IsSortable(column string) bool
- func (s EnvironmentSelectors) IsString(column string) bool
- func (s EnvironmentSelectors) ValidFilters() map[string][]FilterOperator
- type EnvironmentTargetedAccessControl
- type EnvironmentsInput
- type Exposure
- type Exposures
- type ExtensionInput
- type FileType
- type Filter
- type FilterOperator
- type FilterSetOperator
- type Filtered
- type Filters
- type GraphExtensionInput
- type GraphMigration
- type GraphSchemaExtension
- type GraphSchemaExtensions
- type GraphSchemaNodeKind
- type GraphSchemaNodeKinds
- type GraphSchemaProperties
- type GraphSchemaProperty
- type GraphSchemaRelationshipKind
- type GraphSchemaRelationshipKindWithNamedSchema
- type GraphSchemaRelationshipKinds
- type GraphSchemaRelationshipKindsWithNamedSchema
- type IngestJob
- type IngestJobs
- func (s IngestJobs) GetFilterableColumns() []string
- func (s IngestJobs) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
- func (s IngestJobs) IsSortable(column string) bool
- func (s IngestJobs) IsString(column string) bool
- func (s IngestJobs) ValidFilters() map[string][]FilterOperator
- type IngestTask
- type IngestTasks
- type Installation
- type JobStatus
- type Kind
- type LegacyADOU
- type Migration
- type NodeInput
- type NodesInput
- type OIDCProvider
- type OUCacheEntry
- type PagedNodeListEntry
- type PaginatedResponse
- type Permission
- type Permissions
- func (s Permissions) Equals(others Permissions) bool
- func (s Permissions) GetFilterableColumns() []string
- func (s Permissions) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
- func (s Permissions) Has(other Permission) bool
- func (s Permissions) IsSortable(column string) bool
- func (s Permissions) IsString(column string) bool
- func (s Permissions) ValidFilters() map[string][]FilterOperator
- type PropertiesInput
- type PropertyInput
- type QueryParameterFilter
- type QueryParameterFilterMap
- func (s QueryParameterFilterMap) AddFilter(filter QueryParameterFilter)
- func (s QueryParameterFilterMap) BuildAliasedSQLFilter(tableAlias models.Optional[string]) (SQLFilter, error)
- func (s QueryParameterFilterMap) BuildGDBNodeFilter() graph.Criteria
- func (s QueryParameterFilterMap) BuildNeo4jFilter() (string, error)
- func (s QueryParameterFilterMap) BuildSQLFilter() (SQLFilter, error)
- func (s QueryParameterFilterMap) FirstFilter(name string) (QueryParameterFilter, bool)
- func (s QueryParameterFilterMap) IsFiltered(name string) bool
- func (s QueryParameterFilterMap) ToFiltersModel() Filters
- type QueryParameterFilterParser
- type QueryParameterFilters
- type RelationshipFindingInput
- type RelationshipFindingsInput
- type RelationshipInput
- type RelationshipsInput
- type Remediation
- type RemediationInput
- type Role
- type Roles
- func (s Roles) FindByName(name string) (Role, bool)
- func (s Roles) FindByPermissions(permissions Permissions) (Role, bool)
- func (s Roles) GetFilterableColumns() []string
- func (s Roles) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
- func (s Roles) Has(other Role) bool
- func (s Roles) IDs() []int32
- func (s Roles) IsSortable(column string) bool
- func (s Roles) IsString(column string) bool
- func (s Roles) Names() []string
- func (s Roles) Permissions() Permissions
- func (s Roles) RemoveByName(name string) Roles
- func (s Roles) ValidFilters() map[string][]FilterOperator
- type SAMLProvider
- func (s SAMLProvider) AuditData() AuditData
- func (s *SAMLProvider) FormatSAMLProviderURLs(hostUrl url.URL)
- func (s SAMLProvider) GetSAMLUserGivenNameFromAssertion(assertion *saml.Assertion) (string, error)
- func (s SAMLProvider) GetSAMLUserPrincipalNameFromAssertion(assertion *saml.Assertion) (string, error)
- func (s SAMLProvider) GetSAMLUserRolesFromAssertion(assertion *saml.Assertion) (roles []string)
- func (s SAMLProvider) GetSAMLUserSurnameFromAssertion(assertion *saml.Assertion) (string, error)
- func (SAMLProvider) TableName() string
- type SAMLProviders
- type SAMLRootURIVersion
- type SQLFilter
- type SSOProvider
- type SSOProviderAutoProvisionConfig
- type SSOProviderConfig
- type SavedQueries
- func (s SavedQueries) GetFilterableColumns() []string
- func (s SavedQueries) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
- func (s SavedQueries) IsSortable(column string) bool
- func (s SavedQueries) IsString(column string) bool
- func (s SavedQueries) ValidFilters() map[string][]FilterOperator
- type SavedQueriesPermissions
- type SavedQuery
- type SavedQueryScope
- type SchemaEnvironment
- type SchemaEnvironmentPrincipalKind
- type SchemaEnvironmentPrincipalKinds
- type SchemaRelationshipFinding
- type ScopedSavedQuery
- type SearchResult
- type SelectorAutoCertifyMethod
- type SelectorSeed
- type SelectorSeeds
- type SelectorType
- type Serial
- type SessionAuthProvider
- type SessionFlagKey
- type Sort
- type SortDirection
- type SortItem
- type UnifiedEdge
- type UnifiedGraph
- type UnifiedGraphWPropertyKeys
- type UnifiedNode
- type Unique
- type UpdatedAssetGroupSelectors
- type User
- type UserSession
- type Users
- type ValidFilters
Constants ¶
const ( SelectorSpecActionAdd = "add" SelectorSpecActionRemove = "remove" TierZeroAssetGroupName = "Admin Tier Zero" TierZeroAssetGroupTag = "admin_tier_0" OwnedAssetGroupName = "Owned" OwnedAssetGroupTag = "owned" )
const ( AssetGroupActorBloodHound = "BloodHound" AssetGroupTierZeroPosition = 1 AssetGroupTierHygienePlaceholderId = 0 )
const ( TierZeroGlyph = "gem" OwnedGlyph = "skull" )
const ( GreaterThan FilterOperator = "gt" GreaterThanOrEquals FilterOperator = "gte" LessThan FilterOperator = "lt" LessThanOrEquals FilterOperator = "lte" Equals FilterOperator = "eq" NotEquals FilterOperator = "neq" ApproximatelyEquals FilterOperator = "~eq" GreaterThanSymbol string = ">" GreaterThanOrEqualsSymbol string = ">=" LessThanSymbol string = "<" LessThanOrEqualsSymbol string = "<=" EqualsSymbol string = "=" NotEqualsSymbol string = "<>" ApproximatelyEqualSymbol string = "ILIKE" NullString = "null" TrueString = "true" FalseString = "false" IdString = "id" ObjectIdString = "objectid" )
const ( PaginationQueryParameterBefore = "before" PaginationQueryParameterAfter = "after" PaginationQueryParameterLimit = "limit" PaginationQueryParameterOffset = "offset" PaginationQueryParameterSkip = "skip" PaginationQueryParameterSortBy = "sort_by" )
const ( ObjectIDAttributeNameFormat = "urn:oasis:names:tc:SAML:2.0:attrname-format:uri" ObjectIDEmail = "urn:oid:0.9.2342.19200300.100.1.3" ObjectIDGivenName = "urn:oid:2.5.4.42" ObjectIDName = "urn:oid:2.5.4.41" ObjectIDSurname = "urn:oid:2.5.4.4" XMLTypeString = "xs:string" XMLSOAPClaimsEmailAddress = "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress" XMLSOAPClaimsGivenName = "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/givenname" XMLSOAPClaimsName = "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/name" XMLSOAPClaimsSurname = "http://schemas.xmlsoap.org/ws/2005/05/identity/claims/surname" MicrosoftClaimsRole = "http://schemas.microsoft.com/ws/2008/06/identity/claims/role" )
const ( ErrResponseDetailsBadQueryParameterFilters = "there are errors in the query parameter filters specified" ErrResponseDetailsFilterPredicateNotSupported = "the specified filter predicate is not supported for this column" ErrResponseDetailsColumnNotFilterable = "the specified column cannot be filtered" ErrResponseDetailsColumnNotSortable = "the specified column cannot be sorted" )
const AssetGroupHistoryRecordRollingWindow = 90
AssetGroupHistoryRecordRollingWindow This defines the rolling window in days that the asset group history table will be truncated down to at the end of a successful analysis run
const PermissionURIScheme = "permission"
Variables ¶
var ( ErrGraphExtensionBuiltIn = errors.New("cannot modify a built-in graph extension") ErrGraphExtensionValidation = errors.New("graph schema validation error") ErrGraphDBRefreshKinds = errors.New("error refreshing graph db kinds") ErrDuplicateGraphSchemaExtensionName = errors.New("duplicate graph schema extension name") ErrDuplicateGraphSchemaExtensionNamespace = errors.New("duplicate graph schema extension namespace") ErrDuplicateSchemaNodeKindName = errors.New("duplicate schema node kind name") ErrDuplicateGraphSchemaExtensionPropertyName = errors.New("duplicate graph schema extension property name") ErrDuplicateSchemaRelationshipKindName = errors.New("duplicate schema relationship kind name") ErrDuplicateSchemaEnvironment = errors.New("duplicate schema environment") ErrDuplicateSchemaRelationshipFindingName = errors.New("duplicate schema relationship finding name") ErrDuplicatePrincipalKind = errors.New("duplicate principal kind") )
var ErrNotFiltered = errors.New("parameter value is not filtered")
var (
ErrSAMLAssertion = errors.New("SAML assertion error")
)
Functions ¶
func AllPaginationQueryParameters ¶
func AllPaginationQueryParameters() []string
func AssetGroupAssociations ¶
func AssetGroupAssociations() []string
AssetGroupAssociations returns a list of AssetGroup model associations to load eagerly by default with GORM Preload(...). Note: this does not include the "Collections" association on-purpose since this collection grows over time and may require additional parameters for fetching.
func AssetGroupCollectionAssociations ¶
func AssetGroupCollectionAssociations() []string
AssetGroupCollectionAssociations returns a list of AssetGroupCollection model associations to eagerly by default with GORM Preload(...).
func ErrIsGraphSchemaDuplicateError ¶
ErrIsGraphSchemaDuplicateError - determines if the provided error is one of the following errors: ErrDuplicateGraphSchemaExtensionName ErrDuplicateGraphSchemaExtensionNamespace ErrDuplicateSchemaNodeKindName ErrDuplicateGraphSchemaExtensionPropertyName ErrDuplicateSchemaRelationshipKindName ErrDuplicateSchemaEnvironment ErrDuplicateSchemaRelationshipFindingName ErrDuplicatePrincipalKind
func FromDAWGSRelationship ¶
func FromDAWGSRelationship(includeProperties bool) func(*graph.Relationship) UnifiedEdge
This is being used with slices.Map so it is necessary to return a closure
func GetAssetGroupMemberProperties ¶
func GetAssetGroupMemberProperties(node *graph.Node) (primaryKind, displayName, objectId, envId string)
These are the relevant properties for asset group tags. This method serves to keep consistency across the feature
func IgnoreFilters ¶
func IgnoreFilters() []string
func RoleAssociations ¶
func RoleAssociations() []string
func SSOProviderIsStringField ¶
Define which fields are string type
func SSOProviderSortableFields ¶
Define sortable fields
func SSOProviderValidFilterPredicates ¶
Define valid filter predicates for each field
func UserAssociations ¶
func UserAssociations() []string
Used by gorm to preload / instantiate the user FK'd tables data
func UserSessionAssociations ¶
func UserSessionAssociations() []string
Used by gorm to preload / instantiate the user FK'd tables data
Types ¶
type ADDataQualityAggregation ¶
type ADDataQualityAggregation struct {
Domains int `json:"domains"`
Users int `json:"users"`
Groups int `json:"groups"`
Computers int `json:"computers"`
OUs int `json:"ous" gorm:"column:ous"`
Containers int `json:"containers"`
GPOs int `json:"gpos" gorm:"column:gpos"`
AIACAs int `json:"aiacas" gorm:"column:aiacas"`
RootCAs int `json:"rootcas" gorm:"column:rootcas"`
EnterpriseCAs int `json:"enterprisecas" gorm:"column:enterprisecas"`
NTAuthStores int `json:"ntauthstores" gorm:"column:ntauthstores"`
CertTemplates int `json:"certtemplates" gorm:"column:certtemplates"`
IssuancePolicies int `json:"issuancepolicies" gorm:"column:issuancepolicies"`
Acls int `json:"acls" gorm:"column:acls"`
Sessions int `json:"sessions"`
Relationships int `json:"relationships"`
SessionCompleteness float32 `json:"session_completeness"`
LocalGroupCompleteness float32 `json:"local_group_completeness"`
RunID string `json:"run_id" gorm:"index"`
Serial
}
type ADDataQualityAggregations ¶
type ADDataQualityAggregations []ADDataQualityAggregation
type ADDataQualityStat ¶
type ADDataQualityStat struct {
DomainSID string `json:"domain_sid" gorm:"column:domain_sid"`
Users int `json:"users"`
Groups int `json:"groups"`
Computers int `json:"computers"`
OUs int `json:"ous" gorm:"column:ous"`
Containers int `json:"containers"`
GPOs int `json:"gpos" gorm:"column:gpos"`
AIACAs int `json:"aiacas" gorm:"column:aiacas"`
RootCAs int `json:"rootcas" gorm:"column:rootcas"`
EnterpriseCAs int `json:"enterprisecas" gorm:"column:enterprisecas"`
NTAuthStores int `json:"ntauthstores" gorm:"column:ntauthstores"`
CertTemplates int `json:"certtemplates" gorm:"column:certtemplates"`
IssuancePolicies int `json:"issuancepolicies" gorm:"column:issuancepolicies"`
ACLs int `json:"acls" gorm:"column:acls"`
Sessions int `json:"sessions"`
Relationships int `json:"relationships"`
SessionCompleteness nan.Float64 `json:"session_completeness"`
LocalGroupCompleteness nan.Float64 `json:"local_group_completeness"`
RunID string `json:"run_id" gorm:"index"`
Serial
}
type ADDataQualityStats ¶
type ADDataQualityStats []ADDataQualityStat
func (ADDataQualityStats) IsSortable ¶
func (s ADDataQualityStats) IsSortable(column string) bool
type AnalysisRequest ¶
type AnalysisRequest struct {
RequestedBy string `json:"requested_by"`
RequestType AnalysisRequestType `json:"request_type"`
RequestedAt time.Time `json:"requested_at"`
DeleteAllGraph bool `json:"delete_all_graph"` // Deletes all nodes and edges in the graph
DeleteSourcelessGraph bool `json:"delete_sourceless_graph"` // Deletes all nodes and edges in the graph that have a type not registered in the source_kinds table
DeleteSourceKinds pq.StringArray `gorm:"type:text[];column:delete_source_kinds"` // Deletes all nodes and edges per kind provided.
}
type AnalysisRequestType ¶
type AnalysisRequestType string
const ( AnalysisRequestAnalysis AnalysisRequestType = "analysis" AnalysisRequestDeletion AnalysisRequestType = "deletion" )
type AssetGroup ¶
type AssetGroup struct {
Name string `json:"name"`
Tag string `json:"tag"`
SystemGroup bool `json:"system_group"`
Selectors AssetGroupSelectors `gorm:"constraint:OnDelete:CASCADE;"`
Collections AssetGroupCollections `json:"-" gorm:"constraint:OnDelete:CASCADE;"`
MemberCount int `json:"member_count" gorm:"-"`
Serial
}
func (AssetGroup) AuditData ¶
func (s AssetGroup) AuditData() AuditData
type AssetGroupCertification ¶
type AssetGroupCertification int
const ( AssetGroupCertificationPending AssetGroupCertification = 0 AssetGroupCertificationRevoked AssetGroupCertification = 1 AssetGroupCertificationManual AssetGroupCertification = 2 AssetGroupCertificationAuto AssetGroupCertification = 3 )
type AssetGroupCollection ¶
type AssetGroupCollection struct {
AssetGroupID int32 `json:"-"`
Entries AssetGroupCollectionEntries `json:"entries" gorm:"constraint:OnDelete:CASCADE;"`
BigSerial
}
type AssetGroupCollectionEntries ¶
type AssetGroupCollectionEntries []AssetGroupCollectionEntry
type AssetGroupCollections ¶
type AssetGroupCollections []AssetGroupCollection
func (AssetGroupCollections) GetFilterableColumns ¶
func (s AssetGroupCollections) GetFilterableColumns() []string
func (AssetGroupCollections) GetValidFilterPredicatesAsStrings ¶
func (s AssetGroupCollections) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
func (AssetGroupCollections) IsSortable ¶
func (s AssetGroupCollections) IsSortable(column string) bool
func (AssetGroupCollections) ValidFilters ¶
func (s AssetGroupCollections) ValidFilters() map[string][]FilterOperator
type AssetGroupExpansionMethod ¶
type AssetGroupExpansionMethod int
const ( AssetGroupExpansionMethodNone AssetGroupExpansionMethod = 0 AssetGroupExpansionMethodAll AssetGroupExpansionMethod = 1 AssetGroupExpansionMethodChildren AssetGroupExpansionMethod = 2 AssetGroupExpansionMethodParents AssetGroupExpansionMethod = 3 )
type AssetGroupHistory ¶
type AssetGroupHistory struct {
ID int64 `json:"id" gorm:"primaryKey"`
CreatedAt time.Time `json:"created_at"`
Actor string `json:"actor"`
Email null.String `json:"email"`
Action AssetGroupHistoryAction `json:"action"`
Target string `json:"target"`
AssetGroupTagId int `json:"asset_group_tag_id"`
EnvironmentId null.String `json:"environment_id"`
Note null.String `json:"note"`
}
AssetGroupHistory is the record of CRUD changes associated with v2 of the asset groups feature
func (AssetGroupHistory) AuditData ¶
func (s AssetGroupHistory) AuditData() AuditData
func (AssetGroupHistory) IsSortable ¶
func (s AssetGroupHistory) IsSortable(criteria string) bool
func (AssetGroupHistory) IsStringColumn ¶
func (s AssetGroupHistory) IsStringColumn(filter string) bool
func (AssetGroupHistory) TableName ¶
func (AssetGroupHistory) TableName() string
func (AssetGroupHistory) ValidFilters ¶
func (s AssetGroupHistory) ValidFilters() map[string][]FilterOperator
type AssetGroupHistoryAction ¶
type AssetGroupHistoryAction string
const ( AssetGroupHistoryActionCreateTag AssetGroupHistoryAction = "CreateTag" AssetGroupHistoryActionUpdateTag AssetGroupHistoryAction = "UpdateTag" AssetGroupHistoryActionDeleteTag AssetGroupHistoryAction = "DeleteTag" AssetGroupHistoryActionAnalysisEnabledTag AssetGroupHistoryAction = "AnalysisEnabledTag" AssetGroupHistoryActionAnalysisDisabledTag AssetGroupHistoryAction = "AnalysisDisabledTag" AssetGroupHistoryActionCreateSelector AssetGroupHistoryAction = "CreateSelector" AssetGroupHistoryActionUpdateSelector AssetGroupHistoryAction = "UpdateSelector" AssetGroupHistoryActionDeleteSelector AssetGroupHistoryAction = "DeleteSelector" AssetGroupHistoryActionCertifyNodeAuto AssetGroupHistoryAction = "CertifyNodeAuto" AssetGroupHistoryActionCertifyNodeManual AssetGroupHistoryAction = "CertifyNodeManual" AssetGroupHistoryActionCertifyNodeRevoked AssetGroupHistoryAction = "CertifyNodeRevoked" )
func ToAssetGroupHistoryActionFromAssetGroupCertification ¶
func ToAssetGroupHistoryActionFromAssetGroupCertification(certifyValue AssetGroupCertification) AssetGroupHistoryAction
type AssetGroupSelector ¶
type AssetGroupSelector struct {
AssetGroupID int32 `json:"asset_group_id" gorm:"UNIQUE_INDEX:compositeindex"`
Name string `json:"name" gorm:"UNIQUE_INDEX:compositeindex"`
Selector string `json:"selector"`
SystemSelector bool `json:"system_selector"`
Serial
}
func (AssetGroupSelector) AuditData ¶
func (s AssetGroupSelector) AuditData() AuditData
type AssetGroupSelectorNode ¶
type AssetGroupSelectorNode struct {
SelectorId int `json:"selector_id"`
NodeId graph.ID `json:"node_id"`
Certified AssetGroupCertification `json:"certified"`
CertifiedBy null.String `json:"certified_by"`
Source AssetGroupSelectorNodeSource `json:"source"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
NodePrimaryKind string `json:"node_primary_kind"`
NodeEnvironmentId string `json:"node_environment_id"`
NodeObjectId string `json:"node_object_id"`
NodeName string `json:"node_name"`
}
func (AssetGroupSelectorNode) IsStringColumn ¶
func (s AssetGroupSelectorNode) IsStringColumn(filter string) bool
func (AssetGroupSelectorNode) TableName ¶
func (s AssetGroupSelectorNode) TableName() string
func (AssetGroupSelectorNode) ValidFilters ¶
func (s AssetGroupSelectorNode) ValidFilters() map[string][]FilterOperator
type AssetGroupSelectorNodeExpanded ¶
type AssetGroupSelectorNodeExpanded struct {
AssetGroupSelectorNode
AssetGroupTagId int `json:"asset_group_tag_id"`
Position int `json:"position"`
}
type AssetGroupSelectorNodeSource ¶
type AssetGroupSelectorNodeSource int
const ( AssetGroupSelectorNodeSourceSeed AssetGroupSelectorNodeSource = 1 AssetGroupSelectorNodeSourceChild AssetGroupSelectorNodeSource = 2 AssetGroupSelectorNodeSourceParent AssetGroupSelectorNodeSource = 3 )
type AssetGroupSelectorNodes ¶
type AssetGroupSelectorNodes []AssetGroupSelectorNode
type AssetGroupSelectorSpec ¶
type AssetGroupSelectorSpec struct {
SelectorName string `json:"selector_name"`
EntityObjectID string `json:"sid"`
Action string `json:"action"`
}
func (AssetGroupSelectorSpec) AuditData ¶
func (s AssetGroupSelectorSpec) AuditData() AuditData
func (AssetGroupSelectorSpec) Validate ¶
func (s AssetGroupSelectorSpec) Validate() error
type AssetGroupSelectors ¶
type AssetGroupSelectors []AssetGroupSelector
func (AssetGroupSelectors) Strings ¶
func (s AssetGroupSelectors) Strings() []string
type AssetGroupTag ¶
type AssetGroupTag struct {
ID int `json:"id"`
Type AssetGroupTagType `json:"type" validate:"required"`
KindId int `json:"kind_id"`
Name string `json:"name" validate:"required"`
Description string `json:"description"`
CreatedAt time.Time `json:"created_at"`
CreatedBy string `json:"created_by"`
UpdatedAt time.Time `json:"updated_at"`
UpdatedBy string `json:"updated_by"`
DeletedAt null.Time `json:"deleted_at"`
DeletedBy null.String `json:"deleted_by"`
Position null.Int32 `json:"position"`
RequireCertify null.Bool `json:"require_certify"`
AnalysisEnabled null.Bool `json:"analysis_enabled"`
Glyph null.String `json:"glyph"`
}
func (AssetGroupTag) AuditData ¶
func (s AssetGroupTag) AuditData() AuditData
func (AssetGroupTag) GetExpansionMethod ¶
func (s AssetGroupTag) GetExpansionMethod() AssetGroupExpansionMethod
func (AssetGroupTag) IsStringColumn ¶
func (s AssetGroupTag) IsStringColumn(filter string) bool
func (AssetGroupTag) IsTierZero ¶
func (s AssetGroupTag) IsTierZero() bool
func (AssetGroupTag) KindName ¶
func (s AssetGroupTag) KindName() string
func (AssetGroupTag) TableName ¶
func (AssetGroupTag) TableName() string
func (AssetGroupTag) ToKind ¶
func (s AssetGroupTag) ToKind() graph.Kind
func (AssetGroupTag) ToType ¶
func (s AssetGroupTag) ToType() string
func (AssetGroupTag) ValidFilters ¶
func (s AssetGroupTag) ValidFilters() map[string][]FilterOperator
type AssetGroupTagCounts ¶
type AssetGroupTagCountsMap ¶
type AssetGroupTagCountsMap map[int]AssetGroupTagCounts
type AssetGroupTagSelector ¶
type AssetGroupTagSelector struct {
ID int `json:"id"`
AssetGroupTagId int `json:"asset_group_tag_id"`
CreatedAt time.Time `json:"created_at"`
CreatedBy string `json:"created_by"`
UpdatedAt time.Time `json:"updated_at"`
UpdatedBy string `json:"updated_by"`
DisabledAt null.Time `json:"disabled_at"`
DisabledBy null.String `json:"disabled_by"`
Name string `json:"name" validate:"required"`
Description string `json:"description"`
AutoCertify SelectorAutoCertifyMethod `json:"auto_certify"`
IsDefault bool `json:"is_default"`
AllowDisable bool `json:"allow_disable"`
Seeds []SelectorSeed `json:"seeds,omitempty" validate:"required" gorm:"-"`
}
func (AssetGroupTagSelector) AuditData ¶
func (s AssetGroupTagSelector) AuditData() AuditData
func (AssetGroupTagSelector) IsSortable ¶
func (s AssetGroupTagSelector) IsSortable(criteria string) bool
func (AssetGroupTagSelector) IsStringColumn ¶
func (s AssetGroupTagSelector) IsStringColumn(filter string) bool
func (AssetGroupTagSelector) TableName ¶
func (AssetGroupTagSelector) TableName() string
func (AssetGroupTagSelector) ValidFilters ¶
func (s AssetGroupTagSelector) ValidFilters() map[string][]FilterOperator
type AssetGroupTagSelectors ¶
type AssetGroupTagSelectors []AssetGroupTagSelector
type AssetGroupTagType ¶
type AssetGroupTagType int
const ( AssetGroupTagTypeTier AssetGroupTagType = 1 AssetGroupTagTypeLabel AssetGroupTagType = 2 AssetGroupTagTypeOwned AssetGroupTagType = 3 )
type AssetGroupTags ¶
type AssetGroupTags []AssetGroupTag
type AssetGroups ¶
type AssetGroups []AssetGroup
func (AssetGroups) FindByName ¶
func (s AssetGroups) FindByName(name string) (AssetGroup, bool)
func (AssetGroups) GetFilterableColumns ¶
func (s AssetGroups) GetFilterableColumns() []string
func (AssetGroups) GetValidFilterPredicatesAsStrings ¶
func (s AssetGroups) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
func (AssetGroups) IsSortable ¶
func (s AssetGroups) IsSortable(column string) bool
func (AssetGroups) IsString ¶
func (s AssetGroups) IsString(column string) bool
func (AssetGroups) ValidFilters ¶
func (s AssetGroups) ValidFilters() map[string][]FilterOperator
type AuditEntry ¶
type AuditEntry struct {
CommitID uuid.UUID
Action AuditLogAction
Model Auditable
Status AuditLogEntryStatus
ErrorMsg string
}
func NewAuditEntry ¶
func NewAuditEntry(action AuditLogAction, status AuditLogEntryStatus, data AuditData) (AuditEntry, error)
func (AuditEntry) Matches ¶
func (s AuditEntry) Matches(x any) bool
Necessary function for testing. Ensures all fields except CommitID match so mocking checks pass.
func (AuditEntry) String ¶
func (s AuditEntry) String() string
type AuditLog ¶
type AuditLog struct {
ID int64 `json:"id" gorm:"primaryKey"`
CreatedAt time.Time `json:"created_at" gorm:"index"`
ActorID string `json:"actor_id" gorm:"index"`
ActorName string `json:"actor_name"`
ActorEmail string `json:"actor_email"`
Action AuditLogAction `json:"action" gorm:"index"`
Fields types.JSONUntypedObject `json:"fields"`
RequestID string `json:"request_id"`
SourceIpAddress string `json:"source_ip_address"`
Status AuditLogEntryStatus `json:"status"`
CommitID uuid.UUID `json:"commit_id" gorm:"type:text"`
}
TODO embed Basic into this struct instead of declaring the ID and CreatedAt fields. This will require a migration
type AuditLogAction ¶
type AuditLogAction string
const ( AuditLogActionAcceptEULA AuditLogAction = "AcceptEULA" AuditLogActionAcceptFedEULA AuditLogAction = "AcceptFedEULA" // INFO: The FedEULA is only applicable to select enterprise installations AuditLogActionLoginAttempt AuditLogAction = "LoginAttempt" AuditLogActionCreateUser AuditLogAction = "CreateUser" AuditLogActionUpdateUser AuditLogAction = "UpdateUser" AuditLogActionDeleteUser AuditLogAction = "DeleteUser" AuditLogActionCreateAssetGroup AuditLogAction = "CreateAssetGroup" AuditLogActionUpdateAssetGroup AuditLogAction = "UpdateAssetGroup" AuditLogActionDeleteAssetGroup AuditLogAction = "DeleteAssetGroup" AuditLogActionDeleteAssetGroupSelector AuditLogAction = "DeleteAssetGroupSelector" AuditLogActionCreateAuthToken AuditLogAction = "CreateAuthToken" AuditLogActionDeleteAuthToken AuditLogAction = "DeleteAuthToken" AuditLogActionDeleteAllAuthTokens AuditLogAction = "DeleteAllAuthTokens" AuditLogActionCreateAuthSecret AuditLogAction = "CreateAuthSecret" AuditLogActionUpdateAuthSecret AuditLogAction = "UpdateAuthSecret" AuditLogActionDeleteAuthSecret AuditLogAction = "DeleteAuthSecret" AuditLogActionCreateSAMLIdentityProvider AuditLogAction = "CreateSAMLIdentityProvider" AuditLogActionUpdateSAMLIdentityProvider AuditLogAction = "UpdateSAMLIdentityProvider" AuditLogActionCreateOIDCIdentityProvider AuditLogAction = "CreateOIDCIdentityProvider" AuditLogActionUpdateOIDCIdentityProvider AuditLogAction = "UpdateOIDCIdentityProvider" AuditLogActionCreateSSOIdentityProvider AuditLogAction = "CreateSSOIdentityProvider" AuditLogActionUpdateSSOIdentityProvider AuditLogAction = "UpdateSSOIdentityProvider" AuditLogActionDeleteSSOIdentityProvider AuditLogAction = "DeleteSSOIdentityProvider" AuditLogActionAcceptRisk AuditLogAction = "AcceptRisk" AuditLogActionUnacceptRisk AuditLogAction = "UnacceptRisk" AuditLogActionExportRelationshipRisks AuditLogAction = "ExportRelationshipRisks" AuditLogActionExportListRisks AuditLogAction = "ExportListRisks" AuditLogActionExportAllRisks AuditLogAction = "ExportAllRisks" AuditLogActionDeleteBloodhoundData AuditLogAction = "DeleteBloodhoundData" AuditLogActionMutateGraph AuditLogAction = "MutateGraph" AuditLogActionUpdateParameter AuditLogAction = "UpdateParameter" AuditLogActionCreateAssetGroupTag AuditLogAction = "CreateAssetGroupTag" AuditLogActionUpdateAssetGroupTag AuditLogAction = "UpdateAssetGroupTag" AuditLogActionDeleteAssetGroupTag AuditLogAction = "DeleteAssetGroupTag" AuditLogActionCreateAssetGroupTagSelector AuditLogAction = "CreateAssetGroupTagSelector" AuditLogActionUpdateAssetGroupTagSelector AuditLogAction = "UpdateAssetGroupTagSelector" AuditLogActionDeleteAssetGroupTagSelector AuditLogAction = "DeleteAssetGroupTagSelector" AuditLogActionCreateCustomNodeKind AuditLogAction = "CreateCustomNodeKind" AuditLogActionUpdateCustomNodeKind AuditLogAction = "UpdateCustomNodeKind" AuditLogActionDeleteCustomNodeKind AuditLogAction = "DeleteCustomNodeKind" AuditLogActionToggleEarlyAccessFeatureFlag AuditLogAction = "ToggleEarlyAccessFeatureFlag" AuditLogActionCreateClient AuditLogAction = "CreateClient" AuditLogActionReplaceClientToken AuditLogAction = "ReplaceClientToken" AuditLogActionImportSavedQuery AuditLogAction = "ImportSavedQueries" AuditLogActionExportSavedQuery AuditLogAction = "ExportSavedQuery" AuditLogActionExportSavedQueries AuditLogAction = "ExportSavedQueries" AuditLogActionUpdateETACList AuditLogAction = "UpdateETACList" AuditLogActionDeleteETACList AuditLogAction = "DeleteETACList" AuditLogActionCreateGraphSchemaExtension AuditLogAction = "CreateGraphSchemaExtension" AuditLogActionDeleteGraphSchemaExtension AuditLogAction = "DeleteGraphSchemaExtension" )
type AuditLogEntryStatus ¶
type AuditLogEntryStatus string
const ( AuditLogStatusSuccess AuditLogEntryStatus = "success" AuditLogStatusFailure AuditLogEntryStatus = "failure" AuditLogStatusIntent AuditLogEntryStatus = "intent" )
type AuditLogs ¶
type AuditLogs []AuditLog
func (AuditLogs) GetFilterableColumns ¶
func (AuditLogs) GetValidFilterPredicatesAsStrings ¶
func (AuditLogs) IsSortable ¶
func (AuditLogs) ValidFilters ¶
func (s AuditLogs) ValidFilters() map[string][]FilterOperator
type AuditableURL ¶
type AuditableURL string
func (AuditableURL) AuditData ¶
func (s AuditableURL) AuditData() AuditData
type AuthSecret ¶
type AuthSecret struct {
UserID uuid.UUID `json:"-"`
Digest string `json:"-"`
DigestMethod string `json:"digest_method"`
ExpiresAt time.Time `json:"expires_at"`
TOTPSecret string `json:"-"`
TOTPActivated bool `json:"totp_activated"`
Serial
}
func (AuthSecret) AuditData ¶
func (s AuthSecret) AuditData() AuditData
func (AuthSecret) Expired ¶
func (s AuthSecret) Expired() bool
Expired returns true if the auth secret has expired, false otherwise
type AuthToken ¶
type AuthTokens ¶
type AuthTokens []AuthToken
func (AuthTokens) GetFilterableColumns ¶
func (s AuthTokens) GetFilterableColumns() []string
func (AuthTokens) GetValidFilterPredicatesAsStrings ¶
func (s AuthTokens) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
func (AuthTokens) IDs ¶
func (s AuthTokens) IDs() []uuid.UUID
func (AuthTokens) IsSortable ¶
func (s AuthTokens) IsSortable(column string) bool
func (AuthTokens) IsString ¶
func (s AuthTokens) IsString(column string) bool
func (AuthTokens) StripKeys ¶
func (s AuthTokens) StripKeys() AuthTokens
func (AuthTokens) ValidFilters ¶
func (s AuthTokens) ValidFilters() map[string][]FilterOperator
type AzureDataQualityAggregation ¶
type AzureDataQualityAggregation struct {
Serial
AzureStatKinds
RunID string `json:"run_id" gorm:"index"`
Tenants int `json:"tenants"`
}
type AzureDataQualityAggregations ¶
type AzureDataQualityAggregations []AzureDataQualityAggregation
type AzureDataQualityStat ¶
type AzureDataQualityStat struct {
Serial
AzureStatKinds
RunID string `json:"run_id" gorm:"index"`
TenantID string `json:"tenantid" gorm:"column:tenant_id"`
}
type AzureDataQualityStats ¶
type AzureDataQualityStats []AzureDataQualityStat
func (AzureDataQualityStats) IsSortable ¶
func (s AzureDataQualityStats) IsSortable(column string) bool
type AzureStatKinds ¶
type AzureStatKinds struct {
Relationships int `json:"relationships"`
Users int `json:"users"`
Groups int `json:"groups"`
Apps int `json:"apps"`
ServicePrincipals int `json:"service_principals"`
Devices int `json:"devices"`
ManagementGroups int `json:"management_groups"`
Subscriptions int `json:"subscriptions"`
ResourceGroups int `json:"resource_groups"`
VMs int `json:"vms"`
KeyVaults int `json:"key_vaults"`
AutomationAccounts int `json:"automation_accounts"`
ContainerRegistries int `json:"container_registries"`
FunctionApps int `json:"function_apps"`
LogicApps int `json:"logic_apps"`
ManagedClusters int `json:"managed_clusters"`
VMScaleSets int `json:"vm_scale_sets"`
WebApps int `json:"web_apps"`
}
type BaseADEntity ¶
type Basic ¶
type Basic struct {
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
DeletedAt sql.NullTime `json:"deleted_at" gorm:"-"`
}
Basic is a struct which includes the following basic fields: CreatedAt, UpdatedAt, DeletedAt.
type BigSerial ¶
BigSerial is a struct that follows the same design principles as Serial but with one exception: the ID type is set to int64 to support an ID sequence limit of up to 9223372036854775807.
type CompletedTask ¶
type CompletedTask struct {
IngestJobId int64 `json:"ingest_job_id"`
FileName string `json:"file_name"`
ParentFileName string `json:"parent_file_name"`
Errors pq.StringArray `json:"errors" gorm:"type:text[]"`
Warnings pq.StringArray `json:"warnings" gorm:"type:text[]"`
BigSerial
}
type CustomNodeIcon ¶
type CustomNodeKind ¶
type CustomNodeKind struct {
ID int32 `json:"id"`
KindName string `json:"kindName"`
Config CustomNodeKindConfig `json:"config"`
}
func (CustomNodeKind) AuditData ¶
func (s CustomNodeKind) AuditData() AuditData
type CustomNodeKindConfig ¶
type CustomNodeKindConfig struct {
Icon CustomNodeIcon `json:"icon"`
}
func (*CustomNodeKindConfig) Scan ¶
func (s *CustomNodeKindConfig) Scan(value interface{}) error
type CustomNodeKindMap ¶
type CustomNodeKindMap map[string]CustomNodeKindConfig
type CustomNodeKinds ¶
type CustomNodeKinds []CustomNodeKind
func (CustomNodeKinds) AuditData ¶
func (s CustomNodeKinds) AuditData() AuditData
type DatapipeStatus ¶
type DatapipeStatus string
const ( DatapipeStatusIdle DatapipeStatus = "idle" DatapipeStatusIngesting DatapipeStatus = "ingesting" DatapipeStatusAnalyzing DatapipeStatus = "analyzing" DatapipeStatusPurging DatapipeStatus = "purging" DatapipeStatusPruning DatapipeStatus = "pruning" DatapipeStatusStarting DatapipeStatus = "starting" )
func (DatapipeStatus) TableName ¶
func (DatapipeStatus) TableName() string
type DatapipeStatusWrapper ¶
type DomainCacheEntry ¶
DomainCacheEntry is used to store necessary domain properties for hydration
type EdgeCompositionEdge ¶
These structs were created for the new edge composition model, but are being saved for later use, since it doesn't work with our current post implementation
type EdgeCompositionEdges ¶
type EdgeCompositionEdges []EdgeCompositionEdge
type EdgeCompositionNode ¶
type EdgeCompositionNodes ¶
type EdgeCompositionNodes []EdgeCompositionNode
type EnvironmentInput ¶
type EnvironmentSelector ¶
type EnvironmentSelector struct {
Type string `json:"type"`
Name string `json:"name"`
ObjectID string `json:"id"`
Collected bool `json:"collected"`
ImpactValue *int `json:"impactValue,omitempty"`
HygieneAttackPaths *int64 `json:"hygiene_attack_paths,omitempty"` // caution: if value is bigger than maxsafeint, the UI will truncate the value
Exposures Exposures `json:"exposures,omitempty"`
}
type EnvironmentSelectors ¶
type EnvironmentSelectors []EnvironmentSelector
func (EnvironmentSelectors) GetFilterCriteria ¶
func (EnvironmentSelectors) GetFilterableColumns ¶
func (s EnvironmentSelectors) GetFilterableColumns() []string
func (EnvironmentSelectors) GetValidFilterPredicatesAsStrings ¶
func (s EnvironmentSelectors) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
func (EnvironmentSelectors) IsSortable ¶
func (s EnvironmentSelectors) IsSortable(column string) bool
func (EnvironmentSelectors) IsString ¶
func (s EnvironmentSelectors) IsString(column string) bool
func (EnvironmentSelectors) ValidFilters ¶
func (s EnvironmentSelectors) ValidFilters() map[string][]FilterOperator
type EnvironmentTargetedAccessControl ¶
type EnvironmentTargetedAccessControl struct {
UserID string `json:"user_id"`
EnvironmentID string `json:"environment_id"`
BigSerial
}
EnvironmentTargetedAccessControl defines the model for a row in the environment_targeted_access_control table
func (EnvironmentTargetedAccessControl) TableName ¶
func (EnvironmentTargetedAccessControl) TableName() string
type EnvironmentsInput ¶
type EnvironmentsInput []EnvironmentInput
type Exposure ¶
type Exposure struct {
ExposurePercent int `json:"exposure_percent"`
AssetGroupTag AssetGroupTag `json:"asset_group_tag"`
}
type ExtensionInput ¶
type Filter ¶
type Filter struct {
Operator FilterOperator
Value string
SetOperator FilterSetOperator
}
type FilterOperator ¶
type FilterOperator string
func ParseFilterOperator ¶
func ParseFilterOperator(raw string) (FilterOperator, error)
type FilterSetOperator ¶
type FilterSetOperator string
const ( FilterAnd FilterSetOperator = "AND" FilterOr FilterSetOperator = "OR" )
type Filtered ¶
type Filtered interface {
ValidFilters() map[string][]FilterOperator
}
type GraphExtensionInput ¶
type GraphExtensionInput struct {
ExtensionInput ExtensionInput
PropertiesInput PropertiesInput
RelationshipKindsInput RelationshipsInput
NodeKindsInput NodesInput
EnvironmentsInput EnvironmentsInput
RelationshipFindingsInput RelationshipFindingsInput
}
type GraphMigration ¶
func (GraphMigration) Version ¶
func (s GraphMigration) Version() version.Version
type GraphSchemaExtension ¶
type GraphSchemaExtension struct {
Serial
Name string
DisplayName string
Version string
IsBuiltin bool
Namespace string
}
func (GraphSchemaExtension) AuditData ¶
func (s GraphSchemaExtension) AuditData() AuditData
func (GraphSchemaExtension) TableName ¶
func (GraphSchemaExtension) TableName() string
type GraphSchemaExtensions ¶
type GraphSchemaExtensions []GraphSchemaExtension
type GraphSchemaNodeKind ¶
type GraphSchemaNodeKind struct {
Serial
Name string
SchemaExtensionId int32 // indicates which extension this node kind belongs to
DisplayName string // can be different from name but usually isn't other than Base/Entity
Description string // human-readable description of the node kind
IsDisplayKind bool // indicates if this kind should supersede others and be displayed
Icon string // font-awesome icon for the registered node kind
IconColor string // icon hex color
}
GraphSchemaNodeKind - represents a node kind for an extension
func (GraphSchemaNodeKind) TableName ¶
func (GraphSchemaNodeKind) TableName() string
TableName - Retrieve table name
func (GraphSchemaNodeKind) ToKind ¶
func (s GraphSchemaNodeKind) ToKind() graph.Kind
type GraphSchemaNodeKinds ¶
type GraphSchemaNodeKinds []GraphSchemaNodeKind
GraphSchemaNodeKinds - slice of node kinds
type GraphSchemaProperties ¶
type GraphSchemaProperties []GraphSchemaProperty
GraphSchemaProperties - slice of graph schema properties.
type GraphSchemaProperty ¶
type GraphSchemaProperty struct {
Serial
SchemaExtensionId int32
Name string
DisplayName string
DataType string
Description string
}
GraphSchemaProperty - represents a property that an relationship or node kind can have. Grouped by schema extension.
func (GraphSchemaProperty) TableName ¶
func (GraphSchemaProperty) TableName() string
type GraphSchemaRelationshipKind ¶
type GraphSchemaRelationshipKind struct {
Serial
SchemaExtensionId int32 // indicates which extension this relationship kind belongs to
Name string
Description string
IsTraversable bool // indicates whether the relationship-kind is a traversable path
}
GraphSchemaRelationshipKind - represents an relationship kind for an extension
func (GraphSchemaRelationshipKind) IsStringColumn ¶
func (GraphSchemaRelationshipKind) IsStringColumn(filter string) bool
func (GraphSchemaRelationshipKind) TableName ¶
func (GraphSchemaRelationshipKind) TableName() string
func (GraphSchemaRelationshipKind) ToKind ¶
func (s GraphSchemaRelationshipKind) ToKind() graph.Kind
func (GraphSchemaRelationshipKind) ValidFilters ¶
func (GraphSchemaRelationshipKind) ValidFilters() map[string][]FilterOperator
type GraphSchemaRelationshipKinds ¶
type GraphSchemaRelationshipKinds []GraphSchemaRelationshipKind
GraphSchemaRelationshipKinds - slice of model.GraphSchemaRelationshipKind
type GraphSchemaRelationshipKindsWithNamedSchema ¶
type GraphSchemaRelationshipKindsWithNamedSchema []GraphSchemaRelationshipKindWithNamedSchema
type IngestJob ¶
type IngestJob struct {
UserID uuid.NullUUID `json:"user_id"`
UserEmailAddress null.String `json:"user_email_address"`
User User `json:"-"`
Status JobStatus `json:"status"`
StatusMessage string `json:"status_message"`
StartTime time.Time `json:"start_time"`
EndTime time.Time `json:"end_time"`
LastIngest time.Time `json:"last_ingest"`
TotalFiles int `json:"total_files"`
FailedFiles int `json:"failed_files"`
PartialFailedFiles int `json:"partial_failed_files"`
BigSerial
}
type IngestJobs ¶
type IngestJobs []IngestJob
func (IngestJobs) GetFilterableColumns ¶
func (s IngestJobs) GetFilterableColumns() []string
func (IngestJobs) GetValidFilterPredicatesAsStrings ¶
func (s IngestJobs) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
func (IngestJobs) IsSortable ¶
func (s IngestJobs) IsSortable(column string) bool
func (IngestJobs) IsString ¶
func (s IngestJobs) IsString(column string) bool
func (IngestJobs) ValidFilters ¶
func (s IngestJobs) ValidFilters() map[string][]FilterOperator
type IngestTask ¶
type IngestTasks ¶
type IngestTasks []IngestTask
type Installation ¶
type Installation struct {
Unique
}
type JobStatus ¶
type JobStatus int
const ( JobStatusInvalid JobStatus = -1 JobStatusReady JobStatus = 0 JobStatusRunning JobStatus = 1 JobStatusComplete JobStatus = 2 JobStatusCanceled JobStatus = 3 JobStatusTimedOut JobStatus = 4 JobStatusFailed JobStatus = 5 JobStatusIngesting JobStatus = 6 JobStatusAnalyzing JobStatus = 7 JobStatusPartiallyComplete JobStatus = 8 )
func GetVisibleJobStatuses ¶
func GetVisibleJobStatuses() []JobStatus
func ParseJobStatus ¶
func (JobStatus) IsValidEndState ¶
type LegacyADOU ¶
type LegacyADOU struct {
BaseADEntity
DistinguishedName string `json:"dn"`
Type string `json:"type"`
}
type Migration ¶
type Migration struct {
ID int32 `gorm:"primaryKey"`
UpdatedAt time.Time
Major int32
Minor int32
Patch int32
}
func NewMigration ¶
type NodeInput ¶
type NodeInput struct {
Name string
DisplayName string // human-readable name
Description string // human-readable description of the node kind
IsDisplayKind bool // indicates if this kind should supersede others and be displayed
Icon string // font-awesome icon for the registered node kind
IconColor string // icon hex color
}
type NodesInput ¶
type NodesInput []NodeInput
type OIDCProvider ¶
type OIDCProvider struct {
ClientID string `json:"client_id"`
Issuer string `json:"issuer"`
SSOProviderID int `json:"sso_provider_id"`
Serial
}
OIDCProvider contains the data needed to initiate an OIDC secure login flow
func (OIDCProvider) AuditData ¶
func (s OIDCProvider) AuditData() AuditData
func (OIDCProvider) TableName ¶
func (OIDCProvider) TableName() string
type OUCacheEntry ¶
OUCacheEntry is used to store necessary OU properties for hydration
type PagedNodeListEntry ¶
type PaginatedResponse ¶
type PaginatedResponse struct {
Count int `json:"count"`
Limit int `json:"limit"`
Skip int `json:"skip"`
Data any `json:"data"`
}
PaginatedResponse has been DEPRECATED as part of V1. Please use api.ResponseWrapper instead
type Permission ¶
func NewPermission ¶
func NewPermission(authority, name string) Permission
func (Permission) Equals ¶
func (s Permission) Equals(other Permission) bool
func (Permission) String ¶
func (s Permission) String() string
func (Permission) URI ¶
func (s Permission) URI() *url.URL
type Permissions ¶
type Permissions []Permission
func (Permissions) Equals ¶
func (s Permissions) Equals(others Permissions) bool
func (Permissions) GetFilterableColumns ¶
func (s Permissions) GetFilterableColumns() []string
func (Permissions) GetValidFilterPredicatesAsStrings ¶
func (s Permissions) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
func (Permissions) Has ¶
func (s Permissions) Has(other Permission) bool
func (Permissions) IsSortable ¶
func (s Permissions) IsSortable(column string) bool
func (Permissions) IsString ¶
func (s Permissions) IsString(column string) bool
func (Permissions) ValidFilters ¶
func (s Permissions) ValidFilters() map[string][]FilterOperator
type PropertiesInput ¶
type PropertiesInput []PropertyInput
type PropertyInput ¶
type QueryParameterFilter ¶
type QueryParameterFilter struct {
Name string
Operator FilterOperator
Value string
IsStringData bool
SetOperator FilterSetOperator
}
func (QueryParameterFilter) BuildGDBNodeFilter ¶
func (s QueryParameterFilter) BuildGDBNodeFilter() graph.Criteria
type QueryParameterFilterMap ¶
type QueryParameterFilterMap map[string]QueryParameterFilters
func (QueryParameterFilterMap) AddFilter ¶
func (s QueryParameterFilterMap) AddFilter(filter QueryParameterFilter)
func (QueryParameterFilterMap) BuildAliasedSQLFilter ¶
func (QueryParameterFilterMap) BuildGDBNodeFilter ¶
func (s QueryParameterFilterMap) BuildGDBNodeFilter() graph.Criteria
func (QueryParameterFilterMap) BuildNeo4jFilter ¶
func (s QueryParameterFilterMap) BuildNeo4jFilter() (string, error)
func (QueryParameterFilterMap) BuildSQLFilter ¶
func (s QueryParameterFilterMap) BuildSQLFilter() (SQLFilter, error)
func (QueryParameterFilterMap) FirstFilter ¶
func (s QueryParameterFilterMap) FirstFilter(name string) (QueryParameterFilter, bool)
func (QueryParameterFilterMap) IsFiltered ¶
func (s QueryParameterFilterMap) IsFiltered(name string) bool
func (QueryParameterFilterMap) ToFiltersModel ¶
func (s QueryParameterFilterMap) ToFiltersModel() Filters
ToFiltersModel converts the query parameter filter map model into the newer, more generic filter model. This is useful when accessing newer functions that expect the newer model without having refactor multiple sites all-at-once.
type QueryParameterFilterParser ¶
type QueryParameterFilterParser struct {
// contains filtered or unexported fields
}
func NewQueryParameterFilterParser ¶
func NewQueryParameterFilterParser() QueryParameterFilterParser
func (QueryParameterFilterParser) ParseQueryParameterFilter ¶
func (s QueryParameterFilterParser) ParseQueryParameterFilter(name, value string) (QueryParameterFilter, error)
func (QueryParameterFilterParser) ParseQueryParameterFilters ¶
func (s QueryParameterFilterParser) ParseQueryParameterFilters(request *http.Request) (QueryParameterFilterMap, error)
type QueryParameterFilters ¶
type QueryParameterFilters []QueryParameterFilter
type RelationshipFindingsInput ¶
type RelationshipFindingsInput []RelationshipFindingInput
type RelationshipInput ¶
type RelationshipsInput ¶
type RelationshipsInput []RelationshipInput
type Remediation ¶
type Remediation struct {
FindingID int32
DisplayName string
ShortDescription string
LongDescription string
ShortRemediation string
LongRemediation string
}
func (Remediation) TableName ¶
func (Remediation) TableName() string
type RemediationInput ¶
type Role ¶
type Role struct {
Name string `json:"name"`
Description string `json:"description"`
Permissions Permissions `json:"permissions" gorm:"many2many:roles_permissions"`
Serial
}
type Roles ¶
type Roles []Role
func (Roles) FindByPermissions ¶
func (s Roles) FindByPermissions(permissions Permissions) (Role, bool)
func (Roles) GetFilterableColumns ¶
func (Roles) GetValidFilterPredicatesAsStrings ¶
func (Roles) IsSortable ¶
func (Roles) Permissions ¶
func (s Roles) Permissions() Permissions
func (Roles) RemoveByName ¶
func (Roles) ValidFilters ¶
func (s Roles) ValidFilters() map[string][]FilterOperator
type SAMLProvider ¶
type SAMLProvider struct {
Name string `json:"name" gorm:"unique;index"`
DisplayName string `json:"display_name"`
IssuerURI string `json:"idp_issuer_uri"`
SingleSignOnURI string `json:"idp_sso_uri"`
MetadataXML []byte `json:"-"`
RootURIVersion SAMLRootURIVersion `json:"root_uri_version"`
// PrincipalAttributeMapping is an array of OID or XML Namespace element mapping strings that can be used to map a
// SAML assertion to a user in the database.
//
// For example: ["http://schemas.xmlsoap.org/ws/2005/05/identity/claims/emailaddress", "urn:oid:0.9.2342.19200300.100.1.3"]
PrincipalAttributeMappings []string `json:"principal_attribute_mappings" gorm:"type:text[];column:ous"`
// The below values generated values that point a client to SAML related resources hosted on the BloodHound instance
// and should not be persisted to the database due to the fact that the URLs rely on the Host header that the user is
// using to communicate to the API
ServiceProviderIssuerURI serde.URL `json:"sp_issuer_uri" gorm:"-"`
ServiceProviderInitiationURI serde.URL `json:"sp_sso_uri" gorm:"-"`
ServiceProviderMetadataURI serde.URL `json:"sp_metadata_uri" gorm:"-"`
ServiceProviderACSURI serde.URL `json:"sp_acs_uri" gorm:"-"`
SSOProviderID null.Int32 `json:"sso_provider_id"`
Serial
}
func (SAMLProvider) AuditData ¶
func (s SAMLProvider) AuditData() AuditData
func (*SAMLProvider) FormatSAMLProviderURLs ¶
func (s *SAMLProvider) FormatSAMLProviderURLs(hostUrl url.URL)
func (SAMLProvider) GetSAMLUserGivenNameFromAssertion ¶
func (s SAMLProvider) GetSAMLUserGivenNameFromAssertion(assertion *saml.Assertion) (string, error)
func (SAMLProvider) GetSAMLUserPrincipalNameFromAssertion ¶
func (s SAMLProvider) GetSAMLUserPrincipalNameFromAssertion(assertion *saml.Assertion) (string, error)
func (SAMLProvider) GetSAMLUserRolesFromAssertion ¶
func (s SAMLProvider) GetSAMLUserRolesFromAssertion(assertion *saml.Assertion) (roles []string)
GetSAMLUserRolesFromAssertion May be empty if not present
func (SAMLProvider) GetSAMLUserSurnameFromAssertion ¶
func (s SAMLProvider) GetSAMLUserSurnameFromAssertion(assertion *saml.Assertion) (string, error)
func (SAMLProvider) TableName ¶
func (SAMLProvider) TableName() string
type SAMLProviders ¶
type SAMLProviders []SAMLProvider
type SAMLRootURIVersion ¶
type SAMLRootURIVersion int
SAMLRootURIVersion is required for payloads to match the ACS / Callback url configured on IDPs While the DB column root_uri_version has a default of 2, it is also hardcoded in the db method CreateSAMLIdentityProvider
var ( SAMLRootURIVersion1 SAMLRootURIVersion = 1 SAMLRootURIVersion2 SAMLRootURIVersion = 2 SAMLRootURIVersionMap = map[SAMLRootURIVersion]string{ SAMLRootURIVersion1: "/api/v1/login/saml", SAMLRootURIVersion2: "/api/v2/sso", } )
type SSOProvider ¶
type SSOProvider struct {
Type SessionAuthProvider `json:"type" gorm:"column:type"`
Name string `json:"name"`
Slug string `json:"slug"`
OIDCProvider *OIDCProvider `json:"oidc_provider,omitempty" gorm:"foreignKey:SSOProviderID"`
SAMLProvider *SAMLProvider `json:"saml_provider,omitempty" gorm:"foreignKey:SSOProviderID"`
Config SSOProviderConfig `json:"config" gorm:"type:jsonb column:config"`
Serial
}
SSOProvider is the common representation of an SSO provider that can be used to display high level information about that provider
func (SSOProvider) AuditData ¶
func (s SSOProvider) AuditData() AuditData
AuditData returns the fields to log in the audit log
type SSOProviderConfig ¶
type SSOProviderConfig struct {
AutoProvision SSOProviderAutoProvisionConfig `json:"auto_provision"`
}
func (*SSOProviderConfig) Scan ¶
func (cfg *SSOProviderConfig) Scan(value interface{}) error
Implement the sql.Scanner interface so that GORM can scan the jsonb column from the database into a golang struct
type SavedQueries ¶
type SavedQueries []SavedQuery
func (SavedQueries) GetFilterableColumns ¶
func (s SavedQueries) GetFilterableColumns() []string
func (SavedQueries) GetValidFilterPredicatesAsStrings ¶
func (s SavedQueries) GetValidFilterPredicatesAsStrings(column string) ([]string, error)
func (SavedQueries) IsSortable ¶
func (s SavedQueries) IsSortable(column string) bool
func (SavedQueries) IsString ¶
func (s SavedQueries) IsString(column string) bool
func (SavedQueries) ValidFilters ¶
func (s SavedQueries) ValidFilters() map[string][]FilterOperator
type SavedQueriesPermissions ¶
type SavedQueriesPermissions struct {
QueryID int64 `json:"query_id"`
Public bool `json:"public"`
BigSerial
}
SavedQueriesPermissions represents the database model which allows users to share saved cypher queries
type SavedQuery ¶
type SavedQueryScope ¶
type SavedQueryScope string
const ( SavedQueryScopeOwned SavedQueryScope = "owned" SavedQueryScopePublic SavedQueryScope = "public" SavedQueryScopeAll SavedQueryScope = "all" )
type SchemaEnvironment ¶
type SchemaEnvironment struct {
Serial
SchemaExtensionId int32
SchemaExtensionDisplayName string
EnvironmentKindId int32
EnvironmentKindName string
SourceKindId int32
}
func (SchemaEnvironment) TableName ¶
func (SchemaEnvironment) TableName() string
type SchemaEnvironmentPrincipalKind ¶
type SchemaEnvironmentPrincipalKind struct {
EnvironmentId int32
PrincipalKind int32
CreatedAt time.Time
}
func (SchemaEnvironmentPrincipalKind) TableName ¶
func (SchemaEnvironmentPrincipalKind) TableName() string
type SchemaEnvironmentPrincipalKinds ¶
type SchemaEnvironmentPrincipalKinds []SchemaEnvironmentPrincipalKind
type SchemaRelationshipFinding ¶
type SchemaRelationshipFinding struct {
ID int32
SchemaExtensionId int32
RelationshipKindId int32
EnvironmentId int32
Name string
DisplayName string
CreatedAt time.Time
}
SchemaRelationshipFinding represents an individual finding (e.g., T0WriteOwner, T0ADCSESC1, T0DCSync)
func (SchemaRelationshipFinding) TableName ¶
func (SchemaRelationshipFinding) TableName() string
type ScopedSavedQuery ¶
type ScopedSavedQuery struct {
SavedQuery
Scope string `json:"scope"`
}
type SearchResult ¶
type SelectorAutoCertifyMethod ¶
type SelectorAutoCertifyMethod int
const ( SelectorAutoCertifyMethodDisabled SelectorAutoCertifyMethod = 0 SelectorAutoCertifyMethodAllMembers SelectorAutoCertifyMethod = 1 SelectorAutoCertifyMethodSeedsOnly SelectorAutoCertifyMethod = 2 )
type SelectorSeed ¶
type SelectorSeed struct {
SelectorId int `json:"-"`
Type SelectorType `json:"type"`
Value string `json:"value"`
}
func (SelectorSeed) AuditData ¶
func (s SelectorSeed) AuditData() AuditData
func (SelectorSeed) TableName ¶
func (SelectorSeed) TableName() string
func (SelectorSeed) ValidFilters ¶
func (s SelectorSeed) ValidFilters() map[string][]FilterOperator
type SelectorSeeds ¶
type SelectorSeeds []SelectorSeed
type SelectorType ¶
type SelectorType int
const ( SelectorTypeObjectId SelectorType = 1 SelectorTypeCypher SelectorType = 2 )
type Serial ¶
Serial is a struct which includes the following basic fields: ID, CreatedAt, UpdatedAt, DeletedAt. This was chosen over the default gorm model so that ID retains the bare int type. We do this because uint has no meaning with regards to the underlying database storage engine - at least where postgresql is concerned. To avoid type gnashing and unexpected pain with sql.NullInt32 the bare int type is a better choice all around.
See: https://www.postgresql.org/docs/current/datatype-numeric.html
type SessionAuthProvider ¶
type SessionAuthProvider int
const ( SessionAuthProviderSecret SessionAuthProvider = 0 SessionAuthProviderSAML SessionAuthProvider = 1 SessionAuthProviderOIDC SessionAuthProvider = 2 )
func (SessionAuthProvider) String ¶
func (s SessionAuthProvider) String() string
type SessionFlagKey ¶
type SessionFlagKey string
const (
SessionFlagFedEULAAccepted SessionFlagKey = "fed_eula_accepted" // INFO: The FedEULA is only applicable to select enterprise installations
)
type SortDirection ¶
type SortDirection int
const ( InvalidSortDirection SortDirection = iota AscendingSortDirection DescendingSortDirection )
type SortItem ¶
type SortItem struct {
Direction SortDirection
Column string
}
type UnifiedEdge ¶
type UnifiedEdge struct {
Source string `json:"source"`
Target string `json:"target"`
Label string `json:"label"`
Kind string `json:"kind"`
LastSeen time.Time `json:"lastSeen"`
Properties map[string]any `json:"properties,omitempty"`
}
UnifiedEdge represents a single path segment in a graph containing a minimal set of attributes for graph rendering
type UnifiedGraph ¶
type UnifiedGraph struct {
Nodes map[string]UnifiedNode `json:"nodes"`
Edges []UnifiedEdge `json:"edges"`
Literals graph.Literals `json:"literals"`
}
UnifiedGraph represents a single, generic and minimalistic graph
func NewUnifiedGraph ¶
func NewUnifiedGraph() UnifiedGraph
NewUnifiedGraph returns a new UnifiedGraph struct with the Nodes field initialized to an empty map
func (*UnifiedGraph) AddNode ¶
func (s *UnifiedGraph) AddNode(node *graph.Node, includeProperties bool)
func (*UnifiedGraph) AddPathSet ¶
func (s *UnifiedGraph) AddPathSet(paths graph.PathSet, includeProperties bool)
func (*UnifiedGraph) AddRelationship ¶
func (s *UnifiedGraph) AddRelationship(rel *graph.Relationship, includeProperties bool)
type UnifiedGraphWPropertyKeys ¶
type UnifiedGraphWPropertyKeys struct {
NodeKeys []string `json:"node_keys,omitempty"`
EdgeKeys []string `json:"edge_keys,omitempty"`
Edges []UnifiedEdge `json:"edges"`
Nodes map[string]UnifiedNode `json:"nodes"`
Literals graph.Literals `json:"literals"`
}
UnifiedGraphWPropertyKeys
type UnifiedNode ¶
type UnifiedNode struct {
Label string `json:"label"`
Kind string `json:"kind"`
Kinds []string `json:"kinds"`
ObjectId string `json:"objectId"`
IsTierZero bool `json:"isTierZero"`
IsOwnedObject bool `json:"isOwnedObject"`
LastSeen time.Time `json:"lastSeen"`
Properties map[string]any `json:"properties,omitempty"`
Hidden bool `json:"hidden,omitempty"`
}
UnifiedNode represents a single node in a graph containing a minimal set of attributes for graph rendering
func FromDAWGSNode ¶
func FromDAWGSNode(node *graph.Node, includeProperties bool) UnifiedNode
type Unique ¶
Unique is a struct is a struct which includes the following basic fields: ID, CreatedAt, UpdatedAt, DeletedAt.
type UpdatedAssetGroupSelectors ¶
type UpdatedAssetGroupSelectors struct {
Added AssetGroupSelectors `json:"added_selectors"`
Removed AssetGroupSelectors `json:"removed_selectors"`
}
type User ¶
type User struct {
SSOProvider *SSOProvider `json:"-" `
SSOProviderID null.Int32 `json:"sso_provider_id,omitempty"`
AuthSecret *AuthSecret `gorm:"constraint:OnDelete:CASCADE;"`
AuthTokens AuthTokens `json:"-" gorm:"constraint:OnDelete:CASCADE;"`
Roles Roles `json:"roles" gorm:"many2many:users_roles"`
FirstName null.String `json:"first_name"`
LastName null.String `json:"last_name"`
EmailAddress null.String `json:"email_address"`
PrincipalName string `json:"principal_name" gorm:"unique;index"`
LastLogin time.Time `json:"last_login"`
IsDisabled bool `json:"is_disabled"`
AllEnvironments bool `json:"all_environments"`
EnvironmentTargetedAccessControl []EnvironmentTargetedAccessControl `json:"environment_targeted_access_control"`
// EULA Acceptance does not pertain to Bloodhound Community Edition; this flag is used for Bloodhound Enterprise users.
// This value is automatically set to true for Bloodhound Community Edition in the patchEULAAcceptance and CreateUser functions.
EULAAccepted bool `json:"eula_accepted"`
Unique
}
func (*User) RemoveRole ¶
func (*User) SSOProviderHasRoleProvisionEnabled ¶
type UserSession ¶
type UserSession struct {
User User `gorm:"constraint:OnDelete:CASCADE;"`
UserID uuid.UUID
AuthProviderType SessionAuthProvider
AuthProviderID int32 // If SSO Session, this will be the child saml or oidc provider id
ExpiresAt time.Time
Flags types.JSONBBoolObject `json:"flags"`
BigSerial
}
func (UserSession) Expired ¶
func (s UserSession) Expired() bool
Expired returns true if the user session has expired, false otherwise
func (UserSession) GetFlag ¶
func (s UserSession) GetFlag(key SessionFlagKey) bool
corresponding set function is cmd/api/src/database/auth.go:SetUserSessionFlag()
type Users ¶
type Users []User
func (Users) GetFilterableColumns ¶
func (Users) GetValidFilterPredicatesAsStrings ¶
func (Users) IsSortable ¶
func (Users) ValidFilters ¶
func (s Users) ValidFilters() map[string][]FilterOperator
type ValidFilters ¶
type ValidFilters map[string][]FilterOperator
Source Files
¶
- adquality.go
- agi.go
- analysisrequest.go
- assetgrouphistory.go
- assetgrouptags.go
- audit.go
- auth.go
- azurequality.go
- cache.go
- completedtask.go
- composition.go
- csv.go
- customnode.go
- datapipestatus.go
- etac.go
- filter.go
- graph_migration.go
- graphschema.go
- ingest.go
- jobs.go
- kind.go
- migration.go
- model.go
- oidc_provider.go
- pagination.go
- samlprovider.go
- saved_queries.go
- saved_queries_permissions.go
- search.go
- sso_provider.go
- unified_graph.go