aws-samples / aws-samples/sample-autonomous-cloud-coding-agents

chore(compute): re-tighten MicroVM-facing IAM if AWS exposes usable condition keys

Offen
#736 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
TypeScript
Sterne
143
Forks
46
Ø Merge
3 T. 9 Std.
Gemergte PRs (30 T.)
20

Beschreibung

### Context

ADR-021's Lambda MicroVMs backend runs with deliberately relaxed IAM in two places, both proven necessary by controlled live experiments (evidence: ADR-021 §4 + `docs/verification/645-p2-smoke-runbook.md`):

1. **Role trust**: the build, execution, and connector-operator roles trust `lambda.amazonaws.com` with **no** `aws:SourceAccount`/`aws:SourceArn` condition — the service presents no source key when assuming them (conditioned trust → deterministic `CREATE_FAILED` / unassumable role).
2. **PassRole**: the orchestrator's grant on the execution role and the bootstrap `MicrovmPassRoles` statement carry **no** `iam:PassedToService` condition — the condition is denied on the `RunMicrovm` and CloudFormation paths (two-arm experiments, verbatim denials in the ADR). Candidate service principals (`microvms.lambda.amazonaws.com` etc.) were all `implicitDeny`, and CloudTrail emits no `lambda-microvms` events, so the value the authorizer would match cannot currently be observed.

Compensating controls in place: exact-ARN / name-prefix resource scoping, backend-conditional bootstrap policy, orchestrator-only pass path for the execution role.

### Ask

When AWS documents (or the service starts presenting) usable condition keys for Lambda MicroVMs role assumption and PassRole:
- add the trust conditions back to all three roles
- restore `iam:PassedToService` on both PassRole grants
- delete the compensating-control prose from ADR-021 §4 / SECURITY.md / DEPLOYMENT_ROLES.md

The ADR says "revisit if AWS documents it" — this issue is that revisit's handle. Consider also raising via internal AWS channels: the service team may simply need to publish the authorization-context documentation.

Refs #645, PR #733, ADR-021.

Beitragsleitfaden

Beitragsleitfaden öffnen

Rechercherichtung

Beginne mit ADR-021 §4 und docs/verification/645-p2-smoke-runbook.md und prüfe anschließend die drei im Issue beschriebenen Trust Policies der Rollen sowie die beiden PassRole-Berechtigungen. Fahre erst fort, sobald AWS nutzbare Lambda MicroVM Condition Keys dokumentiert oder bereitstellt; als abgeschlossen gilt dies, wenn die Trust- und iam:PassedToService-Bedingungen wiederhergestellt und die Ausführungen zu den Ausgleichskontrollen aus ADR-021 §4, SECURITY.md und DEPLOYMENT_ROLES.md entfernt wurden.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
aws
Bereich
authorization, cloud, security
Issue-Typ
Feature
Schwierigkeit
5/5
Geschätzter Aufwand
Über eine Woche
Aktivitätsstatus
Ruhig
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
25/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.