develooper Front page | perl.perl5.porters | Postings from March 2001

[ID 20010328.001] setreuid problem on aix 4.3

Thread Next
From:
Peter Schlaile
Date:
March 28, 2001 00:59
Subject:
[ID 20010328.001] setreuid problem on aix 4.3
Message ID:
E14iBnX-0003rM-00@rzaix-43.rz.uni-karlsruhe.de

This is a bug report for perl from perl@rz.uni-karlsruhe.de,
generated with the help of perlbug 1.28 running under perl v5.6.0.


-----------------------------------------------------------------
[Please enter your report here]

The following small perl code sets correctly the real and effective uid 
under Linux but doesn't work on AIX 4.3:

--------------------------------- 
 $> = 38166;
 $< = 38166;
 $< = $>;
 print $< . "\n" . $> . "\n";
  
  system("bash");
  print $< . "\n" . $> . "\n";
---------------------------------			 
generates on AIX 4.3 (incorrectly) :
# perl test.pl
0
38166
# id
uid=0(root) gid=0(system)
# exit
0
38166                      

but on Linux it works like expected:
# perl test.pl
38166
38166
> id
uid=38166(ry66) gid=0(root) 
# exit
38166
38166                  
---------------------------------
The setreuid system call under AIX works as the following test program 
demonstrates:
---------------------------------
#include <unistd.h>
 
int main(int argc, const char** argv)
{
 setreuid(38166, 38166);
 system("bash");
}    
---------------------------------
# ./test
> id
uid=38166(ry66) gid=0(system)
> exit
#

[Please do not change anything below this line]
-----------------------------------------------------------------
---
Flags:
    category=core
    severity=medium
---
Site configuration information for perl v5.6.0:

Configured by ry66 at Wed Mar 21 20:04:58 CET 2001.

Summary of my perl5 (revision 5.0 version 6 subversion 0) configuration:
  Platform:
    osname=aix, osvers=4.3.3.0, archname=aix
    uname='aix rzaix-43 3 4 002012325700 '
    config_args=''
    hint=previous, useposix=true, d_sigaction=define
    usethreads=undef use5005threads=undef useithreads=undef usemultiplicity=undef
    useperlio=undef d_sfio=undef uselargefiles=define 
    use64bitint=undef use64bitall=undef uselongdouble=undef usesocks=undef
  Compiler:
    cc='cc', optimize='-O', gccversion=
    cppflags=''
    ccflags ='-D_ALL_SOURCE -D_ANSI_C_SOURCE -D_POSIX_SOURCE -qmaxmem=16384 -q32 -D_LARGE_FILES -qlonglong'
    stdchar='unsigned char', d_stdstdio=define, usevfork=false
    intsize=4, longsize=4, ptrsize=4, doublesize=8
    d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=8
    ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
    alignbytes=8, usemymalloc=n, prototype=define
  Linker and Libraries:
    ld='ld', ldflags =' -L/usr/local/lib -b32'
    libpth=/usr/local/lib /lib /usr/lib /usr/ccs/lib
    libs=-lbind -lnsl -ldbm -ldl -lld -lm -lC -lc -lcrypt -lbsd -lPW -liconv
    libc=/lib/libc.a, so=a, useshrplib=false, libperl=libperl.a
  Dynamic Linking:
    dlsrc=dl_aix.xs, dlext=so, d_dlsymun=undef, ccdlflags='  -bE:/usr/install/machine/lib/perl5/5.6.0/aix/CORE/perl.exp -bE:/usr/install/machine/lib/perl5/5.6.0/aix/CORE/perl.exp'
    cccdlflags=' ', lddlflags='-bhalt:4 -bM:SRE -bI:$(PERL_INC)/perl.exp -bE:$(BASEEXT).exp -b noentry -lC -lc -L/usr/local/lib'

Locally applied patches:
    

---
@INC for perl v5.6.0:
    /usr/machine/lib/perl5/5.6.0/aix
    /usr/machine/lib/perl5/5.6.0
    /usr/machine/lib/perl5/site_perl/5.6.0/aix
    /usr/machine/lib/perl5/site_perl/5.6.0
    /usr/machine/lib/perl5/site_perl/5.005/aix
    /usr/machine/lib/perl5/site_perl/5.005
    /usr/machine/lib/perl5/site_perl
    .

---
Environment for perl v5.6.0:
    HOME=/home/dfs/ry00/ry66
    LANG=C
    LANGUAGE (unset)
    LC_CTYPE=de_DE.ISO8859-1
    LC__FASTMSG=true
    LD_LIBRARY_PATH (unset)
    LIBPATH (unset)
    LOGDIR (unset)
    PATH=/usr/local/bin:/usr/machine/bin:/usr/bin:/usr/ibmcxx/bin:/usr/ucb:/usr/bin/X11:/usr/app/bin:/usr/segment/bin:/home/dfs/ry00/ry66/bin/rs6000-ibm-aix4.3.3.0:/home/dfs/ry00/ry66/bin:.:/usr/segment/rz/bin
    PERL_BADLANG (unset)
    SHELL=/usr/machine/bin/bash


Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About