Ministack: Free, open-source local AWS emulator - 60+ services, Terraform compatible, real databases. Free forever. MIT licensed.
Python awsaws-emulatoraws-localaws-sdkdevtoolsdockerdynamodbec2emulatorlambdalocalstacklocalstack-alternativeministackmock-awsopen-sourcepythons3sqsterraform
release v1.3.69 (#1002)
Nahuel Nucera4c9efd572d59
diff --git a/CHANGELOG.md b/CHANGELOG.mdindex 4ffc97c0..0a67de96 100644--- a/CHANGELOG.md+++ b/CHANGELOG.md@@ -5,10 +5,11 @@ All notable changes to MiniStack will be documented here.Format follows [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).Versioning follows [Semantic Versioning](https://semver.org/).-## [Unreleased]+## [1.3.69] — 2026-06-27### Fixed- **EKS — `DescribeCluster` returns a host-reachable endpoint on every path** — `DescribeCluster` now advertises the host-published port, `https://{MINISTACK_HOST}:{port}` (`MINISTACK_HOST` defaults to `localhost`), uniformly on cluster create, OIDC-config restart, and persistence restore. Previously the failure-fallback and restore paths could leave a stale value, so `aws eks update-kubeconfig` + kubectl from the host got an unreachable endpoint. The k3s container publishes 6443 to that host port (`ports={"6443/tcp": port}`), so the endpoint works from the host and from containers that can route to `MINISTACK_HOST`, keeping the `ACTIVE`-cluster shape consistent for `aws eks update-kubeconfig` and Terraform. Contributed by @b-rajesh.+- **SQS — `SendMessage` rejects message bodies with XML 1.0 forbidden characters** — AWS SQS only accepts characters valid in XML 1.0 and returns `InvalidMessageContents` for anything else; MiniStack silently accepted them, so a payload that fails against real AWS passed locally. `SendMessage` (and every `SendMessageBatch` entry) now rejects bodies containing C0 control characters other than tab/LF/CR, the surrogate block `#xD800`–`#xDFFF`, and `#xFFFE`/`#xFFFF` with `InvalidMessageContents`. Contributed by @yamachu.---diff --git a/ministack/services/sqs.py b/ministack/services/sqs.pyindex 7b207f4a..2ca35943 100644--- a/ministack/services/sqs.py+++ b/ministack/services/sqs.py@@ -40,8 +40,10 @@ from ministack.core.responses import AccountScopedDict, get_account_id, get_regilogger = logging.getLogger("sqs")-# XML 1.0 forbidden characters: everything below #x20 except #x9/#xA/#xD, plus #xFFFE and #xFFFF-_INVALID_SQS_CHARS_RE = re.compile("[\x00-\x08\x0b\x0c\x0e-\x1f\ufffe\uffff]")+# XML 1.0 forbidden characters (the complement of the allowed set AWS SQS documents:+# #x9 | #xA | #xD | #x20-#xD7FF | #xE000-#xFFFD | #x10000-#x10FFFF):+# everything below #x20 except #x9/#xA/#xD, the surrogate block #xD800-#xDFFF, and #xFFFE/#xFFFF.+_INVALID_SQS_CHARS_RE = re.compile("[\x00-\x08\x0b\x0c\x0e-\x1f\ud800-\udfff\ufffe\uffff]")# ── Module-level state ──────────────────────────────────────diff --git a/pyproject.toml b/pyproject.tomlindex 4b68dec9..66e54e53 100644--- a/pyproject.toml+++ b/pyproject.toml@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"[project]name = "ministack"-version = "1.3.68"+version = "1.3.69"description = "Free, open-source local AWS emulator — drop-in LocalStack replacement"readme = "README.md"license = { file = "LICENSE" }diff --git a/tests/test_sqs.py b/tests/test_sqs.pyindex 3972e007..a83a9ae0 100644--- a/tests/test_sqs.py+++ b/tests/test_sqs.py@@ -1134,3 +1134,21 @@ def test_sqs_send_message_allows_valid_chars(sqs):for body in allowed:resp = sqs.send_message(QueueUrl=url, MessageBody=body)assert "MessageId" in resp, f"send failed for {repr(body)}"+++def test_sqs_invalid_chars_regex_matches_xml10_complement():+ """The forbidden-char regex must be the exact complement of AWS SQS's allowed+ set (#x9 | #xA | #xD | #x20-#xD7FF | #xE000-#xFFFD | #x10000-#x10FFFF), which+ excludes the surrogate block #xD800-#xDFFF. Lone surrogates can't be sent+ through boto3 (client-side UnicodeEncodeError), so this guards the regex+ directly rather than via the wire."""+ from ministack.services.sqs import _INVALID_SQS_CHARS_RE as rx++ # Forbidden: C0 controls (except tab/LF/CR), surrogates, #xFFFE/#xFFFF.+ for c in ("\x00", "\x08", "\x0b", "\x0c", "\x0e", "\x1f",+ "\ud800", "\udfff", "", ""):+ assert rx.search(c), f"must reject {c!r}"+ # Allowed: tab/LF/CR, the range boundaries, BMP, supplementary.+ for c in ("\t", "\n", "\r", "", "", "�",+ "a", "こ", "\U0001f600"):+ assert not rx.search(c), f"must allow {c!r}"