home *** CD-ROM | disk | FTP | other *** search
/ H4CK3R 14 / hacker14.iso / exploits / cxhextris / cxhextris.txt
Encoding:
Internet Message Format  |  2002-10-21  |  1.1 KB

  1. Date: Sat, 25 Apr 1998 14:36:26 +0100
  2. From: Chris Evans <chris@FERRET.LMH.OX.AC.UK>
  3. To: BUGTRAQ@NETSPACE.ORG
  4. Subject: Minor hole in "cxhextris" on certain Linux.
  5.  
  6. Hi,
  7.  
  8. [This is a minor problem]
  9.  
  10. On my RedHat Linux systems, cxhextris has a binary called "xhextris", and
  11. it runs under the euid "games".
  12.  
  13. -rwsr-xr-x   1 games    games       49688 Apr 25 14:02 /usr/X11R6/bin/xhextris
  14.  
  15. A bug in this program will allow local users to subvert the user "games",
  16. perhaps using this to then hide their activities (or cheat in the high
  17. score table!! :-)
  18.  
  19. Details:
  20.  
  21. The name of the player can optionally be taken from the environment
  22. variable "XHEXNAME":
  23.  
  24. xio.c:    if ((name = (char *)getenv("XHEXNAME")) == NULL)
  25.  
  26. This can obviously be of an arbitrary length.
  27.  
  28. When a high score is achieved:
  29.  
  30. strcpy(high_scores[i].name, name);
  31.  
  32. This overflows a buffer on the stack of the function main().
  33.  
  34. At the same time this is fixed, the following should also be fixed:
  35.  
  36. xio.c: #ifdef LOG
  37.        strcpy(log_message,log_name);
  38.  
  39. log_name can come from getenv("USER") on admittedly rare circumstances.
  40.  
  41. Cheers
  42. Chris
  43.