Documentation ¶
Index ¶
- Constants
- Variables
- func AddAdhocHandlers(version string, app *appsrv.Application)
- func AutoSyncIdentityProviderTask(ctx context.Context, userCred mcclient.TokenCredential, isStart bool)
- func CheckAllUserPasswordIsExpired(ctx context.Context, userCred mcclient.TokenCredential, startRun bool)
- func GetConfigs(model db.IModel, sensitive bool, whiteList, blackList map[string][]string) (api.TConfigs, error)
- func GetDefaultAdminCred() mcclient.TokenCredential
- func GetDefaultClient() *mcclient.Client
- func GetDefaultClientSession(ctx context.Context, token mcclient.TokenCredential, region string) *mcclient.ClientSession
- func GetUserLangForKeyStone(uids []string) (map[string]string, error)
- func InitDB() error
- func InitSyncWorkers()
- func NewServiceConfigSession() common_options.IServiceConfigSession
- func NormalizeProjectName(name string) string
- func RemoveObsoleteInvalidTokens(ctx context.Context, userCred mcclient.TokenCredential, start bool)
- func Usage(ctx context.Context, result rbacutils.SPolicyResult) map[string]int
- func ValidateJoinProjectRoles(userCred mcclient.TokenCredential, projectId string, roleIds []string) error
- func VerifyPassword(user *api.SUserExtended, passwd string) error
- type IEnabledIdentityModel
- type IEnabledIdentityModelManager
- type IIdentityModel
- type IIdentityModelManager
- type SAssignment
- type SAssignmentManager
- func (manager *SAssignmentManager) FetchAll(userId, groupId, roleId, domainId, projectId string, projectDomainId string, ...) ([]api.SRoleAssignment, int64, error)
- func (manager *SAssignmentManager) FetchUserProjectRoles(userId, projId string) ([]SRole, error)
- func (manager *SAssignmentManager) InitializeData() error
- func (manager *SAssignmentManager) ProjectAddUser(ctx context.Context, userCred mcclient.TokenCredential, project *SProject, ...) error
- type SConfigOption
- type SConfigOptionManager
- type SCredential
- func (cred *SCredential) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (cred *SCredential) GetAccessKeySecret() (*api.SAccessKeySecretBlob, error)
- func (cred *SCredential) GetOwnerId() mcclient.IIdentityProvider
- func (cred *SCredential) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
- func (cred *SCredential) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.CredentialUpdateInput, error)
- type SCredentialManager
- func (manager *SCredentialManager) DeleteAll(ctx context.Context, userCred mcclient.TokenCredential, uid string, ...) error
- func (manager *SCredentialManager) FetchCredentials(uid string, credType string) ([]SCredential, error)
- func (manager *SCredentialManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.CredentialDetails
- func (manager *SCredentialManager) FetchOwnerId(ctx context.Context, data jsonutils.JSONObject) (mcclient.IIdentityProvider, error)
- func (manager *SCredentialManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, ...) *sqlchemy.SQuery
- func (manager *SCredentialManager) InitializeData() error
- func (manager *SCredentialManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SCredentialManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SCredentialManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SCredentialManager) ResourceScope() rbacscope.TRbacScope
- func (manager *SCredentialManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.CredentialCreateInput, error)
- type SDomain
- func (domain *SDomain) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (domain *SDomain) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (domain *SDomain) DeleteUserGroups(ctx context.Context, userCred mcclient.TokenCredential) error
- func (domain *SDomain) GetGroupCount() (int, error)
- func (domain *SDomain) GetIdpCount() (int, error)
- func (domain *SDomain) GetPolicyCount() (int, error)
- func (domain *SDomain) GetProjectCount() (int, error)
- func (domain *SDomain) GetRoleCount() (int, error)
- func (domain *SDomain) GetUserCount() (int, error)
- func (domain *SDomain) IsReadOnly() bool
- func (domain *SDomain) PerformUnlinkIdp(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (domain *SDomain) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (domain *SDomain) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
- func (domain *SDomain) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (domain *SDomain) UnlinkIdp(idpId string) error
- func (domain *SDomain) ValidateDeleteCondition(ctx context.Context, info *api.DomainDetails) error
- func (domain *SDomain) ValidateUpdateCondition(ctx context.Context) error
- func (domain *SDomain) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.DomainUpdateInput, error)
- type SDomainManager
- func (manager *SDomainManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.DomainDetails
- func (manager *SDomainManager) FetchDomain(domainId string, domainName string) (*SDomain, error)
- func (manager *SDomainManager) FetchDomainById(domainId string) (*SDomain, error)
- func (manager *SDomainManager) FetchDomainByIdOrName(domain string) (*SDomain, error)
- func (manager *SDomainManager) FetchDomainByName(domainName string) (*SDomain, error)
- func (manager *SDomainManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, ...) *sqlchemy.SQuery
- func (manager *SDomainManager) FilterBySystemAttributes(q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) *sqlchemy.SQuery
- func (manager *SDomainManager) InitializeData() error
- func (manager *SDomainManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SDomainManager) NewQuery(ctx context.Context, userCred mcclient.TokenCredential, ...) *sqlchemy.SQuery
- func (manager *SDomainManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SDomainManager) Query(fields ...string) *sqlchemy.SQuery
- func (manager *SDomainManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SDomainManager) TotalResourceCount(domainIds []string) (map[string]api.DomainUsage, error)
- func (manager *SDomainManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.DomainCreateInput, error)
- type SDomainUsageCount
- type SEnabledIdentityBaseResource
- func (model *SEnabledIdentityBaseResource) GetIEnabledIdentityModel() IEnabledIdentityModel
- func (model *SEnabledIdentityBaseResource) GetIEnabledIdentityModelManager() IEnabledIdentityModelManager
- func (model *SEnabledIdentityBaseResource) GetShortDesc(ctx context.Context) *jsonutils.JSONDict
- func (model *SEnabledIdentityBaseResource) PerformDisable(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (model *SEnabledIdentityBaseResource) PerformEnable(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (ident *SEnabledIdentityBaseResource) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
- func (model *SEnabledIdentityBaseResource) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.EnabledIdentityBaseUpdateInput, error)
- type SEnabledIdentityBaseResourceManager
- func (manager *SEnabledIdentityBaseResourceManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.EnabledIdentityBaseResourceDetails
- func (manager *SEnabledIdentityBaseResourceManager) GetIEnabledIdentityModelManager() IEnabledIdentityModelManager
- func (manager *SEnabledIdentityBaseResourceManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SEnabledIdentityBaseResourceManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SEnabledIdentityBaseResourceManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SEnabledIdentityBaseResourceManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.EnabledIdentityBaseResourceCreateInput, error)
- type SEndpoint
- func (endpoint *SEndpoint) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (endpoint *SEndpoint) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
- func (endpoint *SEndpoint) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (endpoint *SEndpoint) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
- func (endpoint *SEndpoint) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (*jsonutils.JSONDict, error)
- type SEndpointExtended
- type SEndpointManager
- func (manager *SEndpointManager) FetchAll() (SServiceCatalog, error)
- func (manager *SEndpointManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.EndpointDetails
- func (manager *SEndpointManager) InitializeData() error
- func (manager *SEndpointManager) IsEtcdInformerBackend(ep *SEndpoint) bool
- func (manager *SEndpointManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SEndpointManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SEndpointManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SEndpointManager) SetEtcdInformerBackend(ep *SEndpoint) error
- func (manager *SEndpointManager) SetInformerBackend() error
- func (manager *SEndpointManager) SetInformerBackendByEndpoint(ep *SEndpoint)
- func (manager *SEndpointManager) SetInformerBackendUntilSuccess(ep *SEndpoint)
- func (manager *SEndpointManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (*jsonutils.JSONDict, error)
- type SFederatedUser
- type SFederatedUserManager
- type SFederationProtocol
- type SFederationProtocolManager
- type SFernetKey
- type SFernetKeyManager
- type SGroup
- func (group *SGroup) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (group *SGroup) GetProjectCount() (int, error)
- func (group *SGroup) GetUsages() []db.IUsage
- func (group *SGroup) GetUserCount() (int, error)
- func (group *SGroup) IsReadOnly() bool
- func (group *SGroup) LinkedWithIdp(idpId string) bool
- func (group *SGroup) PerformAddUsers(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (group *SGroup) PerformJoin(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (group *SGroup) PerformLeave(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (group *SGroup) PerformRemoveUsers(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (group *SGroup) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (group *SGroup) UnlinkIdp(idpId string) error
- func (group *SGroup) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
- func (group *SGroup) ValidateUpdateCondition(ctx context.Context) error
- func (group *SGroup) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.GroupUpdateInput, error)
- type SGroupManager
- func (manager *SGroupManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.GroupDetails
- func (manager *SGroupManager) FetchGroupsInDomain(domainId string, excludes []string) ([]SGroup, error)
- func (manager *SGroupManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, ...) *sqlchemy.SQuery
- func (manager *SGroupManager) GetContextManagers() [][]db.IModelManager
- func (manager *SGroupManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SGroupManager) NamespaceScope() rbacscope.TRbacScope
- func (manager *SGroupManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SGroupManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SGroupManager) RegisterExternalGroup(ctx context.Context, idpId string, domainId string, groupId string, ...) (*SGroup, error)
- func (manager *SGroupManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.GroupCreateInput, error)
- type SGroupResourceBaseManager
- type SIdentityBaseResource
- func (model *SIdentityBaseResource) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (model *SIdentityBaseResource) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (model *SIdentityBaseResource) GetDomain() *SDomain
- func (model *SIdentityBaseResource) GetIIdentityModel() IIdentityModel
- func (model *SIdentityBaseResource) GetIIdentityModelManager() IIdentityModelManager
- func (model *SIdentityBaseResource) GetShortDesc(ctx context.Context) *jsonutils.JSONDict
- func (model *SIdentityBaseResource) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (model *SIdentityBaseResource) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
- func (model *SIdentityBaseResource) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (model *SIdentityBaseResource) RealDelete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (model *SIdentityBaseResource) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.IdentityBaseUpdateInput, error)
- type SIdentityBaseResourceManager
- func (manager *SIdentityBaseResourceManager) FetchByIdOrName(ctx context.Context, userCred mcclient.IIdentityProvider, idStr string) (db.IModel, error)
- func (manager *SIdentityBaseResourceManager) FetchByName(ctx context.Context, userCred mcclient.IIdentityProvider, idStr string) (db.IModel, error)
- func (manager *SIdentityBaseResourceManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.IdentityBaseResourceDetails
- func (manager *SIdentityBaseResourceManager) FilterBySystemAttributes(q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) *sqlchemy.SQuery
- func (manager *SIdentityBaseResourceManager) GetIIdentityModelManager() IIdentityModelManager
- func (manager *SIdentityBaseResourceManager) GetPropertyDomainTagValuePairs(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (manager *SIdentityBaseResourceManager) GetPropertyDomainTagValueTree(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (manager *SIdentityBaseResourceManager) ListItemExportKeys(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SIdentityBaseResourceManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SIdentityBaseResourceManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SIdentityBaseResourceManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SIdentityBaseResourceManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.IdentityBaseResourceCreateInput, error)
- type SIdentityProvider
- func (self *SIdentityProvider) CanSync() bool
- func (ident *SIdentityProvider) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (self *SIdentityProvider) CustomizeDelete(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (self *SIdentityProvider) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (self *SIdentityProvider) GetDetailsConfig(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (idp *SIdentityProvider) GetDetailsSamlMetadata(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.GetIdpSamlMetadataOutput, error)
- func (idp *SIdentityProvider) GetDetailsSsoCallbackUri(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.GetIdpSsoCallbackUriOutput, error)
- func (idp *SIdentityProvider) GetDetailsSsoRedirectUri(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.GetIdpSsoRedirectUriOutput, error)
- func (self *SIdentityProvider) GetDomainCount() (int, error)
- func (self *SIdentityProvider) GetGroupCount() (int, error)
- func (self *SIdentityProvider) GetPolicyCount() (int, error)
- func (self *SIdentityProvider) GetProjectCount() (int, error)
- func (self *SIdentityProvider) GetRoleCount() (int, error)
- func (self *SIdentityProvider) GetSingleDomain(ctx context.Context, extId string, extName string, extDesc string, ...) (*SDomain, error)
- func (self *SIdentityProvider) GetUserCount() (int, error)
- func (ident *SIdentityProvider) MarkConnected(ctx context.Context, userCred mcclient.TokenCredential) error
- func (ident *SIdentityProvider) MarkDisconnected(ctx context.Context, userCred mcclient.TokenCredential, reason error) error
- func (self *SIdentityProvider) NeedSync() bool
- func (ident *SIdentityProvider) PerformConfig(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (idp *SIdentityProvider) PerformDefaultSso(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (idp *SIdentityProvider) PerformDisable(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (idp *SIdentityProvider) PerformEnable(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (self *SIdentityProvider) PerformSync(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (ident *SIdentityProvider) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (self *SIdentityProvider) Purge(ctx context.Context, userCred mcclient.TokenCredential) error
- func (self *SIdentityProvider) RealDelete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (ident *SIdentityProvider) SetSyncStatus(ctx context.Context, userCred mcclient.TokenCredential, status string) error
- func (self *SIdentityProvider) SyncOrCreateDomain(ctx context.Context, extId string, extName string, extDesc string, ...) (*SDomain, error)
- func (idp *SIdentityProvider) SyncOrCreateDomainAndUser(ctx context.Context, extDomainId, extDomainName string, ...) (*SDomain, *SUser, error)
- func (self *SIdentityProvider) SyncOrCreateUser(ctx context.Context, extId string, extName string, domainId string, ...) (*SUser, error)
- func (idp *SIdentityProvider) TryUserJoinProject(attrConf api.SIdpAttributeOptions, ctx context.Context, usr *SUser, ...)
- func (self *SIdentityProvider) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
- func (self *SIdentityProvider) ValidateUpdateCondition(ctx context.Context) error
- func (self *SIdentityProvider) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.IdentityProviderUpdateInput, error)
- type SIdentityProviderManager
- func (manager *SIdentityProviderManager) CheckUniqueness(extIdpId string, domainId string, driver string, template string, group string, ...) (bool, error)
- func (manager *SIdentityProviderManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.IdentityProviderDetails
- func (manager *SIdentityProviderManager) FetchEnabledProviders(driver string) ([]SIdentityProvider, error)
- func (manager *SIdentityProviderManager) FetchIdentityProviderById(idstr string) (*SIdentityProvider, error)
- func (manager *SIdentityProviderManager) FetchIdentityProvidersByUserId(uid string, drivers []string) ([]SIdentityProvider, error)
- func (manager *SIdentityProviderManager) FetchPasswordProtectedIdpIdsQuery() *sqlchemy.SSubQuery
- func (manager *SIdentityProviderManager) InitializeData() error
- func (manager *SIdentityProviderManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SIdentityProviderManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SIdentityProviderManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SIdentityProviderManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.IdentityProviderCreateInput, error)
- type SIdentityQuota
- func (self *SIdentityQuota) Add(quota quotas.IQuota)
- func (self *SIdentityQuota) Allocable(request quotas.IQuota) int
- func (used *SIdentityQuota) Exceed(request quotas.IQuota, quota quotas.IQuota) error
- func (self *SIdentityQuota) FetchSystemQuota()
- func (self *SIdentityQuota) FetchUsage(ctx context.Context) error
- func (self *SIdentityQuota) GetKeys() quotas.IQuotaKeys
- func (self *SIdentityQuota) IsEmpty() bool
- func (self *SIdentityQuota) ResetNegative()
- func (self *SIdentityQuota) SetKeys(keys quotas.IQuotaKeys)
- func (self *SIdentityQuota) Sub(quota quotas.IQuota)
- func (self *SIdentityQuota) ToJSON(prefix string) jsonutils.JSONObject
- func (self *SIdentityQuota) Update(quota quotas.IQuota)
- type SIdentityQuotaDetail
- type SIdmapping
- type SIdmappingManager
- func (manager *SIdmappingManager) FetchByIdpAndEntityId(ctx context.Context, idpId string, entityId string, entityType string) (string, error)
- func (manager *SIdmappingManager) FetchEntities(idStr string, entType string) ([]SIdmapping, error)
- func (manager *SIdmappingManager) FetchFirstEntity(idStr string, entType string) (*SIdmapping, error)
- func (manager *SIdmappingManager) FetchPublicIdsExcludes(idpId string, entityType string, excludes []string) ([]string, error)
- func (manager *SIdmappingManager) FetchPublicIdsExcludesQuery(idpId string, entityType string, excludes []string) *sqlchemy.SQuery
- func (manager *SIdmappingManager) RegisterIdMap(ctx context.Context, idpId string, entityId string, entityType string) (string, error)
- func (manager *SIdmappingManager) RegisterIdMapWithId(ctx context.Context, idpId string, entityId string, entityType string, ...) (string, error)
- type SIdpRemoteIds
- type SIdpRemoteIdsManager
- type SImpliedRole
- type SImpliedRoleManager
- type SLocalUser
- type SLocalUserManager
- type SNonlocalUser
- type SNonlocalUserManager
- type SOrganization
- func (org *SOrganization) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (org *SOrganization) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (org *SOrganization) GetKeys() []string
- func (org *SOrganization) GetShortDesc(ctx context.Context) *jsonutils.JSONDict
- func (org *SOrganization) PerformAddLevel(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (org *SOrganization) PerformAddNode(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (org *SOrganization) PerformClean(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (org *SOrganization) PerformDisable(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (org *SOrganization) PerformEnable(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (org *SOrganization) PerformSync(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (org *SOrganization) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (org *SOrganization) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (org *SOrganization) SetStatus(ctx context.Context, userCred mcclient.TokenCredential, status string, ...) error
- func (org *SOrganization) SyncTags(ctx context.Context, userCred mcclient.TokenCredential, resourceType string) error
- func (org *SOrganization) ValidateDeleteCondition(ctx context.Context, info *api.ProjectDetails) error
- func (org *SOrganization) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.OrganizationUpdateInput, error)
- type SOrganizationManager
- func (manager *SOrganizationManager) ExtendListQuery(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SOrganizationManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.SOrganizationDetails
- func (manager *SOrganizationManager) FetchOrgnaizations(filter func(q *sqlchemy.SQuery) *sqlchemy.SQuery) ([]SOrganization, error)
- func (manager *SOrganizationManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SOrganizationManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SOrganizationManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SOrganizationManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.OrganizationCreateInput, error)
- type SOrganizationNode
- func (orgNode *SOrganizationNode) BindTargetIds(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (orgNode *SOrganizationNode) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (orgNode *SOrganizationNode) GetChildCount() (int, error)
- func (orgNode *SOrganizationNode) GetDirectChildCount() (int, error)
- func (orgNode *SOrganizationNode) GetOrganization() (*SOrganization, error)
- func (orgNode *SOrganizationNode) GetShortDesc(ctx context.Context) *jsonutils.JSONDict
- func (orgNode *SOrganizationNode) GetTagSet(org *SOrganization) tagutils.TTagSet
- func (orgNode *SOrganizationNode) GetTags(org *SOrganization) map[string]string
- func (orgNode *SOrganizationNode) PerformBind(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (orgNode *SOrganizationNode) PerformUnbind(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (orgNode *SOrganizationNode) ValidateDeleteCondition(ctx context.Context, info *api.ProjectDetails) error
- func (orgNode *SOrganizationNode) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.OrganizationNodeUpdateInput, error)
- type SOrganizationNodeManager
- func (manager *SOrganizationNodeManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.SOrganizationNodeDetails
- func (manager *SOrganizationNodeManager) FilterBySystemAttributes(q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) *sqlchemy.SQuery
- func (manager *SOrganizationNodeManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SOrganizationNodeManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SOrganizationNodeManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- type SPassword
- type SPasswordManager
- type SPolicy
- func (policy *SPolicy) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (policy *SPolicy) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (policy *SPolicy) GetChangeOwnerCandidateDomainIds() []string
- func (policy *SPolicy) GetI18N(ctx context.Context) *jsonutils.JSONDict
- func (policy *SPolicy) GetRequiredSharedDomainIds() []string
- func (policy *SPolicy) GetSharableTargetDomainIds() []string
- func (policy *SPolicy) GetSharedDomains() []string
- func (policy *SPolicy) GetUsages() []db.IUsage
- func (policy *SPolicy) IsSharable(reqUsrId mcclient.IIdentityProvider) bool
- func (policy *SPolicy) IsShared() bool
- func (policy *SPolicy) PerformBindRole(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (policy *SPolicy) PerformPrivate(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (policy *SPolicy) PerformPublic(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (policy *SPolicy) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (policy *SPolicy) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
- func (policy *SPolicy) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (policy *SPolicy) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
- func (policy *SPolicy) ValidateUpdateCondition(ctx context.Context) error
- func (policy *SPolicy) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.PolicyUpdateInput, error)
- type SPolicyManager
- func (manager *SPolicyManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.PolicyDetails
- func (manager *SPolicyManager) FetchEnabledPolicies() ([]SPolicy, error)
- func (manager *SPolicyManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, ...) *sqlchemy.SQuery
- func (manager *SPolicyManager) InitializeData() error
- func (manager *SPolicyManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SPolicyManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SPolicyManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SPolicyManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.PolicyCreateInput, error)
- type SProject
- func (model *SProject) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (proj *SProject) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (proj *SProject) FetchExtend() (*SProjectExtended, error)
- func (self *SProject) GetEmptyProjects() ([]SProject, error)
- func (proj *SProject) GetGroupCount() (int, error)
- func (project *SProject) GetUsages() []db.IUsage
- func (proj *SProject) GetUserCount() (int, error)
- func (proj *SProject) IsAdminProject() bool
- func (project *SProject) PerformJoin(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (project *SProject) PerformLeave(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (project *SProject) PerformSetAdmin(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (project *SProject) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (self *SProject) StartProjectCleanTask(ctx context.Context, userCred mcclient.TokenCredential) error
- func (proj *SProject) ValidateDeleteCondition(ctx context.Context, info *api.ProjectDetails) error
- func (proj *SProject) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.ProjectUpdateInput, error)
- type SProjectExtended
- type SProjectManager
- func (manager *SProjectManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.ProjectDetails
- func (manager *SProjectManager) FetchProject(projectId, projectName string, domainId, domainName string) (*SProject, error)
- func (manager *SProjectManager) FetchProjectById(projectId string) (*SProject, error)
- func (manager *SProjectManager) FetchProjectByName(projectName string, domainId, domainName string) (*SProject, error)
- func (manager *SProjectManager) FetchUserProjects(userId string) ([]SProjectExtended, error)
- func (manager *SProjectManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, ...) *sqlchemy.SQuery
- func (manager *SProjectManager) GetContextManagers() [][]db.IModelManager
- func (manager *SProjectManager) GetSystemProject() (*SProject, error)
- func (manager *SProjectManager) InitializeData() error
- func (manager *SProjectManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SProjectManager) NewProject(ctx context.Context, projectName string, desc string, domainId string) (*SProject, error)
- func (manager *SProjectManager) NewQuery(ctx context.Context, userCred mcclient.TokenCredential, ...) *sqlchemy.SQuery
- func (manager *SProjectManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SProjectManager) PerformClean(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (manager *SProjectManager) Query(fields ...string) *sqlchemy.SQuery
- func (manager *SProjectManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SProjectManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.ProjectCreateInput, error)
- type SProjectResourceBaseManager
- type SQuotaManager
- type SRegion
- type SRegionManager
- func (manager *SRegionManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.RegionDetails
- func (manager *SRegionManager) InitializeData() error
- func (manager *SRegionManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SRegionManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SRegionManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SRegionManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (*jsonutils.JSONDict, error)
- type SRegionResourceBaseManager
- type SRole
- func (role *SRole) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ...) error
- func (role *SRole) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (role *SRole) DeleteInContext(ctx context.Context, userCred mcclient.TokenCredential, ctxObjs []db.IModel, ...) (jsonutils.JSONObject, error)
- func (role *SRole) GetChangeOwnerCandidateDomainIds() []string
- func (role *SRole) GetGroupCount() (int, error)
- func (role *SRole) GetI18N(ctx context.Context) *jsonutils.JSONDict
- func (role *SRole) GetProjectCount() (int, error)
- func (role *SRole) GetRequiredSharedDomainIds() []string
- func (role *SRole) GetSharableTargetDomainIds() []string
- func (role *SRole) GetSharedDomains() []string
- func (role *SRole) GetUsages() []db.IUsage
- func (role *SRole) GetUserCount() (int, error)
- func (role *SRole) IsSharable(reqUsrId mcclient.IIdentityProvider) bool
- func (role *SRole) IsShared() bool
- func (role *SRole) IsSystemRole() bool
- func (role *SRole) PerformAddPolicy(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (role *SRole) PerformPrivate(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (role *SRole) PerformPublic(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (role *SRole) PerformRemovePolicy(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (role *SRole) PerformSetPolicies(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (role *SRole) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (role *SRole) UpdateInContext(ctx context.Context, userCred mcclient.TokenCredential, ctxObjs []db.IModel, ...) (jsonutils.JSONObject, error)
- func (role *SRole) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
- func (role *SRole) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.RoleUpdateInput, error)
- type SRoleManager
- func (manager *SRoleManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.RoleDetails
- func (manager *SRoleManager) FetchRole(roleId, roleName string, domainId, domainName string) (*SRole, error)
- func (manager *SRoleManager) FetchRoleById(roleId string) (*SRole, error)
- func (manager *SRoleManager) FetchRoleByName(roleName string, domainId, domainName string) (*SRole, error)
- func (manager *SRoleManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, ...) *sqlchemy.SQuery
- func (manager *SRoleManager) GetContextManagers() [][]db.IModelManager
- func (manager *SRoleManager) InitializeData() error
- func (manager *SRoleManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SRoleManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SRoleManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SRoleManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.RoleCreateInput, error)
- type SRolePolicy
- func (rp *SRolePolicy) GetId() string
- func (rp *SRolePolicy) GetName() string
- func (rp *SRolePolicy) GetPolicy() *SPolicy
- func (rp *SRolePolicy) GetProject() *SProject
- func (rp *SRolePolicy) GetRole() *SRole
- func (rp *SRolePolicy) MatchIP(ipstr string) bool
- func (rp *SRolePolicy) MatchTime(tm time.Time) bool
- type SRolePolicyManager
- func (manager *SRolePolicyManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.RolePolicyDetails
- func (manager *SRolePolicyManager) FilterById(q *sqlchemy.SQuery, idStr string) *sqlchemy.SQuery
- func (manager *SRolePolicyManager) FilterByName(q *sqlchemy.SQuery, name string) *sqlchemy.SQuery
- func (manager *SRolePolicyManager) FilterByNotId(q *sqlchemy.SQuery, idStr string) *sqlchemy.SQuery
- func (manager *SRolePolicyManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, ...) *sqlchemy.SQuery
- func (manager *SRolePolicyManager) GetMatchPolicyGroup(userCred rbacutils.IRbacIdentity, tm time.Time, nameOnly bool) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
- func (manager *SRolePolicyManager) GetMatchPolicyGroup2(isGuest bool, roleIds []string, pid string, loginIp string, tm time.Time, ...) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
- func (manager *SRolePolicyManager) GetMatchPolicyGroupByCred(ctx context.Context, userCred api.IRbacIdentityWithUserId, tm time.Time, ...) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
- func (manager *SRolePolicyManager) GetMatchPolicyGroupByInput(ctx context.Context, userId, projectId string, tm time.Time, nameOnly bool) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
- func (manager *SRolePolicyManager) GetPolicyGroupByIds(policyIds []string, nameOnly bool) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
- func (manager *SRolePolicyManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SRolePolicyManager) NamespaceScope() rbacscope.TRbacScope
- func (manager *SRolePolicyManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SRolePolicyManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- type SRoleResourceBaseManager
- type SScopeResource
- type SScopeResourceManager
- type SService
- func (service *SService) GetDetailsConfig(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (service *SService) GetEndpointCount() (int, error)
- func (service *SService) PerformConfig(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (service *SService) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (service *SService) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
- func (service *SService) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (service *SService) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
- type SServiceCatalog
- type SServiceCertificate
- type SServiceCertificateManager
- type SServiceManager
- func (manager *SServiceManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.ServiceDetails
- func (manager *SServiceManager) InitializeData() error
- func (manager *SServiceManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SServiceManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SServiceManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- type SServiceResourceBaseManager
- type STokenCache
- type STokenCacheManager
- func (manager *STokenCacheManager) BatchInvalidate(ctx context.Context, userCred mcclient.TokenCredential, method string, ...) error
- func (manager *STokenCacheManager) BatchInvalidateByUserId(ctx context.Context, userCred mcclient.TokenCredential, uid string) error
- func (manager *STokenCacheManager) FetchInvalidTokens() ([]string, error)
- func (manager *STokenCacheManager) FetchToken(tokenStr string) (*STokenCache, error)
- func (manager *STokenCacheManager) Invalidate(ctx context.Context, userCred mcclient.TokenCredential, tokenStr string) error
- func (manager *STokenCacheManager) Save(ctx context.Context, tokenStr string, expiredAt time.Time, method string, ...) error
- type SUser
- func (user *SUser) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
- func (user *SUser) DeleteInContext(ctx context.Context, userCred mcclient.TokenCredential, ctxObjs []db.IModel, ...) (jsonutils.JSONObject, error)
- func (user *SUser) GetCredentialCount() (int, error)
- func (user *SUser) GetGroupCount() (int, error)
- func (user *SUser) GetProjectCount() (int, error)
- func (user *SUser) GetUsages() []db.IUsage
- func (user *SUser) IsAdminUser() bool
- func (user *SUser) IsLocal() bool
- func (user *SUser) LinkedWithIdp(idpId string) bool
- func (user *SUser) PerformDisable(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (user *SUser) PerformEnable(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (user *SUser) PerformJoin(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (user *SUser) PerformLeave(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (user *SUser) PerformLinkIdp(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (user *SUser) PerformResetCredentials(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (user *SUser) PerformUnlinkIdp(ctx context.Context, userCred mcclient.TokenCredential, ...) (jsonutils.JSONObject, error)
- func (user *SUser) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (user *SUser) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, ...)
- func (user *SUser) UnlinkIdp(idpId string) error
- func (user *SUser) UpdateInContext(ctx context.Context, userCred mcclient.TokenCredential, ctxObjs []db.IModel, ...) (jsonutils.JSONObject, error)
- func (user *SUser) ValidateDeleteCondition(ctx context.Context, info *api.UserDetails) error
- func (user *SUser) ValidateUpdateCondition(ctx context.Context) error
- func (user *SUser) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.UserUpdateInput, error)
- type SUserManager
- func (manager *SUserManager) FetchCustomizeColumns(ctx context.Context, userCred mcclient.TokenCredential, ...) []api.UserDetails
- func (manager *SUserManager) FetchScopeResources(userIds []string) (map[string]api.ExternalResourceInfo, error)
- func (manager *SUserManager) FetchUserExtended(userId, userName, domainId, domainName string) (*api.SUserExtended, error)
- func (manager *SUserManager) FetchUsersInDomain(domainId string, excludes []string) ([]SUser, error)
- func (manager *SUserManager) FilterByHiddenSystemAttributes(q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) *sqlchemy.SQuery
- func (manager *SUserManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, ...) *sqlchemy.SQuery
- func (manager *SUserManager) GetContextManagers() [][]db.IModelManager
- func (manager *SUserManager) InitializeData() error
- func (manager *SUserManager) ListItemFilter(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SUserManager) LockUser(uid string, reason string) error
- func (manager *SUserManager) NamespaceScope() rbacscope.TRbacScope
- func (manager *SUserManager) OrderByExtraFields(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, ...) (*sqlchemy.SQuery, error)
- func (manager *SUserManager) QueryDistinctExtraField(q *sqlchemy.SQuery, field string) (*sqlchemy.SQuery, error)
- func (manager *SUserManager) TotalResourceCount(userIds []string) (map[string]api.UserUsage, error)
- func (manager *SUserManager) TraceLoginV2(ctx context.Context, token *mcclient.TokenCredentialV2)
- func (manager *SUserManager) TraceLoginV3(ctx context.Context, token *mcclient.TokenCredentialV3)
- func (manager *SUserManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ...) (api.UserCreateInput, error)
- type SUserOption
- type SUserOptionManager
- type SUserResourceBaseManager
- type SUserUsageCount
- type SUsergroupManager
- type SUsergroupMembership
- type SetIdentityQuotaInput
- type TConfigOptions
Constants ¶
const (
ROLE_DEFAULT_DOMAIN_ID = "<<null>>"
)
Variables ¶
var ( IdentityQuota SIdentityQuota IdentityQuotaManager *SQuotaManager IdentityUsageManager *SQuotaManager IdentityPendingUsageManager *SQuotaManager )
Functions ¶
func AddAdhocHandlers ¶
func AddAdhocHandlers(version string, app *appsrv.Application)
func AutoSyncIdentityProviderTask ¶
func AutoSyncIdentityProviderTask(ctx context.Context, userCred mcclient.TokenCredential, isStart bool)
func CheckAllUserPasswordIsExpired ¶
func CheckAllUserPasswordIsExpired(ctx context.Context, userCred mcclient.TokenCredential, startRun bool)
定时任务判断用户是否需要密码过期通知
func GetConfigs ¶
func GetDefaultAdminCred ¶
func GetDefaultAdminCred() mcclient.TokenCredential
func GetDefaultClient ¶
func GetDefaultClientSession ¶
func GetDefaultClientSession(ctx context.Context, token mcclient.TokenCredential, region string) *mcclient.ClientSession
func InitSyncWorkers ¶
func InitSyncWorkers()
func NewServiceConfigSession ¶
func NewServiceConfigSession() common_options.IServiceConfigSession
func NormalizeProjectName ¶
func RemoveObsoleteInvalidTokens ¶
func RemoveObsoleteInvalidTokens(ctx context.Context, userCred mcclient.TokenCredential, start bool)
func ValidateJoinProjectRoles ¶
func ValidateJoinProjectRoles(userCred mcclient.TokenCredential, projectId string, roleIds []string) error
func VerifyPassword ¶
func VerifyPassword(user *api.SUserExtended, passwd string) error
Types ¶
type IEnabledIdentityModel ¶
type IEnabledIdentityModel interface { IIdentityModel db.IEnabledBaseInterface GetIEnabledIdentityModelManager() IEnabledIdentityModelManager GetIEnabledIdentityModel() IEnabledIdentityModel }
type IEnabledIdentityModelManager ¶
type IEnabledIdentityModelManager interface { IIdentityModelManager GetIEnabledIdentityModelManager() IEnabledIdentityModelManager }
type IIdentityModel ¶
type IIdentityModel interface { db.IStandaloneModel db.IPendingDeletable GetDomain() *SDomain GetIIdentityModelManager() IIdentityModelManager GetIIdentityModel() IIdentityModel }
type IIdentityModelManager ¶
type IIdentityModelManager interface { db.IStandaloneModelManager GetIIdentityModelManager() IIdentityModelManager }
+onecloud:swagger-gen-ignore
type SAssignment ¶
type SAssignment struct { db.SResourceBase // 关联类型,分为四类:'UserProject','GroupProject','UserDomain','GroupDomain' Type string `width:"16" charset:"ascii" nullable:"false" primary:"true" list:"admin"` // 用户或者用户组ID ActorId string `width:"64" charset:"ascii" nullable:"false" primary:"true" list:"admin"` // 项目或者域ID TargetId string `width:"64" charset:"ascii" nullable:"false" primary:"true" list:"admin"` // 角色ID RoleId string `width:"64" charset:"ascii" nullable:"false" primary:"true" list:"admin"` Inherited tristate.TriState `primary:"true" list:"admin"` }
type SAssignmentManager ¶
type SAssignmentManager struct {
db.SResourceBaseManager
}
+onecloud:swagger-gen-ignore
var AssignmentManager *SAssignmentManager
func (*SAssignmentManager) FetchAll ¶
func (manager *SAssignmentManager) FetchAll( userId, groupId, roleId, domainId, projectId string, projectDomainId string, userStrs, groupStrs, roleStrs, domainStrs, projectStrs, projectDomainStrs []string, includeNames, effective, includeSub, includeSystem, includePolicies bool, limit, offset int) ([]api.SRoleAssignment, int64, error)
func (*SAssignmentManager) FetchUserProjectRoles ¶
func (manager *SAssignmentManager) FetchUserProjectRoles(userId, projId string) ([]SRole, error)
func (*SAssignmentManager) InitializeData ¶
func (manager *SAssignmentManager) InitializeData() error
func (*SAssignmentManager) ProjectAddUser ¶
func (manager *SAssignmentManager) ProjectAddUser(ctx context.Context, userCred mcclient.TokenCredential, project *SProject, user *SUser, role *SRole) error
type SConfigOption ¶
type SConfigOption struct { db.SResourceBase db.SRecordChecksumResourceBase ResType string `width:"32" charset:"ascii" nullable:"false" default:"identity_provider" primary:"true"` ResId string `name:"domain_id" width:"64" charset:"ascii" primary:"true"` Group string `width:"191" charset:"utf8" primary:"true"` Option string `width:"191" charset:"utf8" primary:"true"` Value jsonutils.JSONObject `nullable:"false"` }
type SConfigOptionManager ¶
type SConfigOptionManager struct { db.SResourceBaseManager db.SRecordChecksumResourceBaseManager IsSensitive bool }
+onecloud:swagger-gen-ignore
var ( SensitiveConfigManager *SConfigOptionManager WhitelistedConfigManager *SConfigOptionManager )
type SCredential ¶
type SCredential struct { db.SStandaloneResourceBase UserId string `width:"64" charset:"ascii" nullable:"false" list:"user" create:"required"` ProjectId string `width:"64" charset:"ascii" nullable:"true" list:"user" create:"required"` Type string `width:"255" charset:"utf8" nullable:"false" list:"user" create:"required"` KeyHash string `width:"64" charset:"ascii" nullable:"false" create:"required"` Extra *jsonutils.JSONDict `nullable:"true" list:"admin"` EncryptedBlob string `nullable:"false" create:"required"` Enabled tristate.TriState `default:"true" list:"user" update:"user" create:"optional"` }
func (*SCredential) Delete ¶
func (cred *SCredential) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
func (*SCredential) GetAccessKeySecret ¶
func (cred *SCredential) GetAccessKeySecret() (*api.SAccessKeySecretBlob, error)
func (*SCredential) GetOwnerId ¶
func (cred *SCredential) GetOwnerId() mcclient.IIdentityProvider
func (*SCredential) ValidateDeleteCondition ¶
func (cred *SCredential) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
func (*SCredential) ValidateUpdateData ¶
func (cred *SCredential) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.CredentialUpdateInput) (api.CredentialUpdateInput, error)
type SCredentialManager ¶
type SCredentialManager struct { db.SStandaloneResourceBaseManager SUserResourceBaseManager SProjectResourceBaseManager }
var CredentialManager *SCredentialManager
func (*SCredentialManager) DeleteAll ¶
func (manager *SCredentialManager) DeleteAll(ctx context.Context, userCred mcclient.TokenCredential, uid string, credType string) error
func (*SCredentialManager) FetchCredentials ¶
func (manager *SCredentialManager) FetchCredentials(uid string, credType string) ([]SCredential, error)
func (*SCredentialManager) FetchCustomizeColumns ¶
func (manager *SCredentialManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.CredentialDetails
func (*SCredentialManager) FetchOwnerId ¶
func (manager *SCredentialManager) FetchOwnerId(ctx context.Context, data jsonutils.JSONObject) (mcclient.IIdentityProvider, error)
func (*SCredentialManager) FilterByOwner ¶
func (manager *SCredentialManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, userCred mcclient.TokenCredential, owner mcclient.IIdentityProvider, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SCredentialManager) InitializeData ¶
func (manager *SCredentialManager) InitializeData() error
func (*SCredentialManager) ListItemFilter ¶
func (manager *SCredentialManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.CredentialListInput, ) (*sqlchemy.SQuery, error)
用户信用凭证列表
func (*SCredentialManager) OrderByExtraFields ¶
func (manager *SCredentialManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.CredentialListInput, ) (*sqlchemy.SQuery, error)
func (*SCredentialManager) QueryDistinctExtraField ¶
func (*SCredentialManager) ResourceScope ¶
func (manager *SCredentialManager) ResourceScope() rbacscope.TRbacScope
func (*SCredentialManager) ValidateCreateData ¶
func (manager *SCredentialManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.CredentialCreateInput, ) (api.CredentialCreateInput, error)
type SDomain ¶
type SDomain struct { db.SStandaloneResourceBase db.SPendingDeletedBase // 额外信息 Extra *jsonutils.JSONDict `nullable:"true"` // 改域是否启用 Enabled tristate.TriState `default:"true" list:"admin" update:"admin" create:"admin_optional"` // 是否为域 IsDomain tristate.TriState `default:"false"` DomainId string `width:"64" charset:"ascii" default:"default" nullable:"false" index:"true"` ParentId string `width:"64" charset:"ascii"` AdminId string `width:"64" charset:"ascii" nullable:"true"` }
func (*SDomain) CustomizeCreate ¶
func (domain *SDomain) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject) error
func (*SDomain) DeleteUserGroups ¶
func (*SDomain) GetGroupCount ¶
func (*SDomain) GetIdpCount ¶
func (*SDomain) GetPolicyCount ¶
func (*SDomain) GetProjectCount ¶
func (*SDomain) GetRoleCount ¶
func (*SDomain) GetUserCount ¶
func (*SDomain) IsReadOnly ¶
func (*SDomain) PerformUnlinkIdp ¶
func (domain *SDomain) PerformUnlinkIdp( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.UserUnlinkIdpInput, ) (jsonutils.JSONObject, error)
domain和IDP的指定entityId解除关联
func (*SDomain) PostCreate ¶
func (domain *SDomain) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SDomain) PostDelete ¶
func (domain *SDomain) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
func (*SDomain) PostUpdate ¶
func (domain *SDomain) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SDomain) ValidateDeleteCondition ¶
func (*SDomain) ValidateUpdateCondition ¶
func (*SDomain) ValidateUpdateData ¶
func (domain *SDomain) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.DomainUpdateInput) (api.DomainUpdateInput, error)
type SDomainManager ¶
type SDomainManager struct { db.SStandaloneResourceBaseManager db.SPendingDeletedBaseManager }
var (
DomainManager *SDomainManager
)
func (*SDomainManager) FetchCustomizeColumns ¶
func (manager *SDomainManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.DomainDetails
func (*SDomainManager) FetchDomain ¶
func (manager *SDomainManager) FetchDomain(domainId string, domainName string) (*SDomain, error)
func (*SDomainManager) FetchDomainById ¶
func (manager *SDomainManager) FetchDomainById(domainId string) (*SDomain, error)
func (*SDomainManager) FetchDomainByIdOrName ¶
func (manager *SDomainManager) FetchDomainByIdOrName(domain string) (*SDomain, error)
func (*SDomainManager) FetchDomainByName ¶
func (manager *SDomainManager) FetchDomainByName(domainName string) (*SDomain, error)
func (*SDomainManager) FilterByOwner ¶
func (manager *SDomainManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, userCred mcclient.TokenCredential, owner mcclient.IIdentityProvider, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SDomainManager) FilterBySystemAttributes ¶
func (manager *SDomainManager) FilterBySystemAttributes(q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query jsonutils.JSONObject, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SDomainManager) InitializeData ¶
func (manager *SDomainManager) InitializeData() error
func (*SDomainManager) ListItemFilter ¶
func (manager *SDomainManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.DomainListInput, ) (*sqlchemy.SQuery, error)
域列表
func (*SDomainManager) NewQuery ¶
func (manager *SDomainManager) NewQuery(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, useRawQuery bool) *sqlchemy.SQuery
func (*SDomainManager) OrderByExtraFields ¶
func (manager *SDomainManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.DomainListInput, ) (*sqlchemy.SQuery, error)
func (*SDomainManager) Query ¶
func (manager *SDomainManager) Query(fields ...string) *sqlchemy.SQuery
func (*SDomainManager) QueryDistinctExtraField ¶
func (*SDomainManager) TotalResourceCount ¶
func (manager *SDomainManager) TotalResourceCount(domainIds []string) (map[string]api.DomainUsage, error)
func (*SDomainManager) ValidateCreateData ¶
func (manager *SDomainManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.DomainCreateInput, ) (api.DomainCreateInput, error)
type SDomainUsageCount ¶
type SDomainUsageCount struct { Id string api.DomainUsage }
type SEnabledIdentityBaseResource ¶
type SEnabledIdentityBaseResource struct { SIdentityBaseResource db.SEnabledResourceBase `"enabled->default":"true" "enabled->list":"user" "enabled->update":"domain" "enabled->create":"domain_optional"` }
func (*SEnabledIdentityBaseResource) GetIEnabledIdentityModel ¶
func (model *SEnabledIdentityBaseResource) GetIEnabledIdentityModel() IEnabledIdentityModel
func (*SEnabledIdentityBaseResource) GetIEnabledIdentityModelManager ¶
func (model *SEnabledIdentityBaseResource) GetIEnabledIdentityModelManager() IEnabledIdentityModelManager
func (*SEnabledIdentityBaseResource) GetShortDesc ¶
func (model *SEnabledIdentityBaseResource) GetShortDesc(ctx context.Context) *jsonutils.JSONDict
func (*SEnabledIdentityBaseResource) PerformDisable ¶
func (model *SEnabledIdentityBaseResource) PerformDisable(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformDisableInput) (jsonutils.JSONObject, error)
禁用资源
func (*SEnabledIdentityBaseResource) PerformEnable ¶
func (model *SEnabledIdentityBaseResource) PerformEnable(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformEnableInput) (jsonutils.JSONObject, error)
启用资源
func (*SEnabledIdentityBaseResource) ValidateDeleteCondition ¶
func (ident *SEnabledIdentityBaseResource) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
func (*SEnabledIdentityBaseResource) ValidateUpdateData ¶
func (model *SEnabledIdentityBaseResource) ValidateUpdateData( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.EnabledIdentityBaseUpdateInput, ) (api.EnabledIdentityBaseUpdateInput, error)
type SEnabledIdentityBaseResourceManager ¶
type SEnabledIdentityBaseResourceManager struct { SIdentityBaseResourceManager db.SEnabledResourceBaseManager }
+onecloud:swagger-gen-ignore
func NewEnabledIdentityBaseResourceManager ¶
func NewEnabledIdentityBaseResourceManager(dt interface{}, tableName string, keyword string, keywordPlural string) SEnabledIdentityBaseResourceManager
func (*SEnabledIdentityBaseResourceManager) FetchCustomizeColumns ¶
func (manager *SEnabledIdentityBaseResourceManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.EnabledIdentityBaseResourceDetails
func (*SEnabledIdentityBaseResourceManager) GetIEnabledIdentityModelManager ¶
func (manager *SEnabledIdentityBaseResourceManager) GetIEnabledIdentityModelManager() IEnabledIdentityModelManager
func (*SEnabledIdentityBaseResourceManager) ListItemFilter ¶
func (manager *SEnabledIdentityBaseResourceManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.EnabledIdentityBaseResourceListInput, ) (*sqlchemy.SQuery, error)
func (*SEnabledIdentityBaseResourceManager) OrderByExtraFields ¶
func (manager *SEnabledIdentityBaseResourceManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.EnabledIdentityBaseResourceListInput, ) (*sqlchemy.SQuery, error)
func (*SEnabledIdentityBaseResourceManager) QueryDistinctExtraField ¶
func (*SEnabledIdentityBaseResourceManager) ValidateCreateData ¶
func (manager *SEnabledIdentityBaseResourceManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.EnabledIdentityBaseResourceCreateInput) (api.EnabledIdentityBaseResourceCreateInput, error)
type SEndpoint ¶
type SEndpoint struct { db.SStandaloneResourceBase LegacyEndpointId string `width:"64" charset:"ascii" nullable:"true"` Interface string `width:"8" charset:"ascii" nullable:"false" list:"admin" create:"admin_required"` ServiceId string `width:"64" charset:"ascii" nullable:"false" list:"admin" create:"admin_required"` Url string `charset:"utf8" nullable:"false" list:"admin" update:"admin" create:"admin_required"` Extra *jsonutils.JSONDict `nullable:"true"` Enabled tristate.TriState `default:"true" list:"admin" update:"admin" create:"admin_optional"` RegionId string `width:"255" charset:"utf8" nullable:"true" list:"admin" create:"admin_required"` ServiceCertificateId string `nullable:"true" create:"admin_optional" update:"admin"` }
func (*SEndpoint) PostCreate ¶
func (endpoint *SEndpoint) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SEndpoint) PostDelete ¶
func (endpoint *SEndpoint) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
func (*SEndpoint) PostUpdate ¶
func (endpoint *SEndpoint) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SEndpoint) ValidateDeleteCondition ¶
func (*SEndpoint) ValidateUpdateData ¶
type SEndpointExtended ¶
type SEndpointManager ¶
type SEndpointManager struct { db.SStandaloneResourceBaseManager SServiceResourceBaseManager SRegionResourceBaseManager // contains filtered or unexported fields }
var EndpointManager *SEndpointManager
func (*SEndpointManager) FetchAll ¶
func (manager *SEndpointManager) FetchAll() (SServiceCatalog, error)
func (*SEndpointManager) FetchCustomizeColumns ¶
func (manager *SEndpointManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.EndpointDetails
func (*SEndpointManager) InitializeData ¶
func (manager *SEndpointManager) InitializeData() error
func (*SEndpointManager) IsEtcdInformerBackend ¶
func (manager *SEndpointManager) IsEtcdInformerBackend(ep *SEndpoint) bool
func (*SEndpointManager) ListItemFilter ¶
func (manager *SEndpointManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.EndpointListInput, ) (*sqlchemy.SQuery, error)
服务地址列表
func (*SEndpointManager) OrderByExtraFields ¶
func (manager *SEndpointManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.EndpointListInput, ) (*sqlchemy.SQuery, error)
func (*SEndpointManager) QueryDistinctExtraField ¶
func (*SEndpointManager) SetEtcdInformerBackend ¶
func (manager *SEndpointManager) SetEtcdInformerBackend(ep *SEndpoint) error
func (*SEndpointManager) SetInformerBackend ¶
func (manager *SEndpointManager) SetInformerBackend() error
func (*SEndpointManager) SetInformerBackendByEndpoint ¶
func (manager *SEndpointManager) SetInformerBackendByEndpoint(ep *SEndpoint)
func (*SEndpointManager) SetInformerBackendUntilSuccess ¶
func (manager *SEndpointManager) SetInformerBackendUntilSuccess(ep *SEndpoint)
func (*SEndpointManager) ValidateCreateData ¶
func (manager *SEndpointManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data *jsonutils.JSONDict, ) (*jsonutils.JSONDict, error)
type SFederatedUser ¶
type SFederatedUser struct { db.SResourceBase Id int `nullable:"false" primary:"true" auto_increment:"true"` UserId string `width:"64" charset:"ascii" nullable:"false" index:"true"` IdpId string `width:"64" charset:"ascii" nullable:"false" index:"true"` ProtocolId string `width:"64" charset:"ascii" nullable:"false" index:"true"` UniqueId string `width:"255" charset:"ascii" nullable:"false"` DisplayName string `width:"255" charset:"utf8" nullable:"true"` }
type SFederatedUserManager ¶
type SFederatedUserManager struct {
db.SResourceBaseManager
}
+onecloud:swagger-gen-ignore
var (
FederatedUserManager *SFederatedUserManager
)
type SFederationProtocol ¶
type SFederationProtocol struct { db.SModelBase Id string `width:"64" charset:"ascii" nullable:"false" primary:"true"` IdpId string `width:"64" charset:"ascii" nullable:"false" primary:"true"` MappingId string `width:"64" charset:"ascii" nullable:"false"` }
type SFederationProtocolManager ¶
type SFederationProtocolManager struct {
db.SModelBaseManager
}
+onecloud:swagger-gen-ignore
var (
FederationProtocolManager *SFederationProtocolManager
)
type SFernetKey ¶
type SFernetKey struct { db.SModelBase Type string `width:"36" charset:"ascii" nullable:"false" primary:"true"` Index int `nullable:"false" primary:"true"` Key string `width:"64" charset:"ascii" nullable:"false"` }
type SFernetKeyManager ¶
type SFernetKeyManager struct {
db.SModelBaseManager
}
+onecloud:swagger-gen-ignore
var (
FernetKeyManager *SFernetKeyManager
)
func (*SFernetKeyManager) InitializeData ¶
func (manager *SFernetKeyManager) InitializeData() error
type SGroup ¶
type SGroup struct { SIdentityBaseResource // 用户组的显示名称 Displayname string `with:"128" charset:"utf8" nullable:"true" list:"domain" update:"domain" create:"domain_optional"` }
func (*SGroup) GetProjectCount ¶
func (*SGroup) GetUserCount ¶
func (*SGroup) IsReadOnly ¶
func (*SGroup) LinkedWithIdp ¶
func (*SGroup) PerformAddUsers ¶
func (group *SGroup) PerformAddUsers( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.PerformGroupAddUsersInput, ) (jsonutils.JSONObject, error)
组添加用户
func (*SGroup) PerformJoin ¶
func (group *SGroup) PerformJoin( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.SJoinProjectsInput, ) (jsonutils.JSONObject, error)
组加入项目
func (*SGroup) PerformLeave ¶
func (group *SGroup) PerformLeave( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.SLeaveProjectsInput, ) (jsonutils.JSONObject, error)
组退出项目
func (*SGroup) PerformRemoveUsers ¶
func (group *SGroup) PerformRemoveUsers( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.PerformGroupRemoveUsersInput, ) (jsonutils.JSONObject, error)
组删除用户
func (*SGroup) PostCreate ¶
func (group *SGroup) PostCreate( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject, )
func (*SGroup) ValidateDeleteCondition ¶
func (*SGroup) ValidateUpdateCondition ¶
func (*SGroup) ValidateUpdateData ¶
func (group *SGroup) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.GroupUpdateInput) (api.GroupUpdateInput, error)
type SGroupManager ¶
type SGroupManager struct {
SIdentityBaseResourceManager
}
var GroupManager *SGroupManager
func (*SGroupManager) FetchCustomizeColumns ¶
func (manager *SGroupManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.GroupDetails
func (*SGroupManager) FetchGroupsInDomain ¶
func (manager *SGroupManager) FetchGroupsInDomain(domainId string, excludes []string) ([]SGroup, error)
func (*SGroupManager) FilterByOwner ¶
func (manager *SGroupManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, userCred mcclient.TokenCredential, owner mcclient.IIdentityProvider, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SGroupManager) GetContextManagers ¶
func (manager *SGroupManager) GetContextManagers() [][]db.IModelManager
func (*SGroupManager) ListItemFilter ¶
func (manager *SGroupManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.GroupListInput, ) (*sqlchemy.SQuery, error)
用户组列表
func (*SGroupManager) NamespaceScope ¶
func (manager *SGroupManager) NamespaceScope() rbacscope.TRbacScope
func (*SGroupManager) OrderByExtraFields ¶
func (manager *SGroupManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.GroupListInput, ) (*sqlchemy.SQuery, error)
func (*SGroupManager) QueryDistinctExtraField ¶
func (*SGroupManager) RegisterExternalGroup ¶
func (*SGroupManager) ValidateCreateData ¶
func (manager *SGroupManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.GroupCreateInput, ) (api.GroupCreateInput, error)
type SGroupResourceBaseManager ¶
type SGroupResourceBaseManager struct{}
func (*SGroupResourceBaseManager) ListItemFilter ¶
func (manager *SGroupResourceBaseManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.GroupFilterListInput, ) (*sqlchemy.SQuery, error)
type SIdentityBaseResource ¶
type SIdentityBaseResource struct { db.SStandaloneResourceBase db.SDomainizedResourceBase db.SPendingDeletedBase // 额外信息 Extra *jsonutils.JSONDict `nullable:"true"` }
func (*SIdentityBaseResource) CustomizeCreate ¶
func (model *SIdentityBaseResource) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject) error
func (*SIdentityBaseResource) Delete ¶
func (model *SIdentityBaseResource) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
func (*SIdentityBaseResource) GetDomain ¶
func (model *SIdentityBaseResource) GetDomain() *SDomain
func (*SIdentityBaseResource) GetIIdentityModel ¶
func (model *SIdentityBaseResource) GetIIdentityModel() IIdentityModel
func (*SIdentityBaseResource) GetIIdentityModelManager ¶
func (model *SIdentityBaseResource) GetIIdentityModelManager() IIdentityModelManager
func (*SIdentityBaseResource) GetShortDesc ¶
func (model *SIdentityBaseResource) GetShortDesc(ctx context.Context) *jsonutils.JSONDict
func (*SIdentityBaseResource) PostCreate ¶
func (model *SIdentityBaseResource) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SIdentityBaseResource) PostDelete ¶
func (model *SIdentityBaseResource) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
func (*SIdentityBaseResource) PostUpdate ¶
func (model *SIdentityBaseResource) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SIdentityBaseResource) RealDelete ¶
func (model *SIdentityBaseResource) RealDelete(ctx context.Context, userCred mcclient.TokenCredential) error
func (*SIdentityBaseResource) ValidateUpdateData ¶
func (model *SIdentityBaseResource) ValidateUpdateData( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.IdentityBaseUpdateInput, ) (api.IdentityBaseUpdateInput, error)
type SIdentityBaseResourceManager ¶
type SIdentityBaseResourceManager struct { db.SStandaloneResourceBaseManager db.SDomainizedResourceBaseManager db.SPendingDeletedBaseManager }
+onecloud:swagger-gen-ignore
func NewIdentityBaseResourceManager ¶
func NewIdentityBaseResourceManager(dt interface{}, tableName string, keyword string, keywordPlural string) SIdentityBaseResourceManager
func (*SIdentityBaseResourceManager) FetchByIdOrName ¶
func (manager *SIdentityBaseResourceManager) FetchByIdOrName(ctx context.Context, userCred mcclient.IIdentityProvider, idStr string) (db.IModel, error)
func (*SIdentityBaseResourceManager) FetchByName ¶
func (manager *SIdentityBaseResourceManager) FetchByName(ctx context.Context, userCred mcclient.IIdentityProvider, idStr string) (db.IModel, error)
func (*SIdentityBaseResourceManager) FetchCustomizeColumns ¶
func (manager *SIdentityBaseResourceManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.IdentityBaseResourceDetails
func (*SIdentityBaseResourceManager) FilterBySystemAttributes ¶
func (manager *SIdentityBaseResourceManager) FilterBySystemAttributes(q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query jsonutils.JSONObject, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SIdentityBaseResourceManager) GetIIdentityModelManager ¶
func (manager *SIdentityBaseResourceManager) GetIIdentityModelManager() IIdentityModelManager
func (*SIdentityBaseResourceManager) GetPropertyDomainTagValuePairs ¶
func (manager *SIdentityBaseResourceManager) GetPropertyDomainTagValuePairs( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, ) (jsonutils.JSONObject, error)
func (*SIdentityBaseResourceManager) GetPropertyDomainTagValueTree ¶
func (manager *SIdentityBaseResourceManager) GetPropertyDomainTagValueTree( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, ) (jsonutils.JSONObject, error)
func (*SIdentityBaseResourceManager) ListItemExportKeys ¶
func (manager *SIdentityBaseResourceManager) ListItemExportKeys(ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, keys stringutils2.SSortedStrings) (*sqlchemy.SQuery, error)
func (*SIdentityBaseResourceManager) ListItemFilter ¶
func (manager *SIdentityBaseResourceManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.IdentityBaseResourceListInput, ) (*sqlchemy.SQuery, error)
func (*SIdentityBaseResourceManager) OrderByExtraFields ¶
func (manager *SIdentityBaseResourceManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.IdentityBaseResourceListInput, ) (*sqlchemy.SQuery, error)
func (*SIdentityBaseResourceManager) QueryDistinctExtraField ¶
func (*SIdentityBaseResourceManager) ValidateCreateData ¶
func (manager *SIdentityBaseResourceManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.IdentityBaseResourceCreateInput) (api.IdentityBaseResourceCreateInput, error)
type SIdentityProvider ¶
type SIdentityProvider struct { db.SEnabledStatusStandaloneResourceBase db.SDomainizedResourceBase `default:""` Driver string `width:"32" charset:"ascii" nullable:"false" list:"domain" create:"domain_required"` Template string `width:"32" charset:"ascii" nullable:"true" list:"domain" create:"domain_optional"` TargetDomainId string `width:"64" charset:"ascii" nullable:"true" list:"domain" create:"admin_optional"` // 是否自动创建项目 AutoCreateProject tristate.TriState `default:"true" list:"domain" create:"domain_optional" update:"domain"` // 是否自动创建用户 AutoCreateUser tristate.TriState `list:"domain" create:"domain_optional" update:"domain"` ErrorCount int `list:"domain"` SyncStatus string `width:"10" charset:"ascii" default:"idle" list:"domain"` LastSync time.Time `list:"domain"` // = Column(DateTime, nullable=True) LastSyncEndAt time.Time `list:"domain"` SyncIntervalSeconds int `create:"domain_optional" update:"domain"` // 认证源图标 IconUri string `width:"256" charset:"utf8" nullable:"true" list:"user" create:"domain_optional" update:"domain"` // 是否是SSO登录方式 IsSso tristate.TriState `list:"domain"` // 是否是缺省SSO登录方式 IsDefault tristate.TriState `list:"domain"` }
func (*SIdentityProvider) CanSync ¶
func (self *SIdentityProvider) CanSync() bool
func (*SIdentityProvider) CustomizeCreate ¶
func (ident *SIdentityProvider) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject) error
func (*SIdentityProvider) CustomizeDelete ¶
func (self *SIdentityProvider) CustomizeDelete(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject) error
func (*SIdentityProvider) Delete ¶
func (self *SIdentityProvider) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
func (*SIdentityProvider) GetDetailsConfig ¶
func (self *SIdentityProvider) GetDetailsConfig(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject) (jsonutils.JSONObject, error)
func (*SIdentityProvider) GetDetailsSamlMetadata ¶
func (idp *SIdentityProvider) GetDetailsSamlMetadata(ctx context.Context, userCred mcclient.TokenCredential, query api.GetIdpSamlMetadataInput) (api.GetIdpSamlMetadataOutput, error)
func (*SIdentityProvider) GetDetailsSsoCallbackUri ¶
func (idp *SIdentityProvider) GetDetailsSsoCallbackUri(ctx context.Context, userCred mcclient.TokenCredential, query api.GetIdpSsoCallbackUriInput) (api.GetIdpSsoCallbackUriOutput, error)
func (*SIdentityProvider) GetDetailsSsoRedirectUri ¶
func (idp *SIdentityProvider) GetDetailsSsoRedirectUri(ctx context.Context, userCred mcclient.TokenCredential, query api.GetIdpSsoRedirectUriInput) (api.GetIdpSsoRedirectUriOutput, error)
func (*SIdentityProvider) GetDomainCount ¶
func (self *SIdentityProvider) GetDomainCount() (int, error)
func (*SIdentityProvider) GetGroupCount ¶
func (self *SIdentityProvider) GetGroupCount() (int, error)
func (*SIdentityProvider) GetPolicyCount ¶
func (self *SIdentityProvider) GetPolicyCount() (int, error)
func (*SIdentityProvider) GetProjectCount ¶
func (self *SIdentityProvider) GetProjectCount() (int, error)
func (*SIdentityProvider) GetRoleCount ¶
func (self *SIdentityProvider) GetRoleCount() (int, error)
func (*SIdentityProvider) GetSingleDomain ¶
func (*SIdentityProvider) GetUserCount ¶
func (self *SIdentityProvider) GetUserCount() (int, error)
func (*SIdentityProvider) MarkConnected ¶
func (ident *SIdentityProvider) MarkConnected(ctx context.Context, userCred mcclient.TokenCredential) error
func (*SIdentityProvider) MarkDisconnected ¶
func (ident *SIdentityProvider) MarkDisconnected(ctx context.Context, userCred mcclient.TokenCredential, reason error) error
func (*SIdentityProvider) NeedSync ¶
func (self *SIdentityProvider) NeedSync() bool
func (*SIdentityProvider) PerformConfig ¶
func (ident *SIdentityProvider) PerformConfig(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.PerformConfigInput) (jsonutils.JSONObject, error)
配置认证源
func (*SIdentityProvider) PerformDefaultSso ¶
func (idp *SIdentityProvider) PerformDefaultSso( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.PerformDefaultSsoInput, ) (jsonutils.JSONObject, error)
func (*SIdentityProvider) PerformDisable ¶
func (idp *SIdentityProvider) PerformDisable( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformDisableInput, ) (jsonutils.JSONObject, error)
func (*SIdentityProvider) PerformEnable ¶
func (idp *SIdentityProvider) PerformEnable( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformEnableInput, ) (jsonutils.JSONObject, error)
func (*SIdentityProvider) PerformSync ¶
func (self *SIdentityProvider) PerformSync(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error)
手动同步认证源
func (*SIdentityProvider) PostCreate ¶
func (ident *SIdentityProvider) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SIdentityProvider) Purge ¶
func (self *SIdentityProvider) Purge(ctx context.Context, userCred mcclient.TokenCredential) error
func (*SIdentityProvider) RealDelete ¶
func (self *SIdentityProvider) RealDelete(ctx context.Context, userCred mcclient.TokenCredential) error
func (*SIdentityProvider) SetSyncStatus ¶
func (ident *SIdentityProvider) SetSyncStatus(ctx context.Context, userCred mcclient.TokenCredential, status string) error
func (*SIdentityProvider) SyncOrCreateDomain ¶
func (*SIdentityProvider) SyncOrCreateDomainAndUser ¶
func (*SIdentityProvider) SyncOrCreateUser ¶
func (*SIdentityProvider) TryUserJoinProject ¶
func (idp *SIdentityProvider) TryUserJoinProject(attrConf api.SIdpAttributeOptions, ctx context.Context, usr *SUser, domainId string, attrs map[string][]string)
func (*SIdentityProvider) ValidateDeleteCondition ¶
func (self *SIdentityProvider) ValidateDeleteCondition(ctx context.Context, info jsonutils.JSONObject) error
func (*SIdentityProvider) ValidateUpdateCondition ¶
func (self *SIdentityProvider) ValidateUpdateCondition(ctx context.Context) error
func (*SIdentityProvider) ValidateUpdateData ¶
func (self *SIdentityProvider) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.IdentityProviderUpdateInput) (api.IdentityProviderUpdateInput, error)
type SIdentityProviderManager ¶
type SIdentityProviderManager struct { db.SEnabledStatusStandaloneResourceBaseManager db.SDomainizedResourceBaseManager }
var (
IdentityProviderManager *SIdentityProviderManager
)
func (*SIdentityProviderManager) CheckUniqueness ¶
func (*SIdentityProviderManager) FetchCustomizeColumns ¶
func (manager *SIdentityProviderManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.IdentityProviderDetails
func (*SIdentityProviderManager) FetchEnabledProviders ¶
func (manager *SIdentityProviderManager) FetchEnabledProviders(driver string) ([]SIdentityProvider, error)
func (*SIdentityProviderManager) FetchIdentityProviderById ¶
func (manager *SIdentityProviderManager) FetchIdentityProviderById(idstr string) (*SIdentityProvider, error)
func (*SIdentityProviderManager) FetchIdentityProvidersByUserId ¶
func (manager *SIdentityProviderManager) FetchIdentityProvidersByUserId(uid string, drivers []string) ([]SIdentityProvider, error)
func (*SIdentityProviderManager) FetchPasswordProtectedIdpIdsQuery ¶
func (manager *SIdentityProviderManager) FetchPasswordProtectedIdpIdsQuery() *sqlchemy.SSubQuery
func (*SIdentityProviderManager) InitializeData ¶
func (manager *SIdentityProviderManager) InitializeData() error
func (*SIdentityProviderManager) ListItemFilter ¶
func (manager *SIdentityProviderManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.IdentityProviderListInput, ) (*sqlchemy.SQuery, error)
func (*SIdentityProviderManager) OrderByExtraFields ¶
func (manager *SIdentityProviderManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.IdentityProviderListInput, ) (*sqlchemy.SQuery, error)
func (*SIdentityProviderManager) QueryDistinctExtraField ¶
func (*SIdentityProviderManager) ValidateCreateData ¶
func (manager *SIdentityProviderManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.IdentityProviderCreateInput, ) (api.IdentityProviderCreateInput, error)
type SIdentityQuota ¶
type SIdentityQuota struct { quotas.SQuotaBase quotas.SBaseDomainQuotaKeys User int `default:"-1" allow_zero:"true" json:"user"` Group int `default:"-1" allow_zero:"true" json:"group"` Project int `default:"-1" allow_zero:"true" json:"project"` Role int `default:"-1" allow_zero:"true" json:"role"` Policy int `default:"-1" allow_zero:"true" json:"policy"` }
func (*SIdentityQuota) Add ¶
func (self *SIdentityQuota) Add(quota quotas.IQuota)
func (*SIdentityQuota) FetchSystemQuota ¶
func (self *SIdentityQuota) FetchSystemQuota()
func (*SIdentityQuota) FetchUsage ¶
func (self *SIdentityQuota) FetchUsage(ctx context.Context) error
func (*SIdentityQuota) GetKeys ¶
func (self *SIdentityQuota) GetKeys() quotas.IQuotaKeys
func (*SIdentityQuota) IsEmpty ¶
func (self *SIdentityQuota) IsEmpty() bool
func (*SIdentityQuota) ResetNegative ¶
func (self *SIdentityQuota) ResetNegative()
func (*SIdentityQuota) SetKeys ¶
func (self *SIdentityQuota) SetKeys(keys quotas.IQuotaKeys)
func (*SIdentityQuota) Sub ¶
func (self *SIdentityQuota) Sub(quota quotas.IQuota)
func (*SIdentityQuota) ToJSON ¶
func (self *SIdentityQuota) ToJSON(prefix string) jsonutils.JSONObject
func (*SIdentityQuota) Update ¶
func (self *SIdentityQuota) Update(quota quotas.IQuota)
type SIdentityQuotaDetail ¶
type SIdentityQuotaDetail struct { SIdentityQuota quotas.SBaseDomainQuotaDetailKeys }
域的认证配额详情
func GetIdentityQuota ¶
func GetIdentityQuota(query quotas.SBaseQuotaQueryInput) *SIdentityQuotaDetail
获取指定域的认证配额
func ListIdentityQuotas ¶
func ListIdentityQuotas(query quotas.SBaseQuotaQueryInput) *SIdentityQuotaDetail
获取所有域的域配额
func SetIdentityQuotas ¶
func SetIdentityQuotas(input SetIdentityQuotaInput) *SIdentityQuotaDetail
设置域的认证配额
type SIdmapping ¶
type SIdmapping struct { db.SResourceBase PublicId string `width:"64" charset:"ascii" nullable:"false" primary:"false"` IdpId string `name:"domain_id" width:"64" charset:"ascii" nullable:"false" primary:"true"` IdpEntityId string `name:"local_id" width:"128" charset:"utf8" nullable:"false" primary:"true"` EntityType string `width:"10" charset:"ascii" nullable:"false" primary:"true"` }
type SIdmappingManager ¶
type SIdmappingManager struct {
db.SResourceBaseManager
}
+onecloud:swagger-gen-ignore
var IdmappingManager *SIdmappingManager
func (*SIdmappingManager) FetchByIdpAndEntityId ¶
func (*SIdmappingManager) FetchEntities ¶
func (manager *SIdmappingManager) FetchEntities(idStr string, entType string) ([]SIdmapping, error)
func (*SIdmappingManager) FetchFirstEntity ¶
func (manager *SIdmappingManager) FetchFirstEntity(idStr string, entType string) (*SIdmapping, error)
func (*SIdmappingManager) FetchPublicIdsExcludes ¶
func (*SIdmappingManager) FetchPublicIdsExcludesQuery ¶
func (*SIdmappingManager) RegisterIdMap ¶
type SIdpRemoteIds ¶
type SIdpRemoteIds struct { db.SModelBase IdpId string `width:"64" charset:"ascii" nullable:"true"` RemoteId string `width:"255" charset:"ascii" nullable:"false" primary:"true"` }
type SIdpRemoteIdsManager ¶
type SIdpRemoteIdsManager struct {
db.SModelBaseManager
}
+onecloud:swagger-gen-ignore
var (
IdpRemoteIdsManager *SIdpRemoteIdsManager
)
type SImpliedRole ¶
type SImpliedRole struct { db.SModelBase PriorRoleId string `width:"64" charset:"ascii" nullable:"false" primary:"true"` ImpliedRoleId string `width:"64" charset:"ascii" nullable:"false" primary:"true"` }
type SImpliedRoleManager ¶
type SImpliedRoleManager struct {
db.SModelBaseManager
}
+onecloud:swagger-gen-ignore
var (
ImpliedRoleManager *SImpliedRoleManager
)
type SLocalUser ¶
type SLocalUser struct { db.SResourceBase Id int `nullable:"false" primary:"true" auto_increment:"true"` UserId string `width:"64" charset:"ascii" nullable:"false" index:"true"` DomainId string `width:"64" charset:"ascii" nullable:"false" index:"true"` Name string `width:"255" charset:"utf8" nullable:"false"` FailedAuthCount int `nullable:"true"` FailedAuthAt time.Time `nullable:"true"` NeedResetPassword tristate.TriState `default:"false" list:"domain"` ResetHint string `width:"16" charset:"ascii" list:"domain"` }
func (*SLocalUser) ClearFailedAuth ¶
func (usr *SLocalUser) ClearFailedAuth() error
func (*SLocalUser) GetId ¶
func (user *SLocalUser) GetId() string
func (*SLocalUser) GetName ¶
func (user *SLocalUser) GetName() string
func (*SLocalUser) SaveFailedAuth ¶
func (usr *SLocalUser) SaveFailedAuth() error
type SLocalUserManager ¶
type SLocalUserManager struct {
db.SResourceBaseManager
}
+onecloud:swagger-gen-ignore
var LocalUserManager *SLocalUserManager
func (*SLocalUserManager) CreateByInsertOrUpdate ¶
func (manager *SLocalUserManager) CreateByInsertOrUpdate() bool
func (*SLocalUserManager) FetchLocalUserById ¶
func (manager *SLocalUserManager) FetchLocalUserById(localId int) (*SLocalUser, error)
type SNonlocalUser ¶
type SNonlocalUser struct { db.SModelBase DomainId string `width:"64" charset:"ascii" primary:"true"` Name string `width:"191" charset:"utf8" primary:"true"` UserId string `width:"64" charset:"ascii" nullable:"false" index:"true"` }
type SNonlocalUserManager ¶
type SNonlocalUserManager struct {
db.SModelBaseManager
}
+onecloud:swagger-gen-ignore
var NonlocalUserManager *SNonlocalUserManager
type SOrganization ¶
type SOrganization struct { SEnabledIdentityBaseResource db.SSharableBaseResource db.SStatusResourceBase Type api.TOrgType `width:"32" charset:"ascii" list:"user" create:"admin_required"` Keys string `width:"256" charset:"utf8" list:"user" create:"admin_optional"` Level int `list:"user" create:"admin_optional"` }
func (*SOrganization) CustomizeCreate ¶
func (org *SOrganization) CustomizeCreate( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject, ) error
func (*SOrganization) Delete ¶
func (org *SOrganization) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
func (*SOrganization) GetKeys ¶
func (org *SOrganization) GetKeys() []string
func (*SOrganization) GetShortDesc ¶
func (org *SOrganization) GetShortDesc(ctx context.Context) *jsonutils.JSONDict
func (*SOrganization) PerformAddLevel ¶
func (org *SOrganization) PerformAddLevel( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.OrganizationPerformAddLevelsInput, ) (jsonutils.JSONObject, error)
func (*SOrganization) PerformAddNode ¶
func (org *SOrganization) PerformAddNode( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.OrganizationPerformAddNodeInput, ) (jsonutils.JSONObject, error)
func (*SOrganization) PerformClean ¶
func (org *SOrganization) PerformClean( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.OrganizationPerformCleanInput, ) (jsonutils.JSONObject, error)
func (*SOrganization) PerformDisable ¶
func (org *SOrganization) PerformDisable( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformDisableInput, ) (jsonutils.JSONObject, error)
func (*SOrganization) PerformEnable ¶
func (org *SOrganization) PerformEnable( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformEnableInput, ) (jsonutils.JSONObject, error)
func (*SOrganization) PerformSync ¶
func (org *SOrganization) PerformSync( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.OrganizationPerformSyncInput, ) (jsonutils.JSONObject, error)
func (*SOrganization) PostCreate ¶
func (org *SOrganization) PostCreate( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject, )
func (*SOrganization) PostUpdate ¶
func (org *SOrganization) PostUpdate( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject, )
func (*SOrganization) SetStatus ¶
func (org *SOrganization) SetStatus(ctx context.Context, userCred mcclient.TokenCredential, status string, reason string) error
func (*SOrganization) SyncTags ¶
func (org *SOrganization) SyncTags(ctx context.Context, userCred mcclient.TokenCredential, resourceType string) error
func (*SOrganization) ValidateDeleteCondition ¶
func (org *SOrganization) ValidateDeleteCondition(ctx context.Context, info *api.ProjectDetails) error
func (*SOrganization) ValidateUpdateData ¶
func (org *SOrganization) ValidateUpdateData( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.OrganizationUpdateInput, ) (api.OrganizationUpdateInput, error)
type SOrganizationManager ¶
type SOrganizationManager struct { SEnabledIdentityBaseResourceManager db.SSharableBaseResourceManager db.SStatusResourceBaseManager // contains filtered or unexported fields }
var OrganizationManager *SOrganizationManager
func (*SOrganizationManager) ExtendListQuery ¶
func (manager *SOrganizationManager) ExtendListQuery( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.OrganizationListInput, ) (*sqlchemy.SQuery, error)
func (*SOrganizationManager) FetchCustomizeColumns ¶
func (manager *SOrganizationManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.SOrganizationDetails
func (*SOrganizationManager) FetchOrgnaizations ¶
func (manager *SOrganizationManager) FetchOrgnaizations(filter func(q *sqlchemy.SQuery) *sqlchemy.SQuery) ([]SOrganization, error)
func (*SOrganizationManager) ListItemFilter ¶
func (manager *SOrganizationManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.OrganizationListInput, ) (*sqlchemy.SQuery, error)
组织列表
func (*SOrganizationManager) OrderByExtraFields ¶
func (manager *SOrganizationManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.OrganizationListInput, ) (*sqlchemy.SQuery, error)
func (*SOrganizationManager) QueryDistinctExtraField ¶
func (*SOrganizationManager) ValidateCreateData ¶
func (manager *SOrganizationManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.OrganizationCreateInput, ) (api.OrganizationCreateInput, error)
type SOrganizationNode ¶
type SOrganizationNode struct { db.SStandaloneResourceBase `name:""` db.SPendingDeletedBase OrgId string `width:"36" charset:"ascii" list:"user" create:"admin_required"` FullLabel string `width:"180" charset:"utf8" list:"user" create:"admin_required"` Level int `list:"user" create:"admin_required"` Weight int `list:"user" create:"admin_required" update:"admin" default:"1"` }
func (*SOrganizationNode) BindTargetIds ¶
func (orgNode *SOrganizationNode) BindTargetIds(ctx context.Context, userCred mcclient.TokenCredential, input api.OrganizationNodePerformBindInput, bind bool) error
func (*SOrganizationNode) Delete ¶
func (orgNode *SOrganizationNode) Delete(ctx context.Context, userCred mcclient.TokenCredential) error
fake delete
func (*SOrganizationNode) GetChildCount ¶
func (orgNode *SOrganizationNode) GetChildCount() (int, error)
func (*SOrganizationNode) GetDirectChildCount ¶
func (orgNode *SOrganizationNode) GetDirectChildCount() (int, error)
func (*SOrganizationNode) GetOrganization ¶
func (orgNode *SOrganizationNode) GetOrganization() (*SOrganization, error)
func (*SOrganizationNode) GetShortDesc ¶
func (orgNode *SOrganizationNode) GetShortDesc(ctx context.Context) *jsonutils.JSONDict
func (*SOrganizationNode) GetTagSet ¶
func (orgNode *SOrganizationNode) GetTagSet(org *SOrganization) tagutils.TTagSet
func (*SOrganizationNode) GetTags ¶
func (orgNode *SOrganizationNode) GetTags(org *SOrganization) map[string]string
func (*SOrganizationNode) PerformBind ¶
func (orgNode *SOrganizationNode) PerformBind( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.OrganizationNodePerformBindInput, ) (jsonutils.JSONObject, error)
func (*SOrganizationNode) PerformUnbind ¶
func (orgNode *SOrganizationNode) PerformUnbind( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.OrganizationNodePerformBindInput, ) (jsonutils.JSONObject, error)
func (*SOrganizationNode) ValidateDeleteCondition ¶
func (orgNode *SOrganizationNode) ValidateDeleteCondition(ctx context.Context, info *api.ProjectDetails) error
func (*SOrganizationNode) ValidateUpdateData ¶
func (orgNode *SOrganizationNode) ValidateUpdateData( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.OrganizationNodeUpdateInput, ) (api.OrganizationNodeUpdateInput, error)
type SOrganizationNodeManager ¶
type SOrganizationNodeManager struct { db.SStandaloneResourceBaseManager db.SPendingDeletedBaseManager }
var OrganizationNodeManager *SOrganizationNodeManager
func (*SOrganizationNodeManager) FetchCustomizeColumns ¶
func (manager *SOrganizationNodeManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.SOrganizationNodeDetails
func (*SOrganizationNodeManager) FilterBySystemAttributes ¶
func (manager *SOrganizationNodeManager) FilterBySystemAttributes(q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query jsonutils.JSONObject, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SOrganizationNodeManager) ListItemFilter ¶
func (manager *SOrganizationNodeManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.OrganizationNodeListInput, ) (*sqlchemy.SQuery, error)
项目列表
func (*SOrganizationNodeManager) OrderByExtraFields ¶
func (manager *SOrganizationNodeManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.OrganizationNodeListInput, ) (*sqlchemy.SQuery, error)
func (*SOrganizationNodeManager) QueryDistinctExtraField ¶
type SPassword ¶
type SPassword struct { db.SResourceBase Id int `primary:"true" auto_increment:"true"` LocalUserId int `nullable:"false" index:"true"` Password string `width:"128" charset:"ascii" nullable:"true"` ExpiresAt time.Time `nullable:"true"` SelfService bool `nullable:"false" default:"false"` PasswordHash string `width:"255" charset:"ascii" nullable:"true"` CreatedAtInt int64 `nullable:"false" default:"0"` ExpiresAtInt int64 `nullable:"true"` }
func (*SPassword) EventNotify ¶
func (pwd *SPassword) EventNotify(ctx context.Context, userCred mcclient.TokenCredential, action notifyapi.SAction, userName string, advanceDays int)
密码即将失效消息通知
func (*SPassword) NeedSendNotify ¶
type SPasswordManager ¶
type SPasswordManager struct {
db.SResourceBaseManager
}
+onecloud:swagger-gen-ignore
var PasswordManager *SPasswordManager
func (*SPasswordManager) CreateByInsertOrUpdate ¶
func (manager *SPasswordManager) CreateByInsertOrUpdate() bool
func (*SPasswordManager) FetchLastPassword ¶
func (manager *SPasswordManager) FetchLastPassword(localUserId int) (*SPassword, error)
type SPolicy ¶
type SPolicy struct { SEnabledIdentityBaseResource db.SSharableBaseResource `"is_public->create":"domain_optional" "public_scope->create":"domain_optional"` // swagger:ignore // Deprecated Type string `width:"255" charset:"utf8" nullable:"false" list:"user" create:"domain_required" update:"domain"` // 权限定义 Blob jsonutils.JSONObject `nullable:"false" list:"user" create:"domain_required" update:"domain"` // 权限范围 Scope rbacscope.TRbacScope `nullable:"true" list:"user" create:"domain_required" update:"domain"` // 是否为系统权限 IsSystem tristate.TriState `default:"false" list:"domain" update:"admin" create:"admin_optional"` // 匹配的项目标签 ProjectTags tagutils.TTagSet `nullable:"true" list:"user" update:"domain" create:"domain_optional"` // 匹配的域标签 DomainTags tagutils.TTagSet `nullable:"true" list:"user" update:"admin" create:"admin_optional"` // 匹配的资源标签 ObjectTags tagutils.TTagSet `nullable:"true" list:"user" update:"domain" create:"domain_optional"` // 匹配的组织架构节点 OrgNodeId []string `nullable:"true" list:"user" update:"domain" create:"domain_optional"` }
func (*SPolicy) CustomizeCreate ¶
func (policy *SPolicy) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject) error
func (*SPolicy) GetChangeOwnerCandidateDomainIds ¶
func (*SPolicy) GetRequiredSharedDomainIds ¶
func (*SPolicy) GetSharableTargetDomainIds ¶
func (*SPolicy) GetSharedDomains ¶
func (*SPolicy) IsSharable ¶
func (policy *SPolicy) IsSharable(reqUsrId mcclient.IIdentityProvider) bool
func (*SPolicy) PerformBindRole ¶
func (policy *SPolicy) PerformBindRole(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.PolicyBindRoleInput) (jsonutils.JSONObject, error)
绑定角色
func (*SPolicy) PerformPrivate ¶
func (policy *SPolicy) PerformPrivate(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformPrivateInput) (jsonutils.JSONObject, error)
设置policy为私有
func (*SPolicy) PerformPublic ¶
func (policy *SPolicy) PerformPublic(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformPublicDomainInput) (jsonutils.JSONObject, error)
共享Policy
func (*SPolicy) PostCreate ¶
func (policy *SPolicy) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SPolicy) PostDelete ¶
func (policy *SPolicy) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
func (*SPolicy) PostUpdate ¶
func (policy *SPolicy) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SPolicy) ValidateDeleteCondition ¶
func (*SPolicy) ValidateUpdateCondition ¶
func (*SPolicy) ValidateUpdateData ¶
func (policy *SPolicy) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.PolicyUpdateInput) (api.PolicyUpdateInput, error)
type SPolicyManager ¶
type SPolicyManager struct { SEnabledIdentityBaseResourceManager db.SSharableBaseResourceManager }
var PolicyManager *SPolicyManager
func (*SPolicyManager) FetchCustomizeColumns ¶
func (manager *SPolicyManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.PolicyDetails
func (*SPolicyManager) FetchEnabledPolicies ¶
func (manager *SPolicyManager) FetchEnabledPolicies() ([]SPolicy, error)
func (*SPolicyManager) FilterByOwner ¶
func (manager *SPolicyManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, userCred mcclient.TokenCredential, owner mcclient.IIdentityProvider, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SPolicyManager) InitializeData ¶
func (manager *SPolicyManager) InitializeData() error
func (*SPolicyManager) ListItemFilter ¶
func (manager *SPolicyManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.PolicyListInput, ) (*sqlchemy.SQuery, error)
权限策略列表
func (*SPolicyManager) OrderByExtraFields ¶
func (manager *SPolicyManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.PolicyListInput, ) (*sqlchemy.SQuery, error)
func (*SPolicyManager) QueryDistinctExtraField ¶
func (*SPolicyManager) ValidateCreateData ¶
func (manager *SPolicyManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.PolicyCreateInput, ) (api.PolicyCreateInput, error)
type SProject ¶
type SProject struct { SIdentityBaseResource // 上级项目或域的ID ParentId string `width:"64" charset:"ascii" list:"domain" create:"domain_optional"` // 该项目是否为域(domain) IsDomain tristate.TriState `default:"false"` AdminId string `width:"64" charset:"ascii" nullable:"true" list:"domain"` }
func (*SProject) CustomizeCreate ¶
func (model *SProject) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject) error
func (*SProject) FetchExtend ¶
func (proj *SProject) FetchExtend() (*SProjectExtended, error)
func (*SProject) GetEmptyProjects ¶
func (*SProject) GetGroupCount ¶
func (*SProject) GetUserCount ¶
func (*SProject) IsAdminProject ¶
func (*SProject) PerformJoin ¶
func (project *SProject) PerformJoin( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.SProjectAddUserGroupInput, ) (jsonutils.JSONObject, error)
将用户或组加入项目
func (*SProject) PerformLeave ¶
func (project *SProject) PerformLeave( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.SProjectRemoveUserGroupInput, ) (jsonutils.JSONObject, error)
将用户或组移出项目
func (*SProject) PerformSetAdmin ¶
func (project *SProject) PerformSetAdmin( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.SProjectSetAdminInput, ) (jsonutils.JSONObject, error)
func (*SProject) PostCreate ¶
func (project *SProject) PostCreate( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject, )
func (*SProject) StartProjectCleanTask ¶
func (*SProject) ValidateDeleteCondition ¶
func (*SProject) ValidateUpdateData ¶
func (proj *SProject) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.ProjectUpdateInput) (api.ProjectUpdateInput, error)
type SProjectExtended ¶
+onecloud:model-api-gen
type SProjectManager ¶
type SProjectManager struct {
SIdentityBaseResourceManager
}
var ProjectManager *SProjectManager
func (*SProjectManager) FetchCustomizeColumns ¶
func (manager *SProjectManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.ProjectDetails
func (*SProjectManager) FetchProject ¶
func (manager *SProjectManager) FetchProject(projectId, projectName string, domainId, domainName string) (*SProject, error)
func (*SProjectManager) FetchProjectById ¶
func (manager *SProjectManager) FetchProjectById(projectId string) (*SProject, error)
func (*SProjectManager) FetchProjectByName ¶
func (manager *SProjectManager) FetchProjectByName(projectName string, domainId, domainName string) (*SProject, error)
func (*SProjectManager) FetchUserProjects ¶
func (manager *SProjectManager) FetchUserProjects(userId string) ([]SProjectExtended, error)
func (*SProjectManager) FilterByOwner ¶
func (manager *SProjectManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, userCred mcclient.TokenCredential, owner mcclient.IIdentityProvider, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SProjectManager) GetContextManagers ¶
func (manager *SProjectManager) GetContextManagers() [][]db.IModelManager
func (*SProjectManager) GetSystemProject ¶
func (manager *SProjectManager) GetSystemProject() (*SProject, error)
func (*SProjectManager) InitializeData ¶
func (manager *SProjectManager) InitializeData() error
func (*SProjectManager) ListItemFilter ¶
func (manager *SProjectManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.ProjectListInput, ) (*sqlchemy.SQuery, error)
项目列表
func (*SProjectManager) NewProject ¶
func (*SProjectManager) NewQuery ¶
func (manager *SProjectManager) NewQuery(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, useRawQuery bool) *sqlchemy.SQuery
func (*SProjectManager) OrderByExtraFields ¶
func (manager *SProjectManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.ProjectListInput, ) (*sqlchemy.SQuery, error)
func (*SProjectManager) PerformClean ¶
func (manager *SProjectManager) PerformClean(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input *api.ProjectCleanInput) (jsonutils.JSONObject, error)
func (*SProjectManager) Query ¶
func (manager *SProjectManager) Query(fields ...string) *sqlchemy.SQuery
func (*SProjectManager) QueryDistinctExtraField ¶
func (*SProjectManager) ValidateCreateData ¶
func (manager *SProjectManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.ProjectCreateInput) (api.ProjectCreateInput, error)
type SProjectResourceBaseManager ¶
type SProjectResourceBaseManager struct{}
+onecloud:swagger-gen-ignore
func (*SProjectResourceBaseManager) ListItemFilter ¶
func (manager *SProjectResourceBaseManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.ProjectFilterListInput, ) (*sqlchemy.SQuery, error)
type SQuotaManager ¶
type SQuotaManager struct {
quotas.SQuotaBaseManager
}
func (*SQuotaManager) FetchIdNames ¶
func (*SQuotaManager) FetchOwnerId ¶
func (manager *SQuotaManager) FetchOwnerId(ctx context.Context, data jsonutils.JSONObject) (mcclient.IIdentityProvider, error)
type SRegion ¶
type SRegion struct { db.SStandaloneResourceBase ParentRegionId string `width:"255" charset:"ascii" nulable:"true"` Extra *jsonutils.JSONDict }
func (*SRegion) CustomizeCreate ¶
func (region *SRegion) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject) error
func (*SRegion) GetEndpointCount ¶
func (*SRegion) ValidateDeleteCondition ¶
type SRegionManager ¶
type SRegionManager struct {
db.SStandaloneResourceBaseManager
}
var RegionManager *SRegionManager
func (*SRegionManager) FetchCustomizeColumns ¶
func (manager *SRegionManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.RegionDetails
func (*SRegionManager) InitializeData ¶
func (manager *SRegionManager) InitializeData() error
func (*SRegionManager) ListItemFilter ¶
func (manager *SRegionManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RegionListInput, ) (*sqlchemy.SQuery, error)
区域列表
func (*SRegionManager) OrderByExtraFields ¶
func (manager *SRegionManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RegionListInput, ) (*sqlchemy.SQuery, error)
func (*SRegionManager) QueryDistinctExtraField ¶
func (*SRegionManager) ValidateCreateData ¶
func (manager *SRegionManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data *jsonutils.JSONDict) (*jsonutils.JSONDict, error)
type SRegionResourceBaseManager ¶
type SRegionResourceBaseManager struct{}
func (*SRegionResourceBaseManager) ListItemFilter ¶
func (manager *SRegionResourceBaseManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RegionFilterListInput, ) (*sqlchemy.SQuery, error)
type SRole ¶
type SRole struct { SIdentityBaseResource `"name->update":""` db.SSharableBaseResource `"is_public->create":"domain_optional" "public_scope->create":"domain_optional"` }
func (*SRole) CustomizeCreate ¶
func (role *SRole) CustomizeCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject) error
func (*SRole) DeleteInContext ¶
func (role *SRole) DeleteInContext(ctx context.Context, userCred mcclient.TokenCredential, ctxObjs []db.IModel, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error)
func (*SRole) GetChangeOwnerCandidateDomainIds ¶
func (*SRole) GetGroupCount ¶
func (*SRole) GetProjectCount ¶
func (*SRole) GetRequiredSharedDomainIds ¶
func (*SRole) GetSharableTargetDomainIds ¶
func (*SRole) GetSharedDomains ¶
func (*SRole) GetUserCount ¶
func (*SRole) IsSharable ¶
func (role *SRole) IsSharable(reqUsrId mcclient.IIdentityProvider) bool
func (*SRole) IsSystemRole ¶
func (*SRole) PerformAddPolicy ¶
func (role *SRole) PerformAddPolicy(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.RolePerformAddPolicyInput) (jsonutils.JSONObject, error)
func (*SRole) PerformPrivate ¶
func (role *SRole) PerformPrivate(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformPrivateInput) (jsonutils.JSONObject, error)
func (*SRole) PerformPublic ¶
func (role *SRole) PerformPublic(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformPublicDomainInput) (jsonutils.JSONObject, error)
func (*SRole) PerformRemovePolicy ¶
func (role *SRole) PerformRemovePolicy(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.RolePerformRemovePolicyInput) (jsonutils.JSONObject, error)
func (*SRole) PerformSetPolicies ¶
func (role *SRole) PerformSetPolicies(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.RolePerformSetPoliciesInput) (jsonutils.JSONObject, error)
func (*SRole) PostCreate ¶
func (role *SRole) PostCreate( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject, )
func (*SRole) UpdateInContext ¶
func (role *SRole) UpdateInContext(ctx context.Context, userCred mcclient.TokenCredential, ctxObjs []db.IModel, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error)
func (*SRole) ValidateDeleteCondition ¶
func (*SRole) ValidateUpdateData ¶
func (role *SRole) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.RoleUpdateInput) (api.RoleUpdateInput, error)
type SRoleManager ¶
type SRoleManager struct { SIdentityBaseResourceManager db.SSharableBaseResourceManager }
var RoleManager *SRoleManager
func (*SRoleManager) FetchCustomizeColumns ¶
func (manager *SRoleManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.RoleDetails
func (*SRoleManager) FetchRole ¶
func (manager *SRoleManager) FetchRole(roleId, roleName string, domainId, domainName string) (*SRole, error)
func (*SRoleManager) FetchRoleById ¶
func (manager *SRoleManager) FetchRoleById(roleId string) (*SRole, error)
func (*SRoleManager) FetchRoleByName ¶
func (manager *SRoleManager) FetchRoleByName(roleName string, domainId, domainName string) (*SRole, error)
func (*SRoleManager) FilterByOwner ¶
func (manager *SRoleManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, userCred mcclient.TokenCredential, owner mcclient.IIdentityProvider, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SRoleManager) GetContextManagers ¶
func (manager *SRoleManager) GetContextManagers() [][]db.IModelManager
func (*SRoleManager) InitializeData ¶
func (manager *SRoleManager) InitializeData() error
func (*SRoleManager) ListItemFilter ¶
func (manager *SRoleManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RoleListInput, ) (*sqlchemy.SQuery, error)
角色列表
func (*SRoleManager) OrderByExtraFields ¶
func (manager *SRoleManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RoleListInput, ) (*sqlchemy.SQuery, error)
func (*SRoleManager) QueryDistinctExtraField ¶
func (*SRoleManager) ValidateCreateData ¶
func (manager *SRoleManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.RoleCreateInput, ) (api.RoleCreateInput, error)
type SRolePolicy ¶
type SRolePolicy struct { db.SResourceBase // 角色ID, 主键 RoleId string `width:"128" charset:"ascii" primary:"true" list:"domain" create:"domain_optional"` // 项目ID,主键 ProjectId string `width:"128" charset:"ascii" primary:"true" list:"domain" create:"domain_optional"` // 权限ID, 主键 PolicyId string `width:"128" charset:"ascii" primary:"true" list:"domain" create:"domain_required"` // 是否需要认证 Auth tristate.TriState `default:"true" list:"domain" create:"domain_optional"` // 匹配的IP白名单 Ips string `list:"domain" create:"domain_optional" update:"domain"` // 匹配开始时间 ValidSince time.Time `list:"domain" create:"domain_optional" update:"domain"` // 匹配结束时间 ValidUntil time.Time `list:"domain" create:"domain_optional" update:"domain"` }
func (*SRolePolicy) GetId ¶
func (rp *SRolePolicy) GetId() string
func (*SRolePolicy) GetName ¶
func (rp *SRolePolicy) GetName() string
func (*SRolePolicy) GetPolicy ¶
func (rp *SRolePolicy) GetPolicy() *SPolicy
func (*SRolePolicy) GetProject ¶
func (rp *SRolePolicy) GetProject() *SProject
func (*SRolePolicy) GetRole ¶
func (rp *SRolePolicy) GetRole() *SRole
func (*SRolePolicy) MatchIP ¶
func (rp *SRolePolicy) MatchIP(ipstr string) bool
type SRolePolicyManager ¶
type SRolePolicyManager struct {
db.SResourceBaseManager
}
var RolePolicyManager *SRolePolicyManager
func (*SRolePolicyManager) FetchCustomizeColumns ¶
func (manager *SRolePolicyManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.RolePolicyDetails
func (*SRolePolicyManager) FilterById ¶
func (*SRolePolicyManager) FilterByName ¶
func (*SRolePolicyManager) FilterByNotId ¶
func (*SRolePolicyManager) FilterByOwner ¶
func (manager *SRolePolicyManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, userCred mcclient.TokenCredential, owner mcclient.IIdentityProvider, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SRolePolicyManager) GetMatchPolicyGroup ¶
func (manager *SRolePolicyManager) GetMatchPolicyGroup(userCred rbacutils.IRbacIdentity, tm time.Time, nameOnly bool) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
func (*SRolePolicyManager) GetMatchPolicyGroup2 ¶
func (manager *SRolePolicyManager) GetMatchPolicyGroup2(isGuest bool, roleIds []string, pid string, loginIp string, tm time.Time, nameOnly bool) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
func (*SRolePolicyManager) GetMatchPolicyGroupByCred ¶
func (manager *SRolePolicyManager) GetMatchPolicyGroupByCred(ctx context.Context, userCred api.IRbacIdentityWithUserId, tm time.Time, nameOnly bool) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
func (*SRolePolicyManager) GetMatchPolicyGroupByInput ¶
func (manager *SRolePolicyManager) GetMatchPolicyGroupByInput(ctx context.Context, userId, projectId string, tm time.Time, nameOnly bool) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
func (*SRolePolicyManager) GetPolicyGroupByIds ¶
func (manager *SRolePolicyManager) GetPolicyGroupByIds(policyIds []string, nameOnly bool) (map[rbacscope.TRbacScope][]string, rbacutils.TPolicyGroup, error)
func (*SRolePolicyManager) ListItemFilter ¶
func (manager *SRolePolicyManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RolePolicyListInput, ) (*sqlchemy.SQuery, error)
func (*SRolePolicyManager) NamespaceScope ¶
func (manager *SRolePolicyManager) NamespaceScope() rbacscope.TRbacScope
func (*SRolePolicyManager) OrderByExtraFields ¶
func (manager *SRolePolicyManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RolePolicyListInput, ) (*sqlchemy.SQuery, error)
func (*SRolePolicyManager) QueryDistinctExtraField ¶
type SRoleResourceBaseManager ¶
type SRoleResourceBaseManager struct{}
func (*SRoleResourceBaseManager) ListItemFilter ¶
func (manager *SRoleResourceBaseManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RoleFilterListInput, ) (*sqlchemy.SQuery, error)
type SScopeResource ¶
type SScopeResource struct { db.SModelBase DomainId string `width:"64" charset:"ascii" primary:"true"` ProjectId string `width:"64" charset:"ascii" primary:"true"` OwnerId string `width:"64" charset:"ascii" primary:"true"` RegionId string `width:"32" charset:"ascii" primary:"true"` ServiceId string `width:"32" charset:"ascii" primary:"true"` Resource string `width:"32" charset:"ascii" primary:"true"` Count int UpdatedAt time.Time `nullable:"true" updated_at:"true"` }
type SScopeResourceManager ¶
type SScopeResourceManager struct {
db.SModelBaseManager
}
var ScopeResourceManager *SScopeResourceManager
type SService ¶
type SService struct { db.SStandaloneResourceBase Type string `width:"255" charset:"utf8" list:"admin" create:"admin_required"` Enabled tristate.TriState `default:"true" list:"admin" update:"admin" create:"admin_optional"` Extra *jsonutils.JSONDict `nullable:"true" list:"admin"` ConfigVersion int `list:"admin" nullable:"false" default:"0"` }
func (*SService) GetDetailsConfig ¶
func (service *SService) GetDetailsConfig(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject) (jsonutils.JSONObject, error)
func (*SService) GetEndpointCount ¶
func (*SService) PerformConfig ¶
func (service *SService) PerformConfig(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.PerformConfigInput) (jsonutils.JSONObject, error)
func (*SService) PostCreate ¶
func (service *SService) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SService) PostDelete ¶
func (service *SService) PostDelete(ctx context.Context, userCred mcclient.TokenCredential)
func (*SService) PostUpdate ¶
func (service *SService) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SService) ValidateDeleteCondition ¶
type SServiceCatalog ¶
type SServiceCatalog []SEndpointExtended
func (SServiceCatalog) GetKeystoneCatalogV2 ¶
func (cata SServiceCatalog) GetKeystoneCatalogV2() mcclient.KeystoneServiceCatalogV2
func (SServiceCatalog) GetKeystoneCatalogV3 ¶
func (cata SServiceCatalog) GetKeystoneCatalogV3() mcclient.KeystoneServiceCatalogV3
type SServiceCertificate ¶
type SServiceCertificate struct { db.SStandaloneResourceBase db.SCertificateResourceBase CaCertificate string `create:"optional" list:"admin"` CaPrivateKey string `create:"optional" list:"admin"` }
func (*SServiceCertificate) ToOutput ¶
func (cert *SServiceCertificate) ToOutput() *api.CertificateDetails
func (*SServiceCertificate) ValidateUpdateData ¶
func (cert *SServiceCertificate) ValidateUpdateData( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data *jsonutils.JSONDict, ) (*jsonutils.JSONDict, error)
type SServiceCertificateManager ¶
type SServiceCertificateManager struct {
db.SStandaloneResourceBaseManager
}
var ServiceCertificateManager *SServiceCertificateManager
func (*SServiceCertificateManager) ValidateCreateData ¶
func (man *SServiceCertificateManager) ValidateCreateData(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data *jsonutils.JSONDict) (*jsonutils.JSONDict, error)
type SServiceManager ¶
type SServiceManager struct {
db.SStandaloneResourceBaseManager
}
var ServiceManager *SServiceManager
func (*SServiceManager) FetchCustomizeColumns ¶
func (manager *SServiceManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.ServiceDetails
func (*SServiceManager) InitializeData ¶
func (manager *SServiceManager) InitializeData() error
func (*SServiceManager) ListItemFilter ¶
func (manager *SServiceManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.ServiceListInput, ) (*sqlchemy.SQuery, error)
服务列表
func (*SServiceManager) OrderByExtraFields ¶
func (manager *SServiceManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.RegionListInput, ) (*sqlchemy.SQuery, error)
func (*SServiceManager) QueryDistinctExtraField ¶
type SServiceResourceBaseManager ¶
type SServiceResourceBaseManager struct{}
func (*SServiceResourceBaseManager) ListItemFilter ¶
func (manager *SServiceResourceBaseManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.ServiceFilterListInput, ) (*sqlchemy.SQuery, error)
type STokenCache ¶
type STokenCache struct { db.SStandaloneAnonResourceBase // Token string `width:"700" charset:"ascii" nullable:"false" primary:"true"` ExpiredAt time.Time `nullable:"false"` Valid bool Method string `width:"32" charset:"ascii"` AuditIds string `width:"256" charset:"utf8" index:"true"` UserId string `width:"128" charset:"ascii" nullable:"false"` ProjectId string `width:"128" charset:"ascii" nullable:"true"` DomainId string `width:"128" charset:"ascii" nullable:"true"` Source string `width:"16" charset:"ascii"` Ip string `width:"64" charset:"ascii"` }
type STokenCacheManager ¶
type STokenCacheManager struct {
db.SStandaloneAnonResourceBaseManager
}
var TokenCacheManager *STokenCacheManager
func (*STokenCacheManager) BatchInvalidate ¶
func (manager *STokenCacheManager) BatchInvalidate(ctx context.Context, userCred mcclient.TokenCredential, method string, auditIds []string) error
func (*STokenCacheManager) BatchInvalidateByUserId ¶
func (manager *STokenCacheManager) BatchInvalidateByUserId(ctx context.Context, userCred mcclient.TokenCredential, uid string) error
func (*STokenCacheManager) FetchInvalidTokens ¶
func (manager *STokenCacheManager) FetchInvalidTokens() ([]string, error)
func (*STokenCacheManager) FetchToken ¶
func (manager *STokenCacheManager) FetchToken(tokenStr string) (*STokenCache, error)
func (*STokenCacheManager) Invalidate ¶
func (manager *STokenCacheManager) Invalidate(ctx context.Context, userCred mcclient.TokenCredential, tokenStr string) error
type SUser ¶
type SUser struct { db.SRecordChecksumResourceBase SEnabledIdentityBaseResource // 用户邮箱 Email string `width:"64" charset:"utf8" nullable:"true" index:"true" list:"domain" update:"domain" create:"domain_optional"` // 用户手机号 Mobile string `width:"20" charset:"utf8" nullable:"true" index:"true" list:"domain" update:"domain" create:"domain_optional"` // 显示名称,用户登录后显示在右上角菜单入口 Displayname string `with:"128" charset:"utf8" nullable:"true" list:"domain" update:"domain" create:"domain_optional"` // 上次登录时间 LastActiveAt time.Time `nullable:"true" list:"domain"` // 上次用户登录IP LastLoginIp string `nullable:"true" list:"domain"` // 上次用户登录方式,可能值有:web(web控制台),cli(命令行climc),API(api) LastLoginSource string `nullable:"true" list:"domain"` // 是否为系统账号,系统账号不会检查密码复杂度,默认不在列表显示 IsSystemAccount tristate.TriState `default:"false" list:"domain" update:"admin" create:"admin_optional"` // deprecated DefaultProjectId string `width:"64" charset:"ascii" nullable:"true"` // 是否允许登录Web控制台,如果是用于API访问的用户,可禁用web控制台登录 AllowWebConsole tristate.TriState `default:"true" list:"domain" update:"domain" create:"domain_optional"` // 是否开启MFA EnableMfa tristate.TriState `default:"false" list:"domain" update:"domain" create:"domain_optional"` // 用户的默认语言设置,默认是zh_CN Lang string `width:"8" charset:"ascii" nullable:"false" list:"domain" update:"domain" create:"domain_optional"` }
func (*SUser) DeleteInContext ¶
func (user *SUser) DeleteInContext(ctx context.Context, userCred mcclient.TokenCredential, ctxObjs []db.IModel, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error)
func (*SUser) GetCredentialCount ¶
func (*SUser) GetGroupCount ¶
func (*SUser) GetProjectCount ¶
func (*SUser) IsAdminUser ¶
func (*SUser) LinkedWithIdp ¶
func (*SUser) PerformDisable ¶
func (user *SUser) PerformDisable( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformDisableInput, ) (jsonutils.JSONObject, error)
func (*SUser) PerformEnable ¶
func (user *SUser) PerformEnable( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input apis.PerformEnableInput, ) (jsonutils.JSONObject, error)
func (*SUser) PerformJoin ¶
func (user *SUser) PerformJoin( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.SJoinProjectsInput, ) (jsonutils.JSONObject, error)
用户加入项目
func (*SUser) PerformLeave ¶
func (user *SUser) PerformLeave( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.SLeaveProjectsInput, ) (jsonutils.JSONObject, error)
用户退出项目
func (*SUser) PerformLinkIdp ¶
func (user *SUser) PerformLinkIdp( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.UserLinkIdpInput, ) (jsonutils.JSONObject, error)
用户和IDP的指定entityId关联
func (*SUser) PerformResetCredentials ¶
func (user *SUser) PerformResetCredentials( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.ResetCredentialInput, ) (jsonutils.JSONObject, error)
用户加入项目
func (*SUser) PerformUnlinkIdp ¶
func (user *SUser) PerformUnlinkIdp( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.UserUnlinkIdpInput, ) (jsonutils.JSONObject, error)
用户和IDP的指定entityId解除关联
func (*SUser) PostCreate ¶
func (user *SUser) PostCreate(ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SUser) PostUpdate ¶
func (user *SUser) PostUpdate(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, data jsonutils.JSONObject)
func (*SUser) UpdateInContext ¶
func (user *SUser) UpdateInContext(ctx context.Context, userCred mcclient.TokenCredential, ctxObjs []db.IModel, query jsonutils.JSONObject, data jsonutils.JSONObject) (jsonutils.JSONObject, error)
func (*SUser) ValidateDeleteCondition ¶
func (*SUser) ValidateUpdateCondition ¶
func (*SUser) ValidateUpdateData ¶
func (user *SUser) ValidateUpdateData(ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, input api.UserUpdateInput) (api.UserUpdateInput, error)
type SUserManager ¶
type SUserManager struct { SEnabledIdentityBaseResourceManager db.SRecordChecksumResourceBaseManager }
var UserManager *SUserManager
func (*SUserManager) FetchCustomizeColumns ¶
func (manager *SUserManager) FetchCustomizeColumns( ctx context.Context, userCred mcclient.TokenCredential, query jsonutils.JSONObject, objs []interface{}, fields stringutils2.SSortedStrings, isList bool, ) []api.UserDetails
func (*SUserManager) FetchScopeResources ¶
func (manager *SUserManager) FetchScopeResources(userIds []string) (map[string]api.ExternalResourceInfo, error)
func (*SUserManager) FetchUserExtended ¶
func (manager *SUserManager) FetchUserExtended(userId, userName, domainId, domainName string) (*api.SUserExtended, error)
Fetch extended userinfo by Id or name + domainId or name + domainName
func (*SUserManager) FetchUsersInDomain ¶
func (manager *SUserManager) FetchUsersInDomain(domainId string, excludes []string) ([]SUser, error)
func (*SUserManager) FilterByHiddenSystemAttributes ¶
func (manager *SUserManager) FilterByHiddenSystemAttributes(q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query jsonutils.JSONObject, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SUserManager) FilterByOwner ¶
func (manager *SUserManager) FilterByOwner(ctx context.Context, q *sqlchemy.SQuery, man db.FilterByOwnerProvider, userCred mcclient.TokenCredential, owner mcclient.IIdentityProvider, scope rbacscope.TRbacScope) *sqlchemy.SQuery
func (*SUserManager) GetContextManagers ¶
func (manager *SUserManager) GetContextManagers() [][]db.IModelManager
func (*SUserManager) InitializeData ¶
func (manager *SUserManager) InitializeData() error
func (*SUserManager) ListItemFilter ¶
func (manager *SUserManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.UserListInput, ) (*sqlchemy.SQuery, error)
用户列表
func (*SUserManager) LockUser ¶
func (manager *SUserManager) LockUser(uid string, reason string) error
func (*SUserManager) NamespaceScope ¶
func (manager *SUserManager) NamespaceScope() rbacscope.TRbacScope
func (*SUserManager) OrderByExtraFields ¶
func (manager *SUserManager) OrderByExtraFields( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.UserListInput, ) (*sqlchemy.SQuery, error)
func (*SUserManager) QueryDistinctExtraField ¶
func (*SUserManager) TotalResourceCount ¶
func (*SUserManager) TraceLoginV2 ¶
func (manager *SUserManager) TraceLoginV2(ctx context.Context, token *mcclient.TokenCredentialV2)
func (*SUserManager) TraceLoginV3 ¶
func (manager *SUserManager) TraceLoginV3(ctx context.Context, token *mcclient.TokenCredentialV3)
func (*SUserManager) ValidateCreateData ¶
func (manager *SUserManager) ValidateCreateData( ctx context.Context, userCred mcclient.TokenCredential, ownerId mcclient.IIdentityProvider, query jsonutils.JSONObject, input api.UserCreateInput, ) (api.UserCreateInput, error)
type SUserOption ¶
type SUserOption struct { db.SModelBase UserId string `width:"64" charset:"ascii" nullable:"false" primary:"true"` OptionId string `width:"4" charset:"ascii" nullable:"false" primary:"true"` OptionValue string `nullable:"true"` }
type SUserOptionManager ¶
type SUserOptionManager struct {
db.SModelBaseManager
}
+onecloud:swagger-gen-ignore
var (
UserOptionManager *SUserOptionManager
)
type SUserResourceBaseManager ¶
type SUserResourceBaseManager struct{}
func (*SUserResourceBaseManager) ListItemFilter ¶
func (manager *SUserResourceBaseManager) ListItemFilter( ctx context.Context, q *sqlchemy.SQuery, userCred mcclient.TokenCredential, query api.UserFilterListInput, ) (*sqlchemy.SQuery, error)
type SUserUsageCount ¶
type SUsergroupManager ¶
type SUsergroupManager struct {
db.SResourceBaseManager
}
+onecloud:swagger-gen-ignore
var UsergroupManager *SUsergroupManager
func (*SUsergroupManager) SyncGroupUsers ¶
func (manager *SUsergroupManager) SyncGroupUsers(ctx context.Context, userCred mcclient.TokenCredential, groupId string, userIds []string)
func (*SUsergroupManager) SyncUserGroups ¶
func (manager *SUsergroupManager) SyncUserGroups(ctx context.Context, userCred mcclient.TokenCredential, userId string, groupIds []string)
type SUsergroupMembership ¶
type SUsergroupMembership struct { db.SResourceBase UserId string `width:"64" charset:"ascii" nullable:"false" primary:"true"` GroupId string `width:"64" charset:"ascii" nullable:"false" primary:"true"` }
+onecloud:swagger-gen-ignore
func (*SUsergroupMembership) GetId ¶
func (membership *SUsergroupMembership) GetId() string
func (*SUsergroupMembership) GetName ¶
func (membership *SUsergroupMembership) GetName() string
type SetIdentityQuotaInput ¶
type SetIdentityQuotaInput struct { quotas.SBaseQuotaSetInput SIdentityQuota }
设置域的认证配额输入参数
type TConfigOptions ¶
type TConfigOptions []SConfigOption
func (TConfigOptions) Len ¶
func (opts TConfigOptions) Len() int
func (TConfigOptions) Less ¶
func (opts TConfigOptions) Less(i, j int) bool
func (TConfigOptions) Swap ¶
func (opts TConfigOptions) Swap(i, j int)
func (TConfigOptions) Validate ¶
func (opts TConfigOptions) Validate() error
Source Files ¶
- assignments.go
- configs.go
- credentials.go
- default_admin.go
- doc.go
- domains.go
- endpoints.go
- expandidps.go
- federated_user.go
- federation_protocol.go
- fernetkeys.go
- groupresource.go
- groups.go
- id_mappings.go
- identity_provider.go
- identitybase.go
- identityquota.go
- idp_remote_ids.go
- implied_role.go
- initdb.go
- localusers.go
- nonlocal_users.go
- organization_nodes.go
- organizations.go
- passwords.go
- policies.go
- project_resources.go
- projectresource.go
- projects.go
- regionresource.go
- regions.go
- rolepolicies.go
- roleresource.go
- roles.go
- servicecertificates.go
- serviceresource.go
- services.go
- sync.go
- syncworker.go
- tokencache.go
- usages.go
- user_group_memberships.go
- user_option.go
- userresource.go
- users.go