Commit Graph
23 Commits
Author SHA1 Message Date
TATSUNO “Taz” Yasuhiro ffe8a92635 perf(build): replace BouncyCastle with JDK crypto API as much as possible (#2988)
* perf(security): stop registering the BouncyCastle JCE provider

ACM signs through the JDK and builds PBES2 there, and KMS PSS
uses RSASSA-PSS with the parameters AWS specifies.
Downsize Docker image from 88.7 to 83.9 MB gzipped.

* test(compat): verify the native image's KMS and ACM crypto from outside Floci

Floci verifying its own signature proves nothing. Signatures now check against
GetPublicKey with an outside library, exported keys are decrypted, and issued
certificates verify their own signature.

* fix(kms): apply real PSS padding when signing a digest with RSASSA_PSS

* fix(acm): set the PBES2 salt and iteration count explicitly

* perf(kms): reuse the shared SecureRandom when signing a PSS digest

* fix(kms): let AwsException pass through the sign and verify catch blocks

* perf(native): drop the native-image config the BouncyCastle provider needed

Five --initialize-at-run-time entries and 21 reflect-config entries existed
for the BouncyCastle JCE provider. Nothing registers that provider any more,
so they only kept dead initialization code in the image.

The run-time initialization entries are what cost size. Removing them takes
the binary from 204.6 to 203.1 MB and gzip -9 from 79.5 to 78.9 MB. The
reflect-config entries measured as noise, because those classes stay
registered through another path, but they still describe a provider Floci
no longer installs.

Verified on a native build. The Python suite passes 354 tests, the Java SDK
suite passes 61 including CloudHSM v2 and ACM, and a TLS run generates its
self-signed certificate and signs with secp256k1 over HTTPS.
2026-09-03 21:49:52 -04:00
Brian Taylor 0a3bc030f6 feat(cognito): implement identity provider configuration CRUD (#2858)
* feat(cognito): implement identity provider configuration CRUD

CreateIdentityProvider, DescribeIdentityProvider, ListIdentityProviders,
UpdateIdentityProvider and DeleteIdentityProvider were unsupported, so
infrastructure tooling could not manage a user pool's federated providers.

Stores provider configuration alongside the other user pool sub-resources and
matches the response and update semantics measured against the live API:

- IdpIdentifiers is echoed by create and update only when the request supplied
  the member, whatever the stored value; describe always returns it
- AttributeMapping defaults to username -> sub when the member is absent at
  create, while an explicitly empty map is stored as given
- members a request omits are preserved rather than cleared
- a duplicate provider name raises DuplicateProviderException
- ListIdentityProviders returns name/type/date summaries, never ProviderDetails

Federated sign-in itself is out of scope: Floci has no /oauth2/authorize or
/oauth2/idpresponse endpoint, so providers are stored configuration only.

* test(cognito): match identity provider exceptions on the SDK error name

`rejects.toThrow(/re/)` matches the error message, but the JS SDK maps the wire
`__type` onto `error.name` and puts the AWS text in `message`, so the duplicate
provider assertion never matched. Assert the name, and pin the enum text with
an explicit message matcher.

* fix(cognito): delete a pool's identity providers with the pool, and update a copy

Two review findings, both reproduced first.

DeleteUserPool left provider records behind. A pool recreated on a pinned id
(`floci:override-id`) then inherited the dead pool's providers, ProviderDetails
client_secret included. Pool deletion now removes them the way it already
removes groups.

UpdateIdentityProvider mutated the instance the store handed back, so two
concurrent updates could interleave into a state matching neither request. It
now writes a copy, which makes the losing update simply lose — what AWS does.

* fix(cognito): serialise identity provider mutations

UpdateIdentityProvider is a read-modify-write: it copies the stored provider,
applies only the members the request supplied and writes the whole record back.
Two overlapping updates copied the same base, so the later write restored the
other's omitted members to their stale values and silently dropped an update.

Live Cognito merges omitted members rather than clearing them, and applies that
merge atomically, so both updates survive there. One lock now guards every
mutating path, since create (check-then-put) and delete (check-then-act) carry
the same race, matching the existing identityLinkLock idiom.

The regression test runs two writers touching different optional members across
25 rounds; it fails on the first round with the lock reverted.

* fix(cognito): guard the pool deletion provider cascade with the same lock

DeleteUserPool clears a pool's identity providers outside identityProviderLock,
so a create or update interleaving with the cascade could reinstate a provider
for a pool that is going away. It now takes the same lock as the mutations it
races, closing the last unguarded path in that set.

* fix(cognito): recheck the pool under the lock when creating a provider

CreateIdentityProvider validated the pool before taking identityProviderLock and
never rechecked it, so a DeleteUserPool whose cascade ran in between left the
create writing a provider for a pool that no longer exists. It now reasserts the
pool inside the lock, immediately before the duplicate check and the write.

UpdateIdentityProvider needs no equivalent: the cascade deletes the provider, so
its own lookup throws ResourceNotFoundException. The outer validation stays where
it is to keep error ordering unchanged for ordinary single-request calls.
2026-09-02 12:00:26 -04:00
Brian Taylor b8f1e22c74 feat(cognito): implement log delivery configuration (#2867)
* feat(cognito): implement log delivery configuration

SetLogDeliveryConfiguration and GetLogDeliveryConfiguration were unsupported, so a
config declaring `aws_cognito_log_delivery_configuration` could not be applied
against Floci.

The configuration is stored on the user pool and validated the way the live API
validates it:

- LogLevel accepts ERROR or INFO, EventSource accepts userNotification or
  userAuthEvents, both reported with AWS's 1-based member path
- every entry must name a CloudWatch, Firehose or S3 destination
- Set replaces the list rather than merging, so an empty list clears it
- Get always returns LogConfigurations, as [] when nothing is configured

Floci stores the configuration and delivers nothing: the destination is neither
written to nor required to exist, and the pricing-tier gate AWS applies to
userAuthEvents is not reproduced.

Closes #2855

* fix(cognito): reject a null LogConfigurations instead of clearing the configuration

SetLogDeliveryConfiguration treated an omitted, null or wrongly typed
LogConfigurations as an empty replacement, so a malformed request returned 200
and erased the pool's stored configuration.

AWS rejects all three. An omitted or null member fails validation, and a value of
the wrong JSON type fails deserialization:

  omitted / null -> InvalidParameterException: 1 validation error detected: Value
                    null at 'logConfigurations' failed to satisfy constraint:
                    Member must not be null
  wrong type     -> SerializationException: Expected list or null

Also drops two em-dashes from the docs, per AGENTS.md.

* fix(cognito): translate malformed LogConfigurations elements the way AWS does

A scalar inside the array reached Jackson's convertValue directly, so an
IllegalArgumentException escaped as a 500 InternalFailure instead of a client
error, and a null element would have failed on the validation loop.

AWS answers both without a 500:

  [1, 2] / ["a string"] -> SerializationException: Expected null
  [null]                -> 200, the null element is dropped

Elements are now checked before conversion: nulls are skipped and non-objects
raise SerializationException.

* fix(cognito): bound LogConfigurations and reject a repeated event source

SetLogDeliveryConfiguration validated each element but never checked the list
itself, so a request with three or more well-formed configurations, or two
naming the same event source, was accepted and stored where AWS rejects it.

Measured against Cognito in ap-southeast-1:

  3 well-formed configs   InvalidParameterException, length constraint on
                          'logConfigurations', max 2
  2 duplicate sources     InvalidParameterException, "appear more then once"
  3 configs, one bad enum 2 validation errors, the length one reported first
  unknown pool, bad enum  the validation error, not ResourceNotFoundException
  0 configs               200 OK

The shape checks now run before the pool lookup, matching that last row, and
collect every violation into one message instead of throwing on the first.
The duplicate and missing-destination complaints share one message with the
missing-destination clause first, and each event source is named once however
many configurations carry it, as measured.

"more then once" is the service's own spelling, kept so the message matches.

The length message embeds the request model's toString, which the emulator now
reproduces for all three destination shapes and for an absent destination.
2026-09-02 11:44:18 -04:00
TATSUNO “Taz” Yasuhiro 146753b094 fix(kms): give ECC_NIST_EDWARDS25519 an actual Ed25519 key (#2930)
* fix(kms): give ECC_NIST_EDWARDS25519 an actual Ed25519 key

The spec carried secp521r1 from the line above it, so it made an EC key and every
Sign failed. Ed25519 now has its own key type. Message type rules and errors match
real KMS, measured in ap-northeast-1.

Closes #2924

* fix(kms): reject an ED25519_PH_SHA_512 digest of the wrong length

Sign and Verify took any DIGEST value, where real KMS requires exactly one
SHA-512 digest and answers otherwise with a ValidationException. Measured in
ap-northeast-1 against both operations.
2026-09-02 11:29:15 -04:00
Brian Taylor 2bf9b57bd9 fix(lambda): omit Environment when no variables are set (#2838)
* fix(lambda): omit Environment when no variables are set

Real AWS omits the Environment member entirely from CreateFunction,
GetFunction, GetFunctionConfiguration and ListFunctions responses when a
function has no environment variables. Floci always emitted it, as an
empty object.

The Terraform provider reads a present-but-empty Environment back as an
environment {} block in state, so any function declared without variables
plans a removal on every run and never converges. On Lambda@Edge, where
environment variables are not permitted at all, the block can never
legitimately exist and each no-op apply also republishes the function.

Layers, KMSKeyArn, FileSystemConfigs and VpcConfig in the same response
builder already omit-when-empty; Environment was the outlier.

* test(compat): correct Environment assertions to match live AWS

Three assertions in the Python and Java SDK compatibility suites required
an Environment block that real AWS does not send:

  - test_get_function_configuration_environment_always_present
  - test_update_environment_variables_round_trip (the cleared case)
  - LambdaFunctionConfigTest.getFunctionConfigurationHasDefaults

Measured against the live service in both directions: a function created
without variables comes back with no Environment member, and clearing to an
empty Variables map removes it again. The tests encoded Floci's previous
behaviour rather than the API's, which is why they went green.

Also corrects the wording of the Java clear case. It sends an Environment
with no Variables member, which is 'leave unchanged', not 'clear' — live AWS
keeps the existing variables, as Floci already did. The assertion now pins
that instead of describing a clear that never happened.
2026-09-01 10:56:48 -04:00
Sam Fakhreddine 1b3417a7a3 feat(config): compliance evaluation loop, retention, pagination (#2642)
* feat(config): add compliance evaluation loop, retention, and pagination

Replace the hardcoded INSUFFICIENT_DATA compliance with real aggregation
over evaluations reported via PutEvaluations / PutExternalEvaluation:

- New actions (13): PutEvaluations, PutExternalEvaluation,
  DeleteEvaluationResults, DescribeComplianceByResource,
  GetComplianceDetailsByConfigRule, GetComplianceDetailsByResource,
  GetComplianceSummaryByConfigRule, GetComplianceSummaryByResourceType,
  DeleteConfigurationRecorder, DeleteDeliveryChannel,
  PutRetentionConfiguration, DescribeRetentionConfigurations,
  DeleteRetentionConfiguration
- PutConfigRule now round-trips the full AWS rule shape (Description,
  Scope, SourceDetails, InputParameters, MaximumExecutionFrequency,
  EvaluationModes) instead of silently dropping fields
- Evaluations persist to config-evaluations.json and are cascade-deleted
  with their rule; retention persists to config-retention.json
- NextToken/Limit pagination on describe/get operations with AWS page
  sizes and InvalidNextTokenException/InvalidLimitException validation
- DescribeConfigRules with an unknown name now fails with
  NoSuchConfigRuleException, matching AWS
- boto3 compatibility suite: tests/test_config.py

Since Floci performs no Lambda invocation, PutEvaluations accepts the
config rule name as the ResultToken; documented in the service doc's
deviations section.

* fix: honor Limit field in Config pagination requests

* fix(config): enforce the modeled rule enums and the ComplianceTypes filter shape

PutConfigRule now deserializes the whole modeled ConfigRule and stores it, so
Source.Owner, MaximumExecutionFrequency, ConfigRuleState and
EvaluationModes[].Mode were persisted and echoed back verbatim — a rule AWS
would have rejected with InvalidParameterValueException read back as a valid
one.

The ComplianceTypes filter on the four compliance reads was likewise unchecked:
an unmodeled value or a list longer than the shape's max of 3 simply matched
nothing, which a caller reads as an empty result rather than as a rejection.

* fix(config): validate the nested SourceDetails enums and Scope cardinality

The stored ConfigRule carries SourceDetails, whose EventSource (aws.config only),
MessageType and MaximumExecutionFrequency are all enum-typed, and a Scope whose
ComplianceResourceTypes list is capped at 100. All four were persisted and echoed
back by DescribeConfigRules verbatim, one level below the members the previous
commit checked.

* fix(config): reject a missing ConfigRuleName on DeleteConfigRule

store.remove(ruleName) throws NullPointerException on the backing
ConcurrentHashMap when ruleName is null (the handler passes null when
ConfigRuleName is absent from the request), producing a 500 instead of
the modeled NoSuchConfigRuleException. Guard on isBlank(ruleName)
first, matching the existing requireRule() idiom used by the sibling
evaluation operations for the same field.

* fix(config): keep the newest evaluation when PutEvaluations reorders

storeEvaluations() unconditionally overwrote the stored compliance
result for a resource/rule pair, so an older evaluation arriving after
a newer one (e.g. an out-of-order Lambda invocation) regressed
compliance details, aggregates, and summaries back to the stale value.
Compare against the stored OrderingTimestamp and skip the incoming
evaluation when it is older than what is already recorded.

* fix(config): make PutEvaluations atomic per resource/rule key

storeEvaluations() read the current evaluation with a plain get() and
wrote the new one with a separate put(), so two concurrent
PutEvaluations calls for the same resource could both read the old
value before either wrote, letting an older OrderingTimestamp win the
race regardless of arrival order. Replace the read-then-write with
ConcurrentHashMap.compute(), which is atomic per key.

Added a stress test exercising 16 concurrent writers per resource key
across 100 attempts; it passes reliably under the fix. The race window
in the prior get/put shape is narrow enough (a handful of nanoseconds
between the two calls) that it did not reproduce deterministically
under test scheduling even with that much contention -- the fix is
justified by the non-atomic read-then-write shape itself, not by a
forced failure.

* fix(config): enforce DescribeConfigRules' 25-name limit

ConfigRuleNames is modeled with Maximum 25 items (confirmed against
botocore's config service-2.json) but describeConfigRules had no size
check, so 26+ names were processed instead of rejected with
InvalidParameterValueException like every other array-size limit this
PR already enforces.

* fix(config): close the DeleteConfigRule/PutEvaluations deletion race

PutEvaluations (and PutExternalEvaluation, DeleteEvaluationResults)
checked a rule's existence via requireRule and then wrote to the
evaluations map as two separate steps. If DeleteConfigRule ran in
between -- removing the rule and its evaluation bucket -- the pending
PutEvaluations call would recreate the bucket via computeIfAbsent
after the delete, orphaning evaluations under the deleted rule's name.
A later rule created with that same name would then inherit the
deleted rule's compliance details and evaluation status.

Guard the check-then-act with a per-rule monitor (ruleKey(region,
ruleName)), matching the lockFor()-keyed-monitor idiom already used by
DocDbService for the identical class of race between a tag update and
a delete.

Added a stress test racing PutEvaluations against DeleteConfigRule
across 200 attempts, then recreating the rule under the same name and
asserting a clean (INSUFFICIENT_DATA) evaluation state. It passes
under the fix; as with the earlier PutEvaluations-ordering race, it
did not reproduce RED against the pre-fix code even under that much
contention -- the race window between the existence check and the map
write is too narrow to hit deterministically without injecting an
artificial delay into production code. The fix is justified by the
non-atomic check-then-act shape itself, confirmed by reading the code.
2026-08-28 11:58:39 -04:00
Kenshin Okinaka ba843013ec chore(compat): align pinned SDK versions across the Python, Java, and CDK suites (#2253)
* chore(compat): align pinned SDK versions across the Python, Java, and CDK suites

Bump the exact-pinned SDK versions to a common recent baseline so the suites no longer
span a wide release window:

- sdk-test-python: boto3 / botocore 1.37.1 -> 1.43.69
- sdk-test-java: AWS SDK for Java v2 2.44.14 -> 2.52.0
- compat-cdk: aws-cdk-lib 2.171.1 -> 2.264.0, aws-cdk 2.171.1 -> 2.1135.1,
  aws-cdk-local ^2.0.0 -> ^3.0.4

Bumping boto3/botocore also restores the current SES v2 model (97 -> 112 operations,
including the Tenant and ReputationEntity families).

The aws-cdk 2.1000+ CLI (decoupled from the library version line) publishes template
assets to S3 using virtual-hosted-style URLs and needs aws-cdk-local v3. Pointing
AWS_ENDPOINT_URL_S3 at Floci's virtual-hosted domain (http://s3.localhost.floci.io:4566)
makes the SDK build <bucket>.s3.localhost.floci.io, which resolves via public DNS locally
and via Floci's embedded DNS (already injected with --dns in the compat workflow) inside
the Docker network, instead of the unresolvable <bucket>.floci.

The Go, Node, AWS CLI, Terraform, and OpenTofu suites float to the latest by design and
are left unchanged.

* chore(compat): let AWS_ENDPOINT_URL_S3 be overridden in the compat-cdk helper

Use a ${:-default} fallback like the other endpoint/region variables in
common-setup.bash so a caller or CI can point the CDK S3 virtual-host endpoint
elsewhere (e.g. a non-4566 port), instead of hard-coding it.
2026-08-16 22:40:20 -05:00
nblomquistandnathan 326b495496 feat(iot) Feature/issue 1038 iot core (#1359)
* feat: add IoT endpoint and thing registry

* feat: add IoT thing tagging

* feat: add IoT certificates and shadows

* feat: add IoT MQTT broker

* feat: upgrade IoT MQTT broker to Moquette 0.18

* feat: restore IoT reserved MQTT topics

* feat: add IoT topic rules engine

* feat: improve IoT thing registry compatibility

* feat: complete IoT MVP 1 compatibility

* feat: complete IoT MVP 2 compatibility

* feat: finish IoT MVP 2 coverage

* fix: disable IoT MQTT broker persistence

* fix(docker): include vendored Maven artifacts in source builds

* fix(iot): stabilize MQTT integration test sockets

* fix(iot): verify MQTT test connections

* fix(iot): use Paho for MQTT integration tests

* fix(iot): use Vert.x MQTT broker

---------

Co-authored-by: nathan <nathan@debian-dev-small.localdomain>
2026-06-25 22:58:44 -05:00
nblomquistandnathan 92f4ff1ccf Feature/issue 1130 glue database tags (#1248)
* fix(glue): register database tags with tagging API (#1130)

* test(glue): add database tagging compatibility coverage (#1130)

* test(tagging): allow additional tagged resources (#1130)

---------

Co-authored-by: nathan <nathan@debian-dev-small.localdomain>
2026-06-11 00:47:00 -05:00
nblomquist 30a598f080 feat(kms): add GenerateRandom action (#1036)
- Add GenerateRandom action routing and handler in KmsJsonHandler
- Add SecureRandom field, constructor overload, and generateRandom() method with bounds validation
- Reject unsupported Recipient and CustomKeyStoreId fields
- Add integration tests for happy path, boundaries, validation, and unsupported fields
- Add SDK compatibility tests for Java, Python, and Node
2026-06-03 17:42:40 -05:00
nblomquist 9d1e24a582 feat(kms) Add KMS Grant APIs (#1073)
* test(kms): add grant compatibility contracts

* feat(kms): support empty ListGrants

* feat(kms): add CreateGrant and persisted ListGrants round trip

* test(kms): add create grant round trip coverage

* feat(kms): add grant pagination, filters, and ListRetirableGrants

* test(kms): add pagination, filter, and retirable grant coverage

* feat(kms): add RevokeGrant administrative delete

* test(kms): add RevokeGrant unit and integration coverage

* feat(kms): add RetireGrant with token and key+grant retirement paths

* docs(kms): document grant lifecycle operations and enforcement scope

* fix(kms): include RetiringPrincipal in ListGrants response

The handleListGrants handler was omitting RetiringPrincipal from the
JSON response even when the grant had one set. This meant grants
created with a retiring principal were invisible through ListGrants,
while ListRetirableGrants worked fine. Adds the missing serialization
to match the GrantListEntry AWS spec.
2026-05-28 18:36:02 -05:00
Nitesh K JainandHector Ventura b71cf0f827 feat(neptune): Neptune control plane, Gremlin Docker backend, and SDK compatibility tests (#958)
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
Co-authored-by: Hector Ventura <hectorvent@gmail.com>
2026-05-20 18:02:00 -05:00
Yorí 8eeb2244a7 Feat/lambda image config working directory (#673)
* feat(lambda): support ImageConfig.WorkingDirectory override

Propagate WorkingDirectory from the Lambda ImageConfig through the full
stack so container images that rely on a specific WORKDIR can be invoked
correctly, matching real AWS behavior.

- LambdaFunction: add imageConfigWorkingDirectory field + getter/setter
- LambdaService: parse WorkingDirectory on CreateFunction and
  UpdateFunctionConfiguration
- ContainerSpec: add workingDir record component
- ContainerBuilder: add withWorkingDir() fluent method
- ContainerLifecycleManager: pass workingDir to Docker via withWorkingDir()
- ContainerLauncher: apply workingDir when building the container spec
- LambdaController: serialize WorkingDirectory in ImageConfigResponse

* test(lambda): add tests for ImageConfig.WorkingDirectory

Unit tests (LambdaImageConfigTest):
- CreateFunction stores WorkingDirectory alongside Command/EntryPoint
- createFunction with all three fields together
- updateFunctionConfiguration updates and clears WorkingDirectory
- ContainerLauncher passes workingDir to ContainerSpec

Compat tests across all SDKs:
- awscli (lambda.bats): create/get/update WorkingDirectory round-trip
- Java SDK (LambdaFunctionConfigTest): ImageConfig.WorkingDirectory round-trip
- Python (test_lambda_function_config.py): TestImageConfigWorkingDirectory class
- Node (lambda.test.ts): create/update WorkingDirectory assertions
- Go (lambda_test.go): TestLambdaImageConfigWorkingDirectory subtests
- Rust (lambda_test.rs): full create/get/update round-trip
2026-04-30 17:25:03 -05:00
Yorí 1cccf43f7b feat(cognito): include all standard attributes in DescribeUserPool Schema (#642)
* feat(cognito): include all standard attributes in DescribeUserPool SchemaAttributes

AWS Cognito always returns all 20 standard OIDC attributes (sub, name,
email, phone_number, etc.) in SchemaAttributes when describing a user
pool, even if none were explicitly configured. Floci was returning only
what was passed in Schema during creation.

Adds CognitoStandardAttributes with the full default set and a merge()
helper that overlays explicit schema overrides and appends custom:
attributes after the standard ones.

* test(cognito): add compat tests for standard SchemaAttributes across all SDKs

Adds DescribeUserPool SchemaAttributes coverage to all compatibility test
suites (AWS CLI/bats, Go, Java, Node, Python, Rust), verifying that all
20 standard OIDC attributes are returned and that sub is required and
immutable.
2026-04-29 00:01:48 -05:00
Kenshin OkinakaandKenshin OKINAKA 763ea379d7 feat(ses): implement email template CRUD with stored, inline, and ARN variants (#573)
* feat(ses): implement email template CRUD with stored, inline, and ARN variants

Adds CreateTemplate / GetTemplate / UpdateTemplate /
DeleteTemplate / ListTemplates on both V2 REST JSON
(/v2/email/templates) and V1 Query.

SendEmail / SendTemplatedEmail resolve templates in three forms
with Mustache-style {{var}} substitution against TemplateData:
  - TemplateName references a stored template
  - TemplateArn extracts the name from the template/<name>
    segment of an SES template ARN (region and account segments
    are not validated, mirroring how KMS / Secrets Manager
    handle ARNs in Floci)
  - TemplateContent (V2 only) supplies inline subject / text /
    html without storing the template first

V2 Content.Template requires exactly one of TemplateName,
TemplateArn, or TemplateContent; violations return
BadRequestException (400). V1 SendTemplatedEmail accepts
TemplateArn either alone or alongside Template (name) — the
name is used for resolution when both are present, matching
AWS where boto3 and the Java SDK keep Template as a required
field and treat TemplateArn as supplementary for cross-account
addressing.

Templates persist region-scoped via StorageFactory in
ses-templates.json. Template names reject leading/trailing
whitespace (same rule as identities) and are validated through
a single validateTemplateName helper reachable from every
resolution path. listTemplates is sorted by CreatedTimestamp
with TemplateName as a tiebreaker for deterministic output.

Error codes: the service layer throws V1-style codes
(TemplateDoesNotExist / AlreadyExists / InvalidTemplate /
InvalidParameterValue); SesController remaps them to
NotFoundException (404) / AlreadyExistsException (400) /
BadRequestException (400) for V2 callers.

* test(ses): add Python and Java SDK compatibility tests for templates

Covers boto3 (ses / sesv2) and AWS Java SDK v2 (SesClient /
SesV2Client) against the SES email template CRUD, inline
TemplateContent, and TemplateArn paths. Happy path,
duplicate-create rejection, missing-template lookups,
Mustache-style variable substitution, and 3-way selector
conflicts on V2 Content.Template are exercised on both SDK
surfaces.

Adds:
- Python: ses_client / sesv2_client conftest fixtures and a
  tests/test_ses_templates.py suite covering V1 + V2
- Java: sesv2 Maven dependency, SesV2Client factory in
  TestFixtures, and a SesTemplateTest covering V1 + V2

* docs(ses): document email template CRUD and templated send

Adds the new V1 template actions (CreateTemplate / GetTemplate
/ UpdateTemplate / DeleteTemplate / ListTemplates /
SendTemplatedEmail) and the V2 /v2/email/templates endpoints
to the SES service reference, and extends the README service
matrix to mention template support on the SES / SES v2 rows.

* fix(ses): add template actions to SES_ACTIONS for unsigned request routing

Unsigned clients (curl, aws --no-sign-request) were falling through to
the SQS handler because the six template Query actions were not
registered in SES_ACTIONS.

* fix(ses): narrow exception catch to JsonProcessingException in template endpoints

Broad Exception catch was masking unexpected errors (e.g. NPE) as 400
responses. Narrowed to JsonProcessingException which is the only
checked exception from objectMapper.readTree().

* test(ses): add template variable substitution edge cases and cross-region isolation

Add SesServiceTemplateTest with 14 unit tests for applyTemplateData
covering undefined variables, spaced/hyphenated names, unclosed braces,
non-string JSON values, regex metacharacters, and case sensitivity.

Add cross-region isolation integration test verifying templates created
in one region are not visible in another.

* test(ses): add awscli compatibility tests for template CRUD and templated send

Cover create, get, update, list, delete template and send-templated-email
via the AWS CLI. Uses JSON parameter format to avoid awscli parser issues
with Mustache-style {{variable}} syntax.

---------

Co-authored-by: Kenshin OKINAKA <kenshin_okinaka@realcross.co.jp>
2026-04-24 20:59:49 -05:00
Christine Nguyen eed72e6222 feat(pipes): add filtering, input templates, batch sizes, and DLQ routing (#576) 2026-04-23 22:56:05 -05:00
Christine Nguyen 51bf4f8480 feat(pipes): add source polling and target invocation for EventBridge Pipes (#555) 2026-04-22 23:36:48 -05:00
Hector Ventura ce60457392 fix(lambda): add missing FunctionConfiguration fields and fix response shape (#546) 2026-04-21 19:44:34 -05:00
TiM 3cdb9b0ded fix(dynamodb): support continuous backups PITR actions (#458) 2026-04-15 01:12:50 -05:00
Conor Heine a0ed51e9d1 feat: ecr (#337) 2026-04-11 09:59:05 -05:00
Conor Heine 13916913e8 fix: handle base64-encoded ACM cert imports (#248) 2026-04-07 13:20:27 -05:00
Conor Heine f4f1752b0d fix: return 400 when encoded s3 copy source is malformed (#244)
fix: replace silent exception swallowing and add per-test timeout in Python test suite

test: misc compatibility-tests cleanups

- Added sync comments to both main.tf files
- Created compatibility-tests/.dockerignore
- Cached CRC32 table in Node setup.ts
- Removed >/dev/null 2>&1 from 3 Dockerfiles

test: add missing .terraform.lock.hcl

chore: remove .terraform.lock.hcl
2026-04-06 16:53:14 -05:00
Conor Heine eeefb729c4 test: move compatibility tests into this repo (#225)
* test: move compatibility tests into this repo
* fix: add StatisticValues parsing to CloudWatchMetricsJsonHandler
* fix: add missing required abstract methods to EmulatorConfig in EventBridgeSchedulerIntegrationTest
* test: add sdk tests for multipart S3 copy coverage
* fix: cover and fix smithy cbor and multipart s3 copy regressions
* test: migrate more test coverage to new folder
* test: add missing ec2 expectation in healthcheck test
* docs: update READMEs in `./compatibility-tests`
2026-04-06 09:35:53 -05:00