Documentation ¶
Index ¶
- Constants
- type AuthMethodConf
- type OwnedObjectsProvider
- type OwnershipStrategy
- func NewViewGroupOwnershipStrategy(client libmongo.DbClient) OwnershipStrategy
- func NewViewOwnerStrategy(client libmongo.DbClient, enforcer security.Enforcer, ...) OwnershipStrategy
- func NewViewTabOwnershipStrategy(client libmongo.DbClient, enforcer security.Enforcer, ...) OwnershipStrategy
- func NewWidgetOwnershipStrategy(client libmongo.DbClient, enforcer security.Enforcer, ...) OwnershipStrategy
- type PermCheck
- type PrivacySettings
- type TokenService
- type TokenStore
- type ViewTabPrivacySettings
Constants ¶
View Source
const ( ObjPbehavior = "api_pbehavior" ObjPbehaviorType = "api_pbehaviortype" ObjPbehaviorReason = "api_pbehaviorreason" ObjPbehaviorException = "api_pbehaviorexception" ObjAction = "api_action" ObjEntity = "api_entity" ObjEntityService = "api_entityservice" ObjEntityCategory = "api_entitycategory" PermEntityComment = "api_entitycomment" ObjContextGraph = "api_contextgraph" ObjView = "api_view" ObjWidgetTemplate = "api_widgettemplate" ObjViewGroup = "api_viewgroup" ObjPlaylist = "api_playlist" PermAlarmRead = "api_alarm_read" PermAlarmUpdate = "api_alarm_update" PermAcl = "api_acl" ObjStateSettings = "api_state_settings" PermDataStorageRead = "api_datastorage_read" PermDataStorageUpdate = "api_datastorage_update" ObjEventFilter = "api_eventfilter" ObjBroadcastMessage = "api_broadcast_message" ObjAssociativeTable = "api_associative_table" PermUserInterfaceUpdate = "api_user_interface_update" PermUserInterfaceDelete = "api_user_interface_delete" PermEvent = "api_event" ObjIdleRule = "api_idlerule" PermNotification = "api_notification" PermMessageRateStatsRead = "api_message_rate_stats_read" PermHealthcheck = "api_healthcheck" ObjFile = "api_file" ObjFlappingRule = "api_flapping_rule" ObjResolveRule = "api_resolve_rule" PermCorporatePattern = "api_corporate_pattern" PermExportConfigurations = "api_export_configurations" PermTechMetrics = "api_techmetrics" ObjTechMetricsSettings = "api_techmetrics_settings" ObjLinkRule = "api_link_rule" ObjAlarmTag = "api_alarm_tag" PermMaintenance = "api_maintenance" ObjColorTheme = "api_color_theme" PermPrivateViewGroups = "api_private_view_groups" PermIcon = "api_icon" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthMethodConf ¶
type AuthMethodConf struct { ExpirationInterval *datetime.DurationWithUnit `bson:"expiration_interval" json:"expiration_interval"` InactivityInterval *datetime.DurationWithUnit `bson:"inactivity_interval" json:"inactivity_interval"` }
type OwnedObjectsProvider ¶
type OwnedObjectsProvider interface {
GetOwnedIDs(ctx context.Context, userID string) ([]string, error)
}
func NewViewOwnedObjectsProvider ¶
func NewViewOwnedObjectsProvider(client libmongo.DbClient) OwnedObjectsProvider
type OwnershipStrategy ¶
func NewViewGroupOwnershipStrategy ¶
func NewViewGroupOwnershipStrategy(client libmongo.DbClient) OwnershipStrategy
func NewViewOwnerStrategy ¶
func NewViewTabOwnershipStrategy ¶
type PermCheck ¶
PermCheck defines the permission check configuration where Obj is an object and Act is an action
type PrivacySettings ¶
type TokenService ¶
type TokenService interface { Create(ctx context.Context, user security.User, provider string) (string, error) CreateWithExpiration(ctx context.Context, user security.User, provider string, expiredAt time.Time) (string, error) Delete(ctx context.Context, token string) (bool, error) DeleteBy(ctx context.Context, user, provider string) error DeleteByUserIDs(ctx context.Context, ids []string) error }
func NewTokenService ¶
func NewTokenService( config security.Config, client mongo.DbClient, generator token.Generator, store TokenStore, ) TokenService
type TokenStore ¶
type ViewTabPrivacySettings ¶
type ViewTabPrivacySettings struct { PrivacySettings `bson:"inline"` View string `bson:"view"` }
Click to show internal directories.
Click to hide internal directories.