mirror of
https://github.com/floci-io/floci.git
synced 2026-12-01 01:12:48 -05:00
IamPolicyCfnProvisioner accepted a Policy that AWS rejects: it generated a PolicyName when the property was absent, and it silently created nothing when no principal was named. Now a genuine create missing PolicyName is rejected with ValidationError (the registry required set lists PolicyName, and PutRolePolicy demands it), and a Policy naming none of Roles/Users/Groups is rejected too (AWS requires at least one, mirrored by Terraform's AtLeastOneOf on the attachment). Updates keep their behavior: a normal update reuses the recorded name, and the legacy managed-policy migration still generates a fresh inline name because its prior id is an ARN, not a usable policy name. Refs #3971