• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

nats-io / nats-server / 20705553599

01 Jan 2026 12:14PM UTC coverage: 84.609% (-0.01%) from 84.62%
20705553599

push

github

web-flow
[FIXED] Filestore with encryption may erroneously reset meta.key (#7678)

If a server was hard killed and was not able to write the `index.db`
file, or it was corrupted, it would allow the stream to be loaded but
without initializing the keys used for encrypting the `meta.inf` and
`index.db` files. The next graceful shutdown would generate the
`index.db` file, but in so doing would regenerate the `meta.key` as
well. On startup the stream would not be able to load since the
`meta.key` was new, but the `meta.inf` was still encrypted with the old
key.

This PR proposes to simply always recover the keys if the key file
exists, and not rely on the `index.db` recovery path.

Signed-off-by: Maurice van Veen <github@mauricevanveen.com>

74105 of 87585 relevant lines covered (84.61%)

361855.38 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

54.4
/src/github.com/nats-io/nats-server/server/jetstream_errors_generated.go


Source Not Available

The file "src/github.com/nats-io/nats-server/server/jetstream_errors_generated.go" isn't available on github. Either it's been removed, or the repo root directory needs to be updated.

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc