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

gunicorn/util.py set_owner_process Mangling gid on RHEL8 + Google Cloud Platform (very large int group id) #3212

Open
jbisbee opened this issue May 16, 2024 · 1 comment

Comments

@jbisbee
Copy link

jbisbee commented May 16, 2024

I'm using Python 3.9.18 on Red Hat Enterprise Linux 8. My uid and gid values are crazy high under RHEL8 and Google Cloud Platform. As a result, they are hitting a hard coded condition within gunicorn/util.py

151 # versions of python < 2.6.2 don't manage unsigned int for
152 # groups like on osx or fedora
153 gid = abs(gid) & 0x7FFFFFFF

Where my gid is being changed from 4133075255 to 1985591607 and then because they don't match, gid is attempted to be set and gunicorn dies because I'm not a priveledged user and I don't have permission to set gid (which is only firing off because my gid was unjustly molested 👎)

@pajod
Copy link
Contributor

pajod commented May 17, 2024

Fairly certain that was a spot-fix for a bug that no longer appears on any supported system/version.
.. and Gunicorn should not only drop that line, but also stop messing with uid/gid/groups altogether when there is no need to.

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

No branches or pull requests

2 participants