# IAM 정책

## 리소스 유형

`AWS.IAM.Policy`

## 리소스 ID 형식

IAM 정책의 경우 리소스 ID는 ARN입니다.

`arn:aws:iam::123456789012:policy/example-policy`

## 배경

이 리소스는 IAM 정책을 나타냅니다. IAM 정책은 신원 또는 리소스에 연결될 때 해당 권한을 정의하는 엔터티입니다.\
IAM 정책을 연결할 수 있는 엔터티는 아래에 나열되어 있습니다:

{% content-ref url="/pages/79f8709f9e96e923d38966822efebff4112e0839" %}
[IAM 사용자](/ko/cloud-scanning/cloud-resource-attributes/aws/iam-user.md)
{% endcontent-ref %}

{% content-ref url="/pages/52cfea1f0f45000200b519a5001098256e7071b7" %}
[IAM 그룹](/ko/cloud-scanning/cloud-resource-attributes/aws/iam-group.md)
{% endcontent-ref %}

{% content-ref url="/pages/5e8d57ddf23dcdf42625e93c624a6af1cb74b916" %}
[IAM 역할](/ko/cloud-scanning/cloud-resource-attributes/aws/iam-role.md)
{% endcontent-ref %}

### AWS 관리형 정책

Panther는 IAM 엔터티에 연결된 경우에만 AWS 관리형 정책을 저장합니다.

IAM 정책은 전역적으로 고유한 네임스페이스 내에 존재하므로, Panther는 저장된 ARN은 유지하되 리소스 ID는 다음과 같이 수정합니다:

```go
// 원본 AWS 관리형 정책 ARN
arn:aws:iam::aws:policy/example-policy

// 저장된 리소스 ID
arn:aws:iam::{ACCOUNT-ID}:policy/example-policy
```

## 필드

| 필드                 | 유형    | 설명                                                                                                            |
| ------------------ | ----- | ------------------------------------------------------------------------------------------------------------- |
| `엔터티`              | `맵`   | 여기에는 세 개의 키가 있습니다, `PolicyGroups`, `PolicyRoles`와 `PolicyUsers`. 각 키는 정책이 연결된 IAM 그룹, 역할 또는 사용자 목록에 각각 매핑됩니다. |
| `AttachmentCount`  | `Int` | 정책이 연결된 엔터티(사용자, 그룹, 역할)의 수입니다.                                                                               |
| `DefaultVersionId` | `문자열` | 기본 버전으로 설정된 정책 버전의 식별자입니다.                                                                                    |
| `설명`               | `문자열` | 정책에 대한 친숙한 설명입니다.                                                                                             |
| `IsAttachable`     | `불리언` | 정책을 IAM 사용자, 그룹 또는 역할에 연결할 수 있는지 여부를 지정합니다.                                                                   |
| `Path`             | `문자열` | 정책의 경로입니다.                                                                                                    |
| `PolicyDocument`   | `문자열` | 이 정책이 부여하는 권한을 설명하는 JSON 정책 문서입니다.                                                                            |
| `UpdateDate`       | `문자열` | 정책이 마지막으로 업데이트된 시각을 ISO 8601 날짜-시간 형식으로 나타낸 것입니다.                                                             |

## 예시

```javascript
{
    "AccountId": "123456789012",
    "Arn": "arn:aws:iam::123456789012:policy/example-policy",
    "AttachmentCount": 1,
    "DefaultVersionId": "v1",
    "Description": null,
    "Entities": {
        "PolicyGroups": null,
        "PolicyRoles": [
            {
                "RoleId": "AAAA",
                "RoleName": "example-role"
            }
        ],
        "PolicyUsers": null
    },
    "Id": "1111",
    "IsAttachable": true,
    "Name": "example-policy",
    "Path": "/",
    "PermissionsBoundaryUsageCount": 0,
    "PolicyDocument": "{\"Version\":\"2012-10-17\",\"Statement\":[{\"Action\":[\"kms:Encrypt\",\"kms:Decrypt\",\"kms:GenerateDataKey\"],\"Resource\":\"arn:aws:kms:us-west-2:123456789012:key/1\",\"Effect\":\"Allow\",\"Sid\":\"DecryptSecrets\"},{\"Action\":[\"sqs:SendMessage\",\"sqs:SendMessageBatch\"],\"Resource\":[\"arn:aws:sqs:us-west-2:123456789012:example-queue\"],\"Effect\":\"Allow\",\"Sid\":\"SendSQSMessages\"}]}",
    "Region": "global",
    "ResourceId": "arn:aws:iam::123456789012:policy/example-policy",
    "ResourceType": "AWS.IAM.Policy",
    "Tags": null,
    "TimeCreated": "2019-01-01T00:00:00.000Z",
    "UpdateDate": "2019-01-01T00:00:00Z"
}
```


---

# Agent Instructions: 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://docs.panther.com/ko/cloud-scanning/cloud-resource-attributes/aws/iam-policy.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.
