Skip to content

Ministack: Free, open-source local AWS emulator - 60+ services, Terraform compatible, real databases. Free forever. MIT licensed.

release v1.3.37 (#628)

Nahuel Nucera3a519cf0f01b
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 16c58dce..aaa4b405 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -7,10 +7,20 @@ Versioning follows [Semantic Versioning](https://semver.org/).
---
-## [Unreleased]
+## [1.3.37] — 2026-05-12
+
+### Added
+- **CloudFormation `AWS::ApiGateway::Authorizer`** — stacks declaring a TOKEN / REQUEST / COGNITO_USER_POOLS authorizer now provision against the existing apigateway_v1 store instead of failing the stack with `Unsupported resource type`. Maps the standard CFN properties (`Name`, `Type`, `AuthorizerUri`, `AuthorizerCredentials`, `IdentitySource`, `IdentityValidationExpression`, `AuthorizerResultTtlInSeconds`, `ProviderARNs`, `RestApiId`); `AuthType` is informational only in the AWS spec and is dropped.
+- **SQS `AddPermission` / `RemovePermission`** — both operations now wire through to the queue's IAM resource policy stored under the existing `Policy` queue attribute. `AddPermission` appends statements in AWS canonical shape (bare 12-digit account IDs in `Principal.AWS`, lowercase `sqs:` action namespace, `<queue-arn>/SQSDefaultPolicy` Id). Duplicate `Label` is rejected with `InvalidParameterValue`; `RemovePermission` is idempotent per AWS.
+- **RDS `DescribePendingMaintenanceActions` no-op surface** — accepts the operation and returns an empty `PendingMaintenanceActions` list. Accepts and ignores `ResourceIdentifier`, `Filters`, `Marker`, and `MaxRecords`. Unblocks brownfield state-capture tooling that walks the full RDS API surface. Contributed by @jayjanssen.
### Fixed
-- **S3 `_parse_bucket_key` absolute-form request targets** — AWS SDK for .NET v4 sends HTTP/1.1 requests with absolute-form targets (e.g. `PUT http://ministack:4566/bucket/key`). hypercorn passes the raw target as `scope["path"]`, causing `_parse_bucket_key` to parse `http:` as the bucket name. The function now strips the scheme and authority before parsing, matching the behaviour of LocalStack.
+- **SQS `SendMessage` honors `MaximumMessageSize`** — body byte length is now validated against the queue's `MaximumMessageSize` attribute (default 262144, configurable up to 1 MiB per AWS). Oversized messages return `InvalidParameterValue` (400). Before this fix MS silently accepted oversized messages that real AWS would reject.
+- **SNS `Publish` and `PublishBatch` enforce 256 KiB** — total payload size (Message + MessageAttributes name/type/value bytes) is now bounded at 262144 bytes per AWS docs. `Publish` returns `InvalidParameter` (400); `PublishBatch` surfaces each oversized entry as a per-entry failure rather than failing the whole batch. Subject is intentionally excluded (AWS limits Subject to 100 chars but does not count it toward the 256 KB payload).
+- **EventBridge SQS target stamps `SqsParameters.MessageGroupId` on FIFO queues** — `_dispatch_to_sqs` now reads the target's `SqsParameters` block and stamps `MessageGroupId` on the delivered message; it also derives a content-based `MessageDeduplicationId` and a `fifo_seq` so the delivery shape matches real EventBridge → FIFO SQS. Before this fix MS dropped MessageGroupId at dispatch, so FIFO targets received messages real AWS would reject.
+- **SQS `DeleteQueue` raises `QueueDoesNotExist` for missing queues** — the action silently returned `{}` when the URL didn't match a stored queue. Real AWS returns 400 `QueueDoesNotExist` (awsQueryCompatible `AWS.SimpleQueueService.NonExistentQueue`). The handler now routes through the same `_get_q` helper every other SQS action uses, also picking up its docker-compose-hostname fallback. Contributed by @mfurqaan31.
+- **S3 `UploadPartCopy` validates `x-amz-copy-source-range`** — the header was parsed with `rng.split("-")` and no validation, so malformed values (`bytes=abc-def`, extra dashes, missing prefix) raised an unhandled `ValueError` and surfaced as HTTP 500; reversed and out-of-bounds ranges silently produced wrong-sized parts. All malformed inputs now return 400 `InvalidArgument`; out-of-bounds includes the source object size in the error message. boto3 retries 5xx but fails fast on 4xx, so the prior 500 behaviour caused infinite client retry loops against MiniStack where real S3 would have failed immediately. Contributed by @mfurqaan31.
+- **S3 `_parse_bucket_key` strips absolute-form request targets** — AWS SDK for .NET v4 sends HTTP/1.1 requests with absolute-form targets (e.g. `PUT http://ministack:4566/bucket/key`); hypercorn passes the raw target through, so MS was parsing `http:` as the bucket name. The function now strips scheme + authority before parsing. Contributed by @mark-bray.
## [1.3.36] — 2026-05-11
@@ -18,7 +28,6 @@ Versioning follows [Semantic Versioning](https://semver.org/).
- **IAM AWS-managed policies (`arn:aws:iam::aws:policy/<Name>`)** — real AWS hosts these under a virtual `aws` account every customer can read; MiniStack used to key every policy by the caller's account so `GetPolicy(arn:aws:iam::aws:policy/AdministratorAccess)` returned `NoSuchEntity`. AWS-managed policies now live in a separate non-account-scoped store, pre-seeded with 20 of the most commonly referenced policies (`AdministratorAccess`, `PowerUserAccess`, `ReadOnlyAccess`, `SecurityAudit`, `AWSLambdaBasicExecutionRole`, `AmazonS3FullAccess`/`ReadOnlyAccess`, `AmazonEC2FullAccess`/`ReadOnlyAccess`, `AmazonSSMManagedInstanceCore`, `AmazonDynamoDBFullAccess`, `AWSLambdaVPCAccessExecutionRole`, and friends) carrying their canonical AWS documents verbatim. Unknown AWS-managed ARNs return `NoSuchEntity` by default so typos surface locally; opt in to permissive autovivify with `MINISTACK_AUTOCREATE_AWS_MANAGED=1`. `AttachmentCount` is tracked per-(session-account, arn) via an account-scoped sidecar, matching real AWS where the counter is per-account. `ListPolicies` respects `Scope=All`/`AWS`/`Local`; attach/detach work against any AWS-managed ARN; mutation operations (`CreatePolicy` into the `aws` namespace, `DeletePolicy`, `TagPolicy`, `UntagPolicy`, `CreatePolicyVersion`, `DeletePolicyVersion`) return `AccessDenied` / `InvalidInput` to match real AWS. Contributed by @spicykay.
- **Cost and Usage Reports (CUR)** — full 7-operation surface (`PutReportDefinition`, `DescribeReportDefinitions`, `ModifyReportDefinition`, `DeleteReportDefinition`, `TagResource`, `UntagResource`, `ListTagsForResource`). Report definitions persist; report file generation is not emulated (MiniStack doesn't track usage or compute costs), so this targets IaC validation — Terraform / CDK / Bash automation that manages `aws_cur_report_definition` resources can now plan and apply against MiniStack without hitting real AWS billing. Contributed by @staranto.
- **Lambda Ruby 4.0 runtime** — `ruby4.0` maps to `public.ecr.aws/lambda/ruby:4.0`, tracking the runtime AWS added in May 2026 (botocore 1.42.94).
-- **RDS `DescribePendingMaintenanceActions` no-op surface** — MiniStack now accepts the operation and returns an empty `PendingMaintenanceActions` list, including calls with a `ResourceIdentifier` and ignored `Filters`, `Marker`, or `MaxRecords`. This unblocks brownfield state capture tools that expect the RDS API surface but do not need modeled maintenance events yet. Contributed by @jayjanssen.
### Fixed
- **RDS `DescribeDBClusters` serialization — `DatabaseName`, `NetworkType`, `EngineLifecycleSupport`** — three independent shape bugs on the same code path. `DatabaseName` was stored as `""` and always emitted, so botocore parsed it as the empty string instead of `null`; the field is now stored as `None` when unset and only emitted when truthy, matching real-AWS XML elision. `NetworkType` and `EngineLifecycleSupport` were never stored or serialized; they're now accepted from the request and emit with the AWS-documented defaults (`IPV4` and `open-source-rds-extended-support`). Surfaced by brownfield-import diffing against a real-AWS captured Aurora cluster. Contributed by @jayjanssen.
diff --git a/pyproject.toml b/pyproject.toml
index 9bd60c6b..514bcbbc 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
[project]
name = "ministack"
-version = "1.3.36"
+version = "1.3.37"
description = "Free, open-source local AWS emulator — drop-in LocalStack replacement"
readme = "README.md"
license = { file = "LICENSE" }