iamservice

package
v1.14.0 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AncestryResource

type AncestryResource struct {
	Type string `json:"type"`
	Id   string `json:"id"`
}

AncestryResource represents a single resource in the project's ancestry.

type IAMService

type IAMService struct {
}

func New

func New() *IAMService

func (*IAMService) Policies

func (s *IAMService) Policies(resourceID string, resourceType string) ([]PolicyBinding, error)

Policies fetches IAM policy for a given resource and all policies in resource ancestry

func (*IAMService) PrincipalsWithRoles

func (s *IAMService) PrincipalsWithRoles(resourceID string, resourceType string) ([]PrincipalWithRoles, error)

type PolicyBinding

type PolicyBinding struct {
	Role         string   `json:"role"`
	Members      []string `json:"members"`
	ResourceID   string   `json:"resourceID"`
	ResourceType string
	PolicyName   string `json:"policyBindings"`
	Condition    string
}

PolicyBindings represents IAM policy bindings.

type PrincipalWithRoles

type PrincipalWithRoles struct {
	Name           string
	Type           string
	PolicyBindings []PolicyBinding
	ResourceID     string
	ResourceType   string
}

Jump to

Keyboard shortcuts

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