func GetAttachedPoliciesMapForGroup(groupname *string, svc *iam.Client) map[string]string {
	result := make(map[string]string)
	params := &iam.ListAttachedGroupPoliciesInput{
		GroupName: groupname,
	}
	resp, err := svc.ListAttachedGroupPolicies(context.TODO(), params)
	if err != nil {
		panic(err)
	}
	if len(resp.AttachedPolicies) > 0 {
		for _, policy := range resp.AttachedPolicies {
			result[*policy.PolicyName] = getAttachedPolicy(policy.PolicyArn, svc)
		}
	}
	return result
}
// GetAttachedPoliciesMapForGroup retrieves a map of attached policies for the
// provided IAM groupname where the key is the name of the policy and the value
// is the actual json policy document
GetAttachedPoliciesMapForGroup retrieves a map of attached policies for the
provided IAM groupname where the key is the name of the policy and the value
is the actual json policy document
// GetAttachedPoliciesMapForGroup retrieves a map of attached policies for the // provided IAM groupname where the key is the name of the policy and the value // is the actual json policy document
func GetAttachedPoliciesMapForGroup(groupname *string, svc *iam.Client) map[string]string {
	result := make(map[string]string)
	params := &iam.ListAttachedGroupPoliciesInput{
		GroupName: groupname,
	}
	resp, err := svc.ListAttachedGroupPolicies(context.TODO(), params)
	if err != nil {
		panic(err)
	}
	if len(resp.AttachedPolicies) > 0 {
		for _, policy := range resp.AttachedPolicies {
			result[*policy.PolicyName] = getAttachedPolicy(policy.PolicyArn, svc)
		}
	}
	return result
}
func GetAttachedPoliciesMapForGroup ( groupname * string , svc * iam . Client ) map [ string ] string { result := make ( map [ string ] string ) params := & iam . ListAttachedGroupPoliciesInput { GroupName : groupname , } resp , err := svc . ListAttachedGroupPolicies ( context . TODO ( ) , params ) if err != nil { panic ( err ) } if len ( resp . AttachedPolicies ) > 0 { for _ , policy := range resp . AttachedPolicies { result [ * policy . PolicyName ] = getAttachedPolicy ( policy . PolicyArn , svc ) } } return result }
GetAttachedPoliciesMapForGroup retrieves a map of attached policies for the
provided IAM groupname where the key is the name of the policy and the value
is the actual json policy document
GetAttachedPoliciesMapForGroup retrieves a map of attached policies for the provided IAM groupname where the key is the name of the policy and the value is the actual json policy document