Under IAM enforcement, Amazon Data Firehose, Cognito identity pools,
Cloud Map, ACM and CodePipeline requests were checked on `*`, so a
grant scoped to a delivery stream, an identity pool, a namespace or a
service, a certificate, a pipeline or a webhook was refused, and a deny
scoped to one never applied.
The generated table of the resources requests name now reads them, 149
operations, from AWS's Service Reference and botocore as it reads the
first batch: their namespaces move from the generator's NOT_COVERED to
NAMESPACES, and the table is regenerated, nothing in it edited by hand.
Each resource type's ARN format is the one Floci's handler mints, which
the tests check against the ARN each create returns:
- `deliverystream/<name>`, `identitypool/<id>`, `namespace/<id>`,
`service/<id>`, `certificate/<id>` and a pipeline's bare name.
- A CodePipeline webhook: AWS's is `webhook:<name>` (the Service
Reference's format, and the CodePipeline User Guide's
"arn:aws:codepipeline:eu-central-1:ACCOUNT_ID:webhook:my-webhook"),
where Floci minted `webhook/<name>`; it now mints AWS's.
Corrections, each with its reason:
- StartPipelineExecution and GetPipelineState name their pipeline by a
bare `name` ("The name of the pipeline to start"), which the rule
reads only for an operation named after the type, as Step Functions'
StartExecution names its execution, not its state machine, by `name`.
- CreatePipeline and UpdatePipeline name it by `pipeline.name`, and
PutWebhook the webhook by `webhook.name` and the pipeline it connects
to by `webhook.targetPipeline`. `pipeline.roleArn` holds the role
CodePipeline assumes, an IAM role's ARN by botocore's pattern, and
names no pipeline: read as one, a pipeline-shaped value there was the
only resource an UpdatePipeline was checked on, so a grant on one
pipeline let a request change another.
- CreateCustomActionType and DeleteCustomActionType are checked on
`actiontype:Custom/<category>/<provider>/<version>`: a custom action
type's owner is Custom, which the request does not give, and AWS's
CreateCustomActionType example answers "owner": "Custom".
- Cloud Map's CreateService names its namespace by NamespaceId or,
when it gives none or a JSON null, by DnsConfig.NamespaceId, which
botocore keeps ("Use NamespaceId in Service instead") and the handler
reads then; read by NamespaceId alone, a deny on the namespace did
not hold for a request giving it in DnsConfig. A member given a JSON
null now counts as absent in a resource's `when` and `unless`, as a
handler reading it with asText(null) takes it, unless the table reads
it as a value through `absent` (EventBridge's bus, `default`).
For those, the table may fill a variable from a structure's field
(`pipeline.name`), and give a variable no member gives the one value
its handler uses (`fixed`), in the generator, the loader and the
reader.
A create that names another resource beside the one it makes has its
tags checked on the one it makes alone, which the table marks `made`:
the resource of the type, or with an ARN format's leading resource
word, related to the operation's name past its verb. PutWebhook's tags
go on the webhook, not the pipeline it connects to, and CreateService's
on `service/*`, not the namespace; no other operation in the table is
marked.
Application Auto Scaling stays unread, its reason in NOT_COVERED: a
scalable target's ARN ends in an id the service mints, while requests
name the target by ServiceNamespace, ResourceId and ScalableDimension,
and read as a member ResourceId would fill that id.
RequestResourceMembersTest's test of every resource in the table now
expects, with the resource a request names, the resources of its
operation that every request names: Cloud Map's CreateService names
the service it creates with every variable open.
* fix(sqs): reject DelaySeconds outside 0-900
* fix(sqs): don't let a json DelaySeconds outside the int range wrap around
* docs(sqs): document the DelaySeconds range
BY_HAND in tools/aws/regen_iam_condition_keys.py names the member for four pairs: iam:ServiceSpecificCredentialServiceName from ServiceName and iam:ServiceSpecificCredentialAgeDays from CredentialAgeDays on CreateServiceSpecificCredential, and iam:DelegationDuration from SessionDuration and iam:TemplateArn from Permissions.PolicyTemplateArn on CreateDelegationRequest. --check fails when a BY_HAND member leaves botocore, its type no longer fits the key, or the reference stops listing the pair. The other notRead pairs now say where AWS takes the value from.
* fix(iam): page ListUsers, ListGroups and policy lists with MaxItems and Marker
ListUsers, ListGroups, ListAttached{User,Group,Role}Policies and
List{User,Group,Role}Policies read neither MaxItems nor Marker and always
answered IsTruncated=false with every entry. They now go through the same
paginate helper ListRoles and ListPolicies use: an omitted MaxItems returns
100 items as the API reference documents, a MaxItems outside 1 to 1000 is a
ValidationError, a Marker the handler did not issue is InvalidInput, and a
Marker appears only on a truncated page.
Users, groups and inline policy names are listed in name order and attached
policies in ARN order, so a Marker keeps pointing at the same place between
calls even when the entry it names is removed in between.
* fix(iam): resume the newly paged IAM lists only from their own markers
ListUsers, ListGroups and the attached and inline policy lists read a
Marker they could not verify as a list offset, so Marker=1 silently
skipped the first entry, and a marker issued for one role's list resumed
another role's list after the same policy. These lists have only ever
issued signed markers, so their cursor now carries the action and, for a
per-principal list, the principal, and any other marker is InvalidInput.
ListRoles, ListPolicies and the other readers keep their existing marker
handling.
Also covers the omitted-MaxItems default on ListUsers and ListGroups with
101 entries: 100 on the first page, IsTruncated and a Marker that fetches
the last one.
* fix(iam): bind the newly paged IAM lists' markers to the request account
IAM entities are stored per account, but the marker cursor named only the
action and principal, so a marker issued in one account resumed the same
listing in another account after the same name and skipped its earlier
entries. The cursor now carries the account the request reads from, and a
marker from another account is InvalidInput.
* feat(iam): generate the IAM paginator table from botocore
tools/aws/regen_iam_paginators.py writes src/main/resources/aws/iam-paginators.json
from botocore's iam/2010-05-08 model, as the other tools/aws generators do: every
operation whose request models Marker, with its input and output token, limit
key, truncation flag and result keys, the MaxItems bounds of maxItemsType
(1 to 1000), the default page size the limit's documentation states ("defaults
to 100"), and markerType's bounds.
The 34 operations botocore's paginators-1.json lists take their tokens and
result keys from it. The six that model Marker without a paginator
(GetServiceLastAccessedDetails, GetServiceLastAccessedDetailsWithEntities,
GetOrganizationsAccessReport, ListServiceSpecificCredentials,
ListDelegationRequests, ListPoliciesGrantingServiceAccess) are read from
their request and response shapes and marked paginator: false.
ListServiceSpecificCredentials documents no default and
ListPoliciesGrantingServiceAccess models no MaxItems; the table records
both as such rather than inventing a value.
make aws-data-sync regenerates it and make aws-data-check fails when it is
stale against the pinned botocore.
* fix(iam): page every IAM list through one path driven by the paginator table
IamQueryHandler paged eight lists by hand through paginateScoped, a few more
through paginate, and left the rest (the tag readers, ListAccessKeys,
ListInstanceProfiles, ListPolicyVersions, GetGroup, ListGroupsForUser,
ListEntitiesForPolicy, GetAccountAuthorizationDetails, the simulations and
others) ignoring MaxItems and Marker with IsTruncated=false. Every operation
the generated aws/iam-paginators.json lists now pages through one paginate
path that reads its entry: the limit's bounds and default, the members that
resume and continue it, and the result keys pagedList and pagedLists write
under. paginateScoped, paginateByMarker and the hardcoded 100/1000 are gone.
ListEntitiesForPolicy and GetAccountAuthorizationDetails page their several
lists as one, in the paginator's order.
Marker semantics, chosen deliberately: a Marker is opaque and resumes only the
listing that issued it, on every paged operation. AWS documents it as "the
value of the Marker element in the response that you received", so a value
Floci did not issue, a bare number included, is InvalidInput; ListRoles,
ListPolicies and the report readers no longer read one as an index. The
marker names the last item of its page, so a deletion or creation ahead of
it skips nothing and repeats nothing, and it is signed (not prefixed) over
the account, the operation and every request member except Marker and
MaxItems, so a marker from another operation, principal, filter or account
is refused while the page size may change between calls. Signing the scope
instead of carrying it keeps issued markers short. markerType's 320-character
bound is not checked separately: every other value is refused as unissued,
and a long ARN key could otherwise push an issued marker past it.
MaxItems is now checked before Marker, as a malformed request is rejected
before anything is read from it. An omitted MaxItems is the documented 100;
ListServiceSpecificCredentials, which documents no default, returns its whole
list.
IamListPaginationIntegrationTest.everyPaginatedOperationHonoursMaxItemsAndMarker
iterates the table's 34 paginated operations, each with a fixture listing two
items, and checks the MaxItems bounds, a one-item page, resumption without
loss or repetition, the default page, and refusal of an unissued, bare-index
or other operation's marker. Its fixture map must name exactly the table's
operations, so one AWS starts paging later fails until it has one.
ListAccountAliases can hold one alias, so it is checked for everything but a
cut page. The tests the table test subsumes are removed; the ordering, anchor,
cross-listing and cross-account tests stay. Two ServiceLastAccessed tests
that walked by bare index now use issued markers.
* fix(iam): hold paged requests to the model through IamRequestShapes
MaxItems and Marker are request constraints, and main now checks a
request against the model before it runs. Every operation the paginator
table pages joins that wave in regen_iam_shapes.py, and the bounds leave
iam-paginators.json (which keeps only defaultItems, the documented page
size) and limit(), which now only parses the number and applies the
default. A pytest pins that every operation the paginator table carries
is in the wave, so a list AWS starts paging later cannot slip past the
bounds.
Six paged operations join with Marker and MaxItems alone: the three
report readers, whose JobId is answered by hand as "length equal to 36"
and whose SortKey enum is checked by hand; ListPoliciesGrantingServiceAccess,
whose empty ServiceNamespaces is answered InvalidInput; and the two
Simulate operations, whose ContextEntries nest a list inside a list of
structures, which the walk refuses. Vendoring their whole request would
reword answers main already settled; vendoring nothing would leave their
paging unbounded (SimulateCustomPolicy with MaxItems=0 was a 500).
Markers fit markerType's 320 characters. A marker embeds the key of the
item its page ended on, so a policy ARN with a long path produced one
of 610 characters, which the model check would now refuse on the way
back. SignedMarkers takes a maximum length: a cursor that would exceed
it is carried as a SHA-256 digest (119 characters once signed and
encoded), and the instance keeps the digest -> key mapping. That keeps
the existing resume semantics exactly: the marker still resolves to the
full key, so a deleted anchor resumes at the first key after it, and
the signature still binds account, operation and filter. Two stateless
alternatives were rejected: a truncated key prefix plus digest cannot
order a deleted anchor against items sharing the prefix, and a position
index skips or repeats when items ahead of it are deleted. The cost is
one map entry per distinct long key a page has ended on, never evicted
(marked ponytail in the code); markers already do not survive a
restart, as the signing key is per instance. Keys short enough to embed
are carried as before.
Checkstyle (./mvnw checkstyle:check) reported six errors in files this
PR touches: javax import order and two inline org.w3c.dom.Node in the
pagination test, and an inline java.util.Base64 in SignedMarkersTest.
The test now parses through XmlParser.parseDocument instead of its own
DocumentBuilderFactory. The switch statements in ListEntitiesForPolicy
and the test's holder fixture are switch expressions.
Tests: aMarkerEndingOnALongPolicyArnFitsTheModelAndResumesPastItsDeletion
attaches three policies under a 391-character path, pages with
MaxItems=1, deletes the anchor and resumes through the model check.
Constructing SignedMarkers without the limit fails it (610 characters);
restoring the pre-wave iam-request-shapes.json fails the table-driven
test (MaxItems=0 answered 500, MaxItems=1001 answered 200).
* fix(iam): bind a caller-resolved list's marker to the resolved user
ListAccessKeys, ListMFADevices, ListSSHPublicKeys, ListSigningCertificates
and ListServiceSpecificCredentials default an omitted UserName to the
caller. The marker was signed over the raw request members, so two users
in one account who both omitted UserName shared a scope and one's marker
resumed the other's listing. These handlers now page over the request
with UserName set to the resolved user, so the marker is bound to the
user the list was read for, named or implicit.
* fix(iam): bound the SignedMarkers digest map and trim the pagination test
SignedMarkers held every long cursor it had issued a digest for, in a map
that never shrank. It is now an access-ordered LinkedHashMap capped at
10,000 entries, the idiom CloudWatch Logs uses for its Insights queries. A
marker whose digest was evicted resolves to null, the same as an unknown
digest, so callers refuse it as an invalid marker.
IamListPaginationIntegrationTest spent most of its time in RestAssured's
per-request overhead on the hundred-item fixtures. Those creates and
deletes now go concurrently through java.net.http. The users and groups
default test keeps its first-page checks of the default of 100 and drops
the second page, which the roles default test and the every-operation test
already cover. The SSH public key fixture is generated once per run.
* fix(ec2): honor DryRun when creating VPCs, subnets and security groups
CreateVpc, CreateSubnet and CreateSecurityGroup never read DryRun, so a
dry run created the resource it asked about. A real CreateVpc that
followed left a second VPC, and the real create of a subnet or group
failed: InvalidSubnet.Conflict for the subnet's CIDR block,
InvalidGroup.Duplicate for the group name.
Each handler now answers DryRunOperation (HTTP 412) and creates
nothing. It answers after parsing the tag specifications and, for
CreateSecurityGroup, reading the required GroupName and
GroupDescription. Ec2Service makes every other check, so a dry run is
answered before the VPC id, the VPC, the CIDR block, the tenancy,
overlap with other subnets or a taken group name are checked. AWS
documents no order for those checks.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* fix(ec2): look up the VPC before answering a subnet or group dry run
A DryRun CreateSubnet or CreateSecurityGroup naming a VPC that does not
exist answered DryRunOperation, "would have succeeded", while the real
create fails with InvalidVpcID.NotFound. CreateSubnet without a VpcId
answered DryRunOperation too, where the real create gives
MissingParameter.
The handlers now require the VpcId and look up the VPC, the default one
for a security group without a VpcId, before they answer the dry run.
A RunInstances dry run already keeps the error of a missing subnet or
group, and the Service Authorization Reference lists the VPC, with its
tags and tenancy, in both actions' permissions.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* fix(ec2): share the security group VPC lookup with its dry run
The CreateSecurityGroup handler and Ec2Service each picked the group's
VPC, the named one or the region's default, so the two copies could
drift. Ec2Service.requireSecurityGroupVpc now does it for both, and the
CreateSubnet handler looks up the VpcId it has just required.
New tests cover a group dry run with an absent or empty VpcId, which is
answered for the default VPC, and a group dry run in a missing VPC
through the SDK. The comments and docs now name every check a dry run
skips, the zone and the IPv6 block included, and link the Service
Authorization Reference.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* docs(ec2): list the errors a create dry run still returns
The CreateVpc, CreateSubnet and CreateSecurityGroup rows said which
checks a dry run skips but not which errors it keeps. They now say that
a tag specification error, and a missing VpcId, GroupName,
GroupDescription or VPC, comes back on a dry run too, and that an empty
VpcId also puts a security group in the default VPC.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* test(ec2): keep tag errors ahead of the create dry-run answer
CreateVpc, CreateSubnet and CreateSecurityGroup read their tag
specifications before they answer DryRun, so a reserved aws: key is
still rejected on a dry run, as the EC2 docs page says. A handler test
now pins that for all three actions; it fails if the dry-run answer is
moved ahead of the tag parsing.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* test(ec2): use the shared EC2 request helper in the dry-run test
Ec2CreateDryRunIntegrationTest now calls Ec2Requests.ec2 with "test"
and "us-east-1" instead of its own copy of that helper. The comments
in the CreateSubnet and CreateSecurityGroup handlers shrink to one
line each; docs/services/ec2.md already explains the order.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
---------
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
The Service Authorization Reference lists aws:RequestTag/${TagKey} and
aws:TagKeys as condition keys for s3:TagResource, and aws:TagKeys for
s3:UntagResource. botocore's s3control model says where the request
carries them: TagResource's Tags list in the body, UntagResource's
TagKeys in the tagKeys query parameters.
With IAM enforcement on, Floci checked both S3 Control actions with no
request tag keys. A policy that allows TagResource only for certain tag
values, or UntagResource only for certain keys, matched no request, so
a request it allows was denied, and a ForAllValues condition on
aws:TagKeys allowed UntagResource whatever keys it named.
tools/aws/regen_s3control_tag_condition_keys.py now generates
s3control-tag-condition-keys.json from the two sources, as the DynamoDB
condition key table is generated: every s3 action the reference gives
either key, and every S3 Control operation's request members that feed
them, found as the tag-on-create table finds tag members.
IamConditionContextResolver reads it for a request on an S3 Control
route. The make targets check the members offline against the pinned
botocore in CI and the actions online against AWS in the IAM data drift
workflow. S3's own bucket and object tag keys stay as written, since
they were measured against AWS and do not all match the reference.
AWS runs each policy check on every statement before the next check. It answers an Effect other than Allow or Deny with "Invalid effect: <value>", and a malformed Principal or a non-string Effect with "Syntax error at position (-1,-1)".
* fix(lambda): pass LoggingConfig log format and level to the runtime
A function with LogFormat=JSON logged text: neither launcher set AWS_LAMBDA_LOG_FORMAT or AWS_LAMBDA_LOG_LEVEL, which the runtime interface clients read. Both launchers now pass them, and a JSON function without an ApplicationLogLevel gets INFO, the level the API reports, through one default shared with the response.
Closes#6774
* docs(lambda): note the log format and level the runtime receives
* refactor(lambda): build the runtime environment in one place for both launchers
ContainerLauncher and KubernetesPodLauncher wrote the same AWS_LAMBDA_* lines, the LoggingConfig ones included. LambdaRuntimeEnv.of now builds them once.
* fix(ec2): keep the KMS key a volume is created with
CreateVolume ignored KmsKeyId, so neither CreateVolume nor
DescribeVolumes reported kmsKeyId, even for a volume created encrypted
with a named key. A volume CreateVolume makes encrypted now keeps the
request's KmsKeyId as given, or gets the region's default EBS key when
it names none, and both responses report it. A volume that is not
encrypted keeps no key, and volumes stored before this change load as
they were, with no kmsKeyId.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* test(ec2): read volume responses with XmlParser
The volume KMS key tests read CreateVolume and DescribeVolumes
responses with a regular expression, substring offsets and plain
string matches. They now read them with XmlParser, as other EC2 tests
do, so element values are parsed and decoded as XML. Test-only; the
assertions are unchanged.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* fix(ec2): keep the KMS key a launch's block device mapping names
A launch's encrypted volumes got the region's default EBS key even
when their block device mapping, or the launch template's, named
Ebs.KmsKeyId. The key now goes from the mapping to the volume, root
included, and a mapping that names none still gets the default.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* test(ec2): pin the launch volume key rules
Pin that a launch mapping naming a key without Encrypted leaves the
volume unencrypted and keyless, and that a request entry's key wins
over its launch template's. Delete the test's launch template, reuse
the launch helpers in the root-volume test, and document that a launch
volume encrypted only by its snapshot gets the region's default key,
since snapshots record no key.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
---------
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
CreateService dropped a HealthCheckCustomConfig sent as {}. The handler
passed it through rawJson, which returns null for an empty object, so
the CreateService, GetService and ListServices responses left the field
out. Terraform sends {} when failure_threshold is unset and then sees a
change to the block on every plan.
FailureThreshold is no longer supported, and the Cloud Map API
reference says AWS always sets it to 1. The handler now keeps an empty
object for this field, and CloudMapService stores
{"FailureThreshold":1} for any HealthCheckCustomConfig, so a service
created through CloudFormation reads back the same way.
Fixes#6751
A software-token code now answers one SOFTWARE_TOKEN_MFA challenge only. The step of the
last accepted code is stored on the user, and a code from that step or an earlier one fails
with ExpiredCodeException, as AWS does (RFC 6238 section 5.2). VerifySoftwareToken does not
record a step, and activating a new authenticator clears it.
Fixes#6804
ListTagsForResource, TagResource and UntagResource compared the ARN's
account with the configured default account, while the create calls mint
ARNs with the request's account. Any caller outside the default account
was answered ResourceNotFoundException for its own resources.
Compare with the request account instead. An ARN naming another account
or region is still answered ResourceNotFoundException.
Closes#6008
* feat(cloudfront): serve execute-api custom origins of this Floci in-process
A custom origin whose domain is an execute-api endpoint of an HTTP or
REST API in this Floci is now served through Floci's own listener, as
Lambda Web Function endpoints are, with the execute-api domain as Host.
Before, the origin went through DNS and the viewer got 502.
ApiGatewayExecuteApiHostFilter.routes() says whether the host filter
rewrites a host and path onto an API. A request that it does not route
(a WebSocket API, a disabled endpoint, a missing stage, another region)
answers 404 and never reaches Floci's other endpoints. Dot segments in
the forwarded path are resolved before that check. A forwarded viewer
Host answers 502. Every other origin is unchanged.
* refactor(cloudfront): share the execute-api routing decision with the host filter
ApiGatewayExecuteApiHostFilter.decide() returns the routing decision
without touching the request, with its lookups under the API owner's
account. filter() applies the decision and routes() reuses it, so the
two cannot drift.
This fixes two cases where routes() differed from filter(): an HTTP API
owned by another account than the viewer is now served through
CloudFront, and a REST API origin whose region label is not the API's
region now answers 404. The 404 body is one constant.
* refactor(apigateway): keep Optional out of the route decision record
RouteDecision stores the API owner as a nullable value, and the decision
helpers take it as a plain parameter. Optional stays the return type of
the owner lookup only, as AGENTS.md asks.
* refactor(cloudfront): name the ignored host parse failure and drop the Optional test field
---------
Co-authored-by: liRONCO11 <7966063+liRONCO11@users.noreply.github.com>
* fix(ecs): reclaim anonymous task volumes
Opt ECS lifecycle cleanup into anonymous-volume removal while preserving named volumes, shared defaults, admission and retries. Retain actual Docker regression coverage.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* fix(ecs): reclaim volumes after rejected task starts
Use the existing ephemeral lifecycle path for ordinary task containers so Docker start failures reclaim anonymous volumes before ECS records the container. Preserve named volumes and shared defaults, close fixture callbacks, and retain a real Docker rejected-entrypoint regression.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
---------
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
AWS blocks an Allow whose principal is Federated unless its values include "*" or a trusted condition pins the caller. It checks no pattern on Federated or CanonicalUser values.
GetPackageVersionAsset already 404s an Archived or Disposed version's bytes,
but the native per-format passthroughs (Maven's GAV path, npm's tarball
route, pypi's filename route, nuget's content route) proxied straight to
their own sidecar with no awareness of that override, so a plain mvn/npm/
pip/nuget client could still download an Archived version's real bytes.
Disposed already self-resolves: DisposePackageVersions genuinely deletes the
sidecar's own bytes, so those routes already 404 for the real reason, nothing
to add there. Archived is the real gap, closed the same way for all four
formats via one new CodeArtifactService#requireContainerBackedVersionDownloadable
check, called right before each controller's own proxy:
- Maven and nuget already carry namespace/package/version as path params, so
this is a direct call.
- npm's tarball GET has no version as its own path segment, only embedded in
the filename; detected with the same `/-/` marker-splitting technique
nativeUnpublishTarget already uses for its own `/-rev/` marker.
- pypi's download route is a bare filename with no package name or version
anywhere in the URL at all, so the coordinate is resolved by matching the
filename against this repository's own Archived/Disposed status overrides,
the same way the upload-side guard already does. Whichever path put the file
there (a native upload or CopyPackageVersions), a later status override is
found the same way.
- npm resolves the requested tarball's real version against Verdaccio's own
packument (dist.tarball), and only when the package has a status override
at all.
Verified live against all four real sidecar containers (Reposilite,
Verdaccio, pypiserver, BaGetter): archive a version, confirm the download
404s while the real file is still present, then un-archive and confirm the
exact same bytes come back unchanged.
The upstream drift check reported the table of the resources requests
name as incomplete: AWS's Service Reference has published operations
it does not list. Regenerated with `make iam-request-resources-sync`,
no entry edited by hand:
- ECR's DescribeReplicationBackfillResults, ListReplicationBackfills,
StartReplicationBackfill and StopReplicationBackfill, published since
the table was generated on 2026-10-26, come in. The Service Reference
gives none of them a resource type, so each is checked on `*`, as it
was while the table did not list it. Floci does not serve them.
- `codestar` leaves the namespaces the table does not read, as it left
the IAM service namespace list in #6706: the Service Reference no
longer publishes it.
Nothing a request is checked on changes: 373 operations over the same
5 namespaces, the 369 already listed unchanged.
In the docker runner mode a step that was not a Spark step failed
without running, so a cluster whose steps copy files with the AWS CLI,
run a shell or Python script, or call script-runner.jar could not run
its steps in Floci. Such steps now run in the same per-step container
of the release's EMR Serverless image, with the same credentials,
endpoint, logs and lifecycle as a Spark step, as the Release Guide's
"Run commands and scripts on an Amazon EMR cluster" describes them:
- command-runner.jar runs its arguments as a command, the first naming
it, unless that is spark-submit (the Spark step, as before) or a tool
the image does not have: hive-script, pig-script, hadoop-streaming,
hadoop-lzo and s3-dist-cp still fail without running.
- script-runner.jar, by name (7.13 on) or by its
s3://<region>.elasticmapreduce/libs/script-runner/script-runner.jar
URI, fetches its script from S3 with the image's AWS CLI and the
step's credentials, then runs it with the step's other arguments. A
local script named without a path runs from the working directory
when a file there has that name.
The image runs them as its hadoop user in /home/hadoop, with bash,
Python 3, Java, curl and AWS CLI v2, which reaches Floci through
AWS_ENDPOINT_URL. A spark-submit they start runs in local mode on
Floci's S3 with the cluster's spark-defaults: the image's
spark-defaults.conf names EMR Serverless's resource manager as its
master, which a system property cannot override, so the container
starts through a wrapper that copies the image's Spark configuration,
drops that master, and adds local mode, Floci's settings and the
cluster's spark-defaults, in a SPARK_CONF_DIR of its own, each setting
escaped for the Properties file Spark reads it as. A step's own --conf
still wins. A failed command reads "The step's command exited
with code N.".
SparkJobRunner.Job gets a command, run in place of spark-submit.
Bound the FireLens socket volume name while retaining full ownership labels and cleanup retries, and validate the inspected host path before creating containers.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
Select runtime images with the effective Docker platform while preserving runtime-wide defaults, explicit platform precedence and code-volume helper platform.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* feat(redshift): support event history and SNS notifications
* fix(redshift): guard stale delivery failures and prune all event scopes
* feat(cloudformation): provision Redshift event subscriptions
* fix(redshift): scope snapshot events and serialize subscription tag mutations
* feat(cloudformation): provision Redshift event subscriptions
* fix(cloudformation): resolve Redshift subscription list parameters
Use the shared list reader for SourceIds and EventCategories. Cover CommaDelimitedList and List<String> parameters through the AWS SDK and verify concurrent tag requests preserve CloudFormation tag updates.
* fix(redshift): honor event disablement and restore rollback attributes
Check the EventBridge external service key before publishing API events. Snapshot and restore CloudFormation resource attributes alongside subscription state during in-place rollback.
* fix(redshift): drop API event publisher and share subscription setup
Remove RedshiftApiEventPublisher, its handler hook, tests and docs, which are not part of the CloudFormation resource and emit CloudTrail-style events without a trail. Route createSubscription and replaceSubscription through one helper that normalizes the subscription fields.
* fix(ec2): reject unsupported future capacity reservations
Reject StartDate before capacity reservation creation or client-token replay. Preserve immediate reservation behavior.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* fix(ec2): model scheduled capacity reservations
Retain future start and commitment metadata, activate through capacity reconciliation, and preserve client-token replay.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* fix(ec2): preserve activation membership and replay tags
Reuse open-reservation instance matching during activation, persist creation tag identity, and keep replay from overwriting later tag edits.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* fix(ec2): validate future reservation matching and capacity
Require targeted matching, supported instance families and at least 32 vCPUs before future reservation publication. Preserve scheduling, tag replay and immediate reservation behavior.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
---------
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* feat(redshift): publish CloudWatch cluster metrics
* fix(redshift): skip duplicate CloudWatch publication minutes
* test(redshift): isolate metrics publisher between integration tests
* fix(test): use Java 17 list access in Redshift metrics compatibility test
* fix(metrics): share minute publishing and prevent duplicate SQS samples
Centralize daemon scheduling, minute claims, per-target failures, retention and shutdown for SQS and Redshift. Carry the Redshift proxy key in metric targets and use the shared compatibility await fixture.
* docs(metrics): restore publisher class docs after the shared publisher move
Keep the SQS sample shape on SqsMetricsPublisher and document minute stamping, 15-day retention and the nothing-may-escape rule on MinuteMetricsPublisher.
* feat(lambdaweb): reject resource policies whose principal does not exist
PutResourcePolicy now looks up every AWS principal a policy names, as Lambda
does before it stores the policy. A role or user ARN has to name one IAM
holds in that account, under its own path, and a unique id one in the
function's account. A missing principal, an assumed-role session, a
CanonicalUser or an ARN in another partition gets the invalid principal
message, and a role or user named under another path gets the message
that the ARN does not match the actual one.
The principals are looked up after every statement passes its other
checks and before any statement is refused as public, which is the order
AWS checks them in.
* docs(lambdaweb): drop the principal check from the items not implemented yet
* refactor(lambdaweb): find policy principals through IamService and the resolver's partition
IamService.heldPrincipalArn now gives the ARN IAM holds what a principal
ARN names under, the root as given or the role or user at its own path.
DSQL's principal check and Lambda Web's use it, and Lambda Web keeps only
the path comparison and its messages. Lambda Web takes the partition from
RegionResolver.partitionForRegion, so a custom region falls back to the
deployment's partition.
With AutoPublishAlias, SAM passes a function's VersionDescription to the
Description of the AWS::Lambda::Version it generates. The transform
dropped it, so a version published from a SAM template never had the
description the template gave it.
The version now takes it as written, leaving an intrinsic function for
CloudFormation to resolve. As in SAM, it stays out of the hash that
names the version, and Globals cannot set it: the transform refuses it
there, as it already refuses AutoPublishCodeSha256.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
Handle both documented default-subnet filter aliases and preserve safe asynchronous ENI cleanup.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* fix(stepfunctions): paginate ListExecutions
Honor maxResults and nextToken after applying statusFilter, with newest-first scoped cursors. Add regression coverage for continuation pages and token isolation.
* fix(stepfunctions): snapshot ListExecutions status
* fix(stepfunctions): order terminal executions by stop time
* fix(stepfunctions): expire signed ListExecutions tokens
* fix(stepfunctions): compact ListExecutions continuation scope
* fix(stepfunctions): reuse expiring history pagination
* fix(stepfunctions): validate history token before execution lookup
* refactor(apigateway): decide execute-api host routing before applying it
ApiGatewayExecuteApiHostFilter.decide() returns a RouteDecision for a
host and path without touching the request. filter() applies it:
account and region of the API owner, the REST or HTTP API rewrite, or
the 404 for a disabled endpoint. The lookups for an API with an owner
run under the owner's account, and the caller's account and region are
restored afterwards. No change in behavior for execute-api requests.
* test(apigateway): give the API owner its own region in the restore tests
The owner and the caller used the same region, so the tests passed even
if underAccountOf() did not restore the caller's region. The owner now
uses eu-west-1, and each restore test asserts the caller's region.
---------
Co-authored-by: liRONCO11 <7966063+liRONCO11@users.noreply.github.com>
Each var now names the type javac inferred for it, and each fully qualified type name is
imported instead. The suppression list keeps only the files that open pull requests edit.
A PutEvents entry naming an event bus that does not exist failed with
InvalidArgument "EventBus not found" and counted in FailedEntryCount.
The EventBridge User Guide, on handling PutEvents failures: "If you use
PutEvents to publish an event to an event bus that does not exist,
EventBridge event matching will not find a corresponding rule and will
drop the event. Although EventBridge will send a 200 response, it will
not fail the request or include the event in the FailedEntryCount value
of the request response." botocore models no not-found error for
PutEvents, only InternalException, and the API Reference lists none.
Such an entry is now answered as published, with an event id and not
counted as failed, and dropped: it reaches no rule and no archive.
Floci logs the drop at INFO. An entry that is not valid, missing a
required field or with a Detail that is no JSON object, still fails as
before, whichever bus it names.
Only the PutEvents action changes. Floci's own deliveries to a bus, for
a rule's event bus target, a pipe, a schedule, a Lambda destination or
a replay, still fail an entry for a bus that does not exist: the
guide's sentence is about the action, and no document says how AWS
answers those deliveries.
Step Functions' optimized events:putEvents integration calls the
action, so a task publishing to a missing bus no longer fails with
EventBridge.FailedEntry; step-functions.md listed that as a deviation,
which is gone. Its two tests that used a missing bus to have an entry
rejected now leave out the entry's Source instead, and a third checks
that a task publishing to a missing bus succeeds.
* feat(lambda): list provisioned concurrency configurations
Dispatch List=ALL to a paginated view of existing provisioned concurrency allocations. Preserve qualified ARNs, current status and existing pool lifecycle.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* fix(lambda): share function ARN region resolution
Share the existing Lambda region validation and error message across function resolution and provisioned-concurrency lookup/listing.
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
---------
Signed-off-by: Andre Kurait <akurait@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>