Bug #75696 [NEW]: posix_getgrnam fails to print details of group
| From: | jas at eecs dot yorku dot ca | Date: | Sat, 16 Dec 2017 03:20:15 +0000 |
| Subject: | Bug #75696 [NEW]: posix_getgrnam fails to print details of group | ||
| Groups: | php.bugs | ||
| Request: | Send a blank email to php-bugs+get-213128@lists.php.net to get a copy of this message | ||
From: jas at eecs dot yorku dot ca
Operating system: CentOS 7.4
PHP version: 7.2.0
Package: POSIX related
Bug Type: Bug
Bug description:posix_getgrnam fails to print details of group
Description:
------------
I think I've discovered an odd bug. When I use "posix_getgrnam" to
print details on a group in /etc/group, I get back nothing. If I erase
one entry from the group above it, then it works!
example silly /etc/group file:
root:x:0:
labtest:*:31003:a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z,aa,bb,cc,dd,ee,ff,gg,hh,ii,jj,kk,ll,mm,nn,oo,pp,qq,rr,ss,tt,uu,vv,ww,xx,yy,zz,aaa,bbb,ccc,ddd,eee,fff,ggg,hhh,iii,jjj,kkk,lll,mmm,nnn,ooo,ppp,qqq,rrr,sss,ttt,uuu,vvv,www,xxx,yyy,zzz,aaaa,bbbb,cccc,dddd,eeee,ffff,gggg,hhhh,iiii,jjjj,kkkk
tech:*:1000:tdb
Without removing user "kkkk" from "labtest" group, posix_getgrnam can't
return the details for group tech!
Test script:
---------------
<?php
print_r(posix_getgrnam("tech"));
?>
Expected result:
----------------
I expect to see the group details for group "tech".
Actual result:
--------------
empty.
--
Edit bug report at https://bugs.php.net/bug.php?id=75696&edit=1
--
Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=75696&r=trysnapshot54
Try a snapshot (PHP 5.5): https://bugs.php.net/fix.php?id=75696&r=trysnapshot55
Try a snapshot (trunk): https://bugs.php.net/fix.php?id=75696&r=trysnapshottrunk
Fixed in SVN: https://bugs.php.net/fix.php?id=75696&r=fixed
Fixed in release: https://bugs.php.net/fix.php?id=75696&r=alreadyfixed
Need backtrace: https://bugs.php.net/fix.php?id=75696&r=needtrace
Need Reproduce Script: https://bugs.php.net/fix.php?id=75696&r=needscript
Try newer version: https://bugs.php.net/fix.php?id=75696&r=oldversion
Not developer issue: https://bugs.php.net/fix.php?id=75696&r=support
Expected behavior: https://bugs.php.net/fix.php?id=75696&r=notwrong
Not enough info: https://bugs.php.net/fix.php?id=75696&r=notenoughinfo
Submitted twice: https://bugs.php.net/fix.php?id=75696&r=submittedtwice
register_globals: https://bugs.php.net/fix.php?id=75696&r=globals
PHP 4 support discontinued: https://bugs.php.net/fix.php?id=75696&r=php4
Daylight Savings: https://bugs.php.net/fix.php?id=75696&r=dst
IIS Stability: https://bugs.php.net/fix.php?id=75696&r=isapi
Install GNU Sed: https://bugs.php.net/fix.php?id=75696&r=gnused
Floating point limitations: https://bugs.php.net/fix.php?id=75696&r=float
No Zend Extensions: https://bugs.php.net/fix.php?id=75696&r=nozend
MySQL Configuration Error: https://bugs.php.net/fix.php?id=75696&r=mysqlcfg