guyton%rand-unix@sri-unix.UUCP (07/11/83)
I plugged this hole here a little over a year ago by making the ttys owned by a special group "write", and had the write command be setgid to that group. Seems to make more sense to me than yet another setuid-root program floating around. In case you want to do the same thing, the changes were: /etc/group: added "write" group with no logins. Only for write pgm! write.c: closed other terminal before exec of shell write.c: set group id back to real id before exec of shell write.c: map outgoing control characters into ^X form write.c: stat checks now for 020 bit instead of 002 bit login.c: change of tty group to "write" group. chmod to 620 mesg.c: change to use 020 bit instead of 022 finger.c: checks for stat 0220 instead of 0222 for "messages off" logic -- Jim Guyton