core

package
v0.2.1-dev.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 21, 2024 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AzureRmConfigStructLevelValidation

func AzureRmConfigStructLevelValidation(sl validator.StructLevel)

func ScopeConfigurationStructLevelValidation added in v0.1.0

func ScopeConfigurationStructLevelValidation(sl validator.StructLevel)

Types

type AzureRmConfig

type AzureRmConfig struct {
	Groups   []*Principal                   `validate:"dive"`
	Policies []*Policy                      `validate:"dive"`
	Rulesets []*RoleManagementPolicyRuleset `validate:"dive"`
	Users    []*Principal                   `validate:"dive"`
}

func (*AzureRmConfig) GetGroupAssignmentSchedules added in v0.1.0

func (c *AzureRmConfig) GetGroupAssignmentSchedules(subscriptionId string) []*Schedule

func (*AzureRmConfig) GetGroupEligibilitySchedules added in v0.1.0

func (c *AzureRmConfig) GetGroupEligibilitySchedules(subscriptionId string) []*Schedule

func (*AzureRmConfig) GetPolicyByRoleName added in v0.2.0

func (c *AzureRmConfig) GetPolicyByRoleName(roleName string) *Policy

func (*AzureRmConfig) GetScopeRoleNameCombinations added in v0.1.0

func (c *AzureRmConfig) GetScopeRoleNameCombinations(subscriptionId string) []*ScopeRoleNameCombination

func (*AzureRmConfig) GetUserAssignmentSchedules added in v0.1.0

func (c *AzureRmConfig) GetUserAssignmentSchedules(subscriptionId string) []*Schedule

func (*AzureRmConfig) GetUserEligibilitySchedules added in v0.1.0

func (c *AzureRmConfig) GetUserEligibilitySchedules(subscriptionId string) []*Schedule

func (*AzureRmConfig) Validate

func (c *AzureRmConfig) Validate() error

type ConfigurationEmptyError

type ConfigurationEmptyError struct{}

func (*ConfigurationEmptyError) Error

func (m *ConfigurationEmptyError) Error() string

type Policy added in v0.1.0

type Policy struct {
	Default        []*RulesetReference `yaml:"default"`
	Name           string
	Subscription   []*RulesetReference            `yaml:"subscription"`
	ResourceGroups map[string][]*RulesetReference `yaml:"resourceGroups"`
	Resources      map[string][]*RulesetReference `yaml:"resources"`
}

func (*Policy) GetRulesetReferencesForScope added in v0.2.0

func (p *Policy) GetRulesetReferencesForScope(scope string, subscriptionId string) []*RulesetReference

type Principal

type Principal struct {
	Name           string
	Subscription   *ScopeConfiguration            `yaml:"subscription"`
	ResourceGroups map[string]*ScopeConfiguration `yaml:"resourceGroups"`
	Resources      map[string]*ScopeConfiguration `yaml:"resources"`
}

type RoleAssignmentScheduleCreate added in v0.1.0

type RoleAssignmentScheduleCreate struct {
	EndDateTime                       *time.Time
	PrincipalName                     string
	PrincipalType                     armauthorization.PrincipalType
	RoleAssignmentScheduleRequest     *armauthorization.RoleAssignmentScheduleRequest
	RoleAssignmentScheduleRequestName string
	RoleName                          string
	Scope                             string
	StartDateTime                     *time.Time
}

type RoleAssignmentScheduleDelete added in v0.1.0

type RoleAssignmentScheduleDelete struct {
	Cancel                            bool
	EndDateTime                       *time.Time
	PrincipalName                     string
	PrincipalType                     armauthorization.PrincipalType
	RoleAssignmentScheduleRequest     *armauthorization.RoleAssignmentScheduleRequest
	RoleAssignmentScheduleRequestName string
	RoleName                          string
	Scope                             string
	StartDateTime                     *time.Time
}

type RoleAssignmentScheduleUpdate added in v0.1.0

type RoleAssignmentScheduleUpdate struct {
	EndDateTime                       *time.Time
	PrincipalName                     string
	PrincipalType                     armauthorization.PrincipalType
	RoleAssignmentScheduleRequest     *armauthorization.RoleAssignmentScheduleRequest
	RoleAssignmentScheduleRequestName string
	RoleName                          string
	Scope                             string
	StartDateTime                     *time.Time
}

type RoleEligibilityScheduleCreate

type RoleEligibilityScheduleCreate struct {
	EndDateTime                        *time.Time
	PrincipalName                      string
	PrincipalType                      armauthorization.PrincipalType
	RoleEligibilityScheduleRequest     *armauthorization.RoleEligibilityScheduleRequest
	RoleEligibilityScheduleRequestName string
	RoleName                           string
	Scope                              string
	StartDateTime                      *time.Time
}

type RoleEligibilityScheduleDelete

type RoleEligibilityScheduleDelete struct {
	Cancel                             bool
	EndDateTime                        *time.Time
	PrincipalName                      string
	PrincipalType                      armauthorization.PrincipalType
	RoleEligibilityScheduleRequest     *armauthorization.RoleEligibilityScheduleRequest
	RoleEligibilityScheduleRequestName string
	RoleName                           string
	Scope                              string
	StartDateTime                      *time.Time
}

type RoleEligibilityScheduleUpdate

type RoleEligibilityScheduleUpdate struct {
	EndDateTime                        *time.Time
	PrincipalName                      string
	PrincipalType                      armauthorization.PrincipalType
	RoleEligibilityScheduleRequest     *armauthorization.RoleEligibilityScheduleRequest
	RoleEligibilityScheduleRequestName string
	RoleName                           string
	Scope                              string
	StartDateTime                      *time.Time
}

type RoleManagementPolicyRule

type RoleManagementPolicyRule struct {
	ID    string      `yaml:"id" validate:"required"`
	Patch interface{} `yaml:"patch" validate:"required"`
}

type RoleManagementPolicyRuleset

type RoleManagementPolicyRuleset struct {
	Name  string
	Rules []*RoleManagementPolicyRule `yaml:"rules"`
}

type RoleManagementPolicyUpdate

type RoleManagementPolicyUpdate struct {
	RoleManagementPolicy *armauthorization.RoleManagementPolicy
	RoleName             string
	Scope                string
}

type RulesetReference added in v0.1.0

type RulesetReference struct {
	RulesetName string `yaml:"rulesetName" validate:"required"`
}

type Schedule added in v0.1.0

type Schedule struct {
	EndDateTime   *time.Time `yaml:"endDateTime"`
	PrincipalName string
	RoleName      string `yaml:"roleName" validate:"required"`
	Scope         string
	StartDateTime *time.Time `yaml:"startDateTime"`
}

type ScopeConfiguration added in v0.1.0

type ScopeConfiguration struct {
	Active   []*Schedule `yaml:"active"`
	Eligible []*Schedule `yaml:"eligible"`
}

type ScopeRoleNameCombination added in v0.1.0

type ScopeRoleNameCombination struct {
	RoleName string
	Scope    string
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL