home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #30 / NN_1992_30.iso / spool / comp / unix / aix / 12661 < prev    next >
Encoding:
Text File  |  1992-12-17  |  1.5 KB  |  44 lines

  1. Newsgroups: comp.unix.aix
  2. Path: sparky!uunet!zaphod.mps.ohio-state.edu!pacific.mps.ohio-state.edu!linac!uwm.edu!cs.utexas.edu!hermes.chpc.utexas.edu!jones
  3. From: jones@chpc.utexas.edu (Willaim L. Jones)
  4. Subject: Re: AIX setuid/setgid security hole
  5. Message-ID: <1992Dec17.203701.22872@chpc.utexas.edu>
  6. Organization: The University of Texas System - CHPC
  7. References: <1992Dec17.192558.23830@mintaka.lcs.mit.edu>
  8. Date: Thu, 17 Dec 92 20:37:01 GMT
  9. Lines: 33
  10.  
  11.  
  12.  
  13. >From: mcharity@lcs.mit.edu (Mitchell N Charity)
  14. >
  15. >Bug:  setuid/setgid do not properly limit authority.
  16. >Example:
  17. >   A program running as root,
  18. >   after successfully calling setgid(100) and setuid(100),
  19. >   thus allegedly adopting guest/usr authority,
  20. >   can still delete files from root/security owned directories.
  21. >Security impact:
  22. >   User written programs which begin running as root,
  23. >   (in my case, a /bin/login replacement),
  24. >   and appear to safeguard the filesystem by becoming a unprivileged user,
  25. >   may in fact still have the authority to do significant damage.
  26. >Bug status:
  27. >  - I have begun the tortuous IBM support process.  No feedback yet.
  28. >  - I have heard that a related bug, and an associated workaround,
  29. >   were posted to this list.  Also that they were reported to IBM and CERT,
  30. >   and ignored by both.  ?
  31.  
  32. You forgot about group membership.  You need to do the following sequence:
  33.  
  34.     setgid(basegid);
  35.     initgroups(user, basegid);
  36.     setuid(user);
  37.  
  38. If you don't do this the user inherits the root groups which
  39. includes security.  This should fix you problem.
  40.  
  41. Bill Jones
  42.     
  43.  
  44.