From db5d824486e11d81ad5a159f523f692f06d0764e Mon Sep 17 00:00:00 2001 From: Dirk Avery Date: Thu, 19 Dec 2024 14:46:38 -0500 Subject: [PATCH] Fix changelog, comment on validation --- .changelog/40639.txt | 2 +- internal/service/iam/policy_document_data_source.go | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.changelog/40639.txt b/.changelog/40639.txt index 7a878f458a5..7931dbcd57d 100644 --- a/.changelog/40639.txt +++ b/.changelog/40639.txt @@ -1,3 +1,3 @@ ```release-note:bug -data-source/aws_iam_policy_document: Reverts 40652 due to issues. See: 40639. +data-source/aws_iam_policy_document: Reverts plan-time validation for `statement` `sid` ``` diff --git a/internal/service/iam/policy_document_data_source.go b/internal/service/iam/policy_document_data_source.go index a02f7771b03..33df35b0a0a 100644 --- a/internal/service/iam/policy_document_data_source.go +++ b/internal/service/iam/policy_document_data_source.go @@ -143,6 +143,8 @@ func dataSourcePolicyDocument() *schema.Resource { "principals": principalsSchema(), names.AttrResources: setOfStringSchema(), "sid": { + // Because policy documents are widely used outside IAM, we don't enforce + // IAM validation rules requiring alphanumeric and no spaces. Type: schema.TypeString, Optional: true, },