100 Commits
Author SHA1 Message Date
Priamo Germosen 3a1ea212f0 feat(iam): read DynamoDB from the generated tables, its statement and item permissions from the developer guide (#9235)
DynamoDB is read from iam-request-resources.json now, and
ResourceArnBuilder's DynamoDB branch, the registry's PartiQL action,
the condition resolver's mapping of transaction items and statements to
actions and Step Functions' copy of all three are gone, leaving iam in
HAND_BUILT.

Which action each transaction item and each PartiQL statement is
checked as comes from the developer guide, vendored by
fetch_dynamodb_permissions.py into
tools/aws/sources/dynamodb-permissions.json and read under
PERMISSION_SOURCES: the PartiQL IAM page's required permissions and the
transactions page's paragraph on each kind of item.

- Each transaction item is checked as the action of its kind on the
  table its TableName names (TransactItems[].Put.TableName as
  dynamodb:PutItem), each PartiQL statement as the action of its verb on
  the table or index it names, an EXISTS statement as the SELECT it
  evaluates, which DynamoDB's own parser reads through the new
  StoredResourceArns.statement hook before it binds the request's
  parameters. A request naming nothing is checked as its own action on
  *; a state machine's task naming nothing is left to DynamoDB, as
  before.
- RequestResources.targets replaces checkedAs: each element of a list is
  read apart and returned with its check, so the condition resolver
  still gives each item or statement its own keys and
  dynamodb:EnclosingOperation.
- BatchGetItem and BatchWriteItem name their tables by the keys of
  RequestItems, which the generator reads from botocore (RequestItems{}).
- RequestResourceMembers reads Name{}, Name[].Item.Field and statement
  rows (statement, verb, names).
2026-11-22 22:04:18 -04:00
Priamo GermosenandAndre Kurait 77c11493e7 fix(eks): trust Floci's served certificate in the pod identity webhook (#9231)
The Pod Identity webhook manifest carried only Floci's local CA, so with
floci.tls.cert-path set the API server refused Floci's certificate, and
failurePolicy Ignore admitted every pod unchanged. Its URL named the
Docker host: with Floci in a container that is Floci's container IP,
which Floci's own certificate does not name. An adopted cluster also
kept the manifest written when its container was created.

The caBundle is now the bundle /_floci/ca.pem serves, which moves into
ContainerCaBundle so both read it from one place. The URL uses a host
the served certificate names, through the check custom resource response
URLs already make in ContainerReachableEndpoint: Floci's hostname when
the node resolves through Floci's embedded DNS, otherwise the Docker
host. When the certificate does not name that host, the webhook is
skipped with a warning, as it is with TLS off. Adopting a surviving
cluster writes the manifest again, and names Floci's hostname only when
the surviving node was created with Floci's DNS server as its resolver.

The manifest and the webhook k3s registered from it live on the
cluster's data volume, so a skipped webhook now replaces the manifest
with one holding no objects, and k3s deletes the webhook an earlier
start registered.

The manager's constructors that left collaborators out existed only for
tests; they move to a test-side factory, so the endpoint the webhook
needs is never null in production code.

Closes #5563

Co-authored-by: Andre Kurait <AndreKurait@gmail.com>
2026-11-22 20:29:39 -04:00
Priamo Germosen 739a22ab32 feat(iam): read KMS from the generated tables, its permissions from the developer guide (#9221)
KMS is read from iam-request-resources.json now, and ResourceArnBuilder's
KMS branch and the enforcement filter's call around the table are gone,
leaving dynamodb and iam in HAND_BUILT.

What botocore and the Service Reference do not say comes from the KMS
documentation, vendored by fetch_kms_api_permissions.py into
tools/aws/sources/kms-api-permissions.json and read under
PERMISSION_SOURCES: the developer guide's permissions table, the API
reference's sentence that Decrypt and ReEncrypt read their key from the
ciphertext's metadata, and the guide's key identifier formats.

- ReEncrypt is checked as kms:ReEncryptFrom on its source key, or the
  ciphertext's key without one, and kms:ReEncryptTo on its destination
  key, ReplicateKey as kms:ReplicateKey and kms:CreateKey. An operation
  checked as several actions records them (actions, action), which
  RequestResources.checkedAs reads and the filter checks.
- CreateAlias, UpdateAlias and DeleteAlias are checked on the alias and
  the keys the table names, the alias's current key through the alias.
- Decrypt with no KeyId is checked on the ciphertext's key.
- KmsStoredResourceArns finds a key in any state, uses only an enabled
  one for a forwarded request, reaches the key of an alias, a grant or
  a ciphertext, and gives a key's tags.
2026-11-22 20:28:28 -04:00
Priamo Germosen 81b25c66bc refactor(emr-serverless): name SparkConnectServers' servers by their kind (#9222)
SparkConnectServers runs a session's server through the shared Spark
runner, probes it until it answers, keeps the tokens given for it and
routes a call by its token. Nothing in that is Spark Connect's but its
probe and the words of its refusals and its log, which name the Spark
Connect server and GetSessionEndpoint. EMR on EKS's managed endpoints
need the same for the Jupyter Enterprise Gateway they run (REAL-30).

- The class is SessionServers, and takes a Kind: what its servers are
  called, what each serves, and the operation that gives their tokens.
  Kind.SPARK_CONNECT gives EMR Serverless's and EMR's sessions the same
  answers and log as before.
- The texts a session fails with when its Spark Connect server exits,
  cannot start, never answers or ends, and the failure() that picks
  one, move to SparkConnectSessionOwner, the one class that uses them.
- probe(SparkConnectProxy) is sparkConnectProbe.

No behavior changes.
2026-11-22 18:49:11 -04:00
Priamo Germosen e394329a8b chore(deps): bump botocore to 1.44.9 (#9223)
Moves the pin from 1.43.118 to 1.44.9 and regenerates the data derived
from it.

1.44.9 adds the me-west-1 and sa-west-1 regions, whose optIn and
s3WebsiteDashForm flags come from aws-cdk's aws-entities.ts rather than
botocore, so partitions.json is generated with that file; no existing
region's flags change. AwsPartitionsTest, AwsRegionsTest and
Ec2DescribeRegionsIntegrationTest count 36 commercial regions, 19 of
them opt-in.

The IAM tables aws-data-check-botocore checks are regenerated with it.
The passed-role and tag-on-create tables no longer park any operation
as missing from the pinned botocore, and the passed-role generator's
four MEMBER_NOT_IN_BOTOCORE entries come out, as the reason asks, now
that EventBridge's event sources and WAF v2's web ACLs have the member
naming their role. The DynamoDB and IAM condition key tables are
regenerated too. test_regen_iam_tag_on_create pinned
network-firewall:CreateFirewallPolicyV2 as an operation botocore lacks;
it now checks the tags its request names.

with_parent_ids reads a made resource's parent id from "the one
top-level ARN member named after that type", but request_members keys
a member inside a structure or a list by its whole path, so the
path == member test also took RAM's new
permissionTemplateParameters[].permissionArn and filled the resource
share CreateResourceShare makes with a permission ARN. It now takes a
top-level member alone, which changes that one operation and no other.

Four request members 1.44.9 models were accepted and dropped, as they
were before it, when Floci read them as unknown:

- ECR keeps each replication rule's deleteReplication and returns it
  from PutReplicationConfiguration and DescribeRegistry.
- Lambda MicroVMs keep the kmsKeyIdentifier an image's create or update
  names on each version it builds, and the one RunMicrovm names on the
  MicroVM, and return them where the model has the member.
- STS's GetWebIdentityToken refuses Scope unless SubjectMode is
  OriginIdentity with exactly one audience, and refuses OriginIdentity,
  which reads the calling session's trusted identity propagation
  context, as AWS does a session without one: no Floci session carries
  one. Both answer ValidationError with the reference's own sentence.

LambdaMicrovmImageModeledConstraintsIntegrationTest's invalid cases
follow the model: X86_64 is an architecture now, and an image takes up
to 100 environment variables.
2026-11-22 18:46:45 -04:00
Priamo Germosen 942cace935 fix(iam): refuse a managed policy delete that leaves versions behind (#9224)
DeletePolicy read the attachment count alone, so a policy carrying a version
beside its default was deleted along with its history and answered nothing.
AWS refuses that delete with DeleteConflict 409 and three sentences of
wholly fixed text, "This policy has more than one version. Before you delete a
policy, you must delete the policy's versions. The default version is deleted
with the policy.", recorded against a real account on 2026-10-29, and the
operation's published description asks a caller for the same two steps:
detach the policy from every user, group and role, then delete all of the
policy's versions.

The refusal reports an attachment first and the versions second, the order
those steps are written in. Which of the two AWS names for a policy carrying
both is not recorded, so the page marks that order as this package's reading
rather than a recording, as it already does for attached ahead of inline.

Nothing clears those versions on the caller's behalf, on AWS or here, so
whoever wants the policy gone deletes them first. The CloudFormation
provisioner for AWS::IAM::ManagedPolicy owns the policies its stacks create
and publishes the new document as a new default version on every update, which
leaves the version before it stored: the delete that brings such a stack down
clears the other versions ahead of the policy, in the order the published
steps give, so a stack cannot end up able to create and update a policy it can
never take down again. The clearing asks the attachment question before a
single version goes and answers it with the sentence the delete would, so a
policy a principal the stack never recorded still holds keeps its history
instead of spending it on a delete that was going to be refused anyway.

The reads a delete decides on and the delete itself are under the lock every
other IAM write takes, which the writes to a policy's versions now take as
well, so a version published between the count and the delete is no longer
deleted along with the policy it was added to, and the write back that ends a
clearing cannot restore a policy another caller deleted in between. Inside it
the version map keeps its own monitor, and SetDefaultPolicyVersion moves the
default version id under that monitor beside the flags it already set there:
between those two writes a clearing would have read the id this call had just
replaced and dropped the version it had just made default.

Covered over the API by the refusal, its precedence over the attachment and
the control that deletes the other version and then the policy; at the service
level by the clearing that keeps the default with its document, the attachment
that refuses it with every version intact, and the version a SetDefault just
chose being the one kept; by a trial loop over a delete racing a version
publish; on the provisioner by the order its delete asks for; and end to end by
a stack that is created, updated and then deleted, with the policy gone after
it. One test fixture published a second version and tore the policy down with
one call, which the refusal now blocks, so it deletes that version first.
2026-11-22 17:20:50 -04:00
Priamo Germosen 39b601514a feat(emr-containers): retry a job run's failed driver under its retry policy (#9218)
A docker job run with a retryPolicyConfiguration failed at its driver's
first error, and every run showed its policy, even one that disables
retries.

- With a maxAttempts above 1, a driver that exits with an error is
  started again, "restarted automatically if it fails", until the run
  has made maxAttempts attempts, after "an exponential retry interval of
  (10 seconds, 20 seconds, 40 seconds ...) which is capped at 6 minutes"
  (EMR on EKS Development Guide, "Using job retry policies").
- Between its attempts the run is SUBMITTED and keeps its running slot,
  each new attempt raises its retryPolicyExecution's currentAttemptCount,
  and CancelJobRun cancels it at once. One Floci stopped in between waits
  out the rest of its backoff once it is read again. A driver that cannot
  start, or that Floci stopped, is not retried.
- With retries enabled, its driver pod's name has a suffix of each
  attempt's own, spark-<job id>-driver-<random-suffix>, so each attempt's
  logs go to a folder and streams of their own, under the run's one Spark
  application id.
- A maxAttempts outside 1 to 2,147,483,647 is refused with "Retry policy
  configuration's parameter value of maxAttempts is invalid", and one of
  1 shows neither the policy nor its execution: "These fields will not
  be visible when retry policy is disabled in the job".
- Floci sends no EMR on EKS events, so the docs note that there is no
  "EMR Job Run New Driver Attempt" event.
2026-11-22 15:44:21 -04:00
Priamo Germosen 82fdb36228 fix(iam): answer a blocked delete with the sentence for the dependency that blocks it (#9220)
IAM names exactly one blocking dependent and words each class with its own
wholly fixed sentence, no entity name and no count, because a cleanup loop
reads the sentence to choose its next step. Four of those recordings bear on
this package and three of them diverged.

- DeleteRole read a role's attached and inline policies together and answered
  the detach sentence for both, so an inline policy was told to detach
  something. The two are reported apart now: "Cannot delete entity, must
  detach all policies first." for a managed attachment and "Cannot delete
  entity, must delete policies first." for an embedded policy, which is the
  remedy that clears what is there. DeleteGroup conflated them the same way
  and selects the same two sentences now; DeleteUser already did and is the
  model both follow.
- DeleteRole never looked at instance profiles, so a role a profile held was
  deleted and left the profile naming nothing. A role an instance profile
  holds is "Cannot delete entity, must remove roles from instance profile
  first." and the profile has to let go of it first, as on AWS. The profile
  is reported ahead of an attached policy, which is recorded for a role that
  is both held and carrying attachments, and is what a cleanup loop needs,
  since detaching changes nothing while the pairing is there.
- DeleteInstanceProfile wording its own refusal now carries that same
  sentence, which is AWS's for both ends of the pairing.

The new membership check and the emptiness check it joins are both
check-then-act, so AddRoleToInstanceProfile takes the lock the deletes decide
under, outside the profile's own monitor as every path here already does: one
order throughout, and no pairing can land between a delete's read and what it
does with it.

Nothing takes a role out of a profile on the caller's behalf, on AWS or here.
The CloudFormation role provisioner keeps clearing the policies its stack owns
and lets the conflict reach the stack, with a provisioner case for it; a stack
owning both resources deletes the profile first, since dependents go before
what they depend on. The test fixture that tears a role down removes it from
any profile first, ahead of its policies, so teardown asks for the remedies in
the order the refusals name. The tolerance behind RemoveRoleFromInstanceProfile
stays for state reached another way, and the test that reached it by deleting
the role first now asserts the refusal and clears the pairing before the role.

Which profiles hold a role is kept as an index beside the profiles themselves,
written in the same two places a pairing is and read only under that lock, so
the check costs a lookup rather than a read of every profile in the account
while the lock is held. A scope is filled from storage the first time it is
asked about, so a pairing a restart inherited is in it before the first answer.

The two callers that delete a role of their own clear its policies first, so
each asks about the profile before it clears anything: otherwise a role that
turns out not to be deletable would be left in place with its permissions
stripped by a delete that could not finish.
2026-11-22 15:14:52 -04:00
Priamo Germosen 5c62948838 feat(emr-containers): send a job run's driver logs to its S3 and CloudWatch destinations (#9208)
A docker job run's driver output went to Floci's log only, whatever its
monitoringConfiguration asked for.

- With an s3MonitoringConfiguration, the driver's stdout.gz and
  stderr.gz go to "/logUri/virtual-cluster-id/jobs/job-id/containers/
  spark-application-id/spark-job-id-driver/" once the run ends, as the
  development guide's "Configure a job run to use Amazon S3 logs" lays
  out a driver's logs.
- With a cloudWatchMonitoringConfiguration, its standard output and
  standard error go, as it writes them, to the streams
  "logStreamPrefix/virtual-cluster-id/jobs/job-id/containers/
  spark-application-id/spark-job-id-driver/(stderr/stdout)" in its
  logGroupName, the group and streams created if they do not exist.
- The spark-application-id has the form a Spark application on
  Kubernetes gets, spark- and 32 hexadecimal digits, and is Floci's own.
- A job template's configurationOverrides, whose parametric model need
  not name a destination's log group or log URI, are held to
  StartJobRun's ConfigurationOverrides, as a request's own are.
- The runner gzips a driver's output into temporary files rather than
  memory, and the per-stream CloudWatch forwarding EMR Serverless shares
  sends each line as written, but for an empty one, which CloudWatch
  Logs refuses, and each stream's lines of one emission in one call.
2026-11-22 14:08:25 -04:00
Priamo Germosen 0638a7f1d1 feat(iam): read API Gateway from the generated tables, its paths from the developer guide (#9207)
API Gateway leaves ResourceArnBuilder's own branch, and the enforcement filter's call that went around the
table for it: its requests are matched on their botocore routes and checked on the resources the
request-resources table reads. API Gateway authorizes a management call as the HTTP method of the request, on
the resource its path names, which its developer guide says and neither botocore nor the Service Reference
does. fetch_apigateway_arn_formats.py copies the guide's IAM page (the action and resource format sentences)
and its ARN reference tables unchanged into tools/aws/sources/apigateway-arn-formats.json, which
regen_iam_request_resources.py reads: a route authorized as its method is checked on the resource whose
published format is its own path, a Service Reference type before the guide's REST row, the /v2 of HTTP and
WebSocket API paths left out, and a path neither gives a row on the guide's ARN format with that path as its
resource path. The formats the reference does not give are recorded under pathFormats.

RequestResourceMembers reads pathFormats beside arnFormats and takes a hyphen in a path label;
RequestResources URL-encodes a value filling a UrlEncoded variable, so a tagging route acts on
/tags/<URL-encoded ARN> however it sends the ARN, and escapes % and / in a value filling a path-shaped format,
so one label cannot pass for several segments.
2026-11-22 10:09:43 -04:00
Priamo Germosen 84cbee7d6f feat(emr-containers): run a job run's Spark job in a container (#9203)
An EMR on EKS job run ran nothing: it was COMPLETED at once, or RUNNING
on a timer and then COMPLETED, whatever its Spark job would have done.

- With floci.services.emrcontainers.runner-mode set to docker, a run
  runs its Spark job in a container of its release's EMR on EKS base
  image on Amazon ECR Public, or of its custom image: a
  sparkSubmitJobDriver's spark-submit, or a sparkSqlJobDriver's
  spark-sql with its entry point as the file it runs, with the
  spark-defaults of its configurationOverrides and its execution role's
  credentials, on Floci's S3.
- The release label names the image's repository and tag, as the
  development guide's release notes give each release's "Container
  image tag": emr-7.2.0-20240610 runs emr-7.2.0:20240610. The base
  image's spark-defaults.conf runs a driver in Kubernetes' cluster
  mode, so the driver runs in client mode, its executors with it.
- A run is SUBMITTED while its container starts, RUNNING once its
  driver runs, and COMPLETED or FAILED as the driver exits, a failed
  driver with AWS's USER_ERROR and "Jobrun failed. Main Spark container
  terminated with errors. ...". A container that cannot start, a job
  driver without an entry point, and a run a restart left running fail
  with the development guide's INTERNAL_ERROR and VALIDATION_ERROR
  answers.
- CancelJobRun makes a running run CANCEL_PENDING until its driver is
  stopped, then CANCELLED.
- A run holds its virtual cluster's running slot from its submission
  until its driver ends, counting as concurrent, not queued, and the
  slot then goes to the queue. A run that cannot be handed to a thread
  fails and frees its slot, and a leftover driver of a run found failed
  is removed.
- The immediate runner mode, the default, is unchanged.
2026-11-22 09:33:41 -04:00
Priamo GermosenandYi-111-a d8809f6f0e fix(ecr): scope the registry data plane to each account and answer NAME_UNKNOWN (#9171)
The registry data plane and the catalog reconcile run outside any request, so the
account-aware repository store read and wrote them as the default account. A repository
another account created was not found: its IMMUTABLE tags were not enforced, and the
reconcile recreated it in the default account's partition. The data plane's lookups now
read the repository in the account its registry host names, and the reconcile reads and
writes each entry in the account it belongs to, the configured default account for a
pre-proxy namespace even when a request of another account started the registry.

A push or pull for a repository nobody created fell back to the default namespace, so
registry:2 stored it and the next start adopted it. Once the catalog has been read, such a
name now answers 404 NAME_UNKNOWN before any byte reaches the registry, once it has been
checked against the registry running now: a recovered registry's catalog is read again.
Until then it answers unavailable, since its images may be in the registry: the start's
catalog read is strict now, so a failed read no longer counts as an empty catalog, and the
data plane retries it, at most every 30 seconds. A client that leaves while the catalog is
read gives its write admission back at once, and a lookup that fails after the read is
answered with a 500 rather than left waiting.

The EKS registry-hosts and ECR TLS data-plane tests create their repository before pushing.

Closes #6101
Closes #6140

Co-authored-by: Yi-111-a <153097222+Yi-111-a@users.noreply.github.com>
2026-11-22 09:14:38 -04:00
Priamo Germosen 94c0504bca fix(rds): initialize PostgreSQL as rdsadmin, with the master user in rds_superuser (#9182)
A PostgreSQL backend started with the master user as POSTGRES_USER, so the master was the bootstrap superuser and owned the system catalog: REASSIGN OWNED BY <master> failed with "required by the database system", and rds_superuser did not exist.

A new backend is now initialized as rdsadmin, as RDS initializes one. A first-boot script creates the master as LOGIN NOSUPERUSER INHERIT CREATEDB CREATEROLE NOREPLICATION VALID UNTIL 'infinity' in rds_superuser (RDS User Guide, "Understanding the rds_superuser role"). The master owns postgres, template1 and the instance's database. rds_superuser holds rds_password, rds_replication and the predefined pg_* roles RDS grants it, with ADMIN OPTION, and ADMIN OPTION alone on rds_iam on PostgreSQL 16 and later, so the master can grant rds_iam without becoming an IAM-only member. The rdsadmin database is closed to PUBLIC.

rdsadmin gets a random password on every start, which only the auth proxy uses: an IAM session for a role other than the master is opened as rdsadmin and handed over, since only a superuser can SET SESSION AUTHORIZATION. No client may log in as rdsadmin. The proxy's rds_iam walk skips grants of ADMIN OPTION alone, such as the one PostgreSQL 16 gives the master on each role it creates. Snapshots, restores, exports and database renames run as rdsadmin; a restore applies the RDS roles and ownership again and gives rdsadmin back its password.

A data volume first initialized by an earlier Floci keeps its master as the bootstrap superuser, and a master named rdsadmin stays one. Two tests leaned on a superuser master: the IAM replication test now turns logical replication on through rds.logical_replication in a parameter group instead of ALTER SYSTEM, and the startup-parameters test stores its superuser-only role defaults as rdsadmin and gives app_user its schema with GRANT USAGE.

Closes #5885
2026-11-22 07:31:26 -04:00
Priamo Germosen d63ad7c226 fix(emr-serverless): scope a job run's credentials by its execution IAM policy (#9190)
StartJobRun kept a run's executionIamPolicy only to give it back: its
credentials had every permission of its execution role, and the policy
was stored as sent, members it does not have included.

- A run's inline policy now scopes the session its containers get, as an
  assumed role's session policy does, so with IAM enforcement on "The
  resulting job IAM role permissions will be an intersection of this
  policy and the policy associated with your job execution role". Its
  policyArns are kept and given back but not applied, as Floci's IAM
  applies no managed session policy, an assumed role's included.
- The policy keeps only its two members. An inline policy outside 1 to
  2,048 characters, more than 10 policy ARNs, or one outside 20 to
  2,048 characters is refused with the framework's ValidationException,
  and either member of another JSON type with SerializationException.
2026-11-22 05:02:40 -04:00
Priamo Germosen a1f3379198 fix(emr-serverless): report a Spark job run's total and billed resource utilization (#9187)
GetJobRun gave an ended run no totalResourceUtilization or
billedResourceUtilization, which a cost or usage report reads.

- An ended Spark run gives both, reckoned from the workers it asks for:
  its driver and the executors it starts with, sized as the user
  guide's supported worker configurations size them. A worker has the
  vCPUs its cores ask for, and memory for its Spark memory and its 10%
  overhead, at least 384 MB, rounded up to the sizes its vCPUs allow.
  Unset, a worker has 4 vCPUs, 14G and 20G of disk, and a run starts 3
  executors, as the Spark job properties give them; spark-submit's
  sizing options set over --conf, as Spark takes them. Sizes are read
  as the executors' capacity reads them, which a size too large for a
  long no longer breaks.
- The total covers the time "from the time the job starts to execute,
  until the time the job terminates, rounded up to the nearest second";
  the billed figure includes "a 1-minute minimum usage for workers,
  plus additional storage over 20 GB per worker".
- Its driver's worker counts for the whole attempt. Executors with
  containers of their own count for the time each container ran, as
  they come and go with Spark's target; otherwise the executors it
  starts with count for the whole attempt.
- Each attempt gives its own, and one that never started used nothing.
  A Hive run gives none, its Tez tasks coming and going with its query.
  A Spark run stored before this gets its workers as it ends.
2026-11-22 04:00:01 -04:00
Priamo Germosen 8bc759420f fix(emr-serverless): honour a cancel's grace period, keep flexExecution and check architecture (#9184)
CancelJobRun ignored its shutdownGracePeriodInSeconds and stopped a
run's driver at once, StartJobRun dropped flexExecution, and
CreateApplication and UpdateApplication took any architecture.

- From emr-7.9.0 a RUNNING run in the docker mode gets the grace
  period it is cancelled with, "during which the job can perform
  cleanup operations prior to final termination". Its driver gets
  SIGTERM through an init process, the run is CANCELLING until the
  driver ends, and a driver still running when the period ends is
  stopped. A batch run has none by default and a streaming run 120
  seconds; a run not yet RUNNING, or on an earlier release, is stopped
  at once, and a value other than 0 or 15 to 1800 is refused with
  ValidationException, in Floci's words. Step Functions' cancelJobRun
  passes its ShutdownGracePeriodInSeconds on, read in either case.
- A run keeps its flexExecution's one member, enabled, which GetJobRun,
  ListJobRuns and ListJobRunAttempts give back; an enabled that is not
  a boolean is refused with SerializationException.
- An architecture other than ARM64 or X86_64 is refused with the
  framework's ValidationException, from the one list CloudFormation's
  application provisioner checks too.
2026-11-22 02:57:31 -04:00
Priamo Germosen a9bea6567c fix(emr): give back a cluster's Kerberos realm, OS release, root volume, placement groups and logging settings (#9183)
RunJobFlow dropped the cluster's KerberosAttributes, OSReleaseLabel,
EbsRootVolumeIops, EbsRootVolumeThroughput, PlacementGroupConfigs,
LogEncryptionKmsKeyId, RepoUpgradeOnBoot and MonitoringConfiguration,
so DescribeCluster gave back none of them.

- DescribeCluster gives each back as it was asked for, the placement
  group configs as its PlacementGroups.
- OSReleaseLabel is the one asked for, else the latest Amazon Linux
  release DescribeReleaseLabel lists for the cluster's release, as "If
  no Amazon Linux release was specified, the default Amazon Linux
  release is shown in the response".
- RepoUpgradeOnBoot is SECURITY for a cluster with a custom AMI that
  names none, as "If omitted, the default is SECURITY".
- Of KerberosAttributes only the Realm is kept and given back, never a
  password, and a cluster without them answers an empty structure, as
  AWS does.
- A member the model requires, or a value outside its enum, is refused
  with the framework's ValidationException. So are two placement groups
  for one instance role, and one for the primary nodes of a cluster
  without three of them (three on-demand and no spot for a fleet), in
  the words AWS answers them with.
- As only the primary nodes take a placement group, with SPREAD or NONE,
  another role or strategy is refused, in Floci's words, and a group
  without a strategy gets SPREAD, as the Management Guide says.
- AWS::EMR::Cluster passes these properties to RunJobFlow rather than
  warning that they are not stored.
2026-11-22 01:54:11 -04:00
Priamo Germosen eb6998ed2e fix(iam): answer an assumed-role session's ChangePassword as AWS does (#9181)
ChangePassword answered 400 InvalidUserType to every caller with no
stored user behind the signing key, reading the CLI reference's sentence
for account root credentials. An assumed-role session is not that
caller: recorded against a real account on 2026-10-29, it is answered
NoSuchEntity 404, a code this operation's model declares alongside
InvalidUserType, so the two are not one case and that session was being
given root's error.

The recording is the whole of the change. That session answers the
missing key, with the message this package already gives wherever a
signing key resolves to no user, which keeps one situation to one
wording rather than minting a second. Every other caller keeps
InvalidUserType: a session AssumeRoot minted acts as the account root,
which is what that error is published for however root signs, and what
AWS answers the remaining session kinds is not recorded.
2026-11-22 01:32:18 -04:00
Priamo Germosen 11b66161cd feat(dynamodb): opt-in TransactionConflict emulation for contending transactions (#9179)
With floci.services.dynamodb.transaction-conflicts-enabled on, a
TransactWriteItems keeps its items busy from the moment its conditions
hold until 10 ms after it commits, and answers when that time is up.
While an item is busy, a PutItem, UpdateItem, DeleteItem or single-item
PartiQL write on it fails with TransactionConflictException, and another
TransactWriteItems or a TransactGetItems that reaches it is cancelled
with the reason TransactionConflict, as the developer guide describes.
GetItem, Query, Scan and BatchWriteItem are unaffected, and a
transaction that is cancelled holds nothing.

The busy mark is a deadline kept beside the item, so no item lock is
held during the wait. Off, the default, transactions keep serializing on
their item locks as before. The switch is refused at startup on the
local backend.

Closes #4523
2026-11-22 01:03:17 -04:00
Priamo Germosen 0171af4bce fix(emr): give back the subnets, zones, instance profile and security groups a cluster asked for (#9180)
DescribeCluster's Ec2InstanceAttributes kept only the key name, subnet,
zone and managed security groups. The JobFlowRole, the instance fleets'
Ec2SubnetIds and Placement.AvailabilityZones, and the additional master
and slave security groups that RunJobFlow took were dropped, so a client
reading the cluster back, as Terraform's aws_emr_cluster does, saw none
of them.

- IamInstanceProfile is the JobFlowRole, "The IAM role that was
  specified when the cluster was launched".
- RequestedEc2SubnetIds and RequestedEc2AvailabilityZones are the ones
  requested, an empty list when none was, as AWS gives them. The subnet
  is the one Ec2SubnetId names, else the first of Ec2SubnetIds, and the
  zone the one Placement names, else the first of its AvailabilityZones.
- A request naming both subnets and zones is refused with
  ValidationException, as "RequestedEc2SubnetIDs and
  RequestedEc2AvailabilityZones cannot be specified together".
- AdditionalMasterSecurityGroups and AdditionalSlaveSecurityGroups are
  the ones given, and a list member of another JSON type is refused
  with SerializationException.
- AWS::EMR::Cluster no longer warns that Instances' Ec2SubnetIds and
  additional security groups are not stored.
2026-11-22 00:48:38 -04:00
Priamo Germosen 5b4bc0e44e feat(iam): read Bedrock from the generated tables, its routes vendored (#9169)
Bedrock leaves ResourceArnBuilder's own branch and the registry's three resource-policy rules: its
requests are matched on their botocore routes and checked on the resources the request-resources table
reads. regen_rest_routes.py vendors the bedrock, bedrock-agent and bedrock-runtime models, all signed
for the bedrock scope; bedrock-agent's are needed because its PutResourcePolicy carries resourceArn in
its path where bedrock's carries it in its body, a member the two clients locate apart.
regen_iam_request_resources.py reads bedrock instead of leaving it to the builder, so a guardrail
request is checked on the guardrail its path names and a resource-policy request on the ARN it carries.
The generator's reader of an ARN pattern's type words also reads one whose account is optional, so the
tag actions are checked on the guardrail or application inference profile ARN they carry, and
regen_iam_tag_on_create.py reads bedrock, so a create carrying tags also needs bedrock:TagResource.

BedrockStoredResourceArns gives IAM the tags Bedrock holds on a guardrail or an application inference
profile, for aws:ResourceTag, read in place and matched on the whole ARN; a guardrail's untag now
replaces its tag map rather than editing it, so a reader never sees half of one, and both models keep
their tags volatile.
2026-11-22 00:01:33 -04:00
Priamo Germosen cff222a6f1 fix(emr): keep instance fleets' launch and resize specifications, and modify their configs (#9168)
An instance fleet dropped the LaunchSpecifications, ResizeSpecifications
and Context that RunJobFlow and AddInstanceFleet gave it, and
ModifyInstanceFleet changed its target capacities alone, ignoring the
ResizeSpecifications, InstanceTypeConfigs and Context it took.

- A fleet keeps its LaunchSpecifications, ResizeSpecifications and
  Context, and ListInstanceFleets gives them back.
- ModifyInstanceFleet changes the ResizeSpecifications, InstanceTypeConfigs
  and Context it gives. The configs replace the fleet's own, as the
  Management Guide warns that "Not including fields can result in
  overwriting specifications you declared at launch", and must name
  every instance type the fleet has, as "You must include all instance
  types that are part of your instance fleet in the modify request". A
  request that leaves one out is refused with InvalidRequestException.
  Its configs are checked as AddInstanceFleet checks them, and on both
  calls specifications that are not an object, or a Context that is not
  a string, are refused with SerializationException.
- AWS::EMR::Cluster no longer warns that a fleet's launch and resize
  specifications are not stored, and AWS::EMR::InstanceFleetConfig now
  applies a change to InstanceTypeConfigs or ResizeSpecifications in
  place rather than warning. A rollback puts them back, but not an
  instance type the update added, which every later request must
  include, nor resize specifications where the fleet had none, which no
  request can clear. The update is checked as ModifyInstanceFleet checks
  its request, before anything changes, and dropped configs or resize
  specifications are kept.
2026-11-21 20:29:04 -04:00
Priamo Germosen 26eb1e9264 refactor(iam): check a scoped presigned URL on the resources its request names (#9167)
A generated presigned URL's credential is scoped to one object and action, and the filter compared
that scope with an S3 request's object read again from the wire path, a branch of its own. Since
#9155 the request's resources already name that object as S3 reads its key, the slashes it was sent
with kept (RequestPathLabels), so the filter compares the scope with them, as for any request, and
the S3 branch goes.
2026-11-21 20:07:09 -04:00
Priamo Germosen 1c47f1b4ce fix(iam): name one broken password rule the way AWS names it (#9166)
Every write that stores a password composed one sentence listing every
rule the password broke, "Password does not conform to the account
password policy. It must contain: ...", which AWS writes nowhere. AWS
answers one fixed sentence naming one rule, and two of the five are
recorded against a real account on CreateLoginProfile, both 400
PasswordPolicyViolation with a sender fault and neither ending in a
period: 'Password should have a minimum length of 24', the policy's own
minimum substituted, and 'Password should have at least one symbol',
where this package enumerated a symbol set AWS does not put in the
message.

The three character classes left carry no recording and take the same
shape, as does the order a refusal picks a rule in, no recording covering
a password that breaks more than one: the length first, then the
character classes in the order the policy declares them.

The reuse window keeps a sentence of its own. AWS publishes no wording
for a reused password and nothing records one, so that one site is left
as it was and the page says why.
2026-11-21 20:06:39 -04:00
Priamo GermosenandChuck Swanberg 543a236747 feat(cloudformation): provision Verified Permissions policy stores, templates and policies (#9162)
A template declaring AWS::VerifiedPermissions::PolicyStore, PolicyTemplate or Policy failed its stack
as unsupported, although Floci serves the API behind them. VerifiedPermissionsCfnProvisioner now
provisions the three over VerifiedPermissionsService.

A policy store answers Ref with its id and sets Arn, PolicyStoreId and EncryptionState; its schema is
put once the store stands, and deletion protection is turned on only after that, so a store whose
schema the Cedar sidecar refuses is still removed. A template answers Ref with
PolicyStoreId|PolicyTemplateId and a policy with its id alone, as the Template Reference documents
each; a policy's store is found from its id, and Cloud Control names a policy
PolicyId|PolicyStoreId. PolicyStoreId is create-only on both, and a template or a policy is replaced
in the new store when the engine says the update replaces it. A schema, Description,
DeletionProtection or Name the template drops is cleared, what the stack never declared is left as
the service has it, and a create leaves out an optional field the template does not give. An update
of a stack from before this provisioner, which holds the dispatcher's stub, creates the entity.

An in-place change of a store, a template or a static policy is snapshotted first, so a step that
fails is undone and a later resource failing the update puts it back. A store's settings are
written before its schema, its tags are reconciled only over the keys the stack owns, and a change
of its EncryptionSettings is refused, since Verified Permissions sets encryption at create. Cloud
Control's model names a store by PolicyStoreId and a template by PolicyTemplateId.

Co-authored-by: Chuck Swanberg <cswanberg@mad-swan.com>
2026-11-21 19:47:19 -04:00
Priamo Germosen ce7f1ab185 refactor(iam): match S3 requests on the routed path, as every scope is (#9164)
The registry matched an S3 request's route on the path as sent and every other scope's on the path
the router dispatched on. S3 needs no exception: S3SlashOnlyKeyFilter rewrites a key of slashes alone
escaped (PUT /bucket// is /bucket/%2F), which the routed path keeps as the filter wrote it, and the
object a request names comes from S3's own reading of its key (RequestPathLabels), which keeps the
slashes it was sent with. The routed path is also the one the router dispatched on, so a path it
normalizes, such as /bucket/.., is checked as the operation that runs. A new integration test checks
a key of slashes alone under IAM enforcement.
2026-11-21 19:33:19 -04:00
Priamo Germosen 5a912d5263 fix(emr): keep instance groups' volumes, AMI and shrink policy, and list instances' volumes and public address (#9163)
An instance group dropped the EbsConfiguration and CustomAmiId that
RunJobFlow and AddInstanceGroups gave it, and ModifyInstanceGroups its
ShrinkPolicy, and ListInstances gave no instance an EbsVolumes or a
PublicIpAddress.

- A group keeps its EbsConfiguration and CustomAmiId, and
  ListInstanceGroups gives them back as its EbsBlockDevices, one per
  volume named /dev/sdb on as a fleet's are, its EbsOptimized and its
  CustomAmiId, under the same limit of 25 volumes per instance.
- ModifyInstanceGroups keeps a group's ShrinkPolicy, which
  ListInstanceGroups gives back, and a shrink it comes with follows its
  InstanceResizePolicy: the instances it names to terminate end first,
  then the group's last instances, passing the protected ones. They end
  as EC2InstanceIdsToTerminate ends them, so their ids are not taken
  again, and a later entry for the same group counts from what an
  earlier one leaves. An id to terminate that is not a running instance
  of the group is refused, as EC2InstanceIdsToTerminate refuses it, and
  so is a shrink the protected instances leave short.
- ListInstances gives each instance the PublicIpAddress its
  PublicDnsName names, in 203.0.113.0/24 for a cluster's first 254
  instances and in 100.64.0.0/10 past them, and an EbsVolumes entry for
  each device its group or instance type config gives it, with volume
  ids that differ between clusters. A group's instances' EC2
  descriptions give its CustomAmiId as their image.
- AWS::EMR::Cluster no longer warns that a group's EbsConfiguration and
  CustomAmiId are not stored.
2026-11-21 19:32:36 -04:00
Priamo Germosen 6fe1da3219 fix(iam): word the account property key refusal as AWS does (#9161)
A key that satisfies the published shape and is not Namespace/PropertyName
answers 'Property key must be in format Namespace/PropertyName: <key>',
recorded for a key carrying no separator, with the key as the request sent
it. This package described the rule in a sentence of its own instead.

The rule itself is unchanged, and the layer AWS applies after it is left
out on purpose rather than guessed: an unrecognised namespace is refused
there, and building that check needs the set of namespaces AWS recognises,
which the recordings do not give. The IAM page says so.
2026-11-21 19:25:01 -04:00
Priamo Germosen 1cad7b2b62 refactor(iam): drop the hand-routed scopes from the vendored routes (#9160)
S3 was the one credential scope rest-routes.json listed as hand-routed, authorized by the registry's
rules alone, and #9155 moved it onto its generated routes. The list is empty, so its machinery goes:
regen_rest_routes.py no longer writes handRouted or a hand-routed scope's required members,
IamRestRoutes reads every model, regen_iam_authorized_actions.py takes every model's scope as routed,
and the coverage test builds requests from what a route requires alone.
2026-11-21 18:44:12 -04:00
Priamo Germosen 5db8d098e7 feat(cloudformation): provision EMR steps, instance groups and instance fleets (#9159)
A template can now create AWS::EMR::Step, AWS::EMR::InstanceGroupConfig
and AWS::EMR::InstanceFleetConfig. None was served, so the stack
reported CREATE_COMPLETE with nothing behind it. EmrCfnProvisioner adds
them through AddJobFlowSteps, AddInstanceGroups and AddInstanceFleet,
reading each as those calls read their requests, from methods EmrHandler
now shares, and against the registry schemas, now in the vendored
property types.

- A step's Ref and Id are its id, and its LogUri and EncryptionKeyArn
  are its StepMonitoringConfiguration. Every property is create-only,
  so a change adds a new step, and a step stays in its cluster's
  history when deleted, as the schema's delete handler calls nothing.
- An instance group's Ref and InstanceGroupId are its id. Its
  InstanceCount and AutoScalingPolicy change in place, and the delete
  removes its policy and shrinks it to nothing, as a group cannot be
  removed from its cluster.
- An instance fleet's Ref and InstanceFleetId are its id. Its target
  capacities change in place through ModifyInstanceFleet, and a change
  to InstanceTypeConfigs or ResizeSpecifications is accepted with a
  warning and not applied, as Floci's ModifyInstanceFleet changes the
  capacities alone. The delete shrinks it to nothing.
- A create-only change adds a new group or fleet; a later resource's
  failure, or a failure of the update itself, puts back what it had
  changed; and a group or fleet whose cluster has ended is left alone.

A group's role and a fleet's type must be TASK, the one value the
template reference allows, and a delete shrinks one once its cluster
is running or waiting, waiting for one still starting, and removes a
policy the group has.
2026-11-21 18:36:49 -04:00
Priamo Germosen 1bcd7620bb fix(sts): answer a disabled federation feature with AWS's sentence (#9158)
GetWebIdentityToken answered the error shape's own @documentation prose,
which the model carries to describe the error rather than to be sent as
one: the model states this refusal's code and status and not its message,
so documentation was what the wording fell back to. AWS answers
'OutboundWebIdentityFederation is disabled.', wholly fixed text.
2026-11-21 18:11:03 -04:00
Priamo Germosen 4735606fb9 feat(iam): read S3 and S3 Control from the generated tables (#9155)
S3 leaves the registry's hand rules and ResourceArnBuilder's S3 branch: its requests are matched
on their botocore routes, checked as the actions the authorized-actions file gives them, on the
resources the request-resources table reads. regen_rest_routes.py no longer lists s3 as hand-routed,
and regen_iam_request_resources.py reads s3 instead of leaving it to the builder; the tables gain
S3's and S3 Control's 195 operations and nothing else changes. Operations sharing a route are told
apart by the query parameters and headers botocore requires, an S3 Control request by its route's
model, which also picks S3 Control's error envelope (isS3ControlRequest), and a member the two
clients locate apart is read for the client whose route the request matched.

An object key is read as S3 reads it, keeping the slashes it was sent with, through
RequestPathLabels, a per-namespace hook S3 implements with S3ObjectKeys. DeleteObjects names its
keys in its XML body, so it takes s3:DeleteObject's types from the S3 user guide's Either row and is
unread: the filter leaves it to S3, which checks each key.

The registry's S3 rules, S3 Control rules and sub-resource overrides are deleted, with the tests of
Floci's own handler order, the regional S3 Control ARN form, and a version for HEAD, HEAD
?annotation and Select, none of which an AWS source gives.

S3 also runs only what botocore routes, so what runs is what is checked: a request naming annotationName
is GetObjectAnnotation and a HEAD naming one HeadObject, SelectObjectContent runs on
?select&select-type=2 and reads the current version, the S3 Control tagging handler decodes its ARN
once, and a request two operations' routes take alike is refused under enforcement.
2026-11-21 17:44:36 -04:00
Priamo Germosen 546770ab69 feat(cloudformation): provision AWS::EMR::Cluster (#9156)
A template can now create an EMR cluster. It was not served, so the
stack reported CREATE_COMPLETE with nothing behind it. EmrCfnProvisioner
creates it through RunJobFlow, reading the template as RunJobFlow reads
its request, from a method EmrHandler now shares.

- The properties are read as model validation reads them, against the
  registry schema, now in the vendored property types, and a template
  that sets the read-only Id or MasterPublicDNS is refused.
- Ref is the cluster id; Fn::GetAtt gives Id and MasterPublicDNS.
- The master, core and task groups or fleets become RunJobFlow's
  InstanceGroups or InstanceFleets with their roles, a configuration's
  ConfigurationProperties its Properties, and a step's StepProperties
  its Properties. The create completes once the cluster is waiting or
  running, and a cluster that terminates first fails it and is
  terminated again, its termination protection cleared first.
- The properties, and members of Instances, its groups and its fleets,
  that Floci's RunJobFlow keeps nothing of are accepted with a warning,
  and recorded as ignored. Task groups and fleets need unique names, as
  the reference says, and a cluster that ran its steps and ended came
  up, so its create completes.
- An update applies in place what the reference and the update handler
  let change: AutoTerminationPolicy, ManagedScalingPolicy,
  StepConcurrencyLevel, VisibleToAllUsers, TerminationProtected,
  UnhealthyNodeReplacement, a core or task group's InstanceCount and
  AutoScalingPolicy, a core or task fleet's target capacities, and the
  tag keys the stack owns. They are compared with the values the stack
  last applied, resolved, so one a parameter changes counts. Any other
  change, within Instances included, replaces the cluster: the master
  group's count and the master fleet's capacities among them, which
  the API refuses to change.
- A later resource's failure, or a failure of the update itself, puts
  back what it had applied. A terminated cluster fails an update, and a
  termination-protected one refuses the delete, as TerminateJobFlows
  does.
2026-11-21 17:31:03 -04:00
Priamo Germosen 37bf8f90d2 fix(iam): hold a policy document to three rules AWS applies (#9153)
No write here read any of them. An identity policy carrying a Principal
was stored, where AWS answers 'Policy document should not specify a
principal.'; a trust policy naming no principal was stored, leaving a role
assumable by nobody with no signal, where AWS answers 'Missing required
field Principal'; and a trust policy granting another service's actions
was stored, where AWS answers 'AssumeRole policy may only specify STS
AssumeRole actions.' All three are 400 MalformedPolicyDocument and all
three are read before the document is stored.

Neither rule about principals reads NotPrincipal as one, the IAM reference
saying neither policy may carry that element at all, and the trust rule
asks that a principal is named rather than that the element is present: a
null or an empty Principal names nobody, which is what the evaluator makes
of it too. The action rule stays narrower than AWS's may be, so that it
cannot refuse a document AWS accepts: it is read on the namespace, case
insensitively as AWS reads any action, and on Action alone, so every sts:
spelling passes and a statement excluding actions grants the assume actions
among the rest. Three existing fixtures used a trust policy naming no
principal and now use the shared one that does.
2026-11-21 16:53:54 -04:00
Priamo Germosen 1fe555fbc2 feat(cloudformation): provision EMR security configurations, Studios and session mappings (#9152)
A template can now create AWS::EMR::SecurityConfiguration,
AWS::EMR::Studio and AWS::EMR::StudioSessionMapping. None was served,
so the stack reported CREATE_COMPLETE with nothing behind it. They go
through the services the EMR API uses, and the properties are read as
model validation reads them, against the registry schemas, now in the
vendored property types.

- A security configuration's Ref is its name, generated when the
  template gives none; its JSON is taken as an object or its text. Both
  properties are create-only, so a change replaces it, and one that
  keeps a template's own name is refused, as for every custom-named
  resource.
- A Studio's Ref is its id; Fn::GetAtt gives StudioId, Arn and Url, and
  a template that sets one of them is refused. UpdateStudio applies the
  Name, Description, SubnetIds and DefaultS3Location the template
  changes, and the tags change for the keys the stack owns. A change to
  IdpAuthUrl or IdpRelayStateParameterName is accepted with a warning
  and not applied, as no Studio API changes them, and a create-only
  change replaces the Studio.
- A session mapping's Ref is StudioId|IdentityType|IdentityName, its
  primary identifier; SessionPolicyArn updates in place, and another
  identity replaces it.
- A later resource's failure, or a failure of the update itself, puts
  back what the update changed, but a Studio's added subnets, which
  UpdateStudio cannot take away. A gone resource fails an update and
  counts as deleted.

Two shared fixes go with them. Model validation now looks for a schema
pattern in a value, as the validator CloudFormation runs does, instead
of matching the whole value, so a Studio named with spaces passes. And
CreateSecurityConfiguration, from the API or a stack, refuses a
configuration that is no JSON object, which a cluster naming it could
not read.
2026-11-21 16:34:12 -04:00
Priamo Germosen 1a107f8f46 feat(iam): read members clients locate apart, S3's key shape and unread bodies (#9151)
Four rules of the request-resources generator that S3 needs to be read from the table, which leave the
table as it is while S3 is still built by hand.

A member the clients of an operation carry in different places, a body the reader reads among them, is
recorded under each client locating it (locatedApart: S3's CreateBucket carries its Bucket as {Bucket},
S3 Control's as {name}), and the reader takes the members of the client whose vendored route the request
matched; a split by a client with no vendored routes is refused. A member whose botocore shape is named
as the type and Key fills the type's name (S3's Key, an ObjectKey, the object's ${ObjectName}). A type
named exactly as what an operation makes rules out one only ending with that name (PutObject makes an
object, not an accesspointobject). An operation of a REST-XML model naming what it acts on in its body
by such a key shape, which the reader does not read, is recorded unread (DeleteObjects'
Delete.Objects[].Key), and RequestResources.reads, of and ofBody leave it to its service.
2026-11-21 15:37:05 -04:00
Priamo Germosen 5b9e842cd9 feat(cloudformation): provision AWS::EMRContainers::VirtualCluster (#9150)
A template can now create an EMR on EKS virtual cluster. It was not
served, so the stack reported CREATE_COMPLETE with nothing behind it.
The provisioner goes through the service the EMR on EKS API uses, and
does what AWS's own resource handler does:

- The properties are read as the handler's model validation reads them,
  against the registry schema, now in the vendored property types, and
  a template that sets the read-only Arn or Id is refused in the
  handler's words.
- Ref is the virtual cluster id; Fn::GetAtt gives Id and Arn.
- A create sends Name, ContainerProvider, SecurityConfigurationId,
  SessionEnabled and the tags to CreateVirtualCluster.
- Every property but the tags is create-only: a change replaces the
  virtual cluster, and the old one is terminated once the update
  commits.
- A tag change drives the tags to the template's, removing any other
  but an aws: one; a later resource's failure, or a failure of the
  change itself, puts them back.
- An update of a virtual cluster that is terminated or gone fails as
  the handler's does, and the delete of one is taken as done.
2026-11-21 15:03:44 -04:00
Priamo Germosen 84cea7714a feat(iam): read S3's actions from its user guide, by model and by version (#9147)
Where the Service Reference gives an S3 operation no one answer, S3's user guide does.
tools/aws/fetch_s3_required_actions.py copies its "Required permissions for Amazon S3 API operations"
rows unchanged into tools/aws/sources/s3-required-actions.json, and the authorized-actions generator
reads them: an operation's one required action (ListObjectsV2 is s3:ListBucket, CopyObject
s3:PutObject), the action for one model's requests of an operation S3 and S3 Control both have
(authorizedByModel: S3 Control's account-level GetPublicAccessBlock is s3:GetAccountPublicAccessBlock),
and an Either row's choice by versionId where botocore gives it in the query (versioned). Measured
entries quote the Service Authorization Reference for the account-level GetPublicAccessBlock the page
mislabels and the version annotation actions it omits. The one answer the reference gives an operation
several clients list goes to the namesake client (S3's GetBucketLifecycleConfiguration is
s3:GetLifecycleConfiguration), and the file records the reference's spelling of an action named as its
operation in another case (MemoryDB's CreateACL is memorydb:CreateAcl).

IamAuthorizedActions reads the new sections and gives an action for a route's model and query, which
IamActionRegistry uses wherever it reads a route's action. S3 stays hand-routed, so its rules still
decide its requests; only the spellings show, in the action an AccessDenied message names. A hand-routed
scope's routes list what their requests must carry, for the coverage test, which now also checks each
model-specific action against that model's routes.
2026-11-21 14:13:43 -04:00
Priamo Germosen 858bf8d2db feat(cloudformation): provision AWS::EMRServerless::Application (#9148)
A template can now create an EMR Serverless application. It was not
served, so the stack reported CREATE_COMPLETE with nothing behind it.
The provisioner goes through the services the EMR Serverless API uses,
so a stack and a direct call see the same application, and it does what
AWS's own resource handler does:

- The properties are read as the handler's model validation reads them,
  against the registry schema, now in the vendored property types; an
  Architecture outside its enum and a read-only ApplicationId or Arn
  are refused.
- Ref is the application id; Fn::GetAtt gives ApplicationId and Arn.
- A create sends every property to CreateApplication, the Key/Value
  lists of InitialCapacity and LogTypeMap as the API's maps.
- An update sends UpdateApplication the settings the template changed
  and drives the tags to the template's, removing any other. A dropped
  setting stays as it is, but for InitialCapacity, which the handler
  sends as an empty map, and so clears.
- Name and Type are create-only: a change replaces the application, and
  the old one is deleted once the update commits.
- A later resource's failure puts back the settings and tags the update
  changed; a failure of the update itself puts back what it had changed
  by then, nothing when UpdateApplication refused it, and a restore that
  fails keeps its snapshot for ContinueUpdateRollback.
- Neither an update nor a delete stops a STARTED application, so one
  the API refuses fails the resource, as on AWS.

The vendored create-only properties and schema surface also take AWS's
new AWS::CertificateManager::Certificate properties, RootHierarchyType
and CertificateUsage, which their drift checks on this change asked
for; the ACM provisioner accepts and ignores both.
2026-11-21 13:59:46 -04:00
Priamo Germosen 26c090d4d1 chore(iam): regenerate the IAM tables for what AWS has since changed (#9149)
The vendored-data check against AWS's Service Reference fails on main: the reference no longer lists
glue:DeleteAssetType and glue:PutAssetType, gives QuickSight's tagging actions the knowledgeBase type and
SearchKnowledgeBases none, has kinesisanalytics:CreateSnapshot, lambda:CreateRuntime and
sagemaker:CreateClusterExtension take the request's tags, and adds Identity Center condition keys to IAM's
SAML and OpenID Connect provider actions. Each table is regenerated by its own generator, unchanged:
request resources (QuickSight, Route 53 and Textract operations added, the two Glue actions dropped), tag
on create, IAM condition keys, the service namespaces (7 added), IAM's action resources (3 actions) and the
actions without resource types (5).

The passed-roles table stays as it is. The reference lists iam:PassRole on EventBridge's new
CreateEventSource and UpdateEventSource, whose requests in botocore's eventbridgev2 model name no role, so
the generator stops; the verify reports that table incomplete, not wrong.
2026-11-21 13:41:15 -04:00
Priamo Germosen 2e00917c69 feat(iam): tell apart the operations of a REST route by what botocore requires (#9143)
Thirteen of botocore's S3 routes name more than one operation (PUT /{Bucket}/{Key+} is PutObject,
CopyObject, UploadPart or UploadPartCopy), which is why S3 is hand-routed. The route generator now gives
each operation of a shared route the query parameters and headers of the members its input requires, and
marks a deprecated one. An operation botocore's endpoint rules sign for another service on every request
is left out of the scope's routes and listed under signedElsewhere: S3's ListDirectoryBuckets
(s3express) and WriteGetObjectResponse (s3-object-lambda). The check that a route's operations leave
every request one operation now covers the hand-routed scopes too: no two current ones may require the
same, and what any two require together must be what one of them requires. It passes for S3.

IamRestRoutes matches a route only for a request carrying all its operation requires, headers in any
case, ranks a route requiring all another requires and more above it and a current operation above a
deprecated one, and gives a match its model. IamActionRegistry passes the request's headers wherever it
matches a route. S3 stays hand-routed and no route outside it is shared, so no request is authorized
differently.
2026-11-21 11:45:16 -04:00
Priamo Germosen 4595e8d1ef fix(emr): terminate the instances ModifyInstanceGroups' EC2InstanceIdsToTerminate names (#9142)
ModifyInstanceGroups ignored EC2InstanceIdsToTerminate, "The Amazon EC2
InstanceIds to terminate. After you terminate the instances, the
instance group will not return to its original requested size." Floci's
instances had no identity of their own: their ids and addresses
followed their place in their group, so a group could only shrink from
its end.

Each instance group now keeps the ordinals of the instances those ids
ended, and its instances take the first ordinals that are not among
them. The named instances leave ListInstances and, in the docker runner
mode, take their core or task node with them, HDFS moving its blocks
first, as nodes are named by group and ordinal. The group's requested
and running counts go down by as many. Its other instances keep their
ids, addresses and nodes, as do the cluster's other groups', and an
instance the group gets later takes a new ordinal, not an ended one's.
An InstanceCount beside them is the group's size after that.

An id that is not one of the group's instances is refused with
ValidationException, as ModifyInstanceGroups' other refusals are
recorded, and a MASTER group's with the refusal its count gets; AWS's
wording for these is not documented, so it is Floci's.
2026-11-21 11:45:08 -04:00
Priamo Germosen 8a0112d9c5 fix(emr): honour CancelSteps' StepCancellationOption, SIGTERM by default (#9139)
CancelSteps took no StepCancellationOption: a cancelled RUNNING step's
container was killed at once, which is TERMINATE_PROCESS. The
Management Guide's "Cancel steps" makes SEND_INTERRUPT the default:
"EMR sends a SIGTERM signal to the step", which may catch it "to
terminate descendant step processes or wait for them to complete";
with TERMINATE_PROCESS "EMR sends a SIGKILL signal to the step and all
its descendant processes which terminates them immediately".

With SEND_INTERRUPT the step's container now gets SIGTERM and the step
stays CANCEL_PENDING until its command ends on its own, CANCELLED then,
without its ActionOnFailure. A step's container runs under an init
process, as Docker's --init runs one, so that the signal reaches its
command: a container's first process ignores SIGTERM unless it handles
it. A step whose container is not running yet has nothing to
interrupt, and is stopped as before. TERMINATE_PROCESS kills it at
once, as every cancel did, with SIGKILL alone, as Docker's own stop
would send SIGTERM first and the init would pass it on; it also kills
a step a SEND_INTERRUPT cancel left running, and a cluster's end kills
such a step too. An option that is neither gets the framework's enum
message.

A CancelSteps request takes at most 100 steps from release 7.14.0, and
256 before it, as "With Amazon EMR releases 7.14.0 and later, the
maximum number of steps you can cancel per request is 100".
2026-11-21 10:40:56 -04:00
Priamo Germosen 7ae2339100 fix(emr): apply MERGE reconfigurations, step log locations, the scaling index and ServerUrl (#9129)
Four members EMR accepted and ignored now act as AWS documents them.

ModifyInstanceGroups' ReconfigurationType MERGE merges the group's new
Configurations into its own, as the Release Guide's "Reconfigure an
instance group in a running cluster" has it: "This option only adds or
modifies the new configurations that you submit. It preserves existing
configurations." A classification it names takes its properties over
the group's, nested configurations merged the same way, and the others
stay; OVERWRITE, the default, still replaces them. MERGE is "supported
for Amazon EMR releases 5.35.0 and 6.6.0 and later", so an earlier
release refuses it with ValidationException, in Floci's wording, and a
type that is neither gets the framework's enum message.

A step's StepMonitoringConfiguration sends its logs, and its
applications' container logs, to its own LogUri from release 7.11, as
its options "take precedence over any cluster-wide logging settings",
still only on a cluster with a LogUri. The guide gives no layout under
the step's destination, so it is the cluster's. A node removed while
such steps run puts its containers' logs there when they share one.
DescribeStep and ListSteps give the step's LogUri and EncryptionKeyArn
back.

A managed scaling policy's UtilizationPerformanceIndex is one of 1, 25,
50, 75 and 100: "If you set the index to values other than these, it
results in a validation error." One outside the model's 1 to 100 gets
the framework's ValidationException, another Floci's wording.

A session whose Spark Connect server answers reports ServerUrl, Floci's
own address in Spark Connect's sc:// form, where a call still needs
GetSessionEndpoint's token to reach the server; an ended session has
none.
2026-11-21 09:11:48 -04:00
Priamo Germosen a87e8e47e0 fix(emr-serverless): queue job runs beyond an application's maxConcurrentRuns (#9124)
An application's schedulerConfiguration was stored and echoed, and no
run was ever QUEUED: every run started at once. The user guide's "Job
concurrency and queuing for an EMR Serverless application" has only
maxConcurrentRuns runs going at a time, "Remaining jobs are queued
until one of the running jobs terminates. If queue timeout is reached
earlier, your job times out."

A run beyond the limit is now QUEUED, in either runner mode, and the
first queued run starts the moment a running one ends or is cancelled.
A run still queued after queueTimeoutMinutes is CANCELLED, as the job
run states give a run that "has timed out" as a reason to be cancelled;
its stateDetails is Floci's wording. A run that leaves the queue
reports queuedDurationMilliseconds. A queued run is cancelled at once,
and keeps StopApplication from stopping the application. In the docker
runner mode a queued run's container starts only once it leaves the
queue.

Queuing is "supported on Amazon EMR release 7.0.0 and higher" and
"enabled by default on Amazon EMR release 7.3.0 and higher", the AWS
runtime for Apache Spark's releases included; an application on 7.3.0
or later that sets no limits runs with the defaults, 15 runs and 360
minutes. Terraform's acceptance tests, run against AWS, recorded how
the configuration is kept: a member a request leaves out takes its
default, and here keeps the value already set where there is one; an
empty one turns queuing off, and the application then has none.
maxConcurrentRuns outside 1 to 1000 and queueTimeoutMinutes outside 15
to 720 are refused with ValidationException. A STARTED application
takes a new maxConcurrentRuns, as "You can update maxConcurrentRuns for
an application in the STARTED state", and a higher one starts queued
runs at once; any other scheduler change still needs it stopped.
2026-11-20 22:43:18 -04:00
Priamo Germosen 334f7ad6e6 chore(cloudformation): resync the schema surface and create-only properties with AWS (#9123)
AWS has changed resource schemas since the last sync, so the online drift check fails on every pull
request that touches these files. `make cfn-schema-surface-sync` and `make cfn-create-only-sync`
bring them back in line:

- New writable properties: `JwtConfiguration` on `AWS::ApiGateway::Authorizer`, `HooksConfiguration`
  and `ResourceConfigurations` on `AWS::BedrockAgentCore::Runtime` and `AZAffinity` on `AWS::Route53::RecordSet`. None of their
  services models them, so each gets a row in `writable-property-gaps.tsv`, and the AgentCore
  runtime's two are warned about by name like its other unstored properties.
- Create-only: `AWS::Route53::HealthCheck` adds `HealthCheckConfig/EndpointType`, and
  `AWS::S3Vectors::Index` narrows `MetadataConfiguration` to
  `MetadataConfiguration/NonFilterableMetadataKeys`, the only member Floci reads, so replacement is
  unchanged there.
2026-11-20 21:41:54 -04:00
Priamo Germosen cb5b25821b fix(emr-containers): enforce a virtual cluster's concurrent job limits (#9120)
A virtual cluster's schedulerConfiguration was stored and its
schedulerStatus reported, but StartJobRun ignored the limits: every run
started at once and no submission was refused. The development guide's
"Concurrent job limits for virtual clusters" has them "enforced at
StartJobRun, before any pods are created".

At most maxConcurrentJobRuns runs are RUNNING at once, 1000 when it is
not set, the guide's default. A run beyond that waits PENDING in the
queue, and when a running slot frees up, the run first in the queue
starts: "As running slots free up, queued job runs start
automatically." Once maxInQueueJobRuns runs wait, StartJobRun refuses
another with ValidationException, as the guide and the model say;
neither gives its message, so the wording is Floci's. A run still
queued 30 minutes after it was submitted is FAILED, as "buffered jobs
fail after 30 minutes if no slot frees up".

A higher or cleared limit, or a cancelled run, starts queued runs at
once. The runs are replayed in the order things happened, so a run
leaving the queue starts the moment the slot it takes frees up, and
schedulerStatus counts the queued runs.
2026-11-20 21:40:37 -04:00
Priamo Germosen ff997036a6 fix(iam): check EC2 Instance Connect requests on the instance they name (#9115)
The request resources generator did not read ec2-instance-connect yet,
so SendSSHPublicKey and SendSerialConsoleSSHPublicKey were checked on *,
and a grant or a deny on an instance's ARN never applied to them. The
namespace moves from NOT_COVERED to NAMESPACES and the table gives both
operations the instance their InstanceId names,
arn:${Partition}:ec2:${Region}:${Account}:instance/${InstanceId}, the
ARN EC2 gives its instances, as botocore and the Service Reference give
them. A full regeneration changes nothing else.
2026-11-20 18:44:38 -04:00
Priamo Germosen 89e0242167 fix(emr): list every emr-7.x and emr-spark release, as AWS names and orders them (#9114)
ListReleaseLabels, DescribeReleaseLabel and ListSupportedInstanceTypes
knew five releases, the newest emr-7.5.0, so they refused emr-7.13.0
and the emr-spark-8.x releases Floci runs clusters on. The catalogue
now holds every emr-7.x release, emr-7.0.0 to emr-7.14.0, and the AWS
runtime for Apache Spark's emr-spark-8.0.0, 8.1.0 and 8.2.0, beside
emr-6.15.0, emr-6.14.0 and emr-5.36.2. Each release's applications,
versions and Amazon Linux releases come from its Release Guide page,
as before; the emr-7.14.0, emr-spark-8.1.0 and emr-spark-8.2.0 pages
list no Amazon Linux release, so those report none.

Application names are spelled as AWS answers them, Spark, HBase,
ZooKeeper and JupyterHub, where they were lowercased; each page lists
them that way too, with Trino for "Trino (PrestoSQL)". The Application
filter of ListReleaseLabels still matches without regard to case.

ListReleaseLabels lists the numbered releases newest first, and the
emr-spark ones after them oldest first, the order AWS answered for
that family. DescribeReleaseLabel without a label describes the first
release listed, now emr-7.14.0.

An unknown release label gets AWS's recorded answers, which differ by
operation: DescribeReleaseLabel "The release label isn't valid." with
ErrorCode InvalidInputParameter, and ListSupportedInstanceTypes "The
supplied release label is invalid: <label>." with ErrorCode
INVALID_RELEASE_LABEL, a missing label reading null. A blank label is
refused there too, and a blank default-release-label setting no
longer adds an empty release to the list.
2026-11-20 18:08:32 -04:00
Priamo Germosen 30c37a129c fix(bcm-pricing-calculator): give resource-tag conditions the tags of the workload estimate a request names (#9112)
The generated request resources give Pricing Calculator's workload
estimate type the aws:ResourceTag/ key, but no service answered the bcm-
pricing-calculator namespace's stored tags, so a condition on an
estimate's tags saw none. BcmPricingCalculatorService now answers it: a
workload estimate records no ARN, so storedTags takes the ARN only when
it is the one the estimate's account and id give in the request's
partition, which has no Region, then reads the estimate by its id, in
the request's account, in place. An estimate's tags are the ones it was
created with, which nothing changes. The package now builds that ARN to
compare, so partition/smoke-exemptions.tsv gets a row saying why it
needs no partition smoke case.
2026-11-20 17:24:41 -04:00
Priamo Germosen 3027145979 fix(iam): check CloudWatch Logs requests on the resources they name, from the generated table (#9088)
CloudWatch Logs was built by hand: ResourceArnBuilder built a group or
stream ARN for six operations and resolved the tag operations' ARN
itself, every other Logs operation was checked on *, and only the
vended-log delivery operations and PutDestination were read from the
request resources table, through READ_IN_HAND_BUILT. logs moves from
HAND_BUILT to NAMESPACES, so the table gives each of its 118
operations the log group, stream, destination or delivery resource its
request names, from botocore and the Service Reference: PutLogEvents,
FilterLogEvents, metric and subscription filters, StartQuery and the
other operations on a group or stream are checked on it, no longer on
*. READ_IN_HAND_BUILT, whose only entries were Logs', goes with its
checks and tests. ResourceArnBuilder's buildLogResources and the
filter's Logs case go; the tagged CreateLogGroup check reads the
table's bare group ARN, which the evaluator already matches with or
without the trailing :* for the group's management actions.
CloudWatchLogsStoredResourceArns answers the stored tags of a log
group, a destination and the delivery family; IamConditionContextResolver
keeps only the request tags of Logs' create and tag calls. Log group
tag writes give the group a new map under the lock creating and
deleting a group take, so one racing a delete cannot put the group
back, and its tags field is volatile. Only Logs' operations change in
the table.
2026-11-20 16:21:08 -04:00
Priamo Germosen 751f84079f chore(iam): regenerate the request resources table for OAM's link and sink types (#9108)
The Service Reference now lists both the Link and the Sink resource
types for OAM's CreateLink and UpdateLink, so
iam-request-resources-verify fails on every change touching the table.
make iam-request-resources-sync, with no change to the generator,
brings them in: CreateLink is checked on the sink it names and now on
the link it makes too, link/* in the caller's account and Region, and
UpdateLink, whose Identifier holds a link's ARN, on the same link as
before. The same run brings in Textract's blueprint, job and project
types for its tag actions, which Floci does not serve.
RequestResourcesTest expects the made link, the REST route enforcement
test grants it with the sink and refuses a grant on the sink alone, and
the table-wide member test gives an ARN member that also fills a
resource of one of its types an ARN of that type.
2026-11-20 15:50:59 -04:00
Priamo Germosen 6b420b166f fix(emr): make a uniform RunJobFlow cluster's master and core instance groups (#9107)
RunJobFlow's uniform form, MasterInstanceType, SlaveInstanceType and
InstanceCount in place of InstanceGroups or InstanceFleets, made no
instance groups, so ListInstanceGroups listed none, ListInstances no
instances, and with runner-mode docker the cluster ran on its primary
node alone. It now makes the groups the API reference describes: "If
the value is 1, the same instance serves as both the master and core
and task node. If the value is greater than 1, one instance is the
master node and all others are core and task nodes."

That is a MASTER group of one MasterInstanceType instance and, for a
count above 1, a CORE group of the rest as SlaveInstanceType, both
ON_DEMAND. The master group is named "Master InstanceGroup", as in
DescribeJobFlows' sample response; no source names the core group, so
Floci names it "Core InstanceGroup". A request that gives
InstanceGroups or InstanceFleets keeps its own.

A request for more than one instance without SlaveInstanceType is
refused with a ValidationException, as JobFlowInstancesConfig says "all
three must be present"; a single instance needs none, as AWS runs one
without it. However many instances a cluster asks for, in this form or
any other, its core and task nodes are now built no further than
yarn-max-worker-nodes, where every one asked for was built before the
rest were dropped.
2026-11-20 15:03:53 -04:00
Priamo Germosen dc97ce5cb1 fix(iam): check Resource Groups requests on the groups the generated table gives them (#9074)
Resource Groups was built by hand: ResourceArnBuilder read a group from
the body's Group or GroupName, or CreateGroup's Name, the request
resources table held no Resource Groups operation, and nothing gave a
policy condition a group's tags. resource-groups moves from HAND_BUILT
to NAMESPACES, so the table gives each operation the group its Group
names, by its name or its ARN, and the ARN a tagging route carries;
CreateGroup, for which the Service Reference lists no resource type, is
checked on *, as AWS checks it. ResourceArnBuilder's Resource Groups
branch goes. ResourceGroupsStoredResourceArns answers a group's stored
tags, read in place from the group record the service stores whole. Only
Resource Groups' operations change in the table.
2026-11-20 07:03:52 -04:00
Priamo Germosen e8f16911d2 fix(iam): check EKS requests on the resources the generated table gives them (#9070)
EKS was built by hand: ResourceArnBuilder walked an EKS path, looked
each resource up through EksService, and checked a tagging route on the
caller's cluster named after the ARN's last segment; the request
resources table held no EKS operation, and nothing gave a policy
condition an EKS resource's tags. eks moves from HAND_BUILT to
NAMESPACES, so the table gives each operation the cluster its path
names, the node group, add-on or Fargate profile EksStoredResourceArns
finds by its cluster and name, the ARN a tagging route carries, and
parts of an ARN the request does not give open. CreateCluster, for which
the Service Reference lists no resource type, is checked on the cluster
its body names from a MEASURED entry quoting the EKS user guide's
example policy for creating a cluster. ResourceArnBuilder's EKS section
and its EksService dependency go. EksStoredResourceArns answers the
stored tags of a cluster, node group, Fargate profile, add-on, Pod
Identity association or access entry; EKS's tag changes take one lock
and give a cluster, node group or Fargate profile a new map, whose tags
field is now volatile, and a cluster is tagged only when its ARN is the
whole ARN the request names. Tag changes and tag reads find a cluster,
node group or Fargate profile through one lookup, and an ARN with a part
left open is not looked up. Read from its model, EKS tags only on
/tags/{resourceArn} with the ARN encoded, as the SDKs send it, so the
tagging tests that sent it unencoded now encode it. Only EKS's
operations change in the table.
2026-11-19 23:25:25 -04:00
Priamo Germosen 1a888867ad fix(iam): check STS requests on the resources the generated table gives them (#9033)
STS was built by hand: ResourceArnBuilder checked AssumeRole on the role
its RoleArn named and every other operation on *, IamEnforcementFilter
sent STS requests there by action, and the request resources table held
no STS operation. sts moves from HAND_BUILT to NAMESPACES, so the table
gives each operation what the Service Reference and botocore give it:
AssumeRole the role its RoleArn names, as before, GetFederationToken the
federated user its Name names and AssumeRoot the root user, where the
hand builder checked both on *, and the operations that act on no
resource type * as before. StsStoredResourceArns answers that a role IAM
holds in the account its ARN names is assumed there, as the handler
finds it, so a cross-account AssumeRole is checked on that role alone
and not also on the caller's role of that name. ResourceArnBuilder's STS
section and the filter's STS case go. Only STS's operations change in
the table.
2026-11-19 21:56:53 -04:00
Priamo Germosen 186b0f6a63 chore(iam): regenerate the request resources table for Route 53's health check sources (#9053)
The Service Reference now gives Route 53 a healthchecksource resource
type and lists it for ChangeTagsForResource, ListTagsForResource and
ListTagsForResources, so iam-request-resources-verify fails on every
change touching the table. make iam-request-resources-sync, with no
change to the generator, brings that in, with the type's ARN format and
its aws:ResourceTag/ key, and what else AWS changed since the table was
last written, each read by the existing rules: Route 53's health check
source actions, Cognito user pools' client metadata document policy and
URL actions, the userpool type for those and for the point-in-time
recovery actions, Pricing Calculator's GetUsageLinesEstimatedCost and
its bill-estimate tag key, EventBridge's RotateWebhookCredentials, S3
Tables' DisassociateTableReplication and RDS's subgrp type for
ModifyDBCluster, which nothing the action reads fills.
2026-11-19 21:15:00 -04:00
Priamo Germosen 66dbdd2935 fix(iam): check Aurora DSQL requests on the clusters they name, from the generated table (#9011)
Aurora DSQL was built by hand: ResourceArnBuilder read a cluster or
stream from its path, or a tagging route's ARN, IamEnforcementFilter
sent DSQL requests there without their operation, the request resources
table held no DSQL operation, and nothing gave a policy condition a
cluster's tags. dsql moves from HAND_BUILT to NAMESPACES, so the table
gives each operation the cluster or stream its path names, or the ARN
its modeled /tags/{resourceArn} carries, from botocore's REST model;
ListClusters, for which the Service Reference lists no resource type, is
checked on cluster/* from a MEASURED entry citing the AccessDenied
message AWS returned in #6328. ResourceArnBuilder's DSQL branch, with
the path and tagged-ARN helpers only it still used, and the filter's
DSQL case go, and the shared tags controller now serves DSQL's
tagging on its modeled route only, refusing the bare /tags. Only DSQL's
operations change in the table. DsqlStoredResourceArns answers a
cluster's stored tags; TagResource and UntagResource give the cluster a
new map under its lock, and its tags field is volatile.
2026-11-19 13:31:17 -04:00
Priamo Germosen 56d8b9aedc fix(iam): check EventBridge Pipes requests on the pipes they name, from the generated table (#9000)
Pipes was built by hand: ResourceArnBuilder read a pipe's name from its
path or a tagging route's ARN, IamEnforcementFilter sent Pipes requests
there without their operation, the request resources table held no Pipes
operation, and nothing gave a policy condition a pipe's tags. pipes
moves from HAND_BUILT to NAMESPACES, so the table gives each operation
the pipe its path's Name names, or the ARN a tagging route carries, from
botocore's REST model, and ResourceArnBuilder's Pipes branch and the
filter's Pipes case go. Only Pipes' operations change in the table.
PipesStoredResourceArns answers a pipe's stored tags; TagResource and
UntagResource give the pipe a new map one call at a time, and its tags
field is volatile.
2026-11-19 12:17:15 -04:00
Priamo Germosen 43d6ea4961 fix(iam): check Kinesis Data Streams requests on the resources they name, from the generated table (#8989)
Kinesis was built by hand: ResourceArnBuilder read a request's
StreamARN, StreamName or ResourceARN into one ARN and checked everything
else on stream/*, the request resources table held no Kinesis operation,
and nothing gave a policy condition a stream's tags. kinesis moves from
HAND_BUILT to NAMESPACES, so the table gives each operation the
resources botocore's members name as the Service Reference types them:
the stream by StreamARN or StreamName, a consumer by ConsumerARN, a
tagged resource by ResourceARN, and the KMS key StartStreamEncryption
and StopStreamEncryption name. Its ResourceArnBuilder branch goes. Only
Kinesis's operations change in the table. KinesisStoredResourceArns
answers a stream's or a consumer's stored tags; the tag calls give the
resource a new map under their lock, and the tags fields are volatile.
2026-11-19 10:04:27 -04:00
Priamo Germosen aabe2247c5 fix(iam): check SNS requests on the topics they name, from the generated table (#8971)
SNS was built by hand: ResourceArnBuilder read a request's TopicArn and
checked everything else on the account's open topic ARN, the request
resources table held no SNS operation, and nothing gave a policy
condition a topic's tags. sns moves from HAND_BUILT to NAMESPACES, so
the table gives each operation the topics botocore's members name
(TopicArn, ResourceArn, TargetArn, and CreateTopic's Name), and its
ResourceArnBuilder branch goes. Only SNS's operations change in the
table. SnsStoredResourceArns answers a topic's stored tags; TagResource
and UntagResource give the topic a new map one call at a time, and its
tags field is volatile.
2026-11-19 08:50:08 -04:00
Priamo Germosen 634073fb83 fix(iam): check SQS requests on the queue their URL reaches, from the generated table (#8943)
SQS was built by hand: ResourceArnBuilder read a request's QueueUrl or
QueueName into a queue ARN, the request resources table held no SQS
operation, and nothing gave a policy condition a queue's tags. botocore
documents every QueueUrl as "The URL of the Amazon SQS queue ...", which
the generator's documentation rule did not read: it took only a name, an
id or an identifier as what a member names, and the service's own name
stood between "the" and the type's word. It now reads a URL as one more
such kind, and a member's lead drops its model's own service name as
botocore's metadata spells it before the word it qualifies, and a
hyphenated word before the type's word qualifies it ("The URL of a
dead-letter queue"), so QueueUrl names the queue; being neither the
queue's name nor its id, SQS finds it (find). Only SQS's operations
change in the table. sqs moves from HAND_BUILT to NAMESPACES and its
ResourceArnBuilder branch goes. SqsStoredResourceArns finds the queue a
URL reaches as the handlers do, in the account the URL names, and
answers a queue's stored tags; TagQueue and UntagQueue give the queue a
new map one call at a time, and its tags field is volatile.
2026-11-19 07:16:17 -04:00
Priamo Germosen 987a2e581b chore(iam): regenerate the request resources table for the Service Reference's latest changes (#8944)
The Service Reference now gives Managed Service for Apache Flink's
snapshot actions and tag actions a snapshot resource type, so
iam-request-resources-verify fails on every change touching the table:
CreateSnapshot and ListSnapshots act on the application, the other
snapshot actions on the snapshot, and the tag actions on either. make
iam-request-resources-sync, with no change to the generator, brings that
in, with the actions AWS added since the table was last written: Cognito
user pools' point-in-time recovery, Lambda's durable execution delete,
pause and resume, and EC2's ModifyTransitGatewayPeeringAttachment, each
read by the existing rules, and three namespaces Floci does not serve in
otherNamespaces.
2026-11-19 00:02:34 -04:00
Priamo Germosen f3b8b12777 fix(elbv2): give resource-tag conditions the tags of the load balancer, target group, listener or rule a request names (#8937)
The generated request resources give Elastic Load Balancing's load
balancer, target group, listener and rule types, and the Classic Load
Balancer's, the aws:ResourceTag/ and elasticloadbalancing:ResourceTag/
keys, but no service answered the elasticloadbalancing namespace's
stored tags, so a condition on their tags saw none.
ElbStoredResourceArns now answers it for both versions: a version 2 ARN
reads the tags version 2 keeps under it, in the request's account, in
place; a Classic Load Balancer's ARN, the one Floci gives it, reads the
load balancer of its name in its Region. Both versions' AddTags and
RemoveTags changed the tag map in place with no lock; they now give the
resource a new map one call at a time, and the Classic Load Balancer's
tags field is volatile.
2026-11-18 22:09:21 -04:00
Priamo Germosen 26dc6d79ed fix(cloudmap): give resource-tag conditions the tags of the namespace or service a request names (#8932)
The generated request resources give Cloud Map's namespace and service
types the aws:ResourceTag/ key, but no service answered the
servicediscovery namespace's stored tags, so a condition on their tags
saw none. CloudMapService now answers it: storedTags reads the namespace
or the service by the id its ARN ends in, in the request's account, in
place, the id the handlers find it by in every Region, so a request sent
to another Region is checked with the tags of the resource it acts on; a
tag without a value reads as an empty one. TagResource and UntagResource
changed the tag map in place with no lock; they now give the resource a
new map one call at a time, and the tags fields are volatile.
2026-11-18 21:05:39 -04:00
Priamo Germosen 6372b315f0 test: fold the DSQL external backend profile into a shared sidecar profile (#8923)
DsqlExternalBackendIntegrationTest runs on SidecarAccessEnforcementProfile
now, renamed SidecarServiceSettingsProfile since it no longer holds only
access settings, and that profile takes ExternalPostgresResource as its
test resource. DsqlExternalBackendProfile goes.

The DSQL backend is chosen once per application, so the external one
cannot join SidecarContainersProfile, whose DSQL classes run each cluster
in a container of its own. The Redshift classes here create no DSQL
cluster, and the DSQL class sends no S3 request and runs no Spectrum
query, so neither side's settings reach the other's requests.

Since the application is shared now, a PostgreSQL server that does not
start no longer fails the boot: the resource records why, and only the
DSQL class fails, with that cause. In CI a failed image pull is such a
failure rather than a skip, as a sidecar image's is. The container
carries the run's sidecar namespace, so the next run removes it when a
killed run leaves it behind.
2026-11-18 20:48:39 -04:00
Priamo Germosen 1d8499e837 fix(eks): resolve pod names through Floci's embedded DNS (#8924)
Pods resolve through CoreDNS, which forwards to the resolver file k3s
hands them. k3s takes the node's /etc/resolv.conf, and on a user-defined
Docker network that names only Docker's loopback 127.0.0.11, which k3s
refuses; it then writes a file naming a public resolver. So Route 53
private zones, Cloud Map names and the other names only Floci answers
never resolved from a pod.

When embedded DNS is on and running, and the cluster's Docker network
can reach it, Floci now copies a resolver file naming only its DNS
server into the cluster container before it starts, and passes it to
k3s with --resolv-conf. With Floci in a container that means the
cluster is on Floci's own network: Docker isolates user-defined
networks, and pods given only an unreachable resolver would lose the
public one too. The public fallback resolvers
stay out of it, because CoreDNS picks among its upstreams at random. A
cluster that sets the kubelet's resolv-conf through its tags keeps its
own file. A file that cannot be copied fails the start, as a container
that cannot start does, since k3s would hand its pods a missing file.
2026-11-18 19:51:14 -04:00
Priamo Germosen c4d7499ca2 fix(iam): word the service-linked duration refusal as AWS does (#8910)
The one refusal of the twelve that is recorded: UpdateRole changing a
service-linked role's MaxSessionDuration answers '<roleName> is an AWS
service linked role, max session duration cannot be changed.', where the
clause names the change refused rather than the service the role is linked
to. This package answered its own sentence there.

The other eleven keep it, and the IAM page says why: AWS words the clause
after the change, that clause cannot be inferred for eleven other changes,
and AWS may not refuse all of them this way at all.
2026-11-18 17:49:57 -04:00
Priamo GermosenandDaniël van Ziel 1df1af297d fix(docdb): isolate container identity by account and region (#8888)
A DocumentDB cluster's MongoDB container was named after the cluster
identifier alone, and the manager kept its live handles under that
identifier too. Creating a same-named cluster in another account or
Region removed the first cluster's container and replaced its handle,
so a later delete or shutdown could no longer reach it.

Container names now carry the account and Region
(floci-aws-docdb-<account>-<region>-<cluster>), and live handles are
kept by Docker ID. Deleting a cluster closes the log stream its
container was started with, which the handle DeleteDBCluster rebuilds
from the stored record does not carry.

Ported from #5724.

Co-authored-by: Daniël van Ziel <159726064+danielvanza@users.noreply.github.com>
2026-11-18 17:19:46 -04:00
Priamo Germosen 6afd82c9fb fix(guardduty): give resource-tag conditions the tags of the detector or plan a request names (#8909)
The generated request resources give GuardDuty's detector and
malwareprotectionplan types the aws:ResourceTag/ key, but no service
answered the guardduty namespace's stored tags, so a condition on a
detector's or a Malware Protection plan's tags saw none.
GuardDutyService now answers it: storedTags reads the detector or plan
stored under the Region the ARN names and its id, in the request's
account, where the tag handlers read, in place. A plan is matched on the
ARN it records; a detector, which records none, on the ARN its Region,
the account of its service role and its id give. Tag calls already run
one at a time and give the resource a new map; the tags fields are now
volatile.
2026-11-18 17:03:38 -04:00
Priamo Germosen 1c16ea57cd feat(emr-serverless): open an ended run's Spark History Server from its dashboard link (#8907)
With runner-mode docker, GetDashboardForJobRun's link for a Spark run's
attempt that has ended now opens a Spark History Server over the run's
event logs, and GetResourceDashboard's link does the same for a session
that has ended, as "For completed jobs, the application UI is a
persistent application user interface such as the Spark History Server"
and "After a session ends, the Spark History Server remains available".

A run's or session's driver keeps its event logs where the release's
image writes them, /var/log/spark/apps, on a Docker volume of its own,
for the 30 days EMR Serverless keeps logs in managed storage. The server
runs in a container of the release's image that starts as its link is
first opened, answering 503 until it is up, and stops once no link to it
is valid. A history goes 30 days after its run or session ended, or once
it has gone, which Floci checks as it starts and every hour; a restart
keeps the histories and a reset removes them.

A run whose logs are not kept in managed storage keeps no event logs
and still gets Floci's page, as do Hive runs, histories that have gone
and every link in the immediate mode.
2026-11-18 16:45:03 -04:00
Priamo Germosen d2facef773 fix(sts): refuse a session whose token exceeds the limit (#8883)
An oversized session was minted outright and PackedPolicySize was
published as a flat zero on every session, where AWS holds a session
token to one limit of 4096 bytes, refuses a token that will not fit with
PackedPolicyTooLarge 400 naming the size and the limit, and publishes
that member as the percentage of the limit the token consumes, the same
value as SessionTokenUtilization.

Both are answered now on the four operations that carry state into the
token they mint, the refusal read before anything is minted. The measure
is this emulator's own: the token it will mint, which
MinimumSessionTokenSize can ask to be longer, plus the state the request
carries into it in UTF-8 bytes. AWS assembles and compresses the real
thing, whose size follows the input in neither direction, so the numbers
differ; the IAM page records the one size recorded here, 26092 bytes for
about 19000 of input, so a later recording can calibrate the reading.
2026-11-18 16:06:45 -04:00
Priamo Germosen b57b837286 test: fold four TLS test profiles into the two shared TLS fixtures (#8902)
TlsLocalCaIntegrationTest, ContainerCaBundleDockerIntegrationTest and
EcrTlsUriIntegrationTest each laid down a local CA and a leaf of their
own. They run on SelfSignedTlsProfile now, which writes the same CA and
leaf, covers host.docker.internal and the regional ECR hosts, and now also
writes the Java trust store containers mount and advertises ECR's TLS
URIs. EcrTlsPathUriIntegrationTest needs the path style instead, so it
runs on IotMqttTlsProfile, whose leaf gains localhost.floci.io. The ECR
settings are read only by ECR's control plane and EKS, which no other
class on either profile calls.

The IoT classes stay apart: they dial 127.0.0.1 with hostname
verification, and two SelfSignedTlsProfile classes need that SAN absent.
2026-11-18 16:01:02 -04:00
Priamo Germosen 3f194c4c4f fix(controltower): give resource-tag conditions the tags of the landing zone or enabled control a request names (#8901)
The generated request resources give Control Tower's LandingZone and
EnabledControl types the aws:ResourceTag/ key, but no service answered
the controltower namespace's stored tags, so a condition on a landing
zone's or an enabled control's tags saw none. A new
ControlTowerStoredResourceArns answers it for the namespace, which two
services hold: a landing zone's tags are read in place under the Region
its ARN names, an enabled control's found by the ARN it records among
the Region's controls, as the tag handlers find it, both in the
request's account and matched on the whole ARN. Tag calls already give
the resource a new map; the tags fields are now volatile.
2026-11-18 16:00:15 -04:00
Priamo Germosen 3ffec01a76 feat(emr-serverless): open the live Spark UI from dashboard links (#8890)
With runner-mode docker, GetDashboardForJobRun's link for a Spark run's
attempt that has not ended now opens its driver's Spark UI for real, and
GetResourceDashboard's link does the same for a session's Spark Connect
server, as "For jobs in a running state, the application UI is a live
user interface such as the Spark or Tez web UI" and "While a session is
active, the URL opens the live Apache Spark UI".

Each link opens on a host of its own,
<secret>-4040.emr-serverless-ui.<Floci's host>, through the application
UI proxy EMR's on-cluster UIs use. That proxy moves to core.common
(AppUiProxy, AppUiRoutes, AppUiRoute, AppUiHost), and each service
registers the label its hosts are under. The runner turns the driver's
UI on for every EMR Serverless Spark run, as the release's image turns
it off, publishes port 4040 on the Docker host's loopback interface, and
keeps where Floci reaches it while the container runs.

A run whose logs are not kept in managed storage gets no live UI, as
with logs in S3 alone the application UI is "Not supported". A Hive
run, a run or session that has ended, and every link in the immediate
mode still open Floci's own page, which now says whether the attempt's
logs are in managed storage.
2026-11-18 15:41:25 -04:00
Priamo Germosen 0effc633eb test: run the ELBv2 no-keep-alive class on IndependentServiceSettingsProfile (#8884)
ElbV2BackendNoKeepAliveIntegrationTest's nested profile turned the ELBv2
data plane on and backend keep-alive off. Both settings only act once a
class creates a listener or registers a target, which no other class on
IndependentServiceSettingsProfile does, and the class calls none of the
services that profile configures. ELBv2 looks the default subnets up in
EC2 the way Route53 and RDS do there, from what EC2 has stored, so EC2
running for real changes nothing for it.
2026-11-18 15:16:46 -04:00
Priamo Germosen 08e2824a2c test: run the Lambda leftover containers class on ScopedServiceSettingsProfile (#8887)
LambdaLeftoverContainersDockerIntegrationTest's nested profile set the
Lambda executor to docker, the default already, and a Docker resource
namespace of its own. ScopedServiceSettingsProfile names its containers
in this test JVM's sidecar namespace, which keeps the class's sweep away
from another Floci's containers just as well. The sweep removes only
Lambda environments, which no other class there starts, and the class
drives the launcher directly, so none of the ECS, CORS, partition or EC2
settings reaches it.
2026-11-18 14:59:21 -04:00
Priamo Germosen 4453ca9fe9 fix(securityhub): give resource-tag conditions the tags of the hub or configuration policy a request names (#8889)
The generated request resources give Security Hub's hub and
configuration-policy types the aws:ResourceTag/ key, but no service
answered the securityhub namespace's stored tags, so a condition on a
hub's or a configuration policy's tags saw none. SecurityHubService now
answers it: storedTags reads the account's state for the Region the ARN
names, in the request's account, where the tag handlers read, in place,
and matches the ARN hubArn or policyArn gives; a hub reads its tags only
while Security Hub is enabled there. A policy's tags change in place
under the service's lock, so the lookup takes that lock too.
2026-11-18 14:52:22 -04:00
Priamo Germosen ae856867bf test: run the S3 configured endpoint class on ConfiguredHostnameProfile (#8886)
ConfiguredHostnameProfile takes S3ConfiguredEndpointIntegrationTest's
hostname, configured-endpoint.localhost.floci.io, which the S3 class needs
since it names its buckets after the part before .localhost, with its
extra DNS suffix and S3 authentication. The IoT and API Gateway classes
check the configured hostname through the new HOSTNAME constant instead
of "floci". The name is not one of Floci's built-in suffixes, so the
regional execute-api host under it still routes only through the
configured hostname. No other class here calls S3 or uses the alias.
2026-11-18 14:32:32 -04:00
Priamo Germosen f1777164a3 test: share one sidecar profile across the Redshift access enforcement classes (#8885)
SidecarS3AuthEnforcedProfile becomes SidecarAccessEnforcementProfile and
takes Spectrum's Lake Formation enforcement from
SidecarSpectrumLakeFormationProfile, which goes. Lake Formation leaves a
table to IAM while the account's Data Lake settings leave new tables to
IAM, as AWS's defaults do, so the S3 authorization classes' Spectrum
queries pass it. The Lake Formation class takes new tables away from IAM
to check its grants, so it now puts AWS's defaults back when it is done.
Its role may read the bucket it queries, so S3 authentication leaves its
reads as they were.
2026-11-18 14:31:45 -04:00
Priamo Germosen 2ac4554ea8 fix(ce): give resource-tag conditions the tags of the anomaly monitor or subscription a request names (#8881)
The generated request resources give Cost Explorer's anomalymonitor and
anomalysubscription types the aws:ResourceTag/ key, but no service
answered the ce namespace's stored tags, so a condition on a monitor's
or a subscription's tags saw none. CostAnomalyService now answers it:
storedTags reads the monitor or subscription stored under its whole ARN,
in the request's account, where the handlers read, in place. Every write
already puts a new record under the service's lock, so nothing to lock.
2026-11-18 13:43:11 -04:00
Priamo Germosen 1c3a6b615e test: run the lazy MQTT start classes on ServicesOffSettingsProfile (#8870)
LazyMqttTestProfile only moved the broker to port 18838, off the shipped 1883
a developer's running Floci may hold; the test config already leaves
auto-start off. Both classes stop the broker before and after each test, so
they need no application of their own, and no class on
ServicesOffSettingsProfile reaches the broker or calls IoT. The port becomes
ServicesOffSettingsProfile.MQTT_PORT.
2026-11-18 13:15:18 -04:00
Priamo Germosen 5548bb78eb fix(emr): give resource-tag conditions the tags of the session a request names (#8878)
The generated request resources give EMR's session type the
aws:ResourceTag/ and elasticmapreduce:ResourceTag/ keys, but
EmrService.storedTags answered clusters, Studios and notebook executions
and nothing for a session's ARN, so a condition on a session's tags saw
none. It now reads the session stored under the id the ARN ends in, in
the account the ARN names, in place, matched on the whole ARN, giving
the tags it started with.
2026-11-18 12:21:41 -04:00
Priamo Germosen 0842636ed9 fix(iam): refuse the instance profile pair as AWS words it (#8876)
An instance profile holds one role and both halves of that were wrong.
Adding a second answered prose where AWS names the quota that fired,
'Cannot exceed quota for InstanceSessionsPerInstanceProfile: 1', which is
the form this package already writes for nine other quotas. Removing a
role the profile never held removed nothing and answered 200 where AWS
answers 404 NoSuchEntity naming the role and the profile.

The tolerance the remove path was written for is kept and pinned: a role
deleted while the profile still lists it stays removable, which the
profile's own list decides. Whether the pairing is there and the removal
of it are one decision, taken on the monitor the attach path already
held, so a concurrent attach cannot land between them.

Both CloudFormation callers remove roles they read from the profile's
list, and a caller outside the stack can detach one in between, so each
tolerates a pairing that is already gone rather than leaving a stack
delete or a reconcile part way through. A profile that has itself gone is
a different case and still propagates, so the delete ends where it always
did.
2026-11-18 11:13:31 -04:00
Priamo Germosen 0c1ee1ea32 test: run the kubelet registration class on IamEnforcedServiceSettingsProfile (#8869)
EksKubeletRegistrationIntegrationTest's profile only named the kubelet image
catalog. The catalog replaces EC2's built-in one, so it can only share an
application with classes that launch no instance and look up no image, which
holds for the four classes on IamEnforcedServiceSettingsProfile. The kubelet
class's one request through the HTTP layer signs with a 12-digit account id
as the access key, which IAM enforcement passes through, and it creates its
cluster through the service directly.
2026-11-18 11:00:31 -04:00
Priamo Germosen 7b750b8455 fix(emr-containers): give resource-tag conditions the tags of the resource a request names (#8875)
The generated request resources give EMR on EKS's virtualCluster,
jobRun, managedEndpoint, jobTemplate and securityConfiguration types the
aws:ResourceTag/ key, but no service answered the emr-containers
namespace's stored tags, so a condition on their tags saw none.
EmrContainersService now answers it: storedTags reads the resource
stored under its ARN in the store its kind names, in the request's
account, where the handlers read, in place, and matches the ARN it
records. Every write already stores a new copy, so no lock change.
2026-11-18 10:49:52 -04:00
Priamo Germosen 81c5ecf777 test: run two more ECS Docker classes on ScopedServiceSettingsProfile (#8868)
Both classes ran on a profile of their own for real ECS containers, as
ScopedServiceSettingsProfile already does for the image pull class, with the
startup sweep off. The Linux parameters class's two switches, /dev/null as
the one host path a device may take and privileged containers allowed, move
there: only a task definition that asks for a device or privilege reaches
them, and only that class asks. Their tasks run in bridge mode, which
security-group enforcement never protects, and the pull on every launch the
image pull class needs runs their busybox tasks the same way, falling back to
the cached image when a pull fails.

Dropping the essential-exit class's own namespace would leave its containers
labelled by the port alone, so the profile now names its containers in this
run's sidecar namespace, which also covers the image pull class.
2026-11-18 10:31:58 -04:00
Priamo Germosen 4fe226c253 fix(iam): refuse a service namespace that names no AWS service (#8865)
The member's pattern admits anything word-shaped, so a value like
amazon-s3 satisfied everything the model declares and was answered 200
with an empty policy list, telling a caller the identity reaches nothing
rather than that the question was wrong.

Both operations that take a namespace hold it to the vendored catalog now,
through AwsServiceNamespaces.isPublished so nothing keeps a second list,
and each answers the sentence recorded for it: the list operation names
the rejected values inside AWS's own brackets, and the entity reader
carries AWS's own misspelling of namepace.

ServiceNamespaces is vendored for that to hold. The generator held the
whole member back because the operation answered an empty list with a
sentence of its own, and the cost was that no value in the list was read
at all: one breaking the published pattern reached the catalog check and
was answered InvalidInput where AWS answers ValidationError. The member
is read now, each value held to serviceNamespaceType and the list to its
bounds of 1 to 200, which also retires two answers that were this
package's own: an absent list is the required member the model declares,
and a list over 200 is the model's bound rather than a check beside it.

A namespace the job itself reports stays readable on
GetServiceLastAccessedDetailsWithEntities whether the catalog publishes it
or not, so the job is read first. The catalog is vendored, and a policy
may grant a service published after it: the report keeps the namespace
that policy names, so refusing it there would be this package disagreeing
with itself. Nothing else is exempt, and the list operation, which takes
namespaces rather than reporting them, holds every value to the catalog.
2026-11-18 09:55:49 -04:00
Priamo Germosen a72aedfbb0 fix(emr-serverless): give resource-tag conditions the tags of the application, job run or session a request names (#8853)
The generated request resources give EMR Serverless's application,
jobRun and session types the aws:ResourceTag/ key, but no service
answered the emr-serverless namespace's stored tags, so a condition on
their tags saw none. EmrServerlessStoredResourceArns now answers it for
the three services that hold them: storedTags reads the application, job
run or session by its id, in the request's account, where the tag
handlers read, in place, and matches it on its application and on the
whole ARN; a deleted application's resources name nothing. The tags
fields are now volatile.
2026-11-18 09:40:47 -04:00
Priamo Germosen 84e60f73a8 test: fold eight single-switch profiles into two shared ones (#8860)
Eight profiles each carried a switch only their own class reads. Four go into
ServicesOffSettingsProfile, which keeps the ten services ServiceEnablement
switches off, for classes that call none of them: the delegation partner
registration, the S3 restore delay and EC2 vCPU admission join it. The other
four go into ScopedServiceSettingsProfile, whose classes call DynamoDB, ECS and
FIS: ECS image pulls on real containers, the extra CORS settings, strict
partitions and the fixed mock public address. That profile also turns the ECS
startup sweep off, so an application a class without containers starts never
sweeps the Docker daemon. Each profile's Javadoc lists who relies on each
setting and why it never reaches the other classes.
2026-11-18 09:01:01 -04:00
Priamo Germosen b5994e4d9e test: fold four IAM-enforced one-off profiles into two shared ones (#8859)
RdsIamEnforcementProfile becomes IamEnforcedServiceSettingsProfile and takes
the classes of DsqlEnforcementProfile, of the nested IamEnforcementProfile of
LambdaExecutionRoleDockerIntegrationTest and of the
GlobalNamespaceIamOnlyProfile of
S3PresignedPostBucketPolicyAccountContextIntegrationTest. Each adds one service
setting, and no other class there calls the service it changes. The Lambda
class's fixed port 4587 becomes a free port chosen when the profile loads.

PartnerPermissionBoundaryEnforcementProfile folds into IamEnforcementProfile:
the partner registration only reaches a delegation request filed as the
partner account, which no other class there files. IamEnforcementProfile's
joining rule now asks that settings be inert both ways, as the other shared
profiles do.
2026-11-18 09:00:56 -04:00
Priamo Germosen 1f8dc1651d test: share the Pod Identity profiles and the AppSync IAM profiles (#8858)
The two EKS Pod Identity Docker classes each declared a profile named Profile
with the same webhook, TLS and port settings. Only the agent class's turned EKS
mocking off, which never reaches the other class: it stores its cluster and
add-on through the services directly. They now share EksPodIdentityProfile.

AppSyncHttpDataSourceSidecarIntegrationTest and
EventBridgeAppSyncSidecarIntegrationTest each declared an EnforcedSidecars
profile, the sidecar namespace and port with IAM enforcement, the first with
signature validation as well. AwsIamHttpDataSourceIntegrationTest declared the
same two switches without the sidecar settings, which never reach it: it starts
no container and sends to the port the application listens on. The three now
share SidecarIamEnforcementProfile. The EventBridge class creates and deletes
its stack through a signed CloudFormation client rather than a hand-written
Authorization header, which signature validation would refuse.
Its cleanup now holds the SDK clients in a try-with-resources, so each closes
whatever the stack and IAM cleanup throws.
2026-11-18 09:00:51 -04:00
Priamo Germosen 3dce88baed test: run two classes on the default application, whose profiles change nothing (#8857)
Ec2QuotaDefaultOffIntegrationTest's profile set standard-on-demand-vcpus to 5,
the value the test config already has, and the profile of
CloudWatchLogsMetricFilterRetryIntegrationTest set nothing at all: it kept the
class off a shared application because the class resets all state over HTTP,
which many classes on the default application and on shared profiles already
do. Both classes now run on the default application, so two
applications fewer are built.
2026-11-18 09:00:45 -04:00
Priamo Germosen 4292bca198 docs: check the REST service matrix rows against their controllers (#8861)
Every Service Matrix row now has its operation count checked, or a stated
reason it cannot be. The REST rows map their JAX-RS controllers in
action_count_sources, with:

- rename_actions for a method not named after its AWS action, and a list
  for a method that answers several actions by query parameter
  (CreateRestApi and ImportRestApi on POST /restapis?mode=import)
- route_prefix and skip_route_prefix on a REST source, so API Gateway's v1
  and v2 rows split the one controller that serves both
- a tag_handler source mode: a TagHandler class is what gives a service the
  three tagging actions the shared /tags controllers serve
- exclude_actions for operations that always fail (InvokeModelWithResponseStream
  answers 501, ExecuteSql BadRequestException, Amazon MQ's user calls
  BadRequestException for RabbitMQ brokers)

A new coverage gate fails when a row is neither checked nor listed under
hand_counted with its reason, when two rows share a link target, or when a
row has no numeric count. It replaces the required-sources list. S3 is the
one hand-counted row: its handlers pick most operations by query string.

Most REST rows were undercounted, EKS by the most (7, served 35). IoT Data
gets its own anchor, as it shared iot.md with IoT Core and its count was
never read. The AppSync, CloudFront, EKS, Lambda and Pipes pages now list
the operations their controllers serve: AppSync's listed names that do not
exist, and CloudFront's called stored-only operations unsupported.

Closes #4999
2026-11-18 08:27:23 -04:00
Priamo Germosen 532b64eaea fix(iam): answer a refused MFA device as AWS words it (#8855)
Every MFA refusal here was this package's own sentence. IAM answers
EnableMFADevice and ResyncMFADevice with 'Authentication code for device
is not valid.' and a duplicate virtual device with 'MFA device already
exists.', both recorded and both wholly fixed text.

STS answers two sentences rather than one, by which half of the claim
failed: a serial no device of the caller's answers to, or a code that
device did not produce. Both are 403 AccessDenied, so the sentence is the
only thing that tells a caller which half to look at, and the whitespace
inside them is AWS's own. RequestMfaClaim carries the reason now, so the
seam both session operations share can word them apart.
2026-11-18 08:27:02 -04:00
Priamo Germosen 39cdaa5075 docs: check the switch-dispatched service matrix rows against their handlers (#8854)
The Service Matrix count check covered generated action tables and fifteen
single-dispatcher rows. Rows served by several dispatchers, rows linking to a
section of a shared page, and the rest of the deferred handlers had no check,
and six of them had drifted.

action_count_sources now takes a list of sources per row, an exclude list for
labels that are not actions, and a `slug#anchor` key for a row linking to a
section. regen_action_docs.py gains a map_entries mode for actions answered
from a Map.entry lookup table (Lightsail's empty-list answers). Eighteen more
rows are checked, and the stale counts are corrected: CloudWatch Logs 17 to
53, CloudWatch Metrics 11 to 25, DynamoDB 28 to 53, ECR 34 to 47, SSM 22 to
48, Cost and Usage Reports 6 to 7. The SSM and DynamoDB pages gain rows for
the actions their handlers dispatch but the pages did not list.

Refs #4999
2026-11-18 07:43:19 -04:00
Priamo Germosen e5ddc9fffc fix(globalaccelerator): give resource-tag conditions the tags of the accelerator a request names (#8847)
The generated request resources give Global Accelerator's accelerator,
listener and endpointgroup types the aws:ResourceTag/ key, but no
service answered the globalaccelerator namespace's stored tags, so a
condition on their tags saw none. GlobalAcceleratorService now answers
it: it finds the resource under the ARN itself, in the request's
account, in place, as the tag handlers do, and reads the tags stored
under that ARN. TagResource and UntagResource now run one at a time, so
two tag calls never lose one's tags.
2026-11-18 07:10:51 -04:00
Priamo Germosen cdb1cffa76 test: check the boot restores' wiring instead of booting two fresh applications (#8837)
EcsBootReconcilerIntegrationTest and EksBootRestoreIntegrationTest each took a
Quarkus profile of their own, an application no other class had sent an ECS or
EKS request to, only to see that EcsService and EksService get created at boot.
EmulatorLifecycleTest already checks that onStart restores ECS and that
onHttpStart restores EKS once the port listens; what the two classes added is
that the container fires those observers at boot. One unit test now checks that
wiring directly (onStart observes StartupEvent, onHttpStart observes
HttpServerStart, on an @ApplicationScoped bean), and the two classes and their
profiles go.
2026-11-18 06:52:40 -04:00
Priamo Germosen c9f00fee12 fix(iam): answer a policy ARN that names nothing as AWS words it (#8815)
IAM answers two sentences for a managed policy ARN it cannot resolve and
they are not interchangeable: the ARN names nothing, or it names nothing
the call could attach. One sentence served every operation here, and the
three detach paths added a clause naming the user, group or role that AWS
never emits.

PolicyNotFound sites the two per operation, from the recordings: GetPolicy,
TagPolicy and the detach paths answer the plain sentence, while the attach
family, ListEntitiesForPolicy and the version operations carry the
attachability clause, with GetPolicyVersion naming the version inside it.
The operations no recording covers read with their own family, documented
on the IAM page.
2026-11-18 06:52:18 -04:00
Priamo Germosen 1863f7f4bb fix(datasync): give resource-tag conditions the tags of the agent, location or task a request names (#8844)
The generated request resources give DataSync's agent, location and task
types the aws:ResourceTag/ key, but no service answered the datasync
namespace's stored tags, so a condition on their tags saw none.
DataSyncService now answers it: storedTags reads the resource stored
under the ARN itself, in the request's account, in place, as the tag
handlers find it. TagResource and UntagResource changed the tag map in
place with no lock; they now give the resource a new map one call at a
time, and the tags fields are volatile.
2026-11-18 05:43:16 -04:00