Commit Graph

3600 Commits

Author SHA1 Message Date
Robert Watson e292984cd3 o Make comment match reality, synch code with comment.
o In practice: the comment indicates that all but umask and
  environmental variables of the users login class are applied when su
  occurs, unless -m is used to specify a class.  This was incorrect;
  in practice, the uid, gids, resources, and priority were set, and
  then resources and priority were selectively removed.  This meant
  that some aspects of the user context were not set, including handling
  of login events (wtmp, utmp), as well as the path specified in
  login.conf.
o I changed it so that the behavior is the same, but instead,
  LOGIN_SETALL is used, and appropriate flags are removed, including
  the LOGIN_SETLOGIN and LOGIN_SETPATH entries that were implicitly
  not present before.  I also updated the comment to reflect
  reality, selecting reality as the "correct" behavior.
o This has the practical benefit that as new LOGIN_SET* flags are
  introduced, they are supported by su unless specifically disabled.
  For example, of a LOGIN_SETLABEL flag is introduced to support
  MAC labels determined by the user's login class, then su no longer
  has to be modified.
o It might be desirable to have su use LOGIN_SETPATH depending on
  its command line parameters, as it might or might not be
  considered part of the "environment".

Obtained from:	TrustedBSD Project
2000-11-30 23:14:55 +00:00
Will Andrews 313c36f04b Format string paranoia. This should avoid potential buffer overflows from
user input (in its ever-broadening definition).

Obtained from:	NetBSD
2000-11-30 13:56:19 +00:00
Dag-Erling Smørgrav 30204f9830 If the transfer timed out, but we don't know how large the file is supposed
to be, assume it was truncated.
2000-11-30 10:08:22 +00:00
John Baldwin 7f18d5d343 Make use of the full screen width to display p_comm rather than assuming a
hardcoded screen width of 80 chars.
2000-11-29 23:03:02 +00:00
John Baldwin 089f9b7e2f Display the name of the mutex we are blocked on in the state field. To
differentiate mutex names from wait channel names, prefix mutex names with
an asterisk.

Submitted by:	Dan Nelson <dnelson@emsphone.com>
2000-11-29 20:22:34 +00:00
Nik Clayton 71e1d8b0dd Xref make.conf(5), and point to /usr/share/doc/psd/12.make for the
tutorial paper.
2000-11-29 14:40:02 +00:00
Ruslan Ermilov ef4261bf71 Eliminate groff(1) warnings. 2000-11-29 10:56:59 +00:00
Ruslan Ermilov 38478faf72 Eliminate groff(1) warnings caused by vgrind(1). 2000-11-29 10:32:51 +00:00
Sheldon Hearn 7e812edfb7 Fix a typo and a punctuation mistake, the two of which conspired
against the reader.
2000-11-29 06:55:13 +00:00
Marcel Moolenaar 5a1ce5e6aa Add LIBCRYPT to DPADD.
Implied by: bde
2000-11-28 07:24:15 +00:00
Kris Kennaway a6f339d266 Format string auditing 2000-11-27 07:35:53 +00:00
Kris Kennaway c858db9672 *** empty log message *** 2000-11-27 06:55:38 +00:00
Kris Kennaway 40c068176d Constify 2000-11-27 06:40:35 +00:00
Kris Kennaway 50d793ebb0 Fix format string warnings.
Submitted by:	nra
Obtained from:	NetBSD
2000-11-27 04:26:39 +00:00
Kris Kennaway 56e7ae90cb Cleanup this code a bit by attempting to sync it up with NetBSD and
with each other.

Reviewed by:	markm, dwmalone
2000-11-26 22:36:35 +00:00
David E. O'Brien 5576244cd6 Use the vendor's manpages (which are in old -man format) rather than
our modified one based on a much older version of the vendor's manpage.
2000-11-26 22:19:56 +00:00
Kris Kennaway f6fd83ed27 Correct definition of MAXHOSTNAMELEN in ifdef'ed code.
Submitted by:	Edwin Groothuis <mavetju@chello.nl>
PR:		bin/22787
2000-11-26 21:37:51 +00:00
Kris Kennaway cca0db7e7e Constify 2000-11-26 11:07:45 +00:00
Kris Kennaway da4cd46eac vsprintf() -> vsnprintf() 2000-11-26 08:14:55 +00:00
Robert Watson c3a2720353 o Make systat/vmstat.c use sysctl() to retrieve cp_time, bufspace,
maxvnodes, numvnodes, freevnodes, nchstats, and numdirtybuffers.
o Make the hw.ncpu error checking code a little more rigorous by
  sanity checking the returned data size.
o Didn't fix machine-dependent non-sysctl-exported variables:
  intrnames, eintrnames, intrcnt, eintrcnt, as these variables are
  defined and exported from machine-dependent kernel code in
  assembly.  This should probably be fixed somehow.
