Commit Graph

8 Commits

Author SHA1 Message Date
jsm 20e3305006 Fix -Wsign-compare warnings. 1999-09-18 19:38:46 +00:00
jsm 010f0ab865 Convert tetris to use <err.h> functions. 1999-09-17 20:44:51 +00:00
jsm 5367f3400c Security improvements for games (largely from or inspired by OpenBSD).
Games which run setgid from dm, but don't need to, should drop their
privileges at startup.

Games which have a scorefile should open it at startup, then drop all
privileges leaving just the open writable file descriptor.  If the
game can invoke subprocesses, this should be made close-on-exec.

Games with scorefiles should make sure they do not get a file
descriptor < 3.  (Otherwise, they could get confused and corrupt the
scorefile when using stdin, stdout or stderr.)

Some old setuid revokes from the days of setuid games change into gid
revokes.
1999-09-12 09:02:20 +00:00
jsm 092d313019 Add use of `const' where appropriate to the games.
This merges in all such remaining changes from the Linux port of the
NetBSD games, except in hunt (where substantial changes from OpenBSD
need to be looked at).

Some such changes were previously covered in PRs bin/6041, bin/6146,
bin/6148, bin/6150, bin/6151, bin/6580, bin/6660, bin/7993, bin/7994,
bin/8039, bin/8057 and bin/8093.
1999-09-08 21:17:44 +00:00
lukem 2ce4ef15e6 use <termcap.h> 1997-10-14 01:14:20 +00:00
tls af1ee80179 bfunctions -> memfunctions 1997-01-13 06:50:25 +00:00
cgd aaeacec8fc NetBSD RCS Ids 1995-04-22 07:42:31 +00:00
cgd fece8b5011 ascii tetris! 1994-05-06 06:50:50 +00:00