Skip to content

Release v0.8.2: merge upstream ancestry and protocol fix - #26

Merged
canesin merged 16 commits into
mainfrom
sync/sep25
Sep 26, 2026
Merged

canesin merged 16 commits into
mainfrom
sync/sep25

Conversation

@canesin

@canesin canesin commented Sep 26, 2026

Copy link
Copy Markdown

Description

Merge sync/sep25 into main and prepare Mori v0.8.2. Use a merge commit to retain the original upstream commits and the ancestry reconciliation from #25.

Retained dead/left node records no longer reject push/pull exchanges because they spoke an older core or delegate protocol. Alive and suspect peers still undergo compatibility checks; malformed version vectors are rejected in every state. The Go API and wire encoding are unchanged.

The changelog records v0.8.2 and leaves an empty Unreleased section for subsequent work. After this PR merges and main's checks pass, tag the merge commit v0.8.2 and publish its release notes.

Validation

  • CGO_ENABLED=0 GOTOOLCHAIN=local make ci passes with Go 1.27.1, including amd64/386 tests, race detection (the cgo exception), lint, cross builds, dependency audit, and benchmark smoke.
  • The implementation in Sync upstream memberlist ancestry into sync/sep25 #25 passed all four fuzz targets with make fuzz-smoke FUZZ_TIME=5s (about 3.1 million executions); this PR additionally runs the CI fuzz smoke.
  • No codec or wire encoding changes; the differential oracle is not required.
  • Regression tests cover core/delegate versions, local/remote records, all four node states, and malformed version vectors. Before the fix, all eight dead/left cases failed; representative output from Sync upstream memberlist ancestry into sync/sep25 #25:
--- FAIL: TestVerifyProtocolRetiredNodes (0.00s)
    --- FAIL: TestVerifyProtocolRetiredNodes/core/local/dead (0.00s)
        state_test.go:2385: verifyProtocol = Node 'old' protocol version (1) is incompatible: [2, 5], want compatible=true
    --- FAIL: TestVerifyProtocolRetiredNodes/delegate/remote/left (0.00s)
        state_test.go:2385: verifyProtocol = Node 'old' delegate protocol version (1) is incompatible: [2, 5], want compatible=true
FAIL

After the fix, the focused tests and full gates passed. Full conflict-resolution and validation details are in #25.

Checklist

  • make ci passes; no wire encoding or decoder changes.
  • Behavioral changes have tests, documentation and a changelog entry, promoted to v0.8.2 for this release.
  • AI usage guide read and followed; final changes reviewed and validated locally.

joakimhellum and others added 16 commits July 14, 2026 10:33
readUserMsg sizes make([]byte, header.UserMsgLen) from the wire header with no bound, so a small userMsg frame declaring a large length forces a large allocation on the receiver. This is the userMsg path of the same issue hashicorp#357 fixed for push-pull state.

Fixes: hashicorp#360
decompressBuffer drains the LZW reader with io.Copy into an unbounded buffer, so a small compressMsg expands without limit and can exhaust memory. Cap the output at maxDecompressedBytes with io.CopyN and error past it.
The `make test` target is missing the argument to `-count`, which causes it to fail.
…oup (hashicorp#365)

Bumps the actions group with 1 update: [actions/setup-go](https://github.com/actions/setup-go).


Updates `actions/setup-go` from 6.5.0 to 7.0.0
- [Release notes](https://github.com/actions/setup-go/releases)
- [Commits](actions/setup-go@924ae3a...b7ad1da)

---
updated-dependencies:
- dependency-name: actions/setup-go
  dependency-version: 7.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
  dependency-group: actions
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Add memberlist security model document
If a compressed message is empty after decompression, the `readStream` method
will attempt to index into it and panic. Do a length check here and treat such
malformed messages as an error.

Ref: https://hashicorp.atlassian.net/browse/PSA-2897
Ref: https://hashicorp.atlassian.net/browse/NMD-1624
The protocol version array is not length-checked everywhere, which can result in
a panic if we deference a Vsn off the wire that's short.

Ref: https://hashicorp.atlassian.net/browse/PSA-2897
Ref: https://hashicorp.atlassian.net/browse/NMD-1624
…oup (hashicorp#372)

Bumps the actions group with 1 update: [actions/checkout](https://github.com/actions/checkout).


Updates `actions/checkout` from 7.0.0 to 7.0.1
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](actions/checkout@9c091bb...3d3c42e)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 7.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: actions
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…corp#373)

Bumps the go group with 1 update: [github.com/hashicorp/go-metrics](https://github.com/hashicorp/go-metrics).


Updates `github.com/hashicorp/go-metrics` from 0.6.0 to 0.6.1
- [Release notes](https://github.com/hashicorp/go-metrics/releases)
- [Commits](hashicorp/go-metrics@v0.6.0...v0.6.1)

---
updated-dependencies:
- dependency-name: github.com/hashicorp/go-metrics
  dependency-version: 0.6.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: go
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps the go group with 2 updates: [github.com/miekg/dns](https://github.com/miekg/dns) and [github.com/stretchr/testify](https://github.com/stretchr/testify).


Updates `github.com/miekg/dns` from 1.1.72 to 1.1.73
- [Commits](miekg/dns@v1.1.72...v1.1.73)

Updates `github.com/stretchr/testify` from 1.11.1 to 1.12.1
- [Release notes](https://github.com/stretchr/testify/releases)
- [Commits](stretchr/testify@v1.11.1...v1.12.1)

---
updated-dependencies:
- dependency-name: github.com/miekg/dns
  dependency-version: 1.1.73
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: go
- dependency-name: github.com/stretchr/testify
  dependency-version: 1.12.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: go
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Remove the go-metrics compatibility shim so that downstream consumers no longer need build tags.
…corp#378)

The v0.7.0 release removed support for emitting metrics using the legacy
armon/go-metrics module. Update the README to match the current state.

updates 1c8e675

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Record upstream ancestry through 9378459. Preserve Mori implementations of the security fixes, standard-library-only metrics and codec, contributor documentation, and pinned CI gates, which already incorporate or supersede these upstream changes.

Validation: make ci passes with Go 1.27.1.
Dead and left records may retain older core or delegate versions after a rolling upgrade. Exclude them from speaking-version checks while preserving validation of every remote version vector and compatibility checks for alive and suspect peers.

Add regression coverage for both local and remote records and malformed vectors in every state. Validation: RED on eight retired-node cases, GREEN focused tests, make ci, and all four fuzz smoke targets.
@canesin
canesin merged commit 16fbfcf into main Sep 26, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants