fix(lambda,iam): GetFunctionConcurrency empty, GetUser stable, UpdateRole keeps Description#2014
Merged
Conversation
…Role keeps Description Three contained correctness fixes from the cycle-6 bug audit. - Lambda GetFunctionConcurrency returned `ReservedConcurrentExecutions: 0` for a function with no reserved concurrency. In Lambda, 0 means "throttle to zero" — the opposite of unset — so Terraform/clients read the function as fully throttled. AWS returns an empty body when none is configured; now we do too. - IAM GetUser with no UserName fabricated a brand-new random user (fresh AIDA id + now() date) on every call. It now resolves the caller from their access key id and returns that real user when present, otherwise a stable synthetic identity (deterministic id/date) so repeated calls and follow-ups by the returned name are consistent. - IAM UpdateRole cleared Description whenever it was omitted, so `update-role --max-session-duration ...` silently wiped the description. Description and MaxSessionDuration are independent optionals; Description is now only changed when supplied. Adds e2e tests for each.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bug-hunt batch 3 (cycle 6). Three contained correctness fixes.
ReservedConcurrentExecutions: 0for a function with no reserved concurrency — but0means "throttle to zero" in Lambda, the opposite of unset, so Terraform reads false drift. AWS returns an empty body when none is configured.now()date) every call. Now resolves the caller from their access-key id and returns that real user, otherwise a stable synthetic identity (deterministic id/date) so repeated calls + follow-ups are consistent.Descriptionwhenever it was omitted, soupdate-role --max-session-duration ...silently wiped it. Description and MaxSessionDuration are independent optionals; Description is now only changed when supplied.Tests
E2E for each: empty-vs-set concurrency round-trip, GetUser determinism, UpdateRole preserves description. iam lib suite (496) green.
Builds clean;
clippy --all-targets -D warningsclean; fmt clean.Summary by cubic
Fixes Lambda reserved concurrency, IAM GetUser resolution, and IAM UpdateRole description handling to match AWS and prevent drift or accidental wipes.
Written for commit 9b8d56c. Summary will update on new commits.