mirror of
https://github.com/floci-io/floci.git
synced 2026-11-22 21:50:46 -05:00
fix(iam): pass Cognito identity pool roles to cognito-identity and resync the PassRole table (#7273)
This commit is contained in:
1 parent
699d472f20
commit
39a5a60edc
3 files changed
+11
-8
No files matched your search
@@ -1,8 +1,8 @@
|
||||
{
|
||||
"_source": {"generator": "tools/aws/regen_iam_passed_roles.py", "reference": "https://servicereference.us-east-1.amazonaws.com/", "botocore": "botocore 1.43.113 (installed package)", "retrieved": "2026-10-24", "note": "make iam-passed-roles-check re-derives every member from botocore; make iam-passed-roles-verify checks every operation against AWS."},
|
||||
"_source": {"generator": "tools/aws/regen_iam_passed_roles.py", "reference": "https://servicereference.us-east-1.amazonaws.com/", "botocore": "botocore 1.43.118 (local/aws/botocore)", "retrieved": "2026-11-02", "note": "make iam-passed-roles-check re-derives every member from botocore; make iam-passed-roles-verify checks every operation against AWS."},
|
||||
"namespaces": {"application-autoscaling": ["application-autoscaling"], "athena": ["athena"], "autoscaling": ["autoscaling"], "budgets": ["budgets"], "cloudformation": ["cloudcontrol", "cloudformation"], "cloudtrail": ["cloudtrail"], "cloudwatch": ["cloudwatch", "cloudwatchomni"], "codebuild": ["codebuild"], "codedeploy": ["codedeploy"], "codepipeline": ["codepipeline"], "cognito-identity": ["cognito-identity"], "cognito-idp": ["cognito-idp"], "comprehend": ["comprehend"], "config": ["config"], "datasync": ["datasync"], "dms": ["dms"], "dsql": ["dsql"], "ec2": ["ec2"], "ecr": ["ecr"], "ecs": ["ecs"], "eks": ["eks"], "elasticmapreduce": ["emr"], "events": ["eventbridgev2", "events"], "firehose": ["firehose"], "glue": ["glue"], "iam": ["iam"], "kinesis": ["kinesis"], "kinesisanalytics": ["kinesisanalytics", "kinesisanalyticsv2"], "lambda": ["lambda", "lambda-core", "lambda-microvms", "lambda-web"], "logs": ["logs"], "pipes": ["pipes"], "rds": ["docdb", "neptune", "rds"], "redshift": ["redshift"], "redshift-serverless": ["redshift-serverless"], "rekognition": ["rekognition"], "resource-groups": ["resource-groups"], "s3": ["s3", "s3control"], "sagemaker": ["sagemaker"], "scheduler": ["scheduler"], "secretsmanager": ["secretsmanager"], "servicecatalog": ["servicecatalog"], "ses": ["mailmanager", "pinpoint-email", "ses", "sesv2"], "sns": ["sns"], "ssm": ["ssm"], "states": ["stepfunctions"], "swf": ["swf"], "textract": ["textract"], "transcribe": ["transcribe"], "transfer": ["transfer"], "translate": ["translate"]},
|
||||
"notCovered": {"access-analyzer": "REST routes no rule maps yet", "airflow": "REST routes no rule maps yet", "apigateway": "authorized by HTTP method, so no request is checked as one of these operations", "appconfig": "REST routes no rule maps yet", "appsync": "REST routes no rule maps yet", "aps": "REST routes no rule maps yet", "aws-marketplace": "REST routes no rule maps yet", "backup": "REST routes no rule maps yet", "batch": "REST routes no rule maps yet", "bedrock": "REST routes no rule maps yet", "bedrock-agentcore": "REST routes no rule maps yet", "cloudfront": "REST routes no rule maps yet", "dlm": "REST routes no rule maps yet", "elasticfilesystem": "REST routes no rule maps yet", "emr-serverless": "REST routes no rule maps yet", "es": "REST routes no rule maps yet", "fis": "REST routes no rule maps yet", "guardduty": "REST routes no rule maps yet", "iot": "REST routes no rule maps yet", "kafka": "REST routes no rule maps yet", "macie2": "REST routes no rule maps yet", "mq": "REST routes no rule maps yet", "rum": "REST routes no rule maps yet", "s3tables": "REST routes no rule maps yet"},
|
||||
"otherNamespaces": ["agent-registry", "aidevops", "aiops", "airflow-serverless", "amplify", "aoss", "appflow", "appmesh", "apprunner", "appstream", "arc-region-switch", "backup-gateway", "backup-search", "bcm-dashboards", "braket", "chatbot", "chime", "cleanrooms", "cleanrooms-ml", "codeconnections", "codestar-connections", "cognito-sync", "comprehendmedical", "databrew", "dataexchange", "datapipeline", "datazone", "dax", "deadline", "devicefarm", "elemental-inference", "emr-containers", "entityresolution", "fms", "forecast", "frauddetector", "gamelift", "gameliftstreams", "geo", "grafana", "greengrass", "groundstation", "health-agent", "healthlake", "imagebuilder", "inspector", "iotdeviceadvisor", "iotfleetwise", "iotmanagedintegrations", "iotsitewise", "iottwinmaker", "iotwireless", "kafkaconnect", "kendra", "lex", "lookoutequipment", "m2", "machinelearning", "mediaconnect", "mediaconvert", "medialive", "mediapackage", "mediapackage-vod", "mediapackagev2", "mediastore", "medical-imaging", "mobiletargeting", "neptune-graph", "observabilityadmin", "odb", "omics", "opensearch", "osis", "partnercentral", "pcs", "personalize", "profile", "proton", "qbusiness", "quicksight", "repostspace", "resiliencehub", "rolesanywhere", "s3files", "sagemaker-geospatial", "securityagent", "securitylake", "shield", "sms-voice", "snowball", "social-messaging", "ssm-incidents", "ssm-quicksetup", "storagegateway", "supportapp", "synthetics", "timestream", "voiceid", "wellarchitected", "wisdom", "workmail", "workspaces"],
|
||||
"otherNamespaces": ["agent-registry", "aidevops", "aiops", "airflow-serverless", "amplify", "aoss", "appflow", "appmesh", "apprunner", "appstream", "arc-region-switch", "backup-gateway", "backup-search", "bcm-dashboards", "braket", "chatbot", "chime", "cleanrooms", "cleanrooms-ml", "codeconnections", "codestar-connections", "cognito-sync", "comprehendmedical", "databrew", "dataexchange", "datapipeline", "datazone", "dax", "deadline", "devicefarm", "elemental-inference", "emr-containers", "entityresolution", "fms", "forecast", "frauddetector", "gamelift", "gameliftstreams", "geo", "grafana", "greengrass", "groundstation", "health-agent", "healthlake", "imagebuilder", "iotdeviceadvisor", "iotfleetwise", "iotmanagedintegrations", "iotsitewise", "iottwinmaker", "iotwireless", "kafkaconnect", "kendra", "lex", "lookoutequipment", "m2", "machinelearning", "mediaconnect", "mediaconvert", "medialive", "mediapackage", "mediapackage-vod", "mediapackagev2", "mediastore", "medical-imaging", "mobiletargeting", "neptune-graph", "observabilityadmin", "odb", "omics", "opensearch", "osis", "partnercentral", "pcs", "personalize", "profile", "proton", "qbusiness", "quicksight", "repostspace", "resiliencehub", "rolesanywhere", "s3files", "sagemaker-geospatial", "securityagent", "securitylake", "shield", "sms-voice", "snowball", "social-messaging", "ssm-incidents", "ssm-quicksetup", "storagegateway", "supportapp", "synthetics", "timestream", "voiceid", "wellarchitected", "wisdom", "workmail", "workspaces"],
|
||||
"operations": {
|
||||
"application-autoscaling:RegisterScalableTarget": {"passedTo": ["application-autoscaling"], "byHand": "the scalable target's role"},
|
||||
"athena:CreateWorkGroup": {"passedTo": ["athena"], "roles": [
|
||||
@@ -134,9 +134,9 @@
|
||||
{"member": "pipeline.stages[].onFailure.conditions[].rules[].roleArn", "passedTo": "codepipeline"},
|
||||
{"member": "pipeline.stages[].onSuccess.conditions[].rules[].roleArn", "passedTo": "codepipeline"}
|
||||
]},
|
||||
"cognito-identity:SetIdentityPoolRoles": {"passedTo": [], "roles": [
|
||||
{"member": "RoleMappings{}.RulesConfiguration.Rules[].RoleARN"},
|
||||
{"member": "Roles{}"}
|
||||
"cognito-identity:SetIdentityPoolRoles": {"passedTo": ["cognito-identity"], "roles": [
|
||||
{"member": "RoleMappings{}.RulesConfiguration.Rules[].RoleARN", "passedTo": "cognito-identity"},
|
||||
{"member": "Roles{}", "passedTo": "cognito-identity"}
|
||||
]},
|
||||
"cognito-idp:CreateGroup": {"passedTo": [], "roles": [
|
||||
{"member": "RoleArn"}
|
||||
@@ -409,7 +409,7 @@
|
||||
{"member": "ExecutionEngine.ExecutionRoleArn"},
|
||||
{"member": "ServiceRole", "byName": true}
|
||||
]},
|
||||
"elasticmapreduce:StartSession": {"passedTo": ["elasticmapreduce"], "roles": [
|
||||
"elasticmapreduce:StartSession": {"passedTo": ["elasticmapreduce", "managed-compute.elasticmapreduce"], "roles": [
|
||||
{"member": "ExecutionRoleArn", "passedTo": "elasticmapreduce"}
|
||||
]},
|
||||
"elasticmapreduce:UpdateStudio": {"passedTo": [], "notRead": "no member of the request names a role"},
|
||||
|
||||
@@ -683,8 +683,8 @@ class PassedRolesTest {
|
||||
PassedRoles.of("glue:CreateJob", json("{\"Name\":\"j\",\"Role\":\"app-role\"}"), LOOKUPS));
|
||||
assertEquals(List.of(passed("gone", "glue.amazonaws.com")),
|
||||
PassedRoles.of("glue:CreateJob", json("{\"Name\":\"j\",\"Role\":\"gone\"}"), LOOKUPS));
|
||||
// An identity pool's roles are the values of a map, which the Service Reference passes to no service.
|
||||
assertEquals(List.of(new PassedRole(ROLES + "authenticated", null)), PassedRoles.of(
|
||||
// An identity pool's roles are the values of a map, each passed to Cognito Identity.
|
||||
assertEquals(List.of(passed("authenticated", "cognito-identity.amazonaws.com")), PassedRoles.of(
|
||||
"cognito-identity:SetIdentityPoolRoles", json("{\"IdentityPoolId\":\"p\",\"Roles\":{\"authenticated\":\""
|
||||
+ ROLES + "authenticated\"}}"), LOOKUPS));
|
||||
// A member taking only an ARN passes nothing for a name.
|
||||
|
||||
@@ -393,6 +393,9 @@ MEMBER_SERVICES = {
|
||||
"taskRoleArn": ECS_TASKS,
|
||||
"infrastructureRoleArn": ECS_INFRASTRUCTURE,
|
||||
},
|
||||
# "Amazon EMR uses this role" for the session. The reference also lists
|
||||
# managed-compute.elasticmapreduce, but the request cannot say which compute it runs on.
|
||||
"elasticmapreduce:StartSession": {"ExecutionRoleArn": "elasticmapreduce"},
|
||||
# rds-preview is the principal of RDS's preview environment; PassedRoles' RDS cases pass to rds.
|
||||
"rds:*": {"*": "rds"},
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user