Commit Graph

4785 Commits

Author SHA1 Message Date
agc
03663b89ae Add a "-s verification-type" argument to pkg_add, which adds a callout
to a verification program for a binary package. The following callouts
are defined: "none", "gpg" and "pgp5".

This feature allows you to verify a binary package against a detached
signature file, and to proceed with the installation or not, depending
upon the level of trust you place in the signatory of the binary
package.

Digital signatures will be checked in a recursive manner (i.e. if
pkg_add is called with a verification type which is not "none", the
verification type will be passed to subsequent invocations of pkg_add
for the dependent packages).

At the current time, digital signatures cannot be used with the URL
form of pkg_add(1) - the detached signature file must be in the same
directory as the binary package, either locally or mounted by NFS.

If no -s argument is given, pkg_add(1) retains its current behaviour -
the package will not be verified before installation takes place.
2001-09-25 10:28:16 +00:00
tv
6042281606 Don't override the definition of LEX. 2001-09-25 01:40:09 +00:00
wiz
4c99916337 va_{start,end} audit:
Make sure that each va_start has one and only one matching va_end,
especially in error cases.
If the va_list is used multiple times, do multiple va_starts/va_ends.
If a function gets va_list as argument, don't let it use va_end (since
it's the callers responsibility).

Improved by comments from enami and christos -- thanks!

Heimdal/krb4/KAME changes already fed back, rest to follow.

Inspired by, but not not based on, OpenBSD.
2001-09-24 13:22:25 +00:00
perry
9864f0aae8 Add a -l flag which does "loose" permissions checks, i.e. a mode 444
matches a check for mode 644 (though obviously not the reverse). This
can be used by the nightly security run, making the output1 more useful
by having it contain fewer spurious permissions violations.

Note that I did not make -l work if you have a sgid/suid/sticky bit
set. I don't know how you could cause security trouble with more
stringent settings and a suid file, but I don't want to find out the
hard way.
2001-09-22 03:56:29 +00:00
thorpej
f189453cbc Pull in fbio.h from <dev/sun/fbio.h> 2001-09-19 16:16:03 +00:00
itojun
9a881fc0f7 typo in IPv6 support. listen to wildcard address correctly. 2001-09-18 04:36:28 +00:00
assar
2a2aa85a8d update infrastructure for krb4 1.1 and heimdal 0.4e 2001-09-17 12:34:40 +00:00
joda
f51bc9e68b use strtol instead of atoi to catch non numeric values 2001-09-17 10:05:57 +00:00
hubertf
5653bfc431 if creategid() fails, don't try to print system error message (use errx()
instead of err()), as all error cases in creategid() are already commented
properly from inside creategid().

