Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

process: fix uid/gid validation to avoid crash #44910

Merged
merged 1 commit into from Oct 10, 2022

Conversation

tniessen
Copy link
Member

@tniessen tniessen commented Oct 7, 2022

id |= 0 turns unsigned 32-bit integer values exceeding the unsigned 31-bit range into negative integers, causing a crash. Use id >>>= 0 instead, which works properly for all unsigned 32-bit integers.

Refs: #36786

id |= 0 turns unsigned 32-bit integer values exceeding the unsigned
31-bit range into negative integers, causing a crash. Use id >>>= 0
instead, which works properly for all unsigned 32-bit integers.

Refs: nodejs#36786
@tniessen tniessen requested a review from jasnell October 7, 2022 12:10
@nodejs-github-bot
Copy link
Collaborator

Review requested:

  • @nodejs/startup

@tniessen tniessen added the request-ci Add this label to start a Jenkins CI on a PR. label Oct 7, 2022
@nodejs-github-bot nodejs-github-bot added the needs-ci PRs that need a full CI run. label Oct 7, 2022
@tniessen tniessen added the process Issues and PRs related to the process subsystem. label Oct 7, 2022
@github-actions github-actions bot removed the request-ci Add this label to start a Jenkins CI on a PR. label Oct 7, 2022
@nodejs-github-bot
Copy link
Collaborator

@tniessen tniessen added the author ready PRs that have at least one approval, no pending requests for changes, and a CI started. label Oct 7, 2022
@aduh95 aduh95 added the commit-queue Add this label to land a pull request using GitHub Actions. label Oct 10, 2022
@nodejs-github-bot nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Oct 10, 2022
@nodejs-github-bot nodejs-github-bot merged commit 997334c into nodejs:main Oct 10, 2022
@nodejs-github-bot
Copy link
Collaborator

Landed in 997334c

danielleadams pushed a commit that referenced this pull request Oct 11, 2022
id |= 0 turns unsigned 32-bit integer values exceeding the unsigned
31-bit range into negative integers, causing a crash. Use id >>>= 0
instead, which works properly for all unsigned 32-bit integers.

Refs: #36786
PR-URL: #44910
Reviewed-By: Rich Trott <rtrott@gmail.com>
Reviewed-By: Erick Wendel <erick.workspace@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
author ready PRs that have at least one approval, no pending requests for changes, and a CI started. needs-ci PRs that need a full CI run. process Issues and PRs related to the process subsystem.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants