Skip to content

doc: document crypto RNG behaviour across snapshot/checkpoint restore - #67342

Closed
Fuma2514 wants to merge 1 commit into
nodejs:mainfrom
Fuma2514:doc-crypto-snapshot-reseed
Closed

Fuma2514 wants to merge 1 commit into
nodejs:mainfrom
Fuma2514:doc-crypto-snapshot-reseed

Conversation

@Fuma2514

@Fuma2514 Fuma2514 commented Nov 8, 2026

Copy link
Copy Markdown

For #66880.

The issue measured that crypto.randomBytes, crypto.randomInt, crypto.randomFill, crypto.randomUUID and crypto.getRandomValues produce identical output across a snapshot/checkpoint restore (QEMU/Firecracker/CRIU), because OpenSSL's DRBG continues from the saved state until its next reseed, and crypto.randomUUID draws from a 128-identifier cache. The issue explicitly offered a documentation PR.

This PR adds, docs-only:

  • A NOTE under crypto.randomBytes explaining the DRBG-continues-after-restore behaviour, which functions are affected, and that resumed applications should reseed after their own restore signal.
  • A sentence under crypto.randomUUID about the 128-UUID entropy cache repeating after a restore and the disableEntropyCache escape hatch.

No code changes; the wording follows the sentence shape the issue proposed.

@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/crypto

@nodejs-github-bot nodejs-github-bot added crypto Issues and PRs related to the crypto subsystem. doc Issues and PRs related to Node.js documentation. labels Nov 8, 2026
@github-actions

github-actions Bot commented Nov 8, 2026

Copy link
Copy Markdown
Contributor

Welcome to Node.js, and thank you for your first contribution!

Before review, please take a moment to read:

Please make sure every commit is signed off. For a first pull request, GitHub Actions require collaborator approval and Jenkins CI must be started by a collaborator or triager, so an initial wait is normal.

Caution

AgentScan found account activity patterns that may be consistent with automation. This is a heuristic, not proof that this pull request was opened by an agent or violates policy. AI-assisted contributions are permitted, but automated tooling must not open pull requests without advance approval, and contributors must personally understand, test, verify, and take responsibility for every submitted change. See the AgentScan analysis, AI use policy, and automation policy for additional context.

@MikeMcC399

Copy link
Copy Markdown
Contributor

See Commit message guidelines according to the Pull requests documentation.

Your commit must contain the Signed-off-by line with your name and email address as an acknowledgement that you agree to the Developer Certificate of Origin.

@MikeMcC399

Copy link
Copy Markdown
Contributor

The recommendations in:

advise you should tackle only one issue at a time and that you should not open any new PRs until your first PR has been approved.

You already have another unapproved PR open at this time: #67341

Until the first PR has been approved and has landed in the main branch, GitHub classifies you as "first-time contributor". Each PR commit you push needs to be individually approved by team members to run in GitHub Actions CI. This causes delays for you as a contributor, and it adds to the work load for the team.

Waiting until the first PR has landed ensures that you as a contributor have experienced the complete process from PR submission to successful landing. After this has been completed, any new PRs or new commits to an existing PR are treated to rules for regular Contributors. GitHub Actions CI workflows are then run automatically without intervention by a team member.

Signed-off-by: Fuma2514 <fuma2514@users.noreply.github.com>
@Fuma2514
Fuma2514 force-pushed the doc-crypto-snapshot-reseed branch from 90bd11b to fa687be Compare November 8, 2026 14:42
@Fuma2514 Fuma2514 closed this Nov 8, 2026
@Fuma2514

Fuma2514 commented Nov 8, 2026

Copy link
Copy Markdown
Author

Closing this one for now — keeping a single open PR while the other is under review, per the first-contributor guidance. I'll reopen after the first lands. Thanks @MikeMcC399 for the pointers!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agentscan:automated-account crypto Issues and PRs related to the crypto subsystem. doc Issues and PRs related to Node.js documentation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants