Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds latest IAM updates from AWS #1197

Merged
merged 1 commit into from
Mar 11, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions CHANGELOG/v0.681.0.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
**New actions:**

- elasticloadbalancing:ModifyIpPools
- support:GetInteraction
- support:StartInteraction

**New condition keys:**

- codeconnections:VpcId
- codestar-connections:VpcId
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
Support for:

- 419 Services
- 18398 Actions
- 18401 Actions
- 1972 Resource Types
- 1929 Condition keys
- 1931 Condition keys
<!-- /stats -->

![EXPERIMENTAL](https://img.shields.io/badge/stability-experimantal-orange?style=for-the-badge)**<br>This is an early version of the package. The API will change while I implement new features. Therefore make sure you use an exact version in your `package.json` before it reaches 1.0.0.**
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.680.0
0.681.0
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
author = 'Daniel Schroeder'

# The full version, including alpha/beta/rc tags
release = '0.680.0'
release = '0.681.0'

# -- General configuration ---------------------------------------------------

Expand Down
4 changes: 2 additions & 2 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,9 @@ AWS IAM policy statement generator with fluent interface.
Support for:

- 419 Services
- 18398 Actions
- 18401 Actions
- 1972 Resource Types
- 1929 Condition keys
- 1931 Condition keys

..
/stats
Expand Down
20 changes: 20 additions & 0 deletions lib/generated/policy-statements/codeconnections.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ export class Codeconnections extends PolicyStatement {
* - .ifAwsRequestTag()
* - .ifAwsTagKeys()
* - .ifProviderType()
* - .ifVpcId()
*
* https://docs.aws.amazon.com/codeconnections/latest/APIReference/API_CreateHost.html
*/
Expand Down Expand Up @@ -464,6 +465,9 @@ export class Codeconnections extends PolicyStatement {
*
* Access Level: Write
*
* Possible conditions:
* - .ifVpcId()
*
* https://docs.aws.amazon.com/codeconnections/latest/APIReference/API_UpdateHost.html
*/
public toUpdateHost() {
Expand Down Expand Up @@ -869,4 +873,20 @@ export class Codeconnections extends PolicyStatement {
public ifRepositoryName(value: string | string[], operator?: Operator | string) {
return this.if(`RepositoryName`, value, operator ?? 'StringLike');
}

/**
* Filters access by the VpcId passed in the request
*
* https://docs.aws.amazon.com/dtconsole/latest/userguide/security-iam.html#permissions-reference-connections-hosts
*
* Applies to actions:
* - .toCreateHost()
* - .toUpdateHost()
*
* @param value The value(s) to check
* @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike`
*/
public ifVpcId(value: string | string[], operator?: Operator | string) {
return this.if(`VpcId`, value, operator ?? 'StringLike');
}
}
20 changes: 20 additions & 0 deletions lib/generated/policy-statements/codestarconnections.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ export class CodestarConnections extends PolicyStatement {
* - .ifAwsRequestTag()
* - .ifAwsTagKeys()
* - .ifProviderType()
* - .ifVpcId()
*
* https://docs.aws.amazon.com/codestar-connections/latest/APIReference/API_CreateHost.html
*/
Expand Down Expand Up @@ -464,6 +465,9 @@ export class CodestarConnections extends PolicyStatement {
*
* Access Level: Write
*
* Possible conditions:
* - .ifVpcId()
*
* https://docs.aws.amazon.com/codestar-connections/latest/APIReference/API_UpdateHost.html
*/
public toUpdateHost() {
Expand Down Expand Up @@ -869,4 +873,20 @@ export class CodestarConnections extends PolicyStatement {
public ifRepositoryName(value: string | string[], operator?: Operator | string) {
return this.if(`RepositoryName`, value, operator ?? 'StringLike');
}

/**
* Filters access by the VpcId passed in the request
*
* https://docs.aws.amazon.com/dtconsole/latest/userguide/security-iam.html#permissions-reference-connections-hosts
*
* Applies to actions:
* - .toCreateHost()
* - .toUpdateHost()
*
* @param value The value(s) to check
* @param operator Works with [string operators](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_policies_elements_condition_operators.html#Conditions_String). **Default:** `StringLike`
*/
public ifVpcId(value: string | string[], operator?: Operator | string) {
return this.if(`VpcId`, value, operator ?? 'StringLike');
}
}
18 changes: 18 additions & 0 deletions lib/generated/policy-statements/elasticloadbalancingv2.ts
Original file line number Diff line number Diff line change
Expand Up @@ -512,6 +512,21 @@ export class ElasticloadbalancingV2 extends PolicyStatement {
return this.to('ModifyCapacityReservation');
}

/**
* Grants permission to modify the ip pools for a load balancer
*
* Access Level: Write
*
* Possible conditions:
* - .ifAwsResourceTag()
* - .ifResourceTag()
*
* https://docs.aws.amazon.com/elasticloadbalancing/latest/APIReference/API_ModifyIpPools.html
*/
public toModifyIpPools() {
return this.to('ModifyIpPools');
}

/**
* Grants permission to modify the specified properties of the specified listener
*
Expand Down Expand Up @@ -767,6 +782,7 @@ export class ElasticloadbalancingV2 extends PolicyStatement {
'DeleteTrustStore',
'DeregisterTargets',
'ModifyCapacityReservation',
'ModifyIpPools',
'ModifyListener',
'ModifyListenerAttributes',
'ModifyLoadBalancerAttributes',
Expand Down Expand Up @@ -1015,6 +1031,7 @@ export class ElasticloadbalancingV2 extends PolicyStatement {
* - .toGetTrustStoreCaCertificatesBundle()
* - .toGetTrustStoreRevocationContent()
* - .toModifyCapacityReservation()
* - .toModifyIpPools()
* - .toModifyListener()
* - .toModifyListenerAttributes()
* - .toModifyLoadBalancerAttributes()
Expand Down Expand Up @@ -1125,6 +1142,7 @@ export class ElasticloadbalancingV2 extends PolicyStatement {
* - .toGetTrustStoreCaCertificatesBundle()
* - .toGetTrustStoreRevocationContent()
* - .toModifyCapacityReservation()
* - .toModifyIpPools()
* - .toModifyListener()
* - .toModifyListenerAttributes()
* - .toModifyLoadBalancerAttributes()
Expand Down
26 changes: 25 additions & 1 deletion lib/generated/policy-statements/support.ts
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,17 @@ export class Support extends PolicyStatement {
return this.to('DescribeTrustedAdvisorChecks');
}

/**
* Grants permission to retrieve personalized troubleshooting assistance for account and technical issues for a specific interaction
*
* Access Level: Read
*
* https://docs.aws.amazon.com/awssupport/latest/APIReference/API_GetInteraction.html
*/
public toGetInteraction() {
return this.to('GetInteraction');
}

/**
* Grants permission to initiate a call on AWS Support Center. This is an internally managed function
*
Expand Down Expand Up @@ -293,6 +304,17 @@ export class Support extends PolicyStatement {
return this.to('SearchForCases');
}

/**
* Grants permission to start a specific interaction to receive personalized troubleshooting assistance for account and technical issues
*
* Access Level: Write
*
* https://docs.aws.amazon.com/awssupport/latest/APIReference/API_StartInteraction.html
*/
public toStartInteraction() {
return this.to('StartInteraction');
}

protected accessLevelList: AccessLevelList = {
Write: [
'AddAttachmentsToSet',
Expand All @@ -303,7 +325,8 @@ export class Support extends PolicyStatement {
'PutCaseAttributes',
'RateCaseCommunication',
'RefreshTrustedAdvisorCheck',
'ResolveCase'
'ResolveCase',
'StartInteraction'
],
Read: [
'DescribeAttachment',
Expand All @@ -321,6 +344,7 @@ export class Support extends PolicyStatement {
'DescribeTrustedAdvisorCheckResult',
'DescribeTrustedAdvisorCheckSummaries',
'DescribeTrustedAdvisorChecks',
'GetInteraction',
'SearchForCases'
]
};
Expand Down
1 change: 1 addition & 0 deletions stats/actions/elasticloadbalancing
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ elasticloadbalancing:GetResourcePolicy;Read
elasticloadbalancing:GetTrustStoreCaCertificatesBundle;Read
elasticloadbalancing:GetTrustStoreRevocationContent;Read
elasticloadbalancing:ModifyCapacityReservation;Write
elasticloadbalancing:ModifyIpPools;Write
elasticloadbalancing:ModifyListener;Write
elasticloadbalancing:ModifyListenerAttributes;Write
elasticloadbalancing:ModifyLoadBalancerAttributes;Write
Expand Down
2 changes: 2 additions & 0 deletions stats/actions/support
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@ support:DescribeTrustedAdvisorCheckRefreshStatuses;Read
support:DescribeTrustedAdvisorCheckResult;Read
support:DescribeTrustedAdvisorCheckSummaries;Read
support:DescribeTrustedAdvisorChecks;Read
support:GetInteraction;Read
support:InitiateCallForCase;Write
support:InitiateChatForCase;Write
support:PutCaseAttributes;Write
support:RateCaseCommunication;Write
support:RefreshTrustedAdvisorCheck;Write
support:ResolveCase;Write
support:SearchForCases;Read
support:StartInteraction;Write
1 change: 1 addition & 0 deletions stats/conditions/codeconnections
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,4 @@ codeconnections:RepositoryName
codeconnections:RequestTag/${TagKey}
codeconnections:ResourceTag/${TagKey}
codeconnections:TagKeys
codeconnections:VpcId
1 change: 1 addition & 0 deletions stats/conditions/codestar-connections
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,4 @@ codestar-connections:RepositoryName
codestar-connections:RequestTag/${TagKey}
codestar-connections:ResourceTag/${TagKey}
codestar-connections:TagKeys
codestar-connections:VpcId