> For the complete documentation index, see [llms.txt](https://hawkins.gitbook.io/consoleme/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hawkins.gitbook.io/consoleme/configuration/role-credential-authorization/role-tagging-recommended/role-tagging-service-control-policy-recommended.md).

# Role Tagging Service Control Policy (Recommended)

We highly recommend that you prevent unauthorized services from modifying sensitive tags. In order to do this, we recommend using an organizational-wide Service Control Policy (SCP).

1. Log in to your AWS Organizations master account and create an SCP
2. Configure it with a policy similar to the one below. Be sure to rename **sensitivetagprefix-** to whatever you've decided as a tag prefix. Also ensure that the Principal ARNs match what your ConsoleMe Spoke account roles are named. Add any administrative or fallback users that will need to also perform tagging.
3. Attach this policy to all of your accounts. Use discretion and roll it out slowly if you're concerned about breakage.

```
{
    "Version": "2012-10-17",
    "Statement": [
        {
            "Sid": "protectmytags",
            "Effect": "Deny",
            "Action": [
                "iam:CreateRole",
                "iam:TagRole",
                "iam:UntagRole",
                "iam:CreateUser",
                "iam:TagUser",
                "iam:UntagUser"
            ],
            "Resource": [
                "*"
            ],
            "Condition": {
                "ForAnyValue:StringLike": {
                    "aws:TagKeys": [
                        "sensitivetagprefix-*"
                    ]
                },
                "StringNotLike": {
                    "aws:PrincipalArn": [
                        "arn:aws:iam::*:role/ConsoleMe"
                    ]
                }
            }
        }
    ]
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://hawkins.gitbook.io/consoleme/configuration/role-credential-authorization/role-tagging-recommended/role-tagging-service-control-policy-recommended.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
