TIOCCDTR (bug|feature)

Dave Martindale dmmartindale at watcgl.UUCP
Sun Jun 19 23:15:27 AEST 1983


I don't believe that ioctl calls should have any sort of special restrictions
requiring anything other than the permissions on the tty special file.
If someone can open your tty for writing, why should they not be allowed to
use whatever ioctl they please?  If you don't trust the other users on the
machine to act responsibly, then you don't want general write permission
on your terminal at all.  If this requires that inter-user
communications programs such as "write" be setuid, so be it.
While plugging holes, you should also make write check the characters
it is passing along and strip control characters that might do funny
things to the recipient's terminal.  An even better scheme is something
like the "talk" program posted recently, where the recipient voluntarily
joins the conversation and writing to his screen is done only by a
process which is run by him.



More information about the Comp.bugs.4bsd.ucb-fixes mailing list