# IAMRAGBENCH: Benchmarking Authorization Expansions in LLM-Generated AWS IAM Policies under RAG Poisoning

DevFeed: [IAMRAGBENCH: Benchmarking Authorization Expansions in LLM-Generated AWS IAM Policies under RAG Poisoning](<https://devfeed.tech/articles/iamragbench-benchmarking-authorization-expansions-in-llm-generated-aws-iam-policies-under-rag-poisoning-114098.md>)

Original publisher: [Read original article](<https://arxiv.org/abs/2611.03431>)

Author: Hasan Kaplan, Indika Kumara, Willem-Jan van den Heuvel, Damian Andrew Tamburri

Published: 2026-11-03T05:00:00Z

Content type: article

Language: en

Sources: [arXiv: Cryptography and Security](<https://devfeed.tech/sources/arxiv-cryptography-and-security.md>)

Topics: [AWS IAM](<https://devfeed.tech/topics/aws-iam.md>), [LLM security](<https://devfeed.tech/topics/llm-security.md>), [Authorization](<https://devfeed.tech/topics/authorization.md>), [Retrieval Augmented Generation (RAG)](<https://devfeed.tech/topics/retrieval-augmented-generation-rag.md>), [Access Control](<https://devfeed.tech/topics/access-control.md>), [Large Language Model](<https://devfeed.tech/topics/llm.md>), [identity and access management](<https://devfeed.tech/topics/identity-and-access-management.md>)

Tags: [access-management](<https://devfeed.tech/tags/access-management.md>), [amazon](<https://devfeed.tech/tags/amazon.md>), [amazon-web-services](<https://devfeed.tech/tags/amazon-web-services.md>), [amazon-web-services-aws](<https://devfeed.tech/tags/amazon-web-services-aws.md>), [architecture](<https://devfeed.tech/tags/architecture.md>), [attack](<https://devfeed.tech/tags/attack.md>), [attacks](<https://devfeed.tech/tags/attacks.md>), [authorization](<https://devfeed.tech/tags/authorization.md>), [aws](<https://devfeed.tech/tags/aws.md>), [aws-iam](<https://devfeed.tech/tags/aws-iam.md>), [aws-identity-and-access-management-iam](<https://devfeed.tech/tags/aws-identity-and-access-management-iam.md>), [benchmark](<https://devfeed.tech/tags/benchmark.md>), [benchmarking](<https://devfeed.tech/tags/benchmarking.md>), [bm25](<https://devfeed.tech/tags/bm25.md>), [context](<https://devfeed.tech/tags/context.md>), [cs-cr](<https://devfeed.tech/tags/cs-cr.md>), [iam](<https://devfeed.tech/tags/iam.md>), [llm](<https://devfeed.tech/tags/llm.md>), [policies](<https://devfeed.tech/tags/policies.md>), [rag](<https://devfeed.tech/tags/rag.md>), [rag-poisoning](<https://devfeed.tech/tags/rag-poisoning.md>)

## AI overview

IAMRAGBENCH evaluates whether attacker-controlled RAG context can make LLM-generated AWS IAM policies exceed task authorization requirements. In 60 cases across scope, conditions, explicit denies, trust, permissions boundaries, and role delegation, included-context exposure yielded 46 goal-matched attacks among 292 trials (15.75%). BM25 retrieved the designated poison for all tasks at k=5 but yielded 7/294 attacks (2.38%). Framing the same weakening as a final architecture exception yielded 74/116 attacks in a two-endpoint stress test and 115/294 in a post hoc five-endpoint extension. In replay, AWS CheckNoNewAccess reported no new access for four of 168 goal-matched exact attacks; the benchmark's full pre-deployment rule rejected all 171 exact authorization deltas and sent five unresolved cases to review. The authors conclude that IAM copilots should be treated as proposal generators and their outputs independently checked before deployment.

## Source excerpt

arXiv:2611.03431v1 Announce Type: new Abstract: Large language models (LLMs) using retrieval-augmented generation (RAG) can synthesize Amazon Web Services (AWS) Identity and Access Management (IAM) policies from tasks and operational documents. Attacker-controlled context may induce provider-valid policies that exceed trusted authorization requirements. We present IAMRAGBENCH, a 60-case benchmark spanning scope, conditions, explicit denies, trust, permissions boundaries, and role delegation. It combines deterministic authorization-envelope scoring with case-specific validation, including request-level checks where supported. An attack requires a provider-valid clean policy that satisfies the task and a provider-valid treatment policy that violates the envelope, matches a predeclared goal, preserves an intended request, and newly authorizes a forbidden request. Across five endpoints, included-context exposure produces 49 exact authorization deltas, including 46 goal-matched attacks (46/292; 15.75\%). End-to-end BM25 over 720 documents retrieves the designated poison for all 60 tasks at \(k=5\) but produces 7/294 goal-matched attacks (2.38\%). Presenting the same weakening as a final security architecture exception produces 74/116 attacks in a frozen two-endpoint stress test (63.79\%) and 115/294 in a post hoc all-five extension using the same frozen prompts (39.12\%). In a replay of 194 provider-valid treatment policies that violate task requirements, AWS \texttt{CheckNoNewAccess} reports no new access for four of 168 goal-matched exact attacks. The full pre-deployment rule rejects all 171 exact deltas and routes five unresolved cases to review. These findings support treating IAM copilots as untrusted proposal generators whose outputs require independent authorization checks before deployment.