Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 497540 - grp module does not support whole uid/gid range
grp module does not support whole uid/gid range
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: python (Show other bugs)
4.7
All Linux
low Severity medium
: rc
: ---
Assigned To: Dave Malcolm
Petr Šplíchal
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-04-24 10:46 EDT by Petr Šplíchal
Modified: 2016-05-31 21:37 EDT (History)
1 user (show)

See Also:
Fixed In Version: python-2.3.4-14.8.el4
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-02-16 09:19:34 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
simple reproducer (107 bytes, text/plain)
2009-04-24 10:46 EDT, Petr Šplíchal
no flags Details


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2011:0260 normal SHIPPED_LIVE Low: python security and bug fix update 2011-02-16 09:19:04 EST

  None (edit)
Description Petr Šplíchal 2009-04-24 10:46:59 EDT
Created attachment 341183 [details]
simple reproducer

Description of problem:

In the current RHEL4 UIDs and GIDs are supported in the range
between 0-4294967295 on 64bit archs. However, python's module grp
does not support the full range.

This can cause problems as for example nfs-utils create upon
installation an nfsnobody user account/group with the UID/GID
of 4294967294.

Version-Release number of selected component (if applicable):
python-2.3.4-14.7.el4.x86_64

How reproducible:
Always

Steps to Reproduce:
1. groupadd -g 4294967294 nfsnobody
2. python test_grp.py

Actual results:
Traceback (most recent call last):
  File "test_grp.py", line 8, in ?
    e2 = grp.getgrgid(e.gr_gid)
OverflowError: signed integer is greater than maximum

Expected results:
No traceback.
Comment 2 Dave Malcolm 2010-08-20 13:03:06 EDT
Looks like this was fixed upstream in:
  http://svn.python.org/view/python/trunk/Modules/grpmodule.c?view=diff&r1=39521&r2=39522
(change from int to unsigned int)

Looks trivial to backport.

This was part of this wider fix:
  http://svn.python.org/view?view=rev&revision=39522

Another relevant 64-bit fix from that commit appears to be:
  pwd.getpwuid:
    http://svn.python.org/view/python/trunk/Modules/pwdmodule.c?r1=39522&r2=39521&pathrev=39522



See also:
  http://svn.python.org/view?view=rev&revision=46264
changing from using "I"/unsigned int extraction to PyNumber_Int
Comment 8 errata-xmlrpc 2011-02-16 09:19:34 EST
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-0260.html

Note You need to log in before you can comment on or make changes to this bug.