Development record
launch.ParseSemver discards strconv.Atoi's range error (major,_ := ...), and semverRe's numID is unbounded, so a >int64 version component clamps to MaxInt64: distinct oversized versions collide to one String() and the next Patch++ wraps negative — reachable via GitExistingTags (git tag list) and changelog.DeriveNext; the identical defect was already guarded in spec/spec.go
launch.ParseSemver discards strconv.Atoi's range error (major,_ := ...), and semverRe's numID is unbounded, so a >int64 version component clamps to MaxInt64: distinct oversized versions collide to one String() and the next Patch++ wraps negative — reachable via GitExistingTags (git tag list) and changelog.DeriveNext; the identical defect was already guarded in spec/spec.go
Evidence
internal/core/launch/semver.go—ParseSemverdoesmajor, _ := strconv.Atoi(m[1])(minor/patch likewise), discardingstrconv's out-of-range error;semverRe'snumID(0|[1-9]\d*) is unbounded andIsStrictSemvershares it, so no upstream cap rejects a 20-digit component.Atoiclamps overflow toMaxInt64: two distinct oversized inputs collide to oneString(), andPatch++wraps toMinInt64(a negative version).- Reachable via
internal/core/launch/retention.goGitExistingTags(parsesgit tag) intoComputeRetention, and viainternal/core/changelogLatestChangelogVersionintoDeriveNextwherenext.Patch++overflows. - The identical
Atoi-overflow defect is already guarded one package over ininternal/core/spec/spec.go(specNum).
Adversarial review
CONFIRMED (substantive, low-impact end) by an independent refuter: overflow reproduced;
both reach paths route through the swallowed error; the fetched-ref threat model the sibling
fix names does not exclude git tags / CHANGELOG headings. Fix: have ParseSemver propagate
the strconv.Atoi error (both arithmetic consumers already handle a non-nil error).
Frontmatter
| id | iss-293 |
|---|---|
| type | issue |
| lifecycle | resolved |
| severity | minor |
.abcd/work/issues/resolved/iss-293-launch-parsesemver-discards-strconv-atoi.md
open on GitHub ↗ · commit history ↗
mentions2
- dcn-26081900000000032026-08-19 — bughunt round 1 (branch bughunt-b/round-1): captured iss-291..iss-304 and fixed
- dcn-26082000000000032026-08-20 — Bug-hunt round 1 (hunt A), landed late: the round ran 2026-08-19 on a branch that