This prevents funny errors like:

	miyu# groupadd test2
	miyu# groupadd test2
	groupadd: group `test2' already exists
	groupadd: can't add group: problems with /etc/group file: Inappropriate ioctl for device
2001-09-16 18:08:37 +00:00
wiz
456dff6cb8 Spell 'occurred' with two 'r's. 2001-09-16 16:34:23 +00:00
manu
171c550e3a Removed the HAVE_CLOCKCTL for now (it should not be enabled until all
ports use clockctl. Silly me!)
2001-09-16 09:12:50 +00:00
manu
98b40d754d Enable use of the clockctl device for ntpd (this feature has not yet been
commited to the ntp CVS)
2001-09-16 07:53:12 +00:00
thorpej
8b531ac998 By poppular demand, don't wildcard "bus" on the "list" command
by default.
2001-09-15 18:35:00 +00:00
enami
a88b4adee6 Zero clear the apm_power_info structure being passed to ioctl. 2001-09-15 02:42:26 +00:00
thorpej
477798fcac Fix missing : in a getopt() string. 2001-09-14 17:28:36 +00:00
thorpej
9ed4e90471 Build pcictl. 2001-09-13 23:51:39 +00:00
thorpej
0c91ac689b pcictl(8) -- a program for frobbing the PCI bus, and also an example
of how to use libpci.

Currently has "list" (list devices within a PCI domain) and "dump" (dump
PCI configuration header for a device) sub-commands.
2001-09-13 23:51:04 +00:00
itojun
de3a065dcc CPPFLAGS, not CFLAGS, for -D. 2001-09-13 13:02:20 +00:00
enami
69af775e86 - Bail out when failed to ioctl.
- Clear args to APM_IOC_GETPOWER.
2001-09-13 11:05:58 +00:00
enami
453bf8d640 KNF and other misc. stylistic changes. 2001-09-13 11:01:49 +00:00
thorpej
dd5462b93f Update for TCP timer changes. 2001-09-11 15:45:01 +00:00
thorpej
85f032ca45 Fix printf format. 2001-09-11 15:10:45 +00:00
enami
54d0f0cc4b Fix off-by-one error; root on sd0i shoule be rejected if maxpartition is 8. 2001-09-11 05:11:59 +00:00
itojun
55e8bc4e8b make sup/supfilesrv IPv6 ready. supfilesrv listens to single socket,
therefore, you will need two instances running for dual stack support
(one with -4 and one with -6).
2001-09-11 03:33:52 +00:00
itojun
c976c20dc0 correct 1st arg to select(). 2001-09-11 03:32:55 +00:00
simonb
2db48f4c88 Add "Remember to update distrib/sets..." lines (and NetBSD RCS IDs in
some cases).
2001-09-10 11:18:41 +00:00
lukem
617a65b6f7 replace home-grown parser with fparseln() 2001-09-10 03:22:24 +00:00
lukem
5c2ee5861d Incorporate the enhanced ffs_dirpref() by Grigoriy Orlov, as found in
FreeBSD (three commits; the initial work, man page updates, and a fix
to ffs_reload()), with the following differences:
- Be consistent between newfs(8) and tunefs(8) as to the options which
  set and control the tuning parameters for this work (avgfilesize & avgfpdir)
- Use u_int16_t instead of u_int8_t to keep track of the number of
  contiguous directories (suggested by Chuck Silvers)
- Work within our FFS_EI framework
- Ensure that fs->fs_maxclusters and fs->fs_contigdirs don't point to
  the same area of memory

The new algorithm has a marked performance increase, especially when
performing tasks such as untarring pkgsrc.tar.gz, etc.

The original FreeBSD commit messages are attached:

=====
mckusick    2001/04/10 01:39:00 PDT
  Directory layout preference improvements from Grigoriy Orlov <gluk@ptci.ru>.
  His description of the problem and solution follow. My own tests show
  speedups on typical filesystem intensive workloads of 5% to 12% which
  is very impressive considering the small amount of code change involved.

  ------

    One day I noticed that some file operations run much faster on
  small file systems then on big ones. I've looked at the ffs
  algorithms, thought about them, and redesigned the dirpref algorithm.

    First I want to describe the results of my tests. These results are old
  and I have improved the algorithm after these tests were done. Nevertheless
  they show how big the perfomance speedup may be. I have done two file/directory
  intensive tests on a two OpenBSD systems with old and new dirpref algorithm.
  The first test is "tar -xzf ports.tar.gz", the second is "rm -rf ports".
  The ports.tar.gz file is the ports collection from the OpenBSD 2.8 release.
  It contains 6596 directories and 13868 files. The test systems are:

  1. Celeron-450, 128Mb, two IDE drives, the system at wd0, file system for
     test is at wd1. Size of test file system is 8 Gb, number of cg=991,
     size of cg is 8m, block size = 8k, fragment size = 1k OpenBSD-current
     from Dec 2000 with BUFCACHEPERCENT=35

  2. PIII-600, 128Mb, two IBM DTLA-307045 IDE drives at i815e, the system
     at wd0, file system for test is at wd1. Size of test file system is 40 Gb,
     number of cg=5324, size of cg is 8m, block size = 8k, fragment size = 1k
     OpenBSD-current from Dec 2000 with BUFCACHEPERCENT=50

  You can get more info about the test systems and methods at:
  http://www.ptci.ru/gluk/dirpref/old/dirpref.html

                                Test Results

               tar -xzf ports.tar.gz               rm -rf ports
    mode  old dirpref new dirpref speedup old dirprefnew dirpref speedup
                               First system
   normal     667         472      1.41       477        331       1.44
   async      285         144      1.98       130         14       9.29
   sync       768         616      1.25       477        334       1.43
   softdep    413         252      1.64       241         38       6.34
                               Second system
   normal     329         81       4.06       263.5       93.5     2.81
   async      302         25.7    11.75       112          2.26   49.56
   sync       281         57.0     4.93       263         90.5     2.9
   softdep    341         40.6     8.4        284          4.76   59.66

  "old dirpref" and "new dirpref" columns give a test time in seconds.
  speedup - speed increasement in times, ie. old dirpref / new dirpref.

  ------

  Algorithm description

  The old dirpref algorithm is described in comments:

  /*
   * Find a cylinder to place a directory.
   *
   * The policy implemented by this algorithm is to select from
   * among those cylinder groups with above the average number of
   * free inodes, the one with the smallest number of directories.
   */

  A new directory is allocated in a different cylinder groups than its
  parent directory resulting in a directory tree that is spreaded across
  all the cylinder groups. This spreading out results in a non-optimal
  access to the directories and files. When we have a small filesystem
  it is not a problem but when the filesystem is big then perfomance
  degradation becomes very apparent.

  What I mean by a big file system ?

    1. A big filesystem is a filesystem which occupy 20-30 or more percent
       of total drive space, i.e. first and last cylinder are physically
       located relatively far from each other.
    2. It has a relatively large number of cylinder groups, for example
       more cylinder groups than 50% of the buffers in the buffer cache.

  The first results in long access times, while the second results in
  many buffers being used by metadata operations. Such operations use
  cylinder group blocks and on-disk inode blocks. The cylinder group
  block (fs->fs_cblkno) contains struct cg, inode and block bit maps.
  It is 2k in size for the default filesystem parameters. If new and
  parent directories are located in different cylinder groups then the
  system performs more input/output operations and uses more buffers.
  On filesystems with many cylinder groups, lots of cache buffers are
  used for metadata operations.

  My solution for this problem is very simple. I allocate many directories
  in one cylinder group. I also do some things, so that the new allocation
  method does not cause excessive fragmentation and all directory inodes
  will not be located at a location far from its file's inodes and data.
  The algorithm is:
  /*
   * Find a cylinder group to place a directory.
   *
   * The policy implemented by this algorithm is to allocate a
   * directory inode in the same cylinder group as its parent
   * directory, but also to reserve space for its files inodes
   * and data. Restrict the number of directories which may be
   * allocated one after another in the same cylinder group
   * without intervening allocation of files.
   *
   * If we allocate a first level directory then force allocation
   * in another cylinder group.
   */

    My early versions of dirpref give me a good results for a wide range of
  file operations and different filesystem capacities except one case:
  those applications that create their entire directory structure first
  and only later fill this structure with files.

    My solution for such and similar cases is to limit a number of
  directories which may be created one after another in the same cylinder
  group without intervening file creations. For this purpose, I allocate
  an array of counters at mount time. This array is linked to the superblock
  fs->fs_contigdirs[cg]. Each time a directory is created the counter
  increases and each time a file is created the counter decreases. A 60Gb
  filesystem with 8mb/cg requires 10kb of memory for the counters array.

    The maxcontigdirs is a maximum number of directories which may be created
  without an intervening file creation. I found in my tests that the best
  performance occurs when I restrict the number of directories in one cylinder
  group such that all its files may be located in the same cylinder group.
  There may be some deterioration in performance if all the file inodes
  are in the same cylinder group as its containing directory, but their
  data partially resides in a different cylinder group. The maxcontigdirs
  value is calculated to try to prevent this condition. Since there is
  no way to know how many files and directories will be allocated later
  I added two optimization parameters in superblock/tunefs. They are:

          int32_t  fs_avgfilesize;   /* expected average file size */
          int32_t  fs_avgfpdir;      /* expected # of files per directory */

  These parameters have reasonable defaults but may be tweeked for special
  uses of a filesystem. They are only necessary in rare cases like better
  tuning a filesystem being used to store a squid cache.

  I have been using this algorithm for about 3 months. I have done
  a lot of testing on filesystems with different capacities, average
  filesize, average number of files per directory, and so on. I think
  this algorithm has no negative impact on filesystem perfomance. It
  works better than the default one in all cases. The new dirpref
  will greatly improve untarring/removing/coping of big directories,
  decrease load on cvs servers and much more. The new dirpref doesn't
  speedup a compilation process, but also doesn't slow it down.

  Obtained from:	Grigoriy Orlov <gluk@ptci.ru>
=====

=====
iedowse     2001/04/23 17:37:17 PDT
  Pre-dirpref versions of fsck may zero out the new superblock fields
  fs_contigdirs, fs_avgfilesize and fs_avgfpdir. This could cause
  panics if these fields were zeroed while a filesystem was mounted
  read-only, and then remounted read-write.

  Add code to ffs_reload() which copies the fs_contigdirs pointer
  from the previous superblock, and reinitialises fs_avgf* if necessary.

  Reviewed by:	mckusick
=====

=====
nik         2001/04/10 03:36:44 PDT
  Add information about the new options to newfs and tunefs which set the
  expected average file size and number of files per directory.  Could do
  with some fleshing out.
=====
2001-09-06 02:16:00 +00:00
christos
9a9926ee57 PR/13874: Hubert Feyrer: Add -L class to useradd 2001-09-05 21:37:32 +00:00
itojun
bc0d6cdd22 sync with the latest kame.
- select() with the right maxfd.
- don't write() with len <= 0.
- no wacky macro ERRSTR.
2001-09-05 01:22:24 +00:00
itojun
a12c72c978 sync with the latest KAME tree.
- don't use FD_SETSIZE on select
- "sin" conflicts with math library, so use sin6
- other minor updates
2001-09-05 01:17:31 +00:00
drochner
e569277f0d -fix uninitialized "verbose" flag
-add iso2, iso7 encodings
2001-09-04 17:59:04 +00:00
wiz
c1434a021e Don't mention /usr/local/lib/isdn, since it's not used (anymore?). 2001-09-03 01:22:54 +00:00
lukem
e3ba61f9f3 Incorporate fix by iedowse @ FreeBSD to allow disks with large numbers of
cylinder groups to work correctly, with minor modifications by me to work
with our FFS_EI code.  From the FreeBSD commit message:

	The ffs superblock includes a 128-byte region for use by temporary
	in-core pointers to summary information. An array in this region
	(fs_csp) could overflow on filesystems with a very large number of
	cylinder groups (~16000 on i386 with 8k blocks). When this happens,
	other fields in the superblock get corrupted, and fsck refuses to
	check the filesystem.

	Solve this problem by replacing the fs_csp array in 'struct fs'
	with a single pointer, and add padding to keep the length of the
	128-byte region fixed. Update the kernel and userland utilities
	to use just this single pointer.

	With this change, the kernel no longer makes use of the superblock
	fields 'fs_csshift' and 'fs_csmask'. Add a comment to newfs/mkfs.c
	to indicate that these fields must be calculated for compatibility
	with older kernels.

	Reviewed by:    mckusick
2001-09-02 01:58:30 +00:00
reinoud
ec98fbc0db Code cleanup; remove all `#ifdef sgi' from the code... this clobbered the
code considerably and was mainly providing SGI specific logging facilities
and some hacks to improve the relyablility on SGI systems by increasing
priorities etc...
2001-09-02 00:13:05 +00:00
itojun
ee42f09d5b upgrade to KAME 2001/8/31. 2001-08-31 10:36:08 +00:00
lukem
c56418af73 some improvements from freebsd/openbsd
- replace the unused fs_headswitch and fs_trkseek with fs_id[2], bringing
  our struct fs closer to that in freebsd & openbsd (& solaris FWIW)
