There is no Condition field in the IAMPolicyStatement
- Dominant language
- Go
- Stars
- 3.8k
- Forks
- 578
- Avg merge
- 8h 18m
- Merged PRs (30d)
- 1
Description
**Is your feature request related to a problem? Please describe.**
The following policy cannot be used with Lambda Custom Authorizer because there is no Condition field in the [IAMPolicyStatement](https://pkg.go.dev/github.com/aws/aws-lambda-go/events#IAMPolicyStatement).
```json
{
"Version": "2012-10-17",
"Statement": [
{
"Effect": "Deny",
"Action": "execute-api:Invoke",
"Resource": "execute-api:/{{stageNameOrWildcard}}/{{httpVerbOrWildcard}}/{{resourcePathOrWildcard}}",
"Condition" : {
"IpAddress": {
"aws:SourceIp": [ "{{sourceIpOrCIDRBlock}}", "{{sourceIpOrCIDRBlock}}" ]
}
}
}
]
}
```
**Describe the solution you'd like**
Add a Condition field to the IAMPolicyStatement.
**Describe alternatives you've considered**
**Additional context**
Contributor guide
Assessment
This issue has not been assessed yet.