Skip to content

How to reduce the scope of the IAM policy? #51

Answered by bhoradc
goenning asked this question in Q&A
Discussion options

You must be logged in to vote

Hello @goenning,

You can create IAM policies to restrict access to AWS Systems manager API operations/parameters.

For instance, if we want to allow PutParameter SSM operation for parameters that begin with put*, you can restrict this access at the parameter/resource level in IAM policy as below:

{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "rule1",
            "Effect": "Allow",
            "Action": [
                "ssm:PutParameter",
                "ssm:GetParametersByPath"
            ],
            "Resource": "arn:aws:ssm:<region>:<account-id>:parameter/put*"
        }
    ]
}

And then when you execute below snippet to create/update parameter to t…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by ashishdhingra
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
2 participants
Converted from issue

This discussion was converted from issue #50 on March 30, 2023 16:15.