- dumpfs: improve warning message when cpc == 0
2001-08-30 14:37:25 +00:00
itojun
7cdedd5c84 use strlcpy. from openbsd 2001-08-30 00:53:53 +00:00
itojun
c9e786ce9e security fix from openbsd:
Fix buffer oflow reading from queue file.  While we are at it, crank
the size of buffers that can hold filenames to MAXPATHLEN.
2001-08-30 00:51:50 +00:00
wiz
251b3464be heirarchy -> hierarchy 2001-08-24 10:24:45 +00:00
hubertf
c5967dbc76 Fix typo: heirarchies 2001-08-24 00:48:48 +00:00
itojun
d5e1f166e0 sync with latest kame tree. snprintf() return value audit, log() cleanup,
and such.
2001-08-22 08:52:35 +00:00
itojun
029bd4843d sync with kame better. snprintf return value audit. 2001-08-22 05:24:37 +00:00
yamt
7bc6654ad8 disable unnecessary warning when PKG_PATH isn't set. 2001-08-21 18:38:40 +00:00
wiz
1e378c4c12 precede, not preceed. 2001-08-20 12:00:46 +00:00
hubertf
194031e9be Don't do FTP stuff when operating on all pkgs
Adresses PR 13397 by Greg A. Woods <woods@weird.com>
2001-08-19 23:33:35 +00:00
ad
e04fd20395 Clean up previous. 2001-08-19 09:01:47 +00:00
ad
1e8e78ed07 Update for pw_mkdb() change: restrict updates to one user's records and/or
the secure database where appropriate.
2001-08-18 19:35:32 +00:00
ad
e13d145336 Speed things up a bit. Parts dredged from OpenBSD/FreeBSD.
- Add -u option, to update one user's records only.
- Add -s option, to update the secure database only.
- Give us roughly 1MB of cache per 50kB of password file, but keep within
  a 2MB minimum and 8MB maximum.