2000-11-25 03:53:42 +00:00
Robert Watson 00df22775a o make systat/pigs.c use syctl() to retrieve cp_time, fscale, and ccpu
instead of using kmem.
2000-11-25 03:49:42 +00:00
Robert Watson 8c82fe65a7 o Make systat/iostat.c use sysctl() to retrieve cp_time instead of
kmem.
2000-11-25 03:47:36 +00:00
Robert Watson 7ace4e618a o Make systat use sysctl() to retrieve hz and stathz, instead of
using kmem.
2000-11-25 03:46:45 +00:00
Ruslan Ermilov 92ee29d2a5 Reimplement the groff(1) warnings elimination fixes in a better way. 2000-11-24 10:05:30 +00:00
Joseph Koshy b67f439c91 [rsh.1] Document the `-4' and `-6' options.
[rsh.c] Make usage message match the code.
2000-11-24 09:25:44 +00:00
Joseph Koshy 0deea1c066 [rlogin.1] Document the `-4' and `-6' options. Correct a typo.
[rlogin.c] Make the usage message match the code.
2000-11-24 09:14:09 +00:00
Ruslan Ermilov bbc7e5700d Eliminate groff(1) warnings. 2000-11-23 15:21:30 +00:00
Ben Smithurst d9a7d86c29 kenv(1) first appeared in FreeBSD 4.1.1, not FreeBSD 5.0.
PR:		23020
Submitted by:	Simon Dick <simond@irrelevant.org>
2000-11-23 11:21:35 +00:00
Alexey Zelkin 89368610f8 Use correct macro for path name
PR:		docs/13218
2000-11-22 17:53:17 +00:00
Kris Kennaway 4f377e65c4 Create temporary files in a secure directory, instead of using multiple
filenames based on a single invocation of mktemp() in /tmp, which is
easily predictable after the first one.

Audited by:     markm
2000-11-22 11:09:30 +00:00
Ruslan Ermilov f4d874a1db mdoc(7) police: do not split author names in the AUTHORS section. 2000-11-22 09:35:58 +00:00
Ruslan Ermilov 8fe908ef0c mdoc(7) police: use the new features of the Nm macro. 2000-11-20 19:21:22 +00:00
Ruslan Ermilov 3450dff7f1 mdoc(7) police: use the new features of the Nm macro. 2000-11-20 12:18:54 +00:00
Marcel Moolenaar c71b3c67f1 Add -lcrypt. This fixes cross-building. 2000-11-20 02:19:05 +00:00
Kris Kennaway 29ac114aae Unlink the temporary file immediately so it is removed on exit.
Obtained from:	OpenBSD
2000-11-19 12:04:12 +00:00
Kris Kennaway f743d11975 Fix a buffer overflow from a long local hostname.
Obtained from:	OpenBSD
2000-11-19 10:08:26 +00:00
John W. De Boskey aecbd99950 Add/fix the ability to split a file larger than 2 gigabytes.
Added $FreeBSD tag (in the way the already present sccsid is
done). I've been told the rcsid stuff may be of dubious value
so I'm curious to know if folks (still) use it.

Submitted by:	Brad Chisholm <blc@bsdwins.com>
2000-11-19 01:44:20 +00:00
Matthew Hunt 45fe9882b0 "minute(s) period(s)" --> "minute(s)" 2000-11-17 23:08:03 +00:00
Ruslan Ermilov 251c176f41 mdoc(7) police: use certified section headers wherever possible. 2000-11-17 11:44:16 +00:00
Ben Smithurst 76a06f8483 remove trailing periods from SEE ALSO. 2000-11-15 17:27:54 +00:00
Ruslan Ermilov b82f5db0ac Spell the des's name correctly. 2000-11-14 13:19:26 +00:00
Ruslan Ermilov b5c508fba3 Use Fx macro wherever possible. 2000-11-14 11:20:58 +00:00
Paul Saab ecc50bd485 -U cannot be an option since some signals start with U. -u is the
documented behavior so only check for that.
2000-11-12 07:43:50 +00:00
David Greenman e61715de39 Changed variable killchar to killch and erasechar to erasech to avoid
a name clash with the library functions of the same name (in libncurses).
This problem was masked when building tset shared (the local symbols had
precedence), but caused tset to core dump when it was built -static.
2000-11-11 23:03:38 +00:00
Ruslan Ermilov 726b61ab5f Avoid use of direct troff requests in mdoc(7) manual pages. 2000-11-10 17:46:15 +00:00
Ruslan Ermilov 20279a10b2 Fixed typo: .ar -> .Ar. 2000-11-10 14:40:50 +00:00
David E. O'Brien 912209a5b2 Install `chflags' in the root partition, NOT /usr where it is not available
in single user mode.
2000-11-10 05:31:52 +00:00
Ruslan Ermilov d6801b5c51 Fixed typo: .FL -> .Fl 2000-11-06 09:29:17 +00:00
Ruslan Ermilov 6c56f330ec .UC -> .Os 2000-11-06 09:27:03 +00:00
Ruslan Ermilov 390f1a7402 Fixed typo: .EL -> .El 2000-11-06 09:20:09 +00:00