Commit Graph
647 Commits
Author SHA1 Message Date
Aniket Shukla e82836348b fix(stepfunctions): resolve state machine alias ARNs (#3607)
* fix(stepfunctions): resolve state machine alias arns

* docs(stepfunctions): list alias actions

* fix(stepfunctions): paginate state machine aliases

* ci: rerun compatibility checks
2026-09-14 12:42:56 -04:00
Simone Primarosa 95079965a8 fix(ecr): enforce immutable image tags (#3009)
Route Docker Distribution traffic through Floci so repository mutability applies to manifest writes. Keep legacy registry storage reachable while moving public ECR endpoints to the guarded listener.
2026-09-14 12:07:40 -04:00
Daniel ZwickerandPriamo Germosen a03c4d6160 feat(cognito): support pending user attribute verification (#2531)
* feat(cognito): support pending attribute verification

* fix(cognito): omit UserAttributeUpdateSettings when a pool never configured it

DescribeUserPool/CreateUserPool/UpdateUserPool always serialized
UserAttributeUpdateSettings as an empty object for pools that never set it,
where AWS omits absent optional members entirely. UserPoolAddOns right above
it already handles this correctly (an unconfigured pool omits the key rather
than returning {} or null, confirmed by Terraform re-planning the block into
and out of existence); UserAttributeUpdateSettings now follows the same
pattern.

* test(cognito): replace var with explicit AWS SDK response types

AGENTS.md's Types and names rule bans var in local declarations; the compat
test used it for four locals whose concrete AWS SDK type is the thing under
review here (CodeDeliveryDetailsType, UpdateUserAttributesResponse).

---------

Co-authored-by: Priamo Germosen <6233424+pgermosen@users.noreply.github.com>
2026-09-14 11:50:16 -04:00
Daniel ZwickerandPriamo Germosen 36c3ee4e22 feat(cognito): implement VerifyUserAttribute (#2018)
* feat(cognito): implement VerifyUserAttribute

* fix(cognito): align attribute verification with AWS

* fix(cognito): require access-token scope on VerifyUserAttribute

verifyUserAttribute() extracted username/pool/jti from the caller's token
but never checked token_use or scope, so a valid ID token could reach the
same code-consuming, attribute-mutating path as an access token. AWS
requires an access token carrying the aws.cognito.signin.user.admin scope
for this operation (API_VerifyUserAttribute.html).

Adds a token_use check (unconditional) and a scope check that only rejects
a token when it explicitly carries a scope list missing the required
scope. Most access tokens this simulator issues carry no scope claim at
all (scopes are only modeled through the V2 Pre-Token-Generation Lambda
override), so treating an absent claim as unrestricted keeps every normal
login flow working, while an access token with an explicit, non-conforming
scope list is now rejected.

Adds unit coverage for all three cases (ID token rejected, access token
missing the scope rejected, access token with the scope accepted) plus a
wire-level regression for the ID-token case.

* fix(cognito): scope consumed-code tombstone to attribute verification

VerificationCodeService.consume() retained a consumed-code tombstone for
every purpose, so a reused code answers ExpiredCodeException instead of
the original CodeMismatchException. That behavior was validated against a
real Cognito pool for VerifyUserAttribute, but the service is shared with
ConfirmSignUp (SIGNUP_CONFIRMATION) and ConfirmForgotPassword
(PASSWORD_RESET), so the same change silently altered their reused-code
error too, without the same validation.

Scopes the tombstone to EMAIL_ATTRIBUTE_VERIFICATION and
PHONE_ATTRIBUTE_VERIFICATION only. SIGNUP_CONFIRMATION and PASSWORD_RESET
go back to deleting on consume, restoring their original, previously
validated NOT_FOUND/CodeMismatchException behavior on reuse.

---------

Co-authored-by: Priamo Germosen <6233424+pgermosen@users.noreply.github.com>
2026-09-14 11:05:25 -04:00
Niels Kootstra 1987bf0c96 fix(rds): bound RDS/Redshift auth proxy connections and handshakes (#3545)
Cap concurrent proxy connections with a per-proxy semaphore, apply
configurable handshake and backend-connect timeouts to both the
client and backend sockets, and defer backend PostgreSQL connects
until after client auth completes. Close leaked backend sockets
defensively on every exit path, including a RuntimeException thrown
between authenticate() returning a session and the bridge finishing
its own cleanup, and bound backend-side reads during the handshake
so a silent backend that accepts TCP but never answers cannot pin a
handler thread and its connection permit forever.

New EmulatorConfig keys under services.rds and services.redshift:
proxy-handshake-timeout-millis (default 10000),
proxy-backend-connect-timeout-millis (default 5000),
proxy-max-connections (default 100).
2026-09-14 10:48:48 -04:00
Franklin G. Mendoza ffd2488f02 fix(codepipeline): poll S3 source changes (#3525)
* fix(codepipeline): poll S3 source changes

* fix(codepipeline): serialize source polling baselines
2026-09-14 10:11:15 -04:00
Ovidiu (Ovi) 3003f05953 feat(bedrock-agentcore): implement AgentCore Memory events (#3556)
* feat(bedrock-agentcore): implement AgentCore Memory events

The Memory control plane was emulated but the event data plane was not:
CreateEvent, ListEvents, GetEvent and DeleteEvent were all absent, so an
application that reads a conversation's history had nothing to call.

Rather than answer ListEvents with a fixed empty list, the events are
stored, so a read returns what was written. An empty session is then empty
because nothing wrote to it, not because the answer is hardcoded.

Behaviour captured against real AgentCore in us-west-2:

  - events are returned newest first, and the event id is a zero-padded
    epoch-millisecond prefix plus a random suffix, so ids sort
    chronologically as plain strings
  - includePayloads=false omits the payload key rather than emptying it
  - maxResults accepts 1 to 100; 101 is a ValidationException quoting the
    constraint
  - a malformed memory id is a ValidationException ("Invalid memoryId: not
    a valid memory ID or ARN") while a well-formed but unknown one is a
    ResourceNotFoundException ("Memory not found: <id>"). A memory id is a
    name followed by exactly ten alphanumerics: a nine or eleven character
    suffix is rejected as malformed before any lookup
  - an unknown actor or session is an empty list, not an error
  - sessionId is optional on create, and AgentCore assigns a UUID when it
    is omitted
  - an empty payload is accepted, and a new event lands on the main branch
  - DeleteEvent echoes the deleted id rather than returning an empty body

The endpoints live on the memory controller rather than the data-plane one
because a JAX-RS request is matched against a single root resource class:
the class rooted at "/memories" owns that subtree, and a class rooted at
"/" never gets a look in. The behaviour stays in the data-plane service.

Verified with the same AWS SDK an application would use, pointed at a local
floci: create, list, get and delete round-trip, eventTimestamp parses back
to the exact Date, and each error above arrives as its typed exception.

Memory records (extraction and retrieval) remain unimplemented; they need
an extraction engine rather than stored events.

* fix(bedrock-agentcore): satisfy the docs and native-image CI gates

Three CI failures on this branch, all mine.

The action tables under docs/services are generated, not hand written. I
edited bedrock-agentcore.md directly and put the new event rows in the
wrong position, so `make docs-check` reported the table stale. Regenerated
with `make docs-sync`, which orders actions by registration and therefore
keeps ListMemories ahead of the event family.

BedrockAgentCoreEventService holds a static SecureRandom for event ids.
GraalVM captures such an instance in the image heap unless the class is
initialized at run time, so NativeImageRuntimeInitializationTest failed and
took both native image builds with it. Registered the class under
--initialize-at-run-time alongside the other services that hold one.

* fix(bedrock-agentcore): correct the event wire contract

Three gaps against the modelled contract, all confirmed in the bundled
botocore service model rather than taken on trust.

CreateEvent answers 201, not 200. The operation's HTTP trait says so, and
the test was pinning the wrong status.

payload is a required member of CreateEvent whose valid values include the
empty list. Turning a null into an empty list made an omitted member
indistinguishable from a valid empty array, so presence now travels
separately from the value and an omitted payload is a ValidationException.
The model also caps the list at 100 items, which is now enforced.

ListEvents is paginated. The default page size is 20 rather than the 100
this used, and the request and response carry a nextToken. The token is the
last event id of the previous page rather than an offset: ids sort with
time and the order is stable, so resuming cannot be shifted by a concurrent
write. No token is emitted on the final page, which is what ends a caller's
loop.

Verified with the real SDK against a local floci: five events traverse in
three pages of two, two and one with the token absent on the last, and an
omitted payload comes back as ValidationException.

* fix(bedrock-agentcore): match AWS wording for the maxResults range error

AWS quotes the submitted value and cites only the bound that was breached.
The message always cited the upper bound and dropped the value, so
maxResults=0 reported "less than or equal to 100". Add a test for the
lower bound, which had none.
2026-09-14 00:01:40 -04:00
Alexy Grabov d8e7382d5b fix(docker): allow explicit root for restricted sockets (#3558) 2026-09-13 19:35:01 -05:00
TATSUNO “Taz” Yasuhiro 569f9f55e4 perf(build): replace quarkus-jdbc extensions with plain JDBC drivers (#3465)
* perf(build): replace quarkus-jdbc extensions with plain JDBC drivers

The RDS Data API and Redshift Data API open connections with
DriverManager. They never used Agroal, Narayana or the datasource
layer that quarkus-jdbc-mysql and quarkus-jdbc-postgresql pull in.
Depend on mysql-connector-j and postgresql directly and hand-supply
the native image config the extensions provided.

* perf(build): cut unused JDBC driver paths from the native image

Substitute driver code that cannot be reached against the databases
Floci provisions, mirroring what quarkus-jdbc-mysql did for JMX and
going a step further for authentication and multi-host URLs.

* perf(build): keep the MySQL cleanup thread disabled in JVM mode

quarkus-jdbc-mysql set com.mysql.cj.disableAbandonedConnectionCleanup
at startup in JVM mode as well as at native build time. The first
commit carried only the native build argument and a surefire copy, so
quarkus:dev and the JVM Docker image started Connector/J's abandoned
connection cleanup thread on the first MySQL Data API call. In dev mode
that thread is recreated with every restart and pins the old
classloader.

* fix(rdsdata): reject PostgreSQL result types the Data API does not support

Aurora PostgreSQL answers a result set that holds a point, interval,
money, box, circle, line, lseg, path or polygon column with
UnsupportedResultException and the message "The result contains the
unsupported data type POINT." Floci returned the driver's toString of
the value instead. Check the column type names before reading the rows
and raise the same error. json and jsonb stay supported, and a column
cast to text still reads as a string, which is the workaround AWS
documents.

* perf(build): drop the PGobject reflection entries

pgjdbc builds point, interval, money and the geometric types through
reflection only when a result set holds such a column. The Data API now
rejects those columns before reading a row, and json and jsonb values
are plain PGobject instances the driver creates directly, so none of
the ten entries can be reached.

* chore(rdsdata): name the tolerated ClassNotFoundException in OpenTelemetryUnavailable

* perf(build): keep PGInterval registered for the Redshift Data API

Redshift tables can hold INTERVAL YEAR TO MONTH and INTERVAL DAY TO
SECOND columns and the Redshift Data API returns them as strings. Floci
serves that path from a PostgreSQL container through pgjdbc, which
builds an interval value by reflection, so the entry stays. The Redshift
Data compat test now reads two interval columns on the native image.

* perf(build): keep the geometric reflection entries for the Redshift Data API

Redshift refuses point, box, circle, lseg, path and polygon as column
types but evaluates them in a select, and its Data API returns the
values as strings, checked on a real ra3.large cluster. Floci serves
that path through pgjdbc, which builds those values by reflection, so
the six entries stay. line stays out because Redshift rejects it, and
money never reaches PGmoney because pgjdbc reads it as a double.

The Redshift Data compat test selects those expressions and expects
the strings Redshift returned. JdbcDriverNativeSupportTest resolves
every registered class name.

* fix(redshiftdata): fail statements that produce line, json or jsonb like Redshift

Redshift has none of these types. A select that names one fails with
"ERROR: type "line" not yet implemented" or "ERROR: type "json" does
not exist", checked on a real cluster. The PostgreSQL container behind
Floci's Redshift evaluates them, so the Data API now checks the result
column types and fails the statement with the same text.
2026-09-13 20:08:25 -04:00
Vũ Thế Huy e5bd8be405 feat(redshift): provision AWS::Redshift::Cluster through CloudFormation (#3427)
* feat(cloudformation): provision AWS::Redshift::Cluster (create path)

* feat(cloudformation): AWS::Redshift::Cluster update and replacement

* feat(cloudformation): force replacement on Redshift cluster createOnly property change

* feat(cloudformation): force replacement on Redshift cluster DBName change

* feat(cloudformation): provision Redshift parameter, subnet and security groups

* chore(cloudformation): register Redshift provisioner in inventory and docs

* test(cloudformation): end-to-end AWS::Redshift::Cluster stack

* docs(redshift): document CloudFormation cluster provisioning

* test(cloudformation): assert ClusterSubnetGroupNotFound error code on subnet group deletion

* fix(cloudformation): correct attribute handling for Redshift security group provisioning

* fix(cloudformation): apply Redshift parameter group Parameters and fix docs

ClusterParameterGroup silently dropped Properties.Parameters on both
create and update instead of calling ModifyClusterParameterGroup, and
did not replace the entity when Description or ParameterGroupFamily
changed, even though AWS marks both as replacement properties.

Also remove the Id GetAtt claim from the Cluster docs: neither the
provisioner nor AWS's own schema expose it for AWS::Redshift::Cluster.
2026-09-13 18:45:40 -05:00
Anders Wasen 55ada9b8a3 feat(cloudformation): provision the AppSync resource types (#3424)
Adds AppSyncCfnProvisioner, serving AWS::AppSync::GraphQLApi, GraphQLSchema, DataSource,
FunctionConfiguration, Resolver and ApiKey. Without it a template's AppSync resources fall
to the dispatcher's stub arm, which reports CREATE_COMPLETE while creating nothing and
resolves Fn::GetAtt to the literal "LogicalId.Attr".

Two things are not simple property mapping. The AppSync control plane is REST-JSON with
camelCase members, so every property is lower-camelised on the way in, with DynamoDBConfig
as the one member that does not follow the rule (it is dynamodbConfig). And schema creation
is asynchronous: while it is PROCESSING every other call for that API is refused with a 409,
so the GraphQLSchema resource waits for a terminal status before completing, as CloudFormation
does.

Also carries the service-layer changes the provisioner needs: a PIPELINE resolver reaches its
data through pipelineConfig and names no data source, which createResolver refused outright;
CreateFunction and UpdateFunction now keep the runtime a JS resolver declares; and
UpdateFunction applies a new name, which a CloudFormation rename goes through.
2026-09-13 18:45:32 -05:00
Anders Wasen 10becc593f feat(cloudformation): provision AWS::Lambda::Url (#3423)
A function URL in a template was falling to the stub arm, so a stack exported the literal
string "LogicalId.FunctionUrl" in place of a URL and nothing was listening on it.

The physical id is the FunctionArn the URL is attached to, the alias ARN when Qualifier names
one, which is the registry schema's primary identifier and enough to address the config again
since a qualified ARN parses back into function and qualifier. TargetFunctionArn and Qualifier
are create-only, so an update that moves the URL creates against the new function and removes
the one it displaced.
2026-09-13 18:45:25 -05:00
Niels Kootstra 126af73141 fix(ecs): enforce host-volume bind-mount safety fail-closed at register and run time (#3543)
* fix: enforce host-volume bind-mount safety fail-closed at register and run time

Reject volumes[].host.sourcePath by default unless an operator opts in via
floci.services.ecs.host-volume-roots or allow-unsafe-host-volumes. Block the
Docker socket and any ancestor directory that contains it (/var/run, /run,
/var) unconditionally, even with the unsafe flag set. Extract the check into
HostVolumePolicy and enforce it again immediately before each bind mount in
EcsContainerManager.startTask, not only once at RegisterTaskDefinition, to
narrow the window for a swapped-in symlink and to cover task definitions
persisted before this policy existed.

* fix(ecs): protect the Docker socket Floci actually connects to

The host-volume policy only blocked the literal /var/run/docker.sock
and /run/docker.sock paths, so a task definition could bind-mount the
daemon socket when Floci reached it through DOCKER_HOST or an active
Docker context (Colima, OrbStack, Rancher Desktop, Podman).

Resolve the daemon endpoint through the same DockerClientProducer path
the Docker client uses and add its unix:// socket path to the protected
candidates. The literal paths stay protected as defence in depth.
2026-09-13 18:23:07 -04:00
Abhigya 96707f6d5a feat(apigateway): support HTTP and HTTP_PROXY integrations on REST APIs (#3433)
* feat(apigateway): support HTTP and HTTP_PROXY integrations on REST APIs

PutIntegration already accepted type HTTP_PROXY and HTTP, but dispatch handled
only AWS_PROXY, AWS and MOCK and fell through to a 500 "Unsupported integration
type". A REST API fronting an HTTP microservice - the shape CDK's HttpIntegration
and addProxy emit - could be created but never invoked.

HTTP_PROXY is a passthrough: the request goes to the integration URI with {param}
placeholders resolved from the matched resource's path parameters, and the
backend's status, headers and body are relayed unchanged. AWS applies neither
request templates nor integration-response selection to HTTP_PROXY, so a backend
4xx or 5xx reaches the caller verbatim rather than being remapped into a gateway
error. An unreachable backend yields 502.

HTTP is the non-proxy form and transforms in both directions. The request body is
the rendered requestTemplates entry chosen by the incoming Content-Type, and only
headers and query parameters named by integration.request.* mappings are
forwarded - unmapped inbound headers are deliberately not passed through, which
is what separates it from HTTP_PROXY. The backend's reply then runs through the
method's integration responses, where selectionPattern is matched against the
backend's HTTP status code rather than against an error message as it is for
AWS/Lambda integrations.

Both reuse the existing v2 HttpProxyInvoker for transport, so hop-by-hop header
stripping, chunked decoding and the 502-on-failure behaviour are shared. The
request-template negotiation and integration-response mapping that AWS
integrations already performed are extracted so both types use one implementation.

* fix(apigateway): preserve repeated headers and query parameters through HTTP_PROXY

A REST HTTP_PROXY integration passes the request through, and AWS supports
multi-valued headers and query strings on that path. The adapter collapsed both
into one comma-joined value before handing the request to the shared transport,
so "?tag=a&tag=b" reached the backend as "tag=a,b" and a header sent twice
arrived once. Those are not interchangeable: most servers parse the joined form
as a single value containing a comma.

The relayed response had the same defect. A backend returning two Set-Cookie
headers produced one joined header, which the client cannot split back apart,
since an Expires attribute contains a comma of its own.

The transport already stored headers and query parameters as multimaps
internally; only its boundary types flattened them. RequestContext now carries a
multi-valued view alongside the single-valued one that $request.* expressions
resolve against, ProxyResult returns multi-valued headers, and the REST proxy
path emits one header line per value. An explicit integration.request.* mapping
still overwrites, replacing repeated inbound values with the mapped one.

Non-proxy HTTP is unchanged: its integration responses resolve
integration.response.header.X to a single value, so it collapses the backend's
headers at that point instead.

* fix(apigateway): preserve repeated parameters through HTTP API HTTP_PROXY too

dispatchHttpProxyV2 is the second entry point into the HttpProxyInvoker /
RequestContext / ProxyResult transport, and it still built its request context
from comma-joined single-value maps. So after the REST path was fixed, an HTTP
API (v2) with an HTTP_PROXY integration still sent "?tag=a,b" for "?tag=a&tag=b",
and repeated request headers still arrived joined: the transport's multi-value
support was there but never populated from here.

It now builds the same two views the REST path does. The multi-value maps are
what reaches the backend, and the joined single-value maps stay the lookup
surface for $request.header.X / $request.querystring.X, which resolve to one
value in AWS. The response relay already iterated multi-valued headers, so
repeated Set-Cookie was already correct on this path; it is pinned by a test
now rather than left implicit.

Also drops ProxyResult.firstHeader(), which nothing called, puts braces on the
conditionals in RequestContext.expand(), and imports LinkedHashMap in
ApiGatewayExecuteController instead of spelling it out in full at each use.
2026-09-13 18:06:04 -04:00
Niels Kootstra f38a384e51 fix(appsync): verify JWT signatures and SigV4 requests for GraphQL auth (#3541)
* fix(appsync): verify JWT signatures and SigV4 requests for GraphQL auth

Cognito and OIDC auth modes decoded JWT claims without checking the
signature, and AWS_IAM auth accepted any well-formed Credential= value
without verifying a real SigV4 signature. An unregistered IAM access
key also fell back to an account-root identity instead of being
rejected. Any of these let an attacker forge claims or an identity
for AppSync's GraphQL data-plane endpoint.

Cognito now verifies the token against the issuing user pool's own
RS256 signing key (alg, kid, issuer, expiry) instead of trusting the
decoded payload. OIDC verifies against the configured issuer's
published JWKS via OIDC discovery, reusing JwtSignatureVerifier (the
same verifier the HTTP API JWT authorizer uses), and fails closed on
an unreachable issuer or unsupported algorithm. AWS_IAM verifies a
real header-signed SigV4 request (service "appsync", fixed
/v1/apis/{apiId}/graphql canonical path): the Credential= access key
must resolve to a secret via IamService and the signature must match
the actual request, including its body. An unknown or unsigned key is
always rejected and never resolves to root; the legacy test/test pair
is still emulator-allow but must be signed like any other key.

JwtClaimsDecoder gained decodeHeader()/rawToken() so callers can check
alg/kid and hand the raw token to a signature verifier.
AuthRequestInfo carries the raw request body so IAM signature
verification can hash the real payload rather than trusting an
unsigned one.

* fix(appsync): bind session tokens to temporary IAM credentials

IamAuthValidator.resolveSecretKey resolved a temporary (ASIA...)
access key's session secret and verified the SigV4 signature, but
never checked X-Amz-Security-Token. A caller holding just the secret
could authenticate without presenting the session token AWS requires
to prove the credential is live and genuinely STS-issued.

checkSessionToken now mirrors ExecuteApiSigV4Authorizer: a temporary
key with no X-Amz-Security-Token header is rejected, a present token
is compared against the value IamService recorded at mint time with
MessageDigest.isEqual, and a session recorded before Floci tracked
tokens (no issued value to compare against) is not locked out by a
check it cannot satisfy. The token does not need to ride in
SignedHeaders; comparing it against the issued value binds it
regardless of where it rode.

Also drops the dead Date-header fallback in headerSignedRequest
(AMZ_DATE can never parse RFC 1123 output, so that branch never ran)
and fixes an em-dash in the AWS_IAM docs row.

* test(appsync): sign IAM data-plane requests in the auth integration test

Two AppSyncAuthIntegrationTest cases sent the bare Credential= header
that is enough for the management plane to the GraphQL endpoint and
expected 200. Now that AWS_IAM requests are verified as real SigV4,
that header is an unsigned request and gets 401, which is the intended
behaviour. Sign those two requests with AppSyncRequestSigner using the
legacy test credential; the cases that expect 401 for a dummy
signature are unchanged.
2026-09-13 17:56:24 -04:00
Matheus Oliveira a40409f591 fix(wafv2): reject non-CIDR IPSet addresses (#3511)
CreateIPSet/UpdateIPSet now validate that every Addresses entry is a
CIDR block matching IPAddressVersion, rejecting bare addresses and
out-of-range prefixes with WAFInvalidParameterException. The
IPAddressVersion check now runs even when Addresses is empty or null,
and validation errors carry Field/Parameter/Reason as structured
extendedData instead of a free-text message, matching the real
ParameterExceptionField enum (IP_ADDRESS, IP_ADDRESS_VERSION).

* Fix #3328

Signed-off-by: Matheus Oliveira <matheus.6148@gmail.com>
2026-09-13 17:15:55 -04:00
Vũ Thế Huy e9454af855 feat(redshift): intercept Extended Query protocol (#3474)
* feat(redshift): decode Extended Query wire messages

* feat(redshift): track Extended Query statements and portals

* feat(redshift): coordinate Extended Query backend responses

* refactor(redshift): share S3 COPY and UNLOAD transfers

* feat(redshift): execute S3 transfers through Extended Query

* fix(redshift): retain next-cycle pipelined portals

* feat(redshift): intercept Extended Query statements

* test(redshift): cover Extended Query JDBC compatibility

* test(redshift): cover Extended Query SDK compatibility

* docs(redshift): document Extended Query interception

* feat(redshift): implement extended query execution handling in BackendResponseCoordinator and update related classes

* feat(redshift): enhance ExtendedS3Exchange with client synchronization handling

* fix(redshift): synchronize extended COPY failures

* fix(redshift): tolerate backend ownership fragmentation

* fix(redshift): forward extended query flush frames

* fix(redshift): abort backend copy on unload failure

* fix(redshift): preserve later extended query mutations

* fix(redshift): return ready state after copy failure

* test(redshift): cover later sync cycle rollback

* fix(redshift): preserve independent mutations when rejecting a pipelined mutation

ExtendedQuerySession.rejectFrom() restored the whole statements/portals
map back to the rejected mutation's "before" snapshot and truncated the
journal to the end, discarding any later, independent mutation that
happened to run first. The coordinator already rejects one pipelined
mutation at a time in journal order, so this only ever needs to undo
that one mutation's own effect.

Each journal entry now also records its own "after" snapshot at
creation time, since reconstructing it later from the next entry's
"before" or from the live maps goes stale once an earlier reject's
cascading portal cleanup has already touched a key this mutation never
itself changed.

* fix(redshift): forward the real ReadyForQuery after a COPY/UNLOAD failure

readClientSync(client) called the two-argument overload without its
Flush-forwarding OutputStream, which did not compile.

Every error branch in the Extended Query COPY/UNLOAD path sent CopyFail
and Sync to the backend but never drained or forwarded the backend's
resulting ReadyForQuery: the client waited on a frame nobody ever read
off the wire. drainReadyForQuery already existed for exactly this but
was never called. Wire it into every COPY and UNLOAD error branch.
2026-09-13 08:54:52 -04:00
lex00 043167793b feat(ec2): carry the remaining launch template data fields (#3493)
* feat(ec2): carry the remaining launch template data fields

InstanceMarketOptions, InstanceRequirements and a network interface's
ConnectionTrackingSpecification were the last three RequestLaunchTemplateData
groups Floci accepted and threw away. A Terraform aws_launch_template that
declared any of them read back nothing, so it reported an inconsistent result
after apply or diffed forever.

Ec2QueryHandler now parses all three off the Query wire and renders them into
ResponseLaunchTemplateData, and LaunchTemplateData stores them. All 26 members
of InstanceRequirementsRequest are covered, including the nested
BaselinePerformanceFactors. CreateLaunchTemplateVersion inherits the new
members the same way it inherits the existing ones.

* fix(ec2): validate launch template instance requirements and connection tracking

InstanceRequirements and ConnectionTrackingSpecification became writable in the
previous commit, but nothing checked them. A block carrying only
BurstablePerformance was stored, and so was a network interface asking for a
one second TCP established timeout.

The EC2 service model declares VCpuCount and MemoryMiB required on
InstanceRequirementsRequest, and Min required on each of their range shapes, so
a request missing any of them now fails with MissingParameter. The connection
tracking timeouts have no min or max keys in the model; the ranges live in each
member's documentation string, which gives TcpEstablishedTimeout 60 to 432000
seconds, UdpTimeout 30 to 60 and UdpStreamTimeout 60 to 180. A value outside
one of those fails with InvalidParameterValue, matching the existing hop limit
check. CreateLaunchTemplate and CreateLaunchTemplateVersion both validate
before anything is stored.

* fix(ec2): reject the launch template combinations InstanceRequirements forbids

InstanceRequirements became writable two commits ago, and validation covered the
required members and the connection tracking ranges but not the combinations the
EC2 API reference rules out. Three of them were storable.

The service model documents each rule in a member documentation string rather
than in its constraints. RequestLaunchTemplateData says "If you specify
InstanceRequirements, you can't specify InstanceType". InstanceRequirementsRequest
says "If you specify AllowedInstanceTypes, you can't specify ExcludedInstanceTypes"
and "Only one of SpotMaxPricePercentageOverLowestPrice or
MaxSpotPriceAsPercentageOfOptimalOnDemandPrice can be specified". All three now
fail with InvalidParameterCombination from the shared validation path, so
CreateLaunchTemplate and CreateLaunchTemplateVersion are covered alike.

CreateLaunchTemplateVersion validates the merged version as well as the request it
received. The merge inherits every member the request does not restate and has no
way to express removal, so a version naming only InstanceType against a source
carrying InstanceRequirements would otherwise store a version holding both. That
merged version is what AutoScaling and the fleet APIs read, so it is rejected
rather than stored. Omitting SourceVersion starts from empty data and remains the
way to move a template between the two selection modes.

The instanceRequirementsRoundTrips test set both halves of two of these pairs. Its
assertions are unchanged; the members that cannot share a template moved to a
second template of their own.
2026-09-13 00:32:07 -04:00
Abhigya 505b5d286e feat(ses): preserve raw message fidelity and envelope sender in the SMTP relay (#3522)
* feat(ses): preserve raw messages, envelope sender, and X-SES headers in SMTP relay

The raw relay reparsed each MIME message and rebuilt it from the text and
HTML parts alone, dropping every attachment and custom header. It now walks
the Mime4j tree and maps it onto the outgoing message: the first text/plain
and text/html parts become the body, every other leaf becomes an attachment
(inline when it carries a Content-ID, so cid: references still resolve), an
embedded message/rfc822 part is relayed whole, and display names on addresses
survive. Top-level headers are copied through apart from the MIME structural
ones, which the encoder regenerates for the re-built message.

Wire the envelope sender through to MAIL FROM, resolved in AWS's order: the
Return-Path MIME header, then the ReturnPath request field (v1) or
FeedbackForwardingEmailAddress (v2), then the source. The resolved value is
recorded on SentEmail so the inspection endpoint shows it.

Stamp relayed messages with <{MessageId}@{region}.amazonses.com>, matching the
MessageId returned to the caller, leaving a caller-supplied Message-ID alone.

Honour the X-SES-CONFIGURATION-SET and X-SES-MESSAGE-TAGS control headers on
raw sends, which previously parsed to nothing and left event publishing
silently inert for callers using the header form. Both are stripped from the
relayed message, as AWS consumes rather than forwards them. The tenant send
gate sees the same resolved configuration set, so one named only by header
cannot slip past the association check.

Fix tryBase64Decode, which decoded every raw message with the MIME decoder and
only fell back to plain text when it threw. That decoder skips characters
outside the base64 alphabet rather than rejecting them, so a plain-text RFC
5322 message decoded into garbage whenever the surviving alphabet characters
happened to form a valid length, wiping its headers. The alphabet is now
checked before decoding.

Replace the nine-argument SmtpRelay.relay with a RelayMessage record, and add
a ServerSocket-based SMTP test that drives a real MailClient end to end and
asserts on the negotiated envelope and the bytes on the wire, covering the
authentication and STARTTLS-OPTIONAL configuration branches.

* fix(ses): align SMTP relay with documented AWS header and tag semantics

Verified the relay against the SES documentation and corrected four
deviations.

AWS overrides a caller-supplied Message-ID with the id it assigned, and
rejects Message-ID outright as a custom header on Simple and Templated
content (SES header fields reference). The relay preserved a caller's value
instead; it now always stamps the id returned by the API.

AWS likewise overrides a caller-supplied Date with the time it accepted the
message. The relay copied the caller's Date through, so a stale timestamp
reached the recipient. Date is now regenerated with the rest of the headers
SES sets.

AWS uses only the request field's message tags when tags are supplied both
as a request field and as an X-SES-MESSAGE-TAGS header, and explicitly does
not join the two sets. The relay merged them, letting a header-only tag
survive a request that supplied its own. Header tags now apply only when the
request passes none.

The stamped Message-ID domain was region-scoped, which no AWS documentation
or observed output supports. Use the observed email.amazonses.com instead,
and record in the docs that only the local part, which is the returned
MessageId, is documented behaviour.

Also document that AWS delivers a Return-Path differing from the one
supplied, because it routes bounces through its own address, whereas Floci
has no bounce pipeline and puts the resolved address directly in MAIL FROM.

* fix(ses): align mime4j artifacts to unbreak the native build

The raw relay's new DefaultMessageWriter path failed GraalVM analysis with
an unresolved reference to Field.getSafeRaw(). apache-mime4j-dom was pinned
to 0.8.14 while the Quarkus BOM manages apache-mime4j-core at 0.8.12, so the
writer was compiled against a Field API the resolved core does not declare.
Nothing reached the writer before this branch, which is why the skew only
surfaced now, and only in native builds.

Drop the hardcoded -dom version so both artifacts track the BOM together,
and cover the embedded message/rfc822 branch that exercises the writer.
2026-09-12 23:27:38 -05:00
lex00 325bdfb30e feat(ec2): report instance credit specifications (#3492)
* feat(ec2): report instance credit specifications

DescribeInstanceCreditSpecifications was not implemented, so the action
Terraform's aws_instance resource reads credit_specification from always came
back empty and every plan after an apply showed a credit_specification diff for
an instance nobody had touched. CreditSpecification is not a member of the
Instance shape DescribeInstances returns, per botocore's ec2 2016-11-15 model,
so this dedicated action is the only way that value can reach a client.

The credit option is the launch's explicit CreditSpecification.CpuCredits when
the request named one, and the instance type family's documented default
otherwise: standard for t2, unlimited for t3, t3a and t4g. The model's own
InstanceType enum lists t1, t2, t3, t3a and t4g as the only T families, and t1
predates the credit model, so that table is complete. The default is resolved on
read rather than frozen at launch, so a resize moves the instance onto its new
family's default.

The two request shapes mean different things and both are implemented. Naming
instance ids reports exactly those instances, and an id with no credit option is
an error rather than an omission, which is what the model documents for "an
instance that is not a burstable performance instance". Naming no ids reports
only the instances running unlimited, paginated by MaxResults and NextToken;
AWS rejects MaxResults together with instance ids and so does this.

DescribeInstanceTypes now reports burstablePerformanceSupported. Terraform
checks that flag before it reads a credit specification at all, so without it
the new action would never be called.

ModifyInstanceCreditSpecification is deliberately left out. Describe stands on
its own here: it fixes the read that produced the perpetual diff, and a launch
can already set the option through RunInstances or launch template data. The
modify path is a separate change.

Tests: Ec2InstanceCreditSpecificationsIntegrationTest covers each burstable
family default, a non-burstable type, an explicit launch-time override, an
unknown instance id, the unfiltered form and the MaxResults combination error
on the real Query wire. Ec2InstanceTypeCatalogTest covers the family table.
Ec2RunInstancesPublicIpParamTest's mocked signature gains the new parameter.

* fix(ec2): persist the instance credit option and report standard for non-burstable ids

The first cut of DescribeInstanceCreditSpecifications had the documented behaviour
backwards on two points. Both come from the operation's own documentation string in
botocore's ec2 2016-11-15 model, which the constraint keys alone do not carry.

"If you specify an instance ID that is not a burstable performance instance, Amazon
EC2 returns the standard credit option." A named m5 was answered with
InvalidInstanceID.NotFound, because effectiveCpuCredits() returned null for a type
with no credit model and the named-id path treated that as an unknown id. It now
reports standard. An id that names no instance at all is still
InvalidInstanceID.NotFound, which is the only error that path raises.

The unfiltered form returns burstable instances on the unlimited option "as well as
instances that were previously configured as T2, T3, and T3a with the unlimited
credit option. For example, if you resize a T2 instance, while it is configured as
unlimited, to an M4 instance, Amazon EC2 returns the M4 instance." A launch without
an explicit CreditSpecification stored null and the credit option was recomputed from
the instance's current type on every read, so a t3 that defaulted to unlimited lost
that option the moment it was resized onto an m5. The option is now resolved once, at
the point the instance acquires it, and stored on the instance:
Instance.creditSpecificationCpuCredits, written in runInstances from the request or
the family default, and written again in modifyInstanceAttribute when a resize moves
an instance with no option yet onto a burstable type. Reads return the stored value.
The family default stays on the read path only as a fallback for instance records
written before the option was stored.

Tests: aNonBurstableInstanceIdReportsStandard replaces the regression that locked in
the error. theUnlimitedOptionSurvivesAResizeOntoANonBurstableType,
aResizeOntoABurstableTypeAcquiresTheFamilyDefault and
aStandardOptionSurvivesAResizeOntoAnotherBurstableFamily cover the resize paths, and
the unfiltered-form test now also asserts a non-burstable instance is absent.

* fix(ec2): honor DryRun, Filter.N and the MaxResults range on DescribeInstanceCreditSpecifications

The EC2 model declares more request behavior for this action than the handler
accepted. All three gaps come from local/model-preflight.py ec2
DescribeInstanceCreditSpecifications, which prints the constraint keys and the
documentation prose together.

DryRun is a modeled member and the handler never probed it, so DryRun=true
returned a normal response instead of DryRunOperation. The pagination parameters
are now validated before the probe, matching the order the snapshot block public
access handlers use, since AWS reports an invalid parameter ahead of
DryRunOperation and only returns DryRunOperation once the request could
otherwise succeed.

Filter.N is a modeled member and was parsed nowhere. The model declares one
filter name here, instance-id, which Ec2Service.matchesFilter already resolves
for an Instance, so both request shapes now run their candidates through
matchesFilters. Named ids still decide the base set and are still validated for
existence, then the filters narrow that set with an AND, which is what the
Filters member documents. An unrecognised filter name matches everything,
following the default arm every other filtered EC2 Describe action in this
service already takes.

DescribeInstanceCreditSpecificationsMaxResults carries a min of 5 and a max of
1000, and any positive integer was accepted, so 1 and 1001 were treated as page
sizes. Out of range now raises InvalidMaxResults with the message
describeNetworkInterfaces already uses for the same range.

Tests: maxResultsHonorsItsModeledRange covers 5, 1000, 4 and 1001,
dryRunReturnsDryRunOperation and anInvalidMaxResultsIsReportedAheadOfDryRun
cover the probe and its ordering, and four filter tests cover the unfiltered
form, named ids, an unknown named id under a filter and an unrecognised filter
name.
2026-09-13 00:26:47 -04:00
Brian Taylor 24a8c8440b fix(lambda): resolve layer version ARNs by account (#2948)
* fix(lambda): resolve layer version ARNs by account

Layer resolution dropped the ARN's account segment, so an ARN naming another
account resolved inside the caller's own partition. Two consequences, filed
separately as #2813 and #2809.

A foreign ARN whose layer name and version happened to match one of the
caller's own resolved to that layer: the function recorded an ARN it was not
using, and the launcher mounted different content at /opt than
GetFunctionConfiguration reported. resolveLayerByArn now scopes the lookup to
the caller's account and partition, so a foreign ARN is a miss.

A foreign ARN that matched nothing was rejected outright, which no AWS-managed
public layer can ever satisfy: Powertools, the AppConfig extension and
Datadog-published layers all live in AWS-owned accounts, and every Terraform
stack attaching one failed at CreateFunction. Validation now applies the
eager existence check only to the caller's own account and records a foreign
ARN unresolved, warning that its content is not mounted.

Measured against the live service in ap-southeast-1:

  CreateFunction, foreign ARN matching an own layer name/version
    -> AccessDeniedException, not a substitution
  CreateFunction, AWS-managed Powertools layer
    -> 201, ARN echoed verbatim on GetFunctionConfiguration
  CreateFunction, missing layer in the caller's own account
    -> InvalidParameterValueException: Layer version ... does not exist.

The own-account message and status are unchanged, matching that third case
exactly. The AccessDenied case is a known divergence: Floci implements no
layer permissions, so it cannot tell a public layer from one the caller has no
policy for, and accepts both.

Closes #2813
Closes #2809

* fix(lambda): reject foreign-partition layer ARNs when attaching them

GetLayerVersionByArn already answers a non-aws partition with
InvalidParameterValueException, but CreateFunction and
UpdateFunctionConfiguration accepted the same ARN and persisted it, so a
function could carry a layer Floci's own lookup path calls invalid.

Partitions are isolated, so no resource policy can ever make a cn or
gov layer readable from the aws partition. That is what separates it
from a foreign account, where a policy can, and where AWS-managed public
layers live. Foreign accounts stay accepted; foreign partitions now
reject with the message GetLayerVersionByArn already uses.

Measured on CreateFunction in ap-southeast-1: a cross-partition layer
ARN and a foreign-account layer ARN both fail with AccessDeniedException,
so the live service does not distinguish them at this call. The split
here is Floci's, on reachability grounds, and is documented as such.

* fix(lambda): gate foreign-account layer ARNs behind a config flag

Review asked for the accept-foreign-ARN behaviour to be opt-in rather than the
default, on both PRs' reasoning that it broadens what CreateFunction accepts
beyond AWS. It is now floci.services.lambda.accept-external-layer-arns, default
false, env FLOCI_SERVICES_LAMBDA_ACCEPT_EXTERNAL_LAYER_ARNS.

Off, a layer ARN naming another account is refused. On, it is recorded on the
function verbatim and its content is not mounted, which is what a stack
attaching Powertools or the AppConfig extension needs. A same-account ARN is
unaffected either way: a missing layer is still the eager
InvalidParameterValueException.

The refusal is AccessDeniedException, 403, not the InvalidParameterValueException
this branch previously used for the partition case. That was the second review
finding: the live probe in this PR measured CreateFunction returning
AccessDeniedException for a cross-partition ARN and the identical
AccessDeniedException for a same-partition foreign account, so reporting a
different error class than what was measured was an observable divergence
presented as parity. Both now report what AWS reported.

Cross-partition stays refused with the flag on. Partitions are isolated, so no
resource policy can make an aws-cn layer readable from aws, and
GetLayerVersionByArn already calls such an ARN invalid.

Negative control, with the default flipped to true and the tests kept:

  LambdaLayerArnAccountIntegrationTest
    foreignAccountArnIsDeniedByDefaultAndTheFunctionIsNotCreated
    updateFunctionConfigurationIsDeniedAndLeavesTheExistingLayerInPlace
  Tests run: 7, Failures: 2

Also moves the two generic ARN ownership checks this branch was adding into
AwsArnUtils as isForeignPartition and isForeignAccount, so the layer code keeps
only the layer-shaped part. Review noted RdsService.targetGroupBelongsTo already
carries its own copy and asked not to land a further one. The existing RDS, EKS
and EC2 copies are deliberately left alone; this only avoids adding another.
2026-09-13 00:19:37 -04:00
Matheus André 27def6079d docs(marketplace): add known deviations and behavior notes for change sets (#3523) 2026-09-13 00:16:50 -04:00
Kenshin Okinaka 6790024abc feat(firehose): convert array, struct and map columns to Parquet (#3521)
* feat(firehose): convert array, struct and map columns to Parquet

Data format conversion rejected every complex Hive type up front, so a
stream whose Glue table carried an array<string> or a struct<..> routed
its whole batch to the error output as UnsupportedSchema. That covers the
ordinary Firehose-to-Athena schema, where a JSON event nests.

A column's type is now a recursive tree feeding DuckDB's read_json, and
values coerce the way real AWS's OpenX deserializer does (probed against
us-west-2 with a table of exactly these types):

- a value that is not an array is wrapped into a one-element array
- a struct takes its members from an object by name, dropping an
  undeclared one and leaving a missing one null, and an array fills them
  by position instead; a scalar fails the record
- a map accepts only an object, and its keys are lowercased
- member names match case-insensitively at every depth, and the scalar
  coercions apply inside containers as they do at the top level
- a mismatch at any depth fails that record alone, with the message AWS
  reports there

binary and uniontype stay unsupported, as does a type string the parser
cannot read; each still routes the batch to the error output.

* fix(firehose): refuse under HiveJsonSerDe what AWS refuses

The complex-type conversion applied OpenX's coercions whichever
deserializer was configured: a non-array wrapped into an array, an
array filling a struct by position, a string parsed into a numeric
column, a nested value serialized into a text column. AWS documents
the last two as things HiveJsonSerDe will not do, and a probe over a
Hive stream (us-west-2, twelve records over the same four complex
columns) confirmed it refuses all four and fails the record, with
messages now reproduced: "Start of Array expected", "Start of Object
expected", "Current token (VALUE_STRING) not numeric, can not use
numeric value accessors", and "One or more fields have incorrect
format. Exception when validating field (root)".

The two booleans threaded through the type tree became one SerDeRules
record built from the deserializer, with a third member for this. The
top-level scalar path shares ScalarType, so a string in a numeric
column now fails under Hive there too, which was a deviation before
this branch. Hive still coerces a number into a text column and treats
{}, missing and undeclared members as OpenX does, all probed. A map
column itself given a non-object, and a boolean column given a string,
were not probed; the docs say which way they fall.
2026-09-13 00:09:47 -04:00
Brian Taylor 2a4ca61baf fix(cognito): delete a user pool's records with the pool (#2949)
* fix(cognito): delete a user pool's app clients, revocations and codes

#3419 took users and resource servers out with the pool, closing the half of
#2864 that was reported. Three more record types are the same defect and were
left behind: app clients, revoked token records and outstanding verification
codes.

On AWS a pool id is never reused, so nothing can inherit an orphan. Here
floci:override-id makes ids caller-chosen and therefore reusable, and a pool
recreated on a pinned id picks up whatever the deleted pool left.

Reproduced by pinning us-east-1_orphanprobe1, populating it, deleting the pool
and recreating it on the same id. The client leak is the serious one: the
deleted pool's client id kept resolving against the new pool, carrying a secret
the new pool's caller never saw.

  clients: ["c1"]
  describe-user-pool-client --client-id c1a93e3fc698451d96ed406adb -> c1

Clients are keyed by client id alone, so they are found by their userPoolId
field rather than a key prefix. Revoked tokens and verification codes have
their keys collected before deleting so the backing key set is not modified
while it is being iterated.

confirmSignUpNamesDeletedUserPoolInResourceNotFoundMessage, added by #2936,
built its orphaned client by deleting the client's pool, which this cascade
now prevents. It is renamed and reaches the same defensive path by dropping the
pool record alone, and a second case pins the new behaviour: a client id from a
deleted pool is gone with it.

Refs #2864

* fix(cognito): bound the delete cascade by pool ownership, not key prefix

floci:override-id makes pool ids caller-chosen, and validateOverrideId
permits a colon. Two live pools can therefore be named so that one id
plus the key separator is a prefix of the other, and the revoked-token
and verification-code cascades deleted by the matched key, so deleting
the shorter pool erased the longer one's records. For revoked tokens
that reinstated tokens the surviving pool had revoked.

Both records carry their own userPoolId, so ownership is now settled by
that field rather than by the key prefix. The other cascades reconstruct
the key from the pool id being deleted and so never reached across a
boundary; they are left alone.

A jti can itself contain a colon (global revocations use
global:{username}), so bounding the prefix by the separator would not
have been sufficient either.
2026-09-12 23:39:32 -04:00
lex00andlex00 5d0b0b44b1 fix(ec2): store and validate CreateVpcEndpoint SubnetConfiguration (#3491)
* fix(ec2): store and validate CreateVpcEndpoint SubnetConfiguration

CreateVpcEndpoint accepted SubnetConfiguration.N and dropped it, so an
interface endpoint took floci's own synthesized address in each subnet rather
than the one the caller pinned. Terraform's aws_vpc_endpoint sends the
subnet_configuration block on create and reads it back by following the
endpoint to its network interfaces, so every plan after the apply saw an
address it never asked for and proposed replacing the endpoint.

SubnetConfiguration is request-only in ec2/2016-11-15. No output shape carries
it, so the addresses are stored on the endpoint and consumed when its
interfaces are built, and DescribeVpcEndpoints echoes nothing new.

Ec2QueryHandler parses the flattened SubnetConfiguration.N list for
CreateVpcEndpoint and for ModifyVpcEndpoint, which takes the same parameter.
Ec2Service validates each entry against the named subnet, rejecting an IPv4
address outside its CIDR with InvalidParameterValue, and keeps the pinned
address on the endpoint's interface in that subnet. A subnet named only
through its configuration joins the endpoint's subnet set. Ipv6 is stored as
given, since floci's subnets carry no IPv6 CIDR to validate against and its
network interfaces have no IPv6 field yet.

Adds Ec2VpcEndpointSubnetConfigurationIntegrationTest over the query wire and
three Ec2ServiceTest cases for the create, modify and rejection paths.

* fix(ec2): reject the subnet-reserved addresses in SubnetConfiguration

validateSubnetConfigurations only checked that SubnetConfiguration.Ipv4 parsed
and fell inside the named subnet's CIDR. For a 10.61.1.0/24 subnet that let
10.61.1.0, .1, .2, .3 and .255 through, and each became the private address of
the endpoint's network interface. AWS keeps those five for itself, so none of
them can be assigned to a resource and no real endpoint could ever report one.

The rule is in ec2/2016-11-15 itself, in the CreateSubnet documentation:
"Amazon Web Services reserves both the first four and the last IPv4 address in
each subnet's CIDR block. They're not available for your use." CreateSecondarySubnet
says the same for secondary subnets. No constraint key carries it, and no shape
in the model states it for SubnetConfiguration.

Ipv4Cidrs.isSubnetReserved is new; the EC2 service had no reserved-address helper
to reuse. VpcNetworkManager.firstHostOffset looks close but is not the same rule:
it reserves ten addresses of Docker-network headroom at the bottom of a block and
nothing at the top, for allocation readability rather than AWS semantics.

Small blocks need no special case. A /28, the smallest subnet AWS accepts, keeps
11 of its 16 addresses and a /29 keeps three. Both ends are clamped so they cannot
cross in a block of four addresses or fewer, where every address is reserved.

The check sits in the shared validator, so CreateVpcEndpoint and ModifyVpcEndpoint
both refuse a reserved address with the InvalidParameterValue the containment check
already raises. Tests cover all five reserved addresses and one ordinary host
address on the create path, the modify path, a /28 subnet, and the query wire.

---------

Co-authored-by: lex00 <artigues.dev@gmail.com>
2026-09-12 22:32:12 -04:00
lex00 fe40e06938 feat(ec2): support snapshot block public access (#3490)
* feat(ec2): support snapshot block public access

Adds EnableSnapshotBlockPublicAccess, DisableSnapshotBlockPublicAccess and
GetSnapshotBlockPublicAccessState over the EC2 Query protocol.

The setting is account-level state scoped to one region, so it lives in a small
Ec2SnapshotBlockPublicAccessService keyed by region, mirroring
Ec2EbsEncryptionService. The account-aware storage backend namespaces the keys by
the calling credential's account. A region that was never configured reads back
unblocked.

Enable accepts only block-all-sharing and block-new-sharing, per the EC2 model,
and rejects unblocked with InvalidParameterValue. Disable returns the resulting
unblocked rather than the prior state. Only the Get response carries managedBy,
always account, since Floci has no declarative-policy layer.

* fix(ec2): honor DryRun on snapshot block public access

EnableSnapshotBlockPublicAccess, DisableSnapshotBlockPublicAccess and
GetSnapshotBlockPublicAccessState all model the standard DryRun parameter, but
none of the three handlers checked it. Enable persisted the requested state,
Disable persisted unblocked and Get answered 200, so DryRun=true had real side
effects on both write paths.

All three handlers now take the parameter map and call the existing
checkDryRun(params). Enable validates State first, through a new
validateEnableState on the service, because AWS reports an invalid parameter
ahead of DryRunOperation and only returns DryRunOperation once the request
would otherwise have succeeded. So State=unblocked with DryRun=true still
fails with InvalidParameterValue, and a missing State still fails with
MissingParameter.
2026-09-12 20:21:34 -04:00
lex00 cebb011a00 fix(autoscaling): round-trip the dropped Auto Scaling group fields (#3494)
* fix(autoscaling): round-trip the dropped Auto Scaling group fields

CreateAutoScalingGroup and UpdateAutoScalingGroup accepted DesiredCapacityType,
CapacityRebalance, MaxInstanceLifetime and DefaultInstanceWarmup and threw them
away, so DescribeAutoScalingGroups never read them back. A mixed instances policy
launch template override that selected instance types by InstanceRequirements
instead of by name was dropped the same way, and because the override parser used
InstanceType's presence as its only "is there another override" signal, such an
override also truncated the whole Overrides list.

The four scalar members now travel into AutoScalingService as one AsgOptionalFields
record and are stored on AutoScalingGroup as boxed, uninitialised fields, so a group
that never set one omits it from the Describe response rather than reporting a
default. Update keeps its partial-update semantics: an absent member leaves the
stored value alone. DefaultInstanceWarmup honours the documented -1 removal
sentinel, MaxInstanceLifetime must be 0 or at least 86400, and DesiredCapacityType
is checked against units, vcpu and memory-mib.

LaunchTemplateOverrides.InstanceRequirements parses and echoes every member of the
botocore shape except BaselinePerformanceFactors, and an override that sets both
InstanceType and InstanceRequirements raises ValidationError as AWS does.

Verified against botocore autoscaling/2011-01-01/service-2.json from awscli 2.35.24.

* fix(autoscaling): enforce the attribute-based instance selection rules

Two rules that botocore states but does not encode as constraints were missing.

DesiredCapacityType is typed XmlStringMaxLen255 with no enum, and
CreateAutoScalingGroupType.members.DesiredCapacityType.documentation carries the
rule: "Amazon EC2 Auto Scaling supports DesiredCapacityType for attribute-based
instance type selection only." Floci accepted vcpu and memory-mib for a group
whose launch template names a fixed instance type. Both values now raise
ValidationError unless the mixed instances policy left in effect by the request
carries a launch template override with a non-empty InstanceRequirements. units
is the documented default and stays legal everywhere, and an absent member is
not validated.

The effective policy is the one the request supplies on create. On update it is
the policy the request supplies, the stored policy when the request names no
launch source, or none when the request switches the group to a launch
configuration or a plain launch template. The effective DesiredCapacityType is
likewise the request value or, when absent, the stored one, so an update cannot
strip attribute-based selection out from under a stored vcpu.

shapes.InstanceRequirements.required is ["VCpuCount", "MemoryMiB"] and the shape
documentation repeats it as "You must specify VCpuCount and MemoryMiB". An
override carrying InstanceRequirements without both ranges was stored and
returned 200; it now raises ValidationError. Both rules run on create and on
update.

createGroupCarryingEveryOptionalField is @Order(1) and seeds the group the later
ordered tests reuse, so its setup moved from a launch template naming t3.micro
to a mixed instances policy whose override sets VCpuCount and MemoryMiB. That
makes its DesiredCapacityType=vcpu legal without relaxing any assertion, and the
ordered updates that follow still see attribute-based selection in effect.
2026-09-12 18:37:36 -05:00
Niels Kootstra 2104b33ea7 fix(codepipeline): cap QUEUED and PARALLEL pipelines at 50 active executions (#3503)
AWS allows at most 50 concurrent executions per QUEUED or PARALLEL
pipeline. StartPipelineExecution now counts the pipeline's InProgress
and Stopping executions under a per-pipeline admission lock and returns
ConcurrentPipelineExecutionsLimitExceededException at the limit. The
admission lock is separate from the monitor a QUEUED worker holds for
its whole run, so a start never waits for the running execution.

A start that reaches the executor after shutdown is persisted as Failed
and returns ConflictException instead of leaking
RejectedExecutionException. Shutdown waits up to five seconds for
execution workers to stop so their final status writes complete before
the process exits.
2026-09-12 14:25:07 -04:00
Ovidiu (Ovi)andOvidiu ea5925f630 feat(athena): add UpdateWorkGroup support (#3468)
* feat(athena): add UpdateWorkGroup support

* fix(athena): validate workgroup configuration updates

---------

Co-authored-by: Ovidiu (Ovi) <462561+ovidiubute@users.noreply.github.com>
2026-09-12 14:15:00 -04:00
Niels Kootstra 6507f32aea fix(firehose): keep buffered records when S3 delivery fails (#3471)
* fix(firehose): keep buffered records when S3 delivery fails

A failed S3 write dropped the batch it was delivering. Records that came in
through PutRecord were lost; records polled from a Kinesis source were only
recovered by re-reading from the committed checkpoint.

A failed delivery now restores the batch at the front of the buffer, ahead
of records that arrived while the write was in flight, keeps the buffer's
original start time so the next scheduled tick retries it, and re-pends the
source checkpoint so a later successful delivery commits it. Successful
delivery, compression and the scheduled flush are unchanged.

* fix(firehose): serialize delivery per stream so a later flush cannot commit past an unresolved batch

The buffer monitor only made the snapshot atomic. A poll that had read past
a first flush's checkpoint could buffer its records after that flush took
the pending position, and a second flush would then deliver them and commit
a position past the first batch while its S3 write was still in flight. If
that write failed, the durable checkpoint already sat past records that
were only buffered for retry, and a restart before the retry skipped them.

One delivery at a time per stream, from taking the buffer to committing or
restoring its checkpoint, closes that window; the poller keeps buffering
under the buffer lock alone, so a slow write never stalls a poll.

* docs(firehose): a failed S3 write now keeps its batch buffered

* docs(firehose): drop the stale no-retry note in the Parquet converter
2026-09-12 13:50:21 -04:00
Franklin G. Mendoza e0d43189f7 fix(build): publish arm64 baseline release image (#3461) 2026-09-12 11:15:52 -05:00
Priamo Germosen d429d107ff fix(mwaa): apply AirflowConfigurationOptions to the Airflow container (#3457)
CreateEnvironment stored and GetEnvironment echoed back
AirflowConfigurationOptions, but nothing translated it into the
container's actual configuration, so a DAG reading a custom
conf.get("section", "key") value at import time or task-run time got
nothing back, even though GetEnvironment reported the option as
configured.

Added MwaaEnvironmentManager.airflowConfigurationOptionsEnv, which
converts each AWS "section.key" entry into the AIRFLOW__SECTION__KEY
environment variable real Amazon MWAA sets for the same option, and
wired it into startAirflowContainer's env list. A malformed key (no
"section.key" dot on both sides) or one that would collide with a
variable Floci itself manages (PROTECTED_ENV_VARS: the executor,
database connection, security keys) is skipped and logged rather than
silently breaking the environment's required wiring.

Since this map now genuinely does something instead of being inert,
also added the validation CreateEnvironment's botocore model declares
for it (a 1-64 character key matching [a-z]+([a-z0-9._]*[a-z0-9_]+)?,
a 1-65536 character printable-ASCII value) as a server-side
ValidationException: the AWS SDKs enforce this client-side, but Floci
is also reachable via raw HTTP/CLI --cli-input-json, which bypasses
that, and an oversized or malformed entry should be rejected before
Docker container creation rather than passed through.

Fixes #3436
2026-09-12 11:11:23 -05:00
Franklin G. Mendoza a985773611 feat(bcm-pricing-calculator): emulate workload estimates (#3441)
* feat(bcm-pricing-calculator): emulate workload estimates

* fix(bcm-pricing-calculator): serialize timestamps as epoch seconds

* fix(bcm-pricing-calculator): align idempotency and errors
2026-09-12 11:31:20 -04:00
Franklin G. Mendoza a0fd815366 feat(oam): emulate observability access manager (#3440)
* feat(oam): emulate observability access manager

* fix(oam): honor explicit deny statements
2026-09-12 08:59:21 -04:00
Franklin G. Mendoza 68c783b576 fix(rds): report backing container failures (#3455)
* fix(rds): reconcile dead backing containers

* fix(rds): report backing container failures
2026-09-12 00:25:39 -05:00
Priamo Germosen fe076212c2 fix(mwaa): also detect a crashed sibling Postgres container, not just Airflow (#3454)
hasAirflowContainerExited only inspected the Airflow container. If the
sibling Postgres container dies instead (out of memory, its volume
filling up), Airflow keeps running but never reports metadatabase
healthy, so the environment sat at CREATING exactly as before this
existed, the same failure mode #3446 fixed for the Airflow container
alone.

Generalized into hasAnyContainerExited, backed by a shared per-container
helper, checking both Environment.getDbContainerId() and
getAirflowContainerId(). checkReadiness and its log messages updated to
match; behavior for a lone Airflow-container failure is unchanged.

Follow-up from hectorvent's review on #3446.
2026-09-12 00:20:38 -05:00
Hector Ventura 75a5111f6e docs: standardize Java code style rules (#3451)
* docs: standardize Java code style rules

AGENTS.md becomes the canonical Code Style source, regrouped into General,
Types and names, Imports, conventions the codebase already follows, and Tests.

Two new rules: write explicit types rather than var, and import classes rather
than writing fully-qualified names inline. Both are stated with the reason they
matter here, that the concrete type at a call site is usually what a wire
contract reviewer needs to see, and with the one exception each: record
deconstruction patterns for var, and genuine same-file name collisions for
qualified names.

The rest is existing practice written down so it stays true. Each claim was
measured against src/main and src/test: no printStackTrace, no logger field
named anything but LOG, no Calendar and no SimpleDateFormat. The System.out
rule exempts CLI entry points under tools/, which is its one real use. The
empty-catch rule now blesses naming the variable ignored or expected, the
convention the code already uses.

Two conventions are stated with the exceptions the tree actually contains
rather than as absolutes. java.util.Date survives where a third-party
signature forces it, in the BouncyCastle certificate builder and the JAX-RS
HttpHeaders.getDate() override, so the rule is java.time on Floci's side and
conversion at that boundary. Tab indentation is banned as such, since a JSON
text block may legitimately contain a tab as string content.

CONTRIBUTING.md and docs/contributing.md had no code style section at all, and
copilot-instructions.md had no code style content, so PR review could not flag
either new rule. The Copilot entry also lists the collisions it must not flag.

Existing code does not satisfy these everywhere. The rules are documentation
only: nothing in CI enforces them, and no Java file changes here.

* docs: correct the measured claims in the code style section

Review on #3451 caught that System.out is not confined to the tools CLI: four
test files print too. Checking the rest of the section the same way found five
more claims that do not survive a measurement, so this corrects all six rather
than only the reported one. The section's whole value is that a reader can trust
it without re-measuring.

System.out and System.err are now scoped to src/main, the way the wildcard
import rule already splits src/main from tests. The exception is named by its
real coordinates: AmiImageTool sits in the Java package
io.github.hectorvent.floci.tools.ami, not in the top-level tools/ directory,
which holds only tools/docs. printStackTrace stays absolute, since that one
holds: zero in src/main and src/test.

The Date rule listed two forced boundaries and there are three. BouncyCastle's
certificate builder and the JAX-RS HttpHeaders.getDate() override are joined by
JDBC's java.sql.Date, which extends java.util.Date and which the old wording
read as prohibiting, in RdsDataFieldMapper and RdsDataSqlParameters.

Optional is split, because half the claim was true. Never a field is exact,
there are none. Never a parameter was wrong: Quarkus threads
@ConfigProperty Optional<T> values through parameters in ResolvedServiceCatalog,
ContainerBuilder, DockerClientProducer and LaunchedContainerAwsEnv.

The three Tests rules each asserted something false. testX is not absent, it
names 291 methods across 52 files, so it is described as the older pattern not
to copy rather than as something that never happens. AssertJ is not absent
either, it is a declared test dependency used by the six Lambda launcher tests.
@DisplayName is genuinely rare in src/test, 13 files of 1455, but it is the norm
in compatibility-tests at 183 of 208, as is AssertJ at 197 of 208. That module
has the opposite idiom, so the Tests rules now say they describe src/test and
point a contributor at the module they are in.

Documentation only. No Java file changes here.
2026-09-11 23:23:51 -04:00
Priamo Germosen 2a682a6875 fix(mwaa): mark CREATE_FAILED when the Airflow container exits before becoming ready (#3446)
docker start only launches the entrypoint and returns immediately, so a
startup script or `airflow db migrate` failing partway through never
surfaced anywhere: the readiness poller only checked isReady() and had no
path back to a failure status, so the environment reported CREATING
forever instead of CREATE_FAILED.

MwaaEnvironmentManager.hasAirflowContainerExited inspects the container's
running state (docker-removed counts as exited too), and the readiness
poller (extracted into checkReadiness for direct testability) now marks
CREATE_FAILED when isReady() is false and the container has exited.

Two things this needed to stay safe under concurrency and partial
failure, both of which isReady() already handles and this had to match:

- isReady()/hasAirflowContainerExited() are blocking Docker/HTTP calls,
  wide enough for a concurrent DeleteEnvironment (which sets DELETING on
  the same Environment instance before tearing down its containers) to
  have moved the environment past CREATING in the meantime. checkReadiness
  re-checks the status immediately before writing, in both branches, so it
  can't resurrect a just-deleted environment into storage with a status
  decided from stale, pre-delete information.
- hasAirflowContainerExited only treats NotFoundException (the container
  is actually gone) as exited; any other Docker error is inconclusive and
  must not propagate, since the readiness poller shares one loop across
  every CREATING environment and an uncaught exception from one
  environment's check would otherwise skip every other environment for
  that poll tick, the same failure mode isReady()'s own catch-all already
  avoids.

Fixes #3437
2026-09-11 22:38:06 -04:00
lex00andlex00 128d3ef181 feat(datasync): add the DataSync management plane (#3377)
* feat(datasync): add the DataSync management plane

Emulates the AWS DataSync management API over JSON (X-Amz-Target
FmrsService.<Action>, signing name datasync): agents, the eleven
CreateLocation/DescribeLocation/UpdateLocation trios plus the shared
ListLocations and DeleteLocation, tasks, and resource tagging.

Each DescribeLocation* projects the create request that produced the
location, so the configuration that went in is the configuration that comes
back, and LocationUri is derived from that request per the scheme AWS
documents for the type. DescribeAgent reports ONLINE and DescribeTask reports
AVAILABLE from the first read, which is what the Terraform provider's
aws_datasync_task waits on. Credential members (Password, SecretKey,
SasConfiguration, the Kerberos files and the nested Protocol.SMB.Password)
are dropped before the configuration is stored, as AWS never reads them back
either. Errors use InvalidRequestException, the only client error the
DataSync model declares.

The task-execution data plane (StartTaskExecution, DescribeTaskExecution,
ListTaskExecutions, CancelTaskExecution, UpdateTaskExecution) transfers real
bytes between real storage systems and keeps raising UnknownOperationException
rather than a stub success.

* fix(datasync): default VerifyMode from the task mode

The DataSync model documents two VerifyMode defaults, not one:
POINT_IN_TIME_CONSISTENT for a BASIC task and ONLY_FILES_TRANSFERRED for an
ENHANCED one, which also cannot use POINT_IN_TIME_CONSISTENT at all. CreateTask
applied the BASIC default to every task, so an ENHANCED task created without an
explicit VerifyMode read back wrong.

The default now follows TaskMode, and a VerifyMode the mode does not support is
rejected with InvalidRequestException, the only client error this API declares.
UpdateTaskRequest carries no TaskMode, so a task keeps the mode it was created
with and UpdateTask applies the same rule against the stored mode. An
unrecognized TaskMode is rejected rather than silently treated as BASIC.

* test(datasync): add the SDK compatibility test

Drives an agent, an S3 and an NFS location, both task modes and the tag round
trip through the AWS SDK v2 DataSync client, which is the one piece of real-SDK
verification the RestAssured tests do not cover. It asserts the VerifyMode
default for a BASIC and an ENHANCED task, and that an ENHANCED task rejects
POINT_IN_TIME_CONSISTENT on create and on update.

---------

Co-authored-by: lex00 <artigues.dev@gmail.com>
2026-09-11 22:30:02 -04:00
Priamo Germosen 473a26aad9 fix(mwaa): match real MWAA's Airflow/Python pairing for the emulated image tag (#3445)
Real Amazon MWAA runs every Airflow version through 2.10.x on Python 3.11,
and only 2.11.0 onward (and every 3.x release) on Python 3.12. Floci
hardcoded apache/airflow:<version>-python3.12 for every supported version,
so a requirements.txt built the way AWS documents (a --constraint file
matching the real Airflow/Python pairing, e.g. constraints-3.11.txt for
2.9.x) resolves dependencies for the wrong Python minor version.

Fixes #3438
2026-09-11 20:54:52 -05:00
lex00 cae8f9a013 feat(bedrock): add guardrail lifecycle and versions (#3380)
* feat(bedrock): add guardrail lifecycle and versions

Amazon Bedrock control plane over REST JSON: CreateGuardrail through
DeleteGuardrail, CreateGuardrailVersion, ListGuardrails with pagination, and
resource tagging on /tagResource, /untagResource and /listTagsForResource.
Guardrails report READY on the first read, so the Terraform provider's status
poll for aws_bedrock_guardrail completes without a transition.

The control plane and bedrock-runtime both sign as "bedrock". The runtime
descriptor keeps that credential scope, and the new descriptor routes through
its resource class, which ServiceEnabledFilter checks first.

Policy blocks are stored under the read-shape member names, so a *Config
submitted on create or update reads back unsuffixed. ListGuardrails honours
maxResults and nextToken, and DeleteGuardrail rejects a guardrailVersion that
is not a GuardrailNumericalVersion.

* fix(bedrock): enforce guardrail length caps and resolve kmsKeyId to a key ARN

The AWS model caps description at 200 characters and both blockedInputMessaging
and blockedOutputsMessaging at 500, each with a minimum of 1. None of those were
checked, so an over-long value was stored and read back. name was already bounded
by its [0-9a-zA-Z-_]{1,50} pattern.

kmsKeyId on CreateGuardrail and UpdateGuardrail is a KmsKeyId: a key id, a key
ARN, an alias name or an alias ARN. kmsKeyArn on the read shapes is a KmsKeyArn,
which is only ever the full key ARN. The request value was echoed back verbatim,
so a bare key id or an alias produced a response that does not match the shape
GetGuardrail declares. It now resolves through KmsService.describeKey, the same
way RDS, DocDB and ElastiCache already resolve their KmsKeyId, and a key that is
missing, disabled or pending deletion is rejected with ValidationException.

* test(bedrock): drive the guardrail lifecycle from the AWS SDK v2 client

Adds the bedrock SDK module to the compatibility project, a BedrockClient
factory on TestFixtures, and a BedrockGuardrailTest covering create, read,
update, versioning, listing, tagging and delete. The test also submits kmsKeyId
as a bare key id and as an alias and asserts both read back as the same full KMS
key ARN.

* fix(bedrock): enforce the guardrail tag caps from the AWS model

The AWS model gives TagList a max of 200 items, and that shape backs the tags
member of both CreateGuardrail and TagResource. TooManyTagsException, declared
on both operations, documents a separate limit of 50 tags per resource counted
over the tags already on the resource together with the ones in the request.

parseTagList now rejects an array over 200 items with ValidationException, and
it moved to BedrockService so both entry points share it. CreateGuardrail and
TagResource raise TooManyTagsException once the total the guardrail would be
left holding passes 50, carrying resourceName as the model declares.
2026-09-11 20:36:45 -04:00
Franklin G. Mendoza 07d6cabd8a feat(marketplace-discovery): emulate AWS Marketplace Discovery API (#3342) 2026-09-11 18:48:30 -04:00
lex00 137a39add3 feat(appintegrations): add data and event integrations (#3379)
* feat(appintegrations): add data and event integrations

Amazon AppIntegrations over REST JSON, registered under the app-integrations
signing name: event integrations on /eventIntegrations, data integrations on
/dataIntegrations, and resource tagging through the shared /tags/{resourceArn}
dispatcher. Terraform's aws_appintegrations_event_integration and
aws_appintegrations_data_integration now round-trip against Floci instead of
failing on an unimplemented signing scope.

Event integrations are keyed by name, data integrations by generated id, and
both accept their own ARN wherever the API takes an identifier. The two PATCH
operations apply only the members present in the request body, matching how AWS
treats an optional member the caller did not send. Both tag writes answer 200,
which is what the 2020-07-29 model gives them.

* test(appintegrations): add an SDK compatibility test

Adds the appintegrations AWS SDK v2 module, a TestFixtures client factory,
and an AppIntegrationsTest that drives both integration types and the tag
round trip through the real SDK client.
2026-09-11 17:55:48 -04:00
lex00andlex00 2e79f5c766 feat(globalaccelerator): add the Global Accelerator management plane (#3378)
* feat(globalaccelerator): add the Global Accelerator management plane

Emulates the AWS Global Accelerator management plane over JSON 1.1 under the
GlobalAccelerator_V20180706 target prefix, signing name globalaccelerator:
accelerators, listeners, endpoint groups, accelerator attributes and resource
tags, 22 actions in all.

Global Accelerator is a global service, so ARNs carry an empty region segment
and listener and endpoint group ARNs extend the accelerator ARN. Nothing is
keyed by the signing region, so a caller that signs outside us-west-2 sees the
same accelerators. Accelerators report DEPLOYED and endpoints HEALTHY from the
first read, so SDK and Terraform waiters complete on their first poll.

Enum and range members are validated against the API model, and
UpdateAcceleratorAttributes rejects an update that would leave FlowLogsEnabled
true with no destination bucket.

* fix(globalaccelerator): enforce the list caps and HealthCheckPath format from the API model

The scalar ranges were already checked against globalaccelerator/2018-08-08, but the
array-count caps were not. PortRanges, EndpointConfigurations and PortOverrides each
declare max 10, and IpAddresses declares max 2 for the BYOIP case. All four were
unbounded. HealthCheckPath declares max 255 and the pattern
^/[-a-zA-Z0-9@:%_\+.~#?&/=]*$, which was not checked at all.

The new failures reuse InvalidArgumentException and the message shape the existing
scalar validations already use, so they are indistinguishable in kind from those.

* test(globalaccelerator): add the SDK compatibility test

Adds the globalaccelerator SDK module, a TestFixtures client factory and a
GlobalAcceleratorTest that drives accelerator, listener and endpoint group
lifecycles through the AWS SDK v2 client, including the new PortRanges cap.

---------

Co-authored-by: lex00 <artigues.dev@gmail.com>
2026-09-11 16:53:22 -04:00
Matheus Oliveira e3766eac6f feat(kinesis): implement UpdateShardCount API (#3200)
Adds uniform-scaling reshard support via existing splitShard/mergeShards
machinery, with the documented double/half, 10000-shard, and 10-scales-per-24h
limits enforced as LimitExceededException/InvalidArgumentException/ValidationException.
The half-shard-count minimum rounds up for an odd current count, which is
Floci's own call since AWS documents only "below half" with no stated
rounding direction; the separate 10 TPS call-rate limit AWS documents on this
action is not simulated, matching Floci's lack of real-time request
throttling elsewhere. Both are now called out explicitly in the docs and code.

Signed-off-by: Matheus Oliveira <matheus.6148@gmail.com>

* Fix #3064
2026-09-11 16:25:49 -04:00
Matheus André 8d011cb983 fix(apigateway): implement MOCK integration response selection based on status code (#3327)
Signed-off-by: Matheus André <matheusandr2@gmail.com>
2026-09-11 12:11:12 -04:00
Kenshin Okinaka e219ea409f feat(ses): support v2 dedicated IP (IP-level) and scaling/warmup APIs (#3420)
Add the remaining SES v2 dedicated-IP operations on top of pool management:
GetDedicatedIps, GetDedicatedIp, PutDedicatedIpInPool,
PutDedicatedIpWarmupAttributes, PutDedicatedIpPoolScalingAttributes, and
PutAccountDedicatedIpWarmupAttributes.

SES has no API to create a dedicated IP (they are leased out-of-band or
auto-provisioned), so Floci models an account with no dedicated IPs:
GetDedicatedIps is empty and any IP-targeted operation returns NotFoundException
'Could not find dedicated IP <ip> under this account.', matching real AWS for an
account with no leased IPs (verified 2026-06-21). PutDedicatedIpPoolScalingAttributes
updates the pool's scaling mode, and PutAccountDedicatedIpWarmupAttributes stores
the account-level flag now reflected by GetAccount.

Add integration and AWS SDK v2 compatibility tests.
2026-09-11 12:01:13 -04:00
Kenshin Okinaka d96516dc70 feat(firehose): apply the Lambda transform to buffered records (#3393)
* feat(firehose): apply the Lambda transform to buffered records

A flushed buffer now goes to the Lambda processor's function as a single
invocation, and what the function returns is what reaches the destination.
Ok delivers the returned data, Dropped leaves no trace, and every other
outcome routes that record to the error output while the rest of the batch
still delivers: ProcessingFailed, a record the function did not return, a
record id returned twice, and an Ok carrying no data.

A function-level error is retried NumberOfRetries more times and then fails
the whole batch as Lambda.FunctionError; a response the function returned
successfully is final however malformed it is, matching what AWS reports for
a response naming no records at all.

The transformation runs ahead of data format conversion, so a stream
configured for both converts what the function returned, and the
"not applied yet" warning the configuration used to log is gone.

* fix(firehose): clamp a NumberOfRetries wider than a long, and heal a stored Enabled

Long.parseLong threw for a NumberOfRetries too wide for a long, which the
catch treated as "not a number" and answered with the default 3. A larger
retry count than one that clamps therefore got fewer attempts: 2147483648
delivered 101 attempts where 999999999999999999999 delivered 4. Reading it
as a BigInteger keeps the clamp meaningful at any magnitude.

A ProcessingConfiguration persisted before Enabled was defaulted never
passes canonicalizeProcessors again, so the describe path now fills it, the
way that path already self-heals partial BufferingHints. Only Enabled: the
parameters AWS defaults include RoleArn, which a read must not inject from
whatever role is current by then.
2026-09-11 11:45:03 -04:00
Niels Kootstra c6e64a0977 fix(mwaa): isolate environments by account and region (#3400)
* fix(mwaa): isolate environments by account and region

* fix(mwaa): migrate legacy environment records safely
2026-09-11 10:25:21 -04:00
Matan Baruch 485b7c5047 feat(rds): accept AWS IAM DB auth users on MySQL (#3395) 2026-09-11 10:10:26 -04:00