- Tidy a little.
2001-08-18 19:29:31 +00:00
ad
e3af9d1d6b getopt() returns -1 on error, not EOF. 2001-08-18 17:10:04 +00:00
joda
3a2248a4e7 (usermod): ~F_MKDIR is usually much better than !F_MKDIR in bit masks 2001-08-17 08:29:00 +00:00
lukem
1b81d6353d remove third argument (`int ns') from ffs_sb_swap(), and let ffs_sb_swap()
determine the endianness of the `struct fs *o' superblock from o->fs_magic
and set needswap as necessary, rather than trusting the caller to get
it right.  invariably, almost every caller of ffs_sb_swap() was calling it
with ns set to the wrong value for ns anyway!
ansi KNF ffs_bswap.c declarations whilst here.

this fixes all sorts of problems when trying to use other-endian file systems,
notably the kernel trying to access memory *way* off, possibly corrupting or
panicing, and userland programs SEGVing and/or corrupting things (e.g,
"fsck_ffs -B"  to swap a file system endianness).

whilst the previous rev of ffs_bswap.c (1.10, 2000/12/23) made this problem
worse, i suspect that the problem was always there and previous versions
just happened not to trash things at the wrong time.

FFS_EI should now be a lot more stable.
2001-08-17 02:18:46 +00:00
tv
c98eaba8e8 dhcpd no longer needs the OS_VERSION define. 2001-08-16 18:29:20 +00:00
tv
22207c0806 Add NetBSD rcsids. 2001-08-16 18:03:03 +00:00
itojun
62856425b4 $NetBSD$ 2001-08-16 07:48:08 +00:00
itojun
8b8734d26b string length audit (use strlcpy). sync with latest kame ALTQ. 2001-08-16 07:45:35 +00:00
lukem
69124d8ff2 call ffs_sb_swap() with ns=1, otherwise dumpfs core dumps on other endian fses 2001-08-15 05:52:28 +00:00
tv
dba5d44670 Add hooks to allow toolchain bits to be reachover-built at the top level. 2001-08-14 10:18:26 +00:00
lukem
e4ec9e7a11 - ansi KNF
- add -F flag to specify "argument is an fs image" (effectively a no-op,
  but here for consistency with other tools).
2001-08-14 01:02:02 +00:00
agc
d069ffa789 Add a -n switch to show the packages "needed" by a package (i.e. the
packages which are depended upon).

Provided in PR 13071 by woods@planix.com (Greg A. Woods), the addition
to the synopsis by myself, pedant-in-chief.
2001-08-13 20:08:58 +00:00
yamt
cb1ee3b752 make consistent escape sequence handling
between commandline and command input.

pointed by Christoph Badura <bad@netbsd.org>
2001-08-13 06:54:58 +00:00
uwe
242ff27a4b s/width/height/ in the description of -h option. 2001-08-12 23:51:15 +00:00
mjl
98e1bdc90d Add -W parameter to lpd to disable check for a reserved port,
this is needed to get Win2k print to a NetBSD box. Heavily
inspired by FreeBSD.
2001-08-11 01:04:57 +00:00
drochner
32af7c842a define HMAC_MD5
should fix PR security/13043 by Frank Kardel
2001-08-07 14:51:27 +00:00
christos
4e7d8e10f6 - Filter out the YP_ keys from mail.aliases. How did this ever work?
- Don't be verbose when creating the amd maps.
2001-08-06 18:28:19 +00:00
itojun
92b62a25f8 avoid inet_addr. use snprintf. recent changes from openbsd-current via kame 2001-08-06 07:00:59 +00:00
hubertf
86a406c1ce * Allow generating more than one amd map, by storing the maps to create
in a variable that can be added other maps than amd.home. Patch submitted
   in PR 11826 by Anthony Mallet <anthony.mallet@ficus.yi.org>
 * Slightly optimize calculation of DOMAIN
2001-08-05 12:40:15 +00:00
ad
cc274c12b6 Better argument checking. 2001-08-04 16:55:46 +00:00
drochner
96914bd8e8 our dhclient-script diverged too much from the distributed one,
keep it separate
2001-08-03 14:30:19 +00:00
drochner
ecd0a03ec8 switch to reachover build from src/dist/dhcp 2001-08-03 14:13:55 +00:00
itojun
bb65ba4b13 fgetln() does not \0-terminate the result. 2001-08-03 09:18:58 +00:00
yamt
69ecbbeb80 Fix a bug that prevented %'s and \'s from being passed to the program
invoked.
from FreeBSD.
2001-08-03 04:10:51 +00:00
itojun
4acce1d060 include version number into binary to help diagnosis 2001-08-02 15:27:21 +00:00
itojun
366bd307b0 sync with 2001/8/2 KAME racoon/libipsec. 2001-08-02 12:15:00 +00:00
itojun
de2695eefc copyright clarification. via openbsd 2001-08-02 03:41:42 +00:00
itojun
2b18b04c59 updated copyright notice from Xerox. via openbsd 2001-08-01 16:45:28 +00:00
garbled
c63c221b86 Fix a bug in the multilist noted by Brett Lymn. When nothing was selected
from the popup, don't populate the field with a NULL buffer.

Edit the TODO list, removing a few fixed items from my bughunt tonight.
2001-08-01 09:08:55 +00:00
garbled
3815ce799a Add a -l argument to ypinit that allows adding servers in the format
server1,server2,server3 on the command line.  This allows the user to
optionally avoid the interactive mode of ypinit.  If the -l flag is not
supplied, the old behavior is retained.

This allows users to do things like rsh out creation of YP clients, and
sushi to generate yp clients/servers/slaves.
2001-08-01 07:01:03 +00:00
garbled
249cbcd0e5 add two more bugs 2001-08-01 01:02:55 +00:00
garbled
1092eb0c9d Add some known bugs for sushi.. lest I forget them. 2001-08-01 00:53:58 +00:00
chs
2df1fdaa53 remove spurious newline in an error message. 2001-07-29 21:24:57 +00:00
lukem
1c37a982fa enable WARNS=2 2001-07-29 09:59:12 +00:00
hubertf
b352d63150 Document -f option in synopsis 2001-07-27 22:35:51 +00:00
wiz
d2c504636c aquire -> acquire 2001-07-26 22:50:57 +00:00
lukem
bdf152b906 fix time display bug introduced in previous commit [hi christos! ;]
because it was using an unitialised variable.  change:
	ctime(&t); foo.bar = t
into
	t = foo.bar; ctime(&t)
2001-07-26 05:49:00 +00:00
wiz
64662a0528 Fix `pkg_add -u' for packages without dependencies.
Patch by Hubert Feyrer.
Addresses pkg/13536.
2001-07-24 14:45:16 +00:00
itojun
2dde33d97b sync with latest kame code. ndp -i won't print info for yet-to-be-initialized
interface.
2001-07-23 14:47:43 +00:00
itojun
71aa31a75a support multiple batteries (currently only # of batteris is visible -
need to tweak ioctl API more).  PR 10545.
2001-07-22 16:05:17 +00:00
wiz
a9356936b4 seperate -> separate 2001-07-22 13:33:58 +00:00
itojun
338143f0e5 follow kame p2p interface management rule. use /128 when we specify
both src and dst addr on p2p interface.  sync with kame
2001-07-21 02:28:06 +00:00
taca
6e662bb75d Put pidfile after daemonize. This would fix newsyslog(8) error. 2001-07-19 00:15:32 +00:00
lukem
c0e6fdedfc - add parsetype() (a la parsekey()) to parse the "type=xxx" arg. this improves
the error detection for invalid types, as well as shrinking binary size
- implement inotype() using ftype(), rather than duplicating the switch
- change "char *" arguments to "const char *"
2001-07-18 04:51:54 +00:00
wiz
e46d80027f Close some memory leaks.
Reported (incl. patch) by YAMAMOTO Takashi in pkg/12830.
2001-07-16 13:50:41 +00:00
manu
764096179a - No more lost error messages during syslogd startup, they now all appear on
stdout before syslogd becomes a daemon.
- Flags for setuid/setgid/chroot syslogd after initialization is completed
- Warning instead of silent ignoring for malformed lines (with spaces instead
of tags)
Approved by Christos
2001-07-16 05:04:47 +00:00
manu
ba6302b854 Removed two debug messages commited by mistake. Sorry about this. 2001-07-15 17:27:32 +00:00
hubertf
861dbe4370 Interface change for strip_txz(): now stores suffix 2001-07-15 00:34:14 +00:00
hubertf
f990f4a5a2 * Bugfix: if PLIST_SRC directly follows PLIST_CWD, ignore
the PLIST_CWD in creating the tar pipe.

   This takes care of pkg_create -p PREFIX -L FAKE
   where PREFIX does not exist at pkg creation time.

   From OpenBSD's rev. 1.9->1.10

 * Register PLIST_SRC before dependencies and conflicts so that the
   PLIST_CWD != PLIST_SRC hack works with dependencies present.

   From OpenBSD's rev. 1.10->1.11

 * improve error message to tell full path of exec() that failed
2001-07-15 00:23:14 +00:00
manu
6248c5cc45 strtol -> strtoul because we use an unsigned type (uid_t/gid_t)
isdigit with an unsigned char cast
2001-07-14 21:56:45 +00:00
manu
3ac4f70df5 errno is not tested any more if dbopen succeeds (to quote errno(2), "It
should only be examined after an error")
Added an additionnal chdir so that -o works with a file in the current
directory.
2001-07-14 14:50:44 +00:00
perseant
4e3fced95b Merge the short-lived perseant-lfsv2 branch into the trunk.
Kernels and tools understand both v1 and v2 filesystems; newfs_lfs
generates v2 by default.  Changes for the v2 layout include:

- Segments of non-PO2 size and arbitrary block offset, so these can be
  matched to convenient physical characteristics of the partition (e.g.,
  stripe or track size and offset).

- Address by fragment instead of by disk sector, paving the way for
  non-512-byte-sector devices.  In theory fragments can be as large
  as you like, though in reality they must be smaller than MAXBSIZE in size.

- Use serial number and filesystem identifier to ensure that roll-forward
  doesn't get old data and think it's new.  Roll-forward is enabled for
  v2 filesystems, though not for v1 filesystems by default.

- The inode free list is now a tailq, paving the way for undelete (undelete
  is not yet implemented, but can be without further non-backwards-compatible
  changes to disk structures).

- Inode atime information is kept in the Ifile, instead of on the inode;
  that is, the inode is never written *just* because atime was changed.
  Because of this the inodes remain near the file data on the disk, rather
  than wandering all over as the disk is read repeatedly.  This speeds up
  repeated reads by a small but noticeable amount.

Other changes of note include:

- The ifile written by newfs_lfs can now be of arbitrary length, it is no
  longer restricted to a single indirect block.

- Fixed an old bug where ctime was changed every time a vnode was created.
  I need to look more closely to make sure that the times are only updated
  during write(2) and friends, not after-the-fact during a segment write,
  and certainly not by the cleaner.
2001-07-13 20:30:18 +00:00
manu
2e20a48c80 Moved the errno=0 in the loop for opening the temp file. The problem was that
successful syscalls never set errno, and hence we could have had an inifinite
loop if the opening failed once and succeded on second attempt.
2001-07-13 15:54:22 +00:00
manu
7e7825ce44 FIxed a problem with string length (a leading / was appearing in w, who and others)
We were using rename() to create the target file from the temp file. Now the temp file is created in the same directory of the targer file so that rename() will always work (it needs to have the files in the same filesystem)
Using the -o file, the output file may be on a world writable directory, we hence open the temporary file using O_EXCL, and we loop trying different names until it works.
2001-07-12 20:46:39 +00:00
ad
e1036d7e68 Couple of nits. 2001-07-09 17:46:39 +00:00
ad
773c9cf920 errx() prints the newline for you. 2001-07-09 17:30:37 +00:00
itojun
48375d983c copy necessary variables from sys/netinet/tcp_debug.c.
not sure if it is the right way to deal with this.
2001-07-09 07:54:59 +00:00
itojun
052c0d9a64 sync with kame.
KAME rtsold.c 1.28
watch routing socket, and check for pcmcia card removal.
if pcmcia card gets removed, bring the interface state into IFS_DOWN.

KAME rtsold.c 1.29
changed the timeout period after sending MAX_RTR_SOLICITATIONS solicitation
from RTR_SOLICITATION_INTERVAL to MAX_RTR_SOLICITATION_DELAY according to
the last paragraph of RFC 2461 Section 6.3.7.
in response to a comment from Pekka Savola <pekkas@netcore.fi>
2001-07-09 06:04:28 +00:00
manu
896577bca5 We use rename() to produce the dev.db file, and rename() is not able to move
files across filesystems. Hence we use /var/run for dev.tmp, since dev.db
will be in /var/run.
2001-07-08 20:01:43 +00:00
wiz
dd75462fd1 Uppercase cpu. 2001-07-08 18:19:16 +00:00
simonb
79f5a137af Xref getbsize(3). 2001-07-08 15:34:13 +00:00
abs
46bc122c3c Do not try to reference dbm(3) 2001-07-06 18:07:15 +00:00
manu
b971cc2b24 - Moved the temp file to /tmp instead of /var/tmp
- Added a O_EXCL flag so that we cannot open an existing file for temp file
2001-07-05 20:35:33 +00:00
manu
12cb15934b Added a missing .El 2001-07-05 20:33:56 +00:00
manu
b70b2499b0 Added flags to choose the location of the input device directory and the
output device database. Goal is to be consistent with other *_mkdb
utilities such as pwd_mkdb or kvm_mkdb.
2001-07-04 20:42:02 +00:00
christos
26dfd4a9a0 Fix bogus awk + sed combination to handle continuations and empty lines.
It broke a sequence of:

	key1 \
		value1 \
		value2 \
		value3 \


	key2 \
		value4 \


	etc.

Handle both the netgroup rule and the amd.home rule using a .USEBEFORE
macro rule, since they contain the same code.
XXX: Needs new make(1)
2001-07-03 18:15:06 +00:00
itojun
a42562635c sync .Fl with reality 2001-07-03 08:52:00 +00:00
itojun
338aa1c650 -DLIBWRAP will enable libwrap-based filtering on UDP socket messages.
PR 13348
2001-07-01 16:23:42 +00:00
gmcgarry
32fc55d6d2 Don't pack locators. Introduce a new commandline option to
restore the previous behaviour of packing locators.

Results in a 2.5KB increase in size for the current i386 GENERIC
kernel.  My custom kernel resulted in a 12-byte increase.
2001-07-01 02:46:47 +00:00
itojun
55ae625187 faith(4) is now documented in RFC3142. 2001-06-30 01:01:36 +00:00
itojun
5237fd7778 have sshd listed in use_libwrap[].
From: Frederick Bruckman <fredb@immanent.net>
To: <tech-userlevel@netbsd.org>
Date: Fri, 29 Jun 2001 11:57:14 -0500 (CDT)
2001-06-30 00:56:28 +00:00
enami
ab05795faa Fix tcpdump path. 2001-06-27 05:17:32 +00:00
itojun
b12a7f19d9 drop setgid. suggested by deraadt 2001-06-26 17:10:33 +00:00
itojun
d54eb3a39d change tcpdump dir to refer to. Daniel Carosone <dan@geek.com.au> 2001-06-26 13:43:29 +00:00
itojun
230b44a44a switch to use src/dist/tcpdump. source code has been checked and the new
tree organization should give the same (or more) decoding functionalities.
2001-06-25 19:41:19 +00:00
mrg
b5ca908e21 extend file size lossage message. 2001-06-25 16:40:50 +00:00
mrg
e1633c19d7 printer of "" becomes the DEFLP (the default printer, "lp") 2001-06-25 15:29:12 +00:00
mrg
a062d79672 use DEFLP instead of "lp". 2001-06-25 11:04:51 +00:00
ad
0767fc8d4b Missing space in usage(); from OpenBSD. 2001-06-25 08:47:29 +00:00
itojun
85856f18c0 do not make "useradd foo -s bar" to ignore "-s bar" silently. require
exactly one username.
2001-06-23 02:42:32 +00:00
christos
44f22a6994 make things compile again with -DSMALL 2001-06-23 00:10:06 +00:00
eeh
09af009af3 Fix typo in previous. (damn vi.) 2001-06-21 22:58:36 +00:00
eeh
5e8c69237f Add sparc64 support for both sparc and sparc64:
ELF64 for 64-bit sparc64 kernels.
ELF32 for 32-bit sparc and sparc64 kernels.
a.out for old sparc kernels.
2001-06-21 22:57:25 +00:00
christos
e01ff467fb order the eE options as the others. 2001-06-21 20:58:18 +00:00
drochner
65ae86a522 more obsolete files 2001-06-19 14:55:30 +00:00
drochner
e47db61069 some more files which disappeared in the distribution 2001-06-19 14:45:46 +00:00
drochner
9eb0a9bd7a add missing comma 2001-06-19 14:34:08 +00:00
drochner
e3ef27af9b iron out some unnecessary differences between the distribution and the
NetBSD version
2001-06-19 14:22:45 +00:00
drochner
ad33c4e9c3 these are not in the original distribution anymore 2001-06-19 13:58:30 +00:00
drochner
d94b2b3963 fix some obviously botched error returns 2001-06-19 13:54:58 +00:00
wiz
3f9984fc90 existent', not existant' 2001-06-19 13:42:07 +00:00
wiz
f3f6c5b675 accessible' only has one a'. 2001-06-19 12:52:20 +00:00
ad
14edc766df Check for transport failure before looking at the status code in the reply. 2001-06-19 10:46:16 +00:00
ad
c8adbae640 Refer to the i2ocfg package. 2001-06-19 10:44:03 +00:00
christos
a2458a3f05 use better/quicker shell syntax 2001-06-18 19:43:55 +00:00
drochner
8d1282dd17 update for moved toisc.c 2001-06-18 19:16:10 +00:00
drochner
ef869f8376 merge 3.0rc8 2001-06-18 19:01:50 +00:00
drochner
5233105195 ISC DHCP 3.0rc8 2001-06-18 18:13:13 +00:00
wiz
ccfe29f3cf Symmetric has one s and two m's. 2001-06-18 11:23:00 +00:00
lukem
6a56b422c8 use mktemp(1) as appropriate 2001-06-18 11:21:54 +00:00
itojun
993a4807cb copyright clarification. sync with tcpdump.org.
based on communiation with the author, Jeffrey Mogul <mogul@pa.dec.com>.
by Jakob Schlyter <jakob@openbsd.org>
2001-06-15 02:07:06 +00:00
fredette
fd8d9e615b Merge in ndbootd-0.5. 2001-06-13 21:38:30 +00:00
fredette
74cc4fdaac Import of Matt Fredette's ndbootd-0.5 boot program for Sun2 machines. 2001-06-13 21:35:57 +00:00
wiz
c03a48d64f withough -> without 2001-06-13 10:45:57 +00:00
itojun
a167adffce need va_start/end for every vfprintf(). from markus@openbsd. sync with kame 2001-06-13 04:31:52 +00:00
wiz
0a600be867 receive, not recieve 2001-06-12 15:17:10 +00:00
wiz
40ac848024 Fix various misspellings of compatible/compatibility. 2001-06-11 01:50:48 +00:00
wiz
5811c27b4d Remove trailing dot from .Nd, and a bogus comment line (probably left
over from example man page).
2001-06-08 23:57:43 +00:00
fredette
de800ed660 Added support for listing multiple additional names on
a `machine' line.  For each of these subarches, its
arch/${SUBARCH}/conf/files.${SUBARCH} is included, and
a symlink ${SUBARCH} -> arch/${SUBARCH}/include is made.
This will for a "richer structure" and easier code
sharing under sys/arch.
2001-06-08 12:47:06 +00:00
mrg
5d9bc91556 new `-n' switch to avoid looking up hostnames. 2001-06-08 04:16:28 +00:00
wiz
d422b80ea9 Uppercase Dt argument. 2001-06-05 11:58:55 +00:00
wiz
1375e0081d Minor fixes. 2001-06-05 11:40:04 +00:00
wiz
bca0e833cf Uppercase .Dt argument. 2001-06-05 11:38:42 +00:00
wiz
5b6ad2d2f5 Drop argument of .Os. 2001-06-05 11:31:21 +00:00
wiz
9322798d06 No argument for .Os. 2001-06-05 10:27:02 +00:00
wiz
2c753b6eca Add .Os. 2001-06-05 10:26:26 +00:00
wiz
48a36de9c0 Don't give .Os an argument, not even 'NetBSD' (default includes version). 2001-06-05 10:08:03 +00:00
mrg
7276c20511 don't #define _LKM to work around header lossage; it is no longer necessary. 2001-06-05 09:20:12 +00:00
itojun
dc1b085d64 prevent overflow of lifetime value. sync with kame 2001-06-03 09:26:04 +00:00
itojun
45b2928589 do not visit mtrace6 2001-06-03 06:09:10 +00:00
itojun
780e7ac88c remove pim6[sd]d from the tree. the software had a restrictive license
than we can handle.  hope to re-enable it as pkgsrc, or to re-enable it
into basesrc if license updates.
2001-06-02 00:34:00 +00:00
joda
073d0b6122 (usage): correct number of arguments to fprintf 2001-05-28 07:59:53 +00:00
itojun
8d42ab239c remove extra \n even more. sync with tcpdump.org 2001-05-27 04:57:19 +00:00
itojun
59dea86dc0 disable DNSSEC build, for two reasons. (1) restrictive license
(2) due to protocol changes BIND8 DNSSEC code is not really useful
2001-05-27 04:39:40 +00:00
itojun
840fe8eadc put -NOESW to version number if MKCRYPTO != yes, to sync better with original
BIND8 makefiles.
2001-05-27 04:08:04 +00:00
he
ccc114118a Add `E' to getopt string, so the -E option is recognized.
Should fix PR#13008.
2001-05-26 21:20:28 +00:00
itojun
46636f1249 remove too many \n for icmp6 too big 2001-05-26 12:31:56 +00:00
christos
4fce6523d7 make the -DSMALL option work again. 2001-05-26 00:37:45 +00:00
fredette
735202e79f Merge in ndbootd-0.4. 2001-05-23 02:59:35 +00:00
fredette
bbf2feac6e Import of Matt Fredette's ndbootd boot program for Sun2 machines. 2001-05-23 02:49:37 +00:00
fredette
f2f22b5de0 sunndd has been renamed ndbootd. 2001-05-22 14:52:24 +00:00
fredette
ee3099f75d Note that sunndd has been renamed ndbootd. 2001-05-22 14:50:31 +00:00
fredette
ab467667c7 Finished the 3rdparty import procedure for the ndbootd
package: Added RCS IDs, a Makefile, added to 3RDPARTY.
Also removed sunndd from 3RDPARTY.
2001-05-22 14:41:59 +00:00
fredette
2d0f1618a6 Import of Matt Fredette's ndbootd boot program for Sun2 machines. 2001-05-22 14:20:49 +00:00
agc
bd6e892efe Apply the -I substitution logic for @cd as well as @cwd (just for
completeness, as @cwd will be used almost everywhere, and @cd is
deprecated).
2001-05-21 12:06:30 +00:00
agc
8f6a8bb131 When adding the checksums for the individual file entries in the generated
+CONTENTS file, if the entry is also the last in the package's list, adjust
the tail pointer accordingly.
2001-05-21 12:05:20 +00:00
agc
83dc57abd5 Display the correct directory for the @src directive if -I has been
specified.
2001-05-21 12:03:53 +00:00
agc
95a52b2709 Add -I argument to pkg_create so that the real prefix can be specified
for the @src and @cwd PLIST directives.

Bump version number.
2001-05-21 09:17:28 +00:00
uwe
2e8ee296d6 Don't discard all the hard work of setdefentries() and uniquepath().
Fixes bin/12742.  Reviewed by jdolecek.
2001-05-20 22:05:30 +00:00
agc
6ccfedb598 Add -U argument to pkg_create - by default, all files are added to the
pkgdb.byfile.db database. If -U is specified on command line to
pkg_create, don't add the PLIST entry to pkgdb.byfile.db.

Bump version number.
2001-05-18 13:21:38 +00:00
minoura
81e8dc3cac Correct a typo.
Pointed out by MAEKAWA Masahide <maekawa@kbug.gr.jp>.
2001-05-18 07:48:07 +00:00
itojun
4cd3525823 upgrade to 8.2.4. 2001-05-17 22:59:37 +00:00
fredette
1605cd00aa Build sunndd, used to netboot Sun2 machines. 2001-05-17 21:08:54 +00:00
fredette
a83cae8ce3 Finished the 3rdparty import procedure for the sunndd
package: Added RCS IDs, a Makefile, added to 3RDPARTY.
2001-05-17 20:42:08 +00:00
fredette
d21eeebf46 Import of Matt Fredette's sunndd boot program for Sun2 machines. 2001-05-17 20:15:26 +00:00
tsubai
eef5fa50d3 Big-endian support. 2001-05-16 10:45:36 +00:00
kleink
80fd97ca8d Need <bsd.own.mk> now. 2001-05-15 17:07:49 +00:00
kleink
dccee15238 Don't install the example config if MKSHARE=no. 2001-05-15 17:05:54 +00:00
assar
0eaf453fc3 handle badly formattted access RPC
should fix PR bin/12765
2001-05-15 05:59:13 +00:00
ichiro
a420303a55 It enabled it to control roaming mode and authentication mode. 2001-05-15 04:16:21 +00:00
veego
221a388192 Regenerated for am-utils 6.0.6.
The configure script was fixed, so the default output of configure is now
fine.
2001-05-13 18:11:56 +00:00
veego
2f8b710391 Bump the minor number because of the addition of haseq and hasmnteq. 2001-05-13 18:11:12 +00:00