iam

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2024 License: AGPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AwsClient

type AwsClient interface {
	GetRegion() ptypes.AwsRegion
	GetAccountID() ptypes.AwsAccountID
	IAM() *iam.Client
}

type IamRepository

type IamRepository struct {
	// contains filtered or unexported fields
}

func NewIamRepository

func NewIamRepository(ctx context.Context, client AwsClient) *IamRepository

func (*IamRepository) DescribePolicyByInput

func (r *IamRepository) DescribePolicyByInput(query *iam.GetPolicyInput) (*Policy, error)

func (*IamRepository) DescribePolicyVersion

func (r *IamRepository) DescribePolicyVersion(policy Policy) (*PolicyVersion, error)

func (*IamRepository) DescribePolicyVersionByInput

func (r *IamRepository) DescribePolicyVersionByInput(query *iam.GetPolicyVersionInput) (*PolicyVersion, error)

func (*IamRepository) DescribeRoleByArn

func (r *IamRepository) DescribeRoleByArn(roleArn string) (*Role, error)

func (*IamRepository) DescribeRoleByInput

func (r *IamRepository) DescribeRoleByInput(query *iam.GetRoleInput) (*Role, error)

func (*IamRepository) GetRegion

func (r *IamRepository) GetRegion() ptypes.AwsRegion

func (*IamRepository) ListAssumedRoleArn

func (r *IamRepository) ListAssumedRoleArn(policyVersion PolicyVersion) []RoleArn

func (*IamRepository) ListAttachedRolePoliciesByInput

func (r *IamRepository) ListAttachedRolePoliciesByInput(query *iam.ListAttachedRolePoliciesInput) ([]Policy, error)

func (*IamRepository) ListAttachedRolePoliciesByRole

func (r *IamRepository) ListAttachedRolePoliciesByRole(role Role) ([]Policy, error)

func (*IamRepository) ListAttachedRolePolicyVersionsByInput

func (r *IamRepository) ListAttachedRolePolicyVersionsByInput(query *iam.ListAttachedRolePoliciesInput) ([]PolicyVersion, error)

func (*IamRepository) ListAttachedRolePolicyVersionsByRole

func (r *IamRepository) ListAttachedRolePolicyVersionsByRole(role Role) ([]PolicyVersion, error)

func (*IamRepository) ListAttachedRolePolicyVersionsByRoleName

func (r *IamRepository) ListAttachedRolePolicyVersionsByRoleName(name string) ([]PolicyVersion, error)

func (*IamRepository) ListPoliciesAll

func (r *IamRepository) ListPoliciesAll() ([]Policy, error)

func (*IamRepository) ListPoliciesByInput

func (r *IamRepository) ListPoliciesByInput(query *iam.ListPoliciesInput) ([]Policy, error)

func (*IamRepository) ListPolicyTags

func (r *IamRepository) ListPolicyTags(policy types.Policy) ([]types.Tag, error)

func (*IamRepository) ListRoleTags

func (r *IamRepository) ListRoleTags(role types.Role) ([]types.Tag, error)

func (*IamRepository) ListRolesAll

func (r *IamRepository) ListRolesAll() ([]Role, error)

func (*IamRepository) ListRolesByInput

func (r *IamRepository) ListRolesByInput(query *iam.ListRolesInput) ([]Role, error)

func (*IamRepository) ListUserTags

func (r *IamRepository) ListUserTags(user types.User) ([]types.Tag, error)

func (*IamRepository) ListUsersAll

func (r *IamRepository) ListUsersAll() ([]User, error)

func (*IamRepository) ListUsersByInput

func (r *IamRepository) ListUsersByInput(query *iam.ListUsersInput) ([]User, error)

type Policy

type Policy struct {
	service.AbstractResource
	types.Policy
}

func NewPolicy

func NewPolicy(client AwsClient, policy types.Policy) Policy

func (Policy) GetName

func (e Policy) GetName() string

func (Policy) GetTagValue

func (e Policy) GetTagValue(tag string) string

func (Policy) GetTags

func (e Policy) GetTags() map[string]string

type PolicyDocument

type PolicyDocument struct {
	Version   string      `json:"Version"`
	Statement []Statement `json:"Statement"`
}

type PolicyList

type PolicyList struct {
	Items []Policy
}

type PolicyVersion

type PolicyVersion struct {
	types.PolicyVersion
	// contains filtered or unexported fields
}

func NewPolicyVersion

func NewPolicyVersion(policyVersion types.PolicyVersion, document PolicyDocument) PolicyVersion

func (PolicyVersion) GetDocument

func (p PolicyVersion) GetDocument() PolicyDocument

type Role

type Role struct {
	service.AbstractResource
	types.Role
}

func NewRole

func NewRole(client AwsClient, role types.Role) Role

func (Role) GetName

func (e Role) GetName() string

func (Role) GetTagValue

func (e Role) GetTagValue(tag string) string

func (Role) GetTags

func (e Role) GetTags() map[string]string

type RoleArn

type RoleArn string

func (RoleArn) String

func (r RoleArn) String() string

type RoleList

type RoleList struct {
	Items []Role
}

type Statement

type Statement struct {
	Effect   string      `json:"Effect"`
	Action   interface{} `json:"Action"`
	Resource interface{} `json:"Resource"`
}

type User

type User struct {
	service.AbstractResource
	types.User
}

func NewUser

func NewUser(client AwsClient, user types.User) User

func (User) GetName

func (e User) GetName() string

func (User) GetTagValue

func (e User) GetTagValue(tag string) string

func (User) GetTags

func (e User) GetTags() map[string]string

type UserList

type UserList struct {
	Items []User
}

Jump to

Keyboard shortcuts

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