---
title: "Terraform plan IAM policy diff for AWS pull requests | IAM Policy Lint"
description: "Open a saved Terraform plan JSON, see which AWS IAM policy statements changed, and copy a pull-request note that holds only counts."
url: https://usefultabs.com/tools/iam-policy-lint/
---

[All tools](https://usefultabs.com/tools/)

# IAM Policy Lint: Terraform plan IAM policy diff for AWS pull requests

Open a saved Terraform plan JSON, see which AWS IAM policy statements changed, and copy a pull-request note that holds only counts.

Free No sign-up Runs in your browser

[Open IAM Policy Lint →](https://usefultabs.com/iam-policy-lint/)

## See it work

Three changed policies and one review gap are counted in the PR note.

The note you paste into the pull request: counts only, ready to copy.

Changes it cannot read are named, not guessed: unknown until apply, unsupported types.

## Before you start

As it opens: nothing to install, no sign-up.

The same tool on a phone.

## What it does

IAM Policy Lint compares the AWS IAM policy documents in one saved Terraform plan and shows the statements added and removed. It is for engineers who review a pull request that changes IAM and need to leave a note without pasting role names, account IDs or policy values into the thread.

- Compares managed policies, inline role policies and role trust policies, statement by statement.
- Ignores statement order and object key order. Order inside lists, such as `Action`, still counts.

- Shows added and removed statements and changed top-level fields on the page.
- Lists IAM changes it cannot review, with the reason, such as a policy that is unknown until apply.

- Writes a Markdown note from fixed words and counts, with no addresses, names, ARNs, actions, values or file names.

## How to use it

- Save the plan as JSON: `terraform plan -out=plan.tfplan`, then `terraform show -json plan.tfplan > plan.json`.
- Drop `plan.json` on the page, or choose it. The limit is one `.json` file of up to 10 MiB.

- Read the added and removed statements and check anything listed as unreviewed.
- Press **Copy PR note** and paste it into the pull request.

## What it does not do

- It compares three fields only: `aws_iam_policy.policy`, `aws_iam_role_policy.policy` and `aws_iam_role.assume_role_policy`, from the HashiCorp AWS provider on the Terraform or OpenTofu registry.
- It does not read or list policies on other resource types, such as S3 bucket policies or KMS key policies.

- Attachment resources, other `aws_iam_*` types, changes to a role's `inline_policy` or `managed_policy_arns`, deferred changes, values unknown until apply and unreadable policies are listed as unreviewed.
- Despite the name, it is not a linter: it does not validate policy syntax, flag risky or privilege-escalation actions, work out effective access or explain a policy in plain English.

- An edited statement appears as one removed and one added.
- A new or deleted policy document can count as a top-level field change, for example because of its `Version` field.

- It does not accept pasted IAM JSON, `.tf` files, binary plans or state files, and it does not post to your pull request.
- A plan saved as JSON can contain sensitive values in plain text. The page does not change or delete your file.

[Open IAM Policy Lint](https://usefultabs.com/iam-policy-lint/): it is free and runs in your browser.

Saved you some time? Tools here stay free and sign-up free. [Tip the maker on Ko-fi](https://ko-fi.com/usefultabs).

## More free tools

- [Cloud Bill Spikes](https://usefultabs.com/cloud-bill-spikes/) Map Azure Actual Cost CSV to cost centers Map Azure Actual Cost charges without a resource group to cost centers. Download a CSV and see unassigned balances by currency. [How it works](https://usefultabs.com/tools/cloud-bill-spikes/)

- [OIDC Trust Check](https://usefultabs.com/oidc-trust-check/) GitHub Actions AWS OIDC trust policy checker Check GitHub Actions release refs against environment rules and AWS role trust to see which check blocks each branch or tag first. [How it works](https://usefultabs.com/tools/oidc-trust-check/)

- [Acl Match](https://usefultabs.com/acl-match/) Compare NTFS permissions after migration Compare two icacls exports after a file-server move to find changed rights, inheritance differences, and missing paths. [How it works](https://usefultabs.com/tools/acl-match/)

- [Acl Trace](https://usefultabs.com/acl-trace/) Cisco ACL checker and shadowed rule finder Paste a Cisco IOS extended ACL and a test packet. See the first matching line and each line one earlier rule fully shadows. [How it works](https://usefultabs.com/tools/acl-trace/)

- [App Sweep](https://usefultabs.com/app-sweep/) Entra enterprise app ID checker for CSV exports Paste advisory app IDs and add Entra Enterprise applications CSVs to see which IDs appear in each customer export. [How it works](https://usefultabs.com/tools/app-sweep/)

- [Ca Baseline](https://usefultabs.com/ca-baseline/) Compare conditional access policies Compare Conditional Access exports against one baseline. See missing policies, added exclusions, and weaker controls per customer. [How it works](https://usefultabs.com/tools/ca-baseline/)
