Compare commits

...
1361 Commits
Author SHA1 Message Date
Xin LI e83e866954 MFC r176575:
In pass1(), cap inosused to fs_ipg rather than allowing arbitrary
number read from cylinder group.  Chances that we read a smarshed
cylinder group, and we can not 100% trust information it has
supplied.  fsck_ffs(8) will crash otherwise for some cases.

PR:		bin/138043
Reminded by:	mckusick
2010-01-07 01:57:13 +00:00
Xin LI 0dc93de7c5 MFC r201137
Grammar fix.

Submitted by:	Kenyon Ralph <kenyon kenyonralph com>
2010-01-04 01:15:39 +00:00
Xin LI b0a1c2ff89 Explicitly say that this is an internal library which is intended to be
used within FreeBSD base system only, and discourage user applications
from using it.  User applications should use the expat version from the
ports/package collection.

Reviewed by:	simon (earlier version)
2009-12-27 07:04:21 +00:00
Xin LI d7fc6fc731 MFC r200392:
Apply two vendor fixes for CVE-2009-3720.

Security:	CVE-2009-3720
2009-12-14 01:06:55 +00:00
Daniel Gerzo f4990bd2c7 MFC rev. 180024:
- Mark the section describing return values with an appropriate
  section flag.

PR:		180024
2008-06-30 09:18:49 +00:00
Daniel Gerzo 0db6814620 - MFC rev. 180030 and 180113:
- add description of the MLINK error
  - bump a date

PR:		docs/123019
2008-06-30 09:10:04 +00:00
Paul Saab a39517e5af MFC: r179705
Add support for the P212, P410, P410i, P411, and P812 HP Smart Array
controllers.
2008-06-10 18:40:38 +00:00
Peter Wemm 728d07f2f8 Disown ncurses, as a multi-branch commit test, to make sure the exporter
handles it.
2008-05-31 22:32:51 +00:00
Xin LI 075e5d09ee MFC revision 1.52
date: 2008/05/10 01:27:23;  author: delphij;  state: Exp;  lines: +6 -0

Add support for LSI 1078DE (ServeRAID-AR10is SAS/SATA Controller)
2008-05-24 00:42:53 +00:00
Brooks Davis 72d0b15870 getopt.c is public domain. Add a comment to that effect.
Remove confusing README.

PR:		bin/98911
Submitted by:	Jason McIntyre <jmc at kerhand dot co dot uk>
Obtained from:	OpenBSD
2008-05-19 02:49:02 +00:00
Mark Linimon 7c327373e8 MFC revision 1.21:
Add 'arm' category.
2008-04-23 04:09:17 +00:00
Mark Linimon ddfdaa0d42 MFC revision 1.20:
Update the FILES section which has been wrong for some time.
2008-04-23 04:07:13 +00:00
Xin LI f6c7699f92 MFC: Allow stand.h to be included for multiple times 2008-04-18 04:23:05 +00:00
Xin LI 1647042bd7 MFC: Handle bzip2/zlib changes without using patches,
by doing the work in a programmatical way.  This is an
accumulative patch of the following changes:

	Makefile: 1.46-1.53
	bzipfs.c: 1.7

as well as removal of the now unneeded files.
2008-04-18 00:01:55 +00:00
Xin LI 41afe15d38 Document SA-08:05.openssh 2008-04-17 19:10:57 +00:00
Xin LI 84592558e2 Mention bzip2 1.0.5 MFC. 2008-04-17 01:02:03 +00:00
Xin LI f2231bb372 MFC: bzip2 1.0.5 2008-04-17 00:53:13 +00:00
Colin Percival 88e224a8d2 Fix logic error in sshd(8) concerning the handling of failed
attempts to bind ports for X11 forwarding.

Security:	FreeBSD-SA-08:05.openssh
2008-04-17 00:00:41 +00:00
Bruce A. Mah d0b7eb2834 MFC: BTX real mode, GNOME 2.22.
Bump copyright date while here.
2008-04-06 05:44:11 +00:00
Max Khon e658937aa4 Conditionally add mklocale and gencat to bootstrap-tools to allow to build
RELENG_5 on later FreeBSD versions.
2008-03-31 19:28:13 +00:00
Edwin Groothuis 0c2811ebc3 MFC of tzdata2008b 2008-03-25 03:50:01 +00:00
Edwin Groothuis 3eb98665bb MFC of 1.48
Add projects-all collection to cvs-supfile

PR:		misc/121680
Submitted by:	"Philip M. Gollucci" <[email protected]>
2008-03-20 11:27:15 +00:00
Garrett Wollman 6650f75bc0 MFC rev. 1.26:
stdio is currently limited to file descriptors not greater than
  {SHRT_MAX}, so {STREAM_MAX} should be no greater than that.  (This
  does not exactly meet the letter of POSIX but comes reasonably close
  to it in spirit.)
2008-03-13 02:33:20 +00:00
Robert Watson c16d423e0b Merge db_command.c:1.77 from HEAD to RELENG_5:
When killing a user process from DDB, check that the requested signal is
  > 0 rather than >= 0, or we will panic when trying to deliver the signal.

  PR:             100802
  Submitted by:   Valerio Daelli <valerio.daelli at gmail.com>
2008-03-10 11:38:57 +00:00
Robert Watson 866195b865 Merge db_input.c:1.39 from HEAD to RELENG_5:
Reserve two bytes at the end of the DDB input line in db_readline() to
  hold the newline and nul terminator.  Otherwise, there are cases where
  garbage may end up in the command history due to a lack of a nul
  terminator, or input may end up without room for a newline.

  PR:             119079
  Submitted by:   Michael Plass <[email protected]>
2008-03-10 10:24:12 +00:00
Robert Watson 8678dddbb7 Merge db_input.c:1.38 from HEAD to RELENG_5:
When redrawing an input line, count backspaces to get to the beginning of
  the input field from the current cursor location, rather than the end of
  the input line, as the cursor may not be at the end of the line.
  Otherwise, we may overshoot, overwriting a bit of the previous line and
  failing to fully overwrite the current line.

  PR:             119079
  Submitted by:   Michael Plass <[email protected]>
2008-03-09 14:54:59 +00:00
Edwin Groothuis 302d252dc2 MFV: tzdata2008a
Notable changes:

- Chilis DST has been extended for 3 weeks.
- No leapsecond in 2008

Approved by:	grog@ (mentor)
2008-03-09 11:23:08 +00:00
Gregory Neil Shapiro 0f94e75aa3 MFC: Fix quoting for the dnsbl example -- m4 misparses quoted strings with
commas due to our deconstruction of the line in cf/feature/dnsbl.m4.

     PR:             120038
     Submitted by:   mattijs vreeling

     Revision  Changes    Path
     1.36      +1 -1      src/etc/sendmail/freebsd.mc
2008-02-24 01:03:33 +00:00
Gregory Neil Shapiro 4b63aa6677 MFC: Use better examples (and comment them out for safety).
PR:             118837
     Submitted by:   Matthew Seaman

     Revision  Changes    Path
     1.4       +13 -6     src/etc/mail/access.sample
2008-02-24 01:00:07 +00:00
Bruce A. Mah eec111f14e New errata: SA-08:01.pty (somewhat belatedly), SA-08:03.sendfile,
SA-08:04.ipsec.
2008-02-16 16:30:45 +00:00
Markus Brueffer c4c8f3531b MFC rev. 1.50:
Fix calculation of descriptor tag checksums. According to ECMA-167, Part 4,
  7.2.3, bytes 0-3 and 5-15 are used to calculate the checksum of a descriptor
  tag.

Approved by:    emax (mentor)
2008-02-16 16:21:26 +00:00
Bruce A. Mah 01c34ade46 MFC: SA-08:03.sendfile, SA-08:04.ipsec, tzdata2007k. 2008-02-16 16:09:43 +00:00
Simon L. B. Nielsen 45351091ea Fix sendfile(2) write-only file permission bypass. [08:03.sendfile]
Fix IPsec null pointer dereference panic. [SA-08:04.ipsec]

Security:	FreeBSD-SA-08:03.sendfile
Security:	FreeBSD-SA-08:04.ipsec
2008-02-14 11:49:38 +00:00
Ed Maste 45a48a221d MFC revisions 1.232 and 1.236:
Remove DIAG code that discards oversized packets.
  There has been general consensus that this was a bad idea
2008-02-12 22:27:27 +00:00
Xin LI f812eedea3 MFC revision 1.32
date: 2008/01/12 00:54:47;  author: delphij;  state: Exp;  lines: +4 -0
Plug memory leaks that is observed when argbuf or argspc is used in the
context.

Submitted by:	Michal Vranek <michal.vranek seznam cz>
PR:		bin/118380
2008-02-11 00:31:23 +00:00
Marius Strobl 43621b9a38 MFC: 1.36
Add missing locking for SBus controllers.
2008-01-27 17:43:30 +00:00
Xin LI 32b1472d98 MFC revision 1.7
date: 2008/01/12 00:11:26;  author: delphij;  state: Exp;  lines: +4 -4
 - Handle the case where interface from "middle" is missing by
   more carefully inspecting the return value from sysctl(3). [1]
 - Use calloc instead of malloc+memset of zero.

Submitted by:	Alexander Chernikov <admin su29 net> [1]
PR:		bin/119581
MFC after:	2 weeks
2008-01-26 21:59:10 +00:00
Colin Percival b5068b1ada Fix issues which allow snooping on ptys.
Security: FreeBSD-SA-08:01.pty
2008-01-14 22:57:06 +00:00
Peter Wemm 7656d60a2a MFC: rev 1.4: forward compatability with cvs-1.12 repository 2008-01-07 09:11:23 +00:00
Edwin Groothuis 1fdc5a4248 MFC of tzdata2007k.
Approved by: re (ken smith)
2008-01-06 07:30:02 +00:00
Edwin Groothuis cccf954d9c Update iso3166 with the data from Newsletter VI-1 2007-09-21:
Added SAINT BARTHELEMY (BL) and SAINT MARTIN (MF).

Approved by: re (ken smith)
2008-01-06 07:13:35 +00:00
Gabor Kovesdan 69092c1c04 MFC rev 1.13:
- Add doc/hu_* and doc/mn_* to the refuse examples so that include all
  of the currently used languages
2007-12-10 18:51:40 +00:00
Gabor Kovesdan b0e27946ae MFC rev 1.14:
- Add doc/hu_* and doc/mn_* to the sample refuse file so that it includes all
  of the languages
2007-12-10 18:51:15 +00:00
Ed Maste d86365b80f Merge aac_debug.c:1.23 from HEAD to RELENG_6:
Respell 'Conatainer' as 'Container'.

  Reported by:    Toomas Aas <toomas dot aas at raad dot tartu dot ee>
2007-12-10 18:16:50 +00:00
Bruce A. Mah feefbf9cc4 New errata: FreeBSD-SA-07:09.random, FreeBSD-SA-07:10.gtar. 2007-11-30 05:58:06 +00:00
Bruce A. Mah d6420311ea MFC: FreeBSD-SA-07:09.random.
New release note:  FreeBSD-SA-07:10.tar.
2007-11-30 05:40:09 +00:00
Simon L. B. Nielsen cc60f21197 Correct a random value disclosure in random(4). [07:09]
Correct a gtar directory traversal vulnerability. [07:10]

Security:	FreeBSD-SA-07:09.random
Security:	FreeBSD-SA-07:10.gtar
2007-11-29 16:08:54 +00:00
Max Khon d136af1154 MFC:
Import two binutils header files from FSF 2.15 branch.
These fix binutils compilation on i386/amd64 with GCC 4.1 and
have no other effect.

This fixes RELENG_5 build on RELENG_7/HEAD.
2007-11-24 06:53:09 +00:00
Gregory Neil Shapiro 6989ffaee7 Forced commit to .mc files to force creation of new .cf files for mergemaster.
Approved by:    re (kensmith)
2007-11-22 16:20:31 +00:00
Gregory Neil Shapiro c4b61c5157 MFC: sendmail 8.14.2 2007-11-11 17:09:13 +00:00
Doug Barton 626d72695d MFC version 1.13, update of IP address for l.root-servers.net 2007-11-05 00:00:41 +00:00
Bruce A. Mah 2fd39e913c MFC: SA-07:08.openssl, tzdata2007h, GNOME 2.20.1, KDE 3.5.7. 2007-10-28 17:02:54 +00:00
Doug Barton db34537ff2 MFC version 1.27:
1. Determine the location of the rndc* binaries relative to $command
2. Make the stop routine work more like rc.subr's, but try rndc first
3. Allow the rndc.key file to be owned by root OR the named_uid user
2007-10-28 00:30:18 +00:00
Darren Reed d24303edda Only write the PID file out when becoming a daemon.
PR:		bin/87891
2007-10-27 16:41:12 +00:00
Edwin Groothuis 529a9039b4 MFC of 1.11
Teach makewhatis.c to treat .SS with the same severity as .SH.

At least one port (net-mgmt/net-snmp) creates man-pages which are
in the format:

.SH NAME
The Net-SNMP agent \- The snmp agent responds to SNMP queries from manag
ement stations.

.PP
.SS "Modules"

At this moment, makewhatis determines the end of the .SH NAME section
as where it finds .SH again, but there is none here, is it "terminated"
by the .SS.

PR:		bin/116706
Submitted by:	edwin@
2007-10-25 03:53:46 +00:00
Mike Makonnen 8b2418ebd9 MFC:
rev. 1.10
	The POP daemon's temporary mail file has a leading dot ('.').
	This was lost in the shell script rewrite of the rmuser command.
2007-10-19 07:55:52 +00:00
Edwin Groothuis 21a70d8716 MFC of src/share/zoneinfo
MFV: tzdata2007h
2007-10-18 13:05:49 +00:00
Edwin Groothuis 81e6223503 Whitespace chase after bad copy+paste.
Noticed by: John Baldwin
2007-10-10 00:09:08 +00:00
Edwin Groothuis 08899f7c52 MFC:
Describe the process of importing new zoneinfo data and updating
it into CVS.

PR:             conf/116901
2007-10-09 02:37:21 +00:00
Simon L. B. Nielsen 500cc0d327 Correct a buffer overflow in OpenSSL SSL_get_shared_ciphers().
Security:	FreeBSD-SA-07:08.openssl
2007-10-03 21:42:00 +00:00
Edwin Groothuis 1ea0c6f737 MFCs
Dutch calendar
    More dates: Sint Maarten, Dierendag, Trinitatis
    Fix spelling: Carnaval
    Add more of the Royal Family.

Croation calendars:
    Update to calendar/calendars/hr_HR.ISO_8859-2/calendar.praznici
    with fixes and new dates.

PR:             conf/26658
Submitted by:   Josip Rodin <[email protected]>
2007-09-28 02:51:26 +00:00
Edwin Groothuis 8974324517 MFC: Fix man(1) to allow .so to reference a compressed file
Original PR description:

	man(1) can't handle compressed included files.

	Some ports will install with compressed manpages. man handles
	this by looking for the .gz version of a man source file.
	It is also common to include other files with the .so
	directive where commands or functions share a man page.
	Traditionally ports have had to handle this by either not
	compressing the manpages, or using the _MLINKS macro in the
	port makefile to create symlinks to the actual source file,
	rather than using .so versions. Notably, the current version
	of Xorg port breaks. See ports/113096 and ports/115845.

PR:             bin/115850
Submitted by:   Callum Gibson <[email protected]>
2007-09-28 02:31:30 +00:00
Edwin Groothuis 083b090bc3 Massive MFC for all calendar files which have been updated in the
past but were never MFCd.

PR:		conf/61641 conf/70252 conf/107453 conf/113285 conf/113642 (and others)
Submitted by:	various
2007-09-14 01:32:31 +00:00
cvs2svn 9047584872 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2007-09-07 03:23:07 +00:00
Edwin Groothuis 770b29a3f0 MFC of src/share/zoneinfo
MFV: tzdata2007g

PR:             conf/115706
Submitted by:   edwin@
Obtained from:  ftp://elsie.nci.nih.gov/pub/
2007-09-02 01:24:08 +00:00
Remko Lodder 3ab60dc102 Semi-MFC Makefile v 1.37 (changed in order to reflect 5.X behaviour)
Make zoneinfo optional so that a filesystem upgrade/update does not overwrite
  possibly installed thirdparte zoneinfo databases (from ports for example).

  Submitted by: Mark Andrews <Mark_Andrews at isc dot org> (original patch
  rewritten by me to be more consistent with the new practise).
  Approved by: re (kensmith)
  Approved by: imp (mentor)
  Reviewed by: ru (some time ago already)

Approved by: imp (mentor, implicit MFC)
2007-08-26 16:01:06 +00:00
Ed Maste a3b7410a54 MFC elimination of compiler warnings:
sha2.c 1.8:
  GCC 3.4.6 gets confused on this file and produces bogus warning.
  Shut it up.

sha2.c 1.9:
  Initialize T1 to silent gcc warning.
2007-08-22 21:08:30 +00:00
Simon L. B. Nielsen 5ac3716248 Correct a bug in the patch for FreeBSD-SA-07:01.jail which prevented
jails with custom fstab's from starting due to use of incorrect
variable. [1]

Correct buffer overflow in tcpdump(1). [SA-07:06]

Reported by:	Joel Hatton <[email protected]> [1]
Security:	FreeBSD-SA-07:06.tcpdump
2007-08-01 20:47:12 +00:00
Bruce A. Mah bb70e18b57 New (somewhat belated) errata: SA-07:05.libarchive. 2007-07-30 16:53:55 +00:00
Bruce A. Mah 582a9a05d7 Updated release note: BIND 9.3.4-p1. 2007-07-26 14:45:57 +00:00
Doug Barton f6a07f4614 Update to 9.3.4-P1, which fixes the following:
The DNS query id generation is vulnerable to cryptographic
analysis which provides a 1 in 8 chance of guessing the next
query id for 50% of the query ids. This can be used to perform
cache poisoning by an attacker.

This bug only affects outgoing queries, generated by BIND 9 to
answer questions as a resolver, or when it is looking up data
for internal uses, such as when sending NOTIFYs to slave name
servers.

All users are encouraged to upgrade.

See also:
http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2007-2926
2007-07-25 08:24:40 +00:00
Xin LI 0565f95e3e MFC: Close race conditions between fork() and [sg]etpriority()'s
PRIO_USER case, and possibly also other places that deference p_ucred.
2007-07-20 15:29:34 +00:00
Bruce A. Mah ee77c6a33d MFC: SA-07:05.libarchive. 2007-07-13 17:50:25 +00:00
Colin Percival 7f44f9299b Correct multiple security issues in how libarchive handles corrupt
tar archives, including a potentially exploitable buffer overflow.

Approved by:	so (cperciva)
Reviewed by:	kientzle
Security:	FreeBSD-SA-07:05.libarchive
2007-07-12 15:01:56 +00:00
Remko Lodder 397403e869 MFC rev 1.33 mdmfs.c
o For this change I needed to modify a little extra, since the RELENG_5 version
  works different then the RELENG_6 or HEAD version that we currently have.
  I "backported" the -n change to RELENG_5 as well, without modifying the
  current behaviour for the other options etc.

    -n is used by newfs to tell "do not generate a .snap directory" instead of
    specifying rotational-positions, reflect that in the command arguments.

    PR: bin/110178
    Submitted by: Alex Kozlov <spam at rm-rf dot kiev dot ua>
    Approved by: imp (mentor)

Approved by:	imp (mentor, implicit)
2007-07-07 11:29:27 +00:00
Remko Lodder c5f5a46091 MFC v 1.66 udf_vnops.c
Correct corrupt read when the read starts at a non-aligned offset.

        PR: kern/77234
        Approved by: imp (mentor)
        Requested by: many many people
        Submitted by: Andriy Gapon <avg at icyb dot net dot ua>

Approved by:    imp (implicit, mentor)
2007-06-26 07:00:39 +00:00
Gregory Neil Shapiro 73448b552f Sort SENDMAIL_* entries so I can...
MFC: You can never have enough documentation.

     Document the SENDMAIL_ALIASES, SENDMAIL_MAP_SRC, SENDMAIL_MAP_TYPE, and
     SENDMAIL_START_SCRIPT
     .Xr make.conf 5
     variables.
     These are used in
     .Pa /etc/mail/Makefile .

     PR:       conf/40548

     Revision  Changes    Path
     1.140     +40 -0     src/share/man/man5/make.conf.5
2007-06-18 04:36:10 +00:00
Gregory Neil Shapiro 6399dd9581 MFC: Add a new rc.conf variable, sendmail_rebuild_aliases, which tells
/etc/rc.d/sendmail whether or not to run newaliases if the database
     is missing or the aliases text file is newer than aliases.db.

     In my opinion, the aliases file should never be automatically rebuilt.
     The current text form could represent a work in progress.  Therefore,
     in FreeBSD 7.0, this new option will default to "NO".  When this rc.d
     change is MFC'ed, it will need to remain "YES" to maintain backward
     compatibility.

     PR:             conf/86252
     Approved by:    re (kensmith)
     MFC after:      3 days

     Revision  Changes    Path
     1.316     +1 -0      src/etc/defaults/rc.conf
     1.17      +10 -8     src/etc/rc.d/sendmail
     1.1039    +6 -0      src/release/doc/en_US.ISO8859-1/relnotes/article.sgml
2007-06-15 02:39:36 +00:00
JINMEI Tatuya c6e7c74d01 MFC:
cleanup about the reassembly structures and routine:
  - removed unused structure members
  - fixed a minor bug that the ECN code point may not be restored correctly

Approved by:    ume (mentor)

src/sys/netinet6/frag6.c:  	1.31
src/sys/netinet6/ip6_var.h:  	1.38
2007-06-11 17:04:10 +00:00
JINMEI Tatuya e3a1c0d0fe MFC:
fixed memory leak for IPv6 multicast membership information associated
with interface addresses.

Approved by:	gnn (mentor)

src/sys/netinet6/in6.c:			1.71
src/sys/netinet6/in6_ifattach.c:	1.36
src/sys/netinet6/in6_var.h:		1.31
2007-06-10 17:20:04 +00:00
David Malone 9e9919ec35 MFC 1.209: Don't verify UDP IPv4 checksum in-place. 2007-06-10 07:29:08 +00:00
Pav Lucistnik 571ee85761 MFC addition of bsd.port.options.mk 2007-06-08 16:05:32 +00:00
cvs2svn fb8d6799ac This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2007-06-01 15:17:52 +00:00
Bruce A. Mah 00aad30744 MFC: Add a few sentences of caution for Microsoft Vista users who might
want to try resizing partitions.

	install.sgml	1.37 -> 1.39
2007-05-29 14:31:42 +00:00
JINMEI Tatuya ef9f934864 MFC:
- Disabled responding to NI queries from a global address by default as
  specified in RFC4620.  A new flag for icmp6_nodeinfo was added to enable the
  feature.
- Also cleaned up the code so that the semantics of the icmp6_nodeinfo
  flags is clearer (i.e., defined specific macro names instead of using
  hard-coded values).

Approved by:    gnn (mentor)

src/sys/netinet/icmp6.h:	1.21
src/sys/netinet6/icmp6.c:	1.76
src/sys/netinet6/in6_proto.c:	1.43
2007-05-25 06:35:46 +00:00
Colin Percival 87b0c36670 Fix buffer overflow in libmagic(3).
Security:	FreeBSD-SA-07:04.file
Approved by:	so (cperciva)
2007-05-23 16:13:20 +00:00
Matt Jacob 12c68c07cf MFC increase bitfield to be wide enough to take the default value that
gets set into it.
2007-05-23 00:25:18 +00:00
Pav Lucistnik dbea75a0df Sync with HEAD 2007-05-20 22:21:43 +00:00
Bruce A. Mah 44215cf18b MFC: Mention tools (specifically ntfsresize, GParted, and SystemRescueCD)
that can be used for resizing NTFS partitions (to make room for
FreeBSD).

	install.sgml	1.35 -> 1.37

PR:		65477
2007-05-18 14:13:15 +00:00
David Xu 46638d3391 MFC Revision 1.123:
> Fix a TLS memory leak.
2007-05-15 08:10:15 +00:00
George V. Neville-Neil 14190b1a4f MFC rev 1.42
Reduce the default number of header options that the IPv6 protocol
stack will process from 50 to 15.  As this is a sysctl variable it
can be tuned up or down at the user/administrator's whim.
2007-05-11 16:34:57 +00:00
Matt Jacob e138026a54 mfc: bad merge fix 2007-05-11 13:48:33 +00:00
Matt Jacob 9dc7f548f5 Fix pointy-hat problem with BUS_DMA_ROOTARG macro that caused problems for sparc64. 2007-05-11 06:29:23 +00:00
Matt Jacob 907ba3dd1e MFC to synchronize with -current. The bugs fixed are relatively few and
hopefully the bugs introduved are even fewer.
2007-05-08 17:47:08 +00:00
Peter Pentchev c6821a8f55 MFC rev. 1.35 - remove MSG_PEEK from the description of the send(2)
syscall; it is only relevant for incoming data.
2007-05-04 09:06:59 +00:00
David Malone 9691a5938f MFC: Man page improvements and don't put unix domain sockets into the
per-ip limits code.
2007-04-29 19:24:11 +00:00
Bruce A. Mah 2e11d85f1b New errata: FreeBSD-SA-07:03.ipv6. 2007-04-28 14:01:43 +00:00
Bruce A. Mah 12be7cd944 MFC: FreeBSD-SA-07:03.ipv6. 2007-04-28 13:52:51 +00:00
Gregory Neil Shapiro d57ecdd75e MFC: Bring in sendmail.org code from the future 8.14.2 release which restores
ABI compatibility to users of the libmilter.so shared library.
2007-04-27 03:33:51 +00:00
George V. Neville-Neil b6f2b298e6 Add a new sysctl net.inet.ip6.rthdr0_allowed, which is default off,
to disable the processing of Route Header Type 0 options in IPv6.
This is not really an MFC because currently in HEAD the processing
of these options is disabled unilateraly pending discussion at the IETF
on the future of such headers.

Suggested By: itojun
Reviewed By: jinmei
2007-04-24 11:44:22 +00:00
Gregory Neil Shapiro 0d5db4d597 Forced commit to .mc files to force creation of new .cf files for mergemaster. 2007-04-23 22:30:23 +00:00
Gregory Neil Shapiro 4afd022429 Include a note in the sendmail 8.14.1 release note regarding the libmilter
update.  Unfortunately, this problem (the need to recompile filters) was
found after the MFC.  The release engineering team has asked for this
instead of doing a full backout of sendmail 8.14 in the RELENG_[456]
branches.

Requested by:	re (bmah)
2007-04-20 05:12:48 +00:00
Gregory Neil Shapiro cdecb72116 MFC: Include a note about recompiling ports which use the base libmilter.
Submitted by:	Matthew Seaman
2007-04-14 16:27:16 +00:00
Gregory Neil Shapiro 2d8f7a956e MFC: sendmail 8.14.1 2007-04-12 03:13:04 +00:00
Xin LI cdb1081e37 MFC 1.5-1.6: Correctly compare between two UUIDs according
to specification found DCE 1.1.

PR:		83107
2007-04-12 02:20:15 +00:00
cvs2svn 15637308be This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2007-04-09 01:38:54 +00:00
Maksim Yevmenkin 92d349bd79 MFC:
Try to silence Coverity by adding (void) in front of function call.
Also add a comment, explaining why return value is not being checked.

Requested by:	netchild
2007-04-04 22:26:42 +00:00
Matt Jacob b2fba27435 MFC of constification, cleanups of pre-7.X compiles, additions of
SYNC_REG memory barriers and so on.
2007-04-01 17:21:19 +00:00
Matt Jacob d7de71f44a MFC the firmware for the new card functionality. 2007-03-12 05:30:05 +00:00
Matt Jacob ff2d1c6ab2 Move the current states of isp(4) and mpt(4) into RELENG_5. 2007-03-11 02:03:01 +00:00
Matt Jacob b361bc0661 MFC xpt_print function. 2007-03-11 02:02:02 +00:00
cvs2svn 088f03be13 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2007-03-10 02:39:56 +00:00
Hajimu UMEMOTO d38eb69e0f MFC 1.53: Check the return value from rad_cvt_ipv6prefix(). 2007-03-08 05:23:30 +00:00
Colin Percival 12f92eaea1 MFi386: Ident the SMP kernel as SMP-GENERIC (not GENERIC). 2007-03-03 23:20:42 +00:00
Maksim Yevmenkin 0e019f52f5 MFC:
Check that the length of the received message is at least as big as a PDU
before we use pdu->len.

While I'm here, sync up code with RELENG_6 and CURRENT.

Submitted by:	Iain Hibbert
2007-02-26 17:57:07 +00:00
Bruce A. Mah 5e679532e3 New errata: SA-07:02.bind. 2007-02-15 17:43:08 +00:00
Pav Lucistnik c7dfc1f055 MFC 1.41:
Fix a bug in 1.40 - it missed three occurences in pkg_info which leads to
  (null)/file output.
2007-02-14 09:37:15 +00:00
Bruce A. Mah b308bae752 MFC: SA-07:02.bind, BIND 9.3.4. 2007-02-11 02:21:13 +00:00
Ade Lovett 7d76d3ca6f MFC: rev 1.71/1.72
Remove hard-coded limit (200) on maximum number of packages that can be
added with a single invocation of pkg_add, replacing it with something
rather more dynamic.
2007-02-07 09:15:04 +00:00
Doug Barton cde8c4e9ec MFC the upgrade to BIND 9.3.4 2007-02-07 00:46:35 +00:00
Remko Lodder 4bfe66c402 MFC:
Fix a typo in ata-queue.c

  PR:             kern/107100
  Submitted by:   Stephen J. Roznowski <sjr at comcast dot net>
  Approved by:    sos

and

  Add the SMART command to the ATA instruction set.
  When the disk has an error, it will now print SMART
  instead of 'Unknown CMD'.

  PR:             kern/93368
  Submitted by:   Garry Belka <garry at NetworkPhysics dot COM>
  Approved by:    sos

Approved by:	sos (implicitly with the two previous commits).
2007-02-02 07:54:10 +00:00
Markus Brueffer 7ee4e22d79 MFC rev. 1.13:
- Grammar fixes
  - Reword some sentences
  - Use .Cm for arguments
  - s/CAVEAT/CAVEATS/

Approved by:	emax (mentor)
2007-01-21 02:32:06 +00:00
Markus Brueffer e85729d128 MFC rev. 1.83:
Fix a buffer overflow iff USB_DEBUG is set, hw.usb.ums.debug is > 5 and the
  total size of all input reports is < 6.

Approved by:	emax (mentor)
2007-01-21 02:27:40 +00:00
Bruce A. Mah 2fad822707 New errata: SA-07:01.jail. Bump copyright date while here. 2007-01-11 20:14:48 +00:00
Bruce A. Mah 17152e50b7 MFC: SA-07:01.jail. Bump copyright date while here. 2007-01-11 19:56:34 +00:00
Simon L. B. Nielsen 213ad06be7 Fix jail rc.d script privilege escalation via symlink attack against
/var/log/console.log and mount points.

Security:	FreeBSD-SA-07:01.jail
2007-01-11 18:18:57 +00:00
Xin LI e1be5296cf The pc98 porting team's copyright year should be 2003, when
5.0-RELEASE, the first release including pc98 is released.

Noticed by:	hrs
Confirmed by:	nyan
2007-01-10 01:29:46 +00:00
David E. O'Brien 0e2fe7248a MFC: Welcome to 2007 2007-01-01 03:01:24 +00:00
Ceri Davies 6b59b6bf02 MFC revision 1.25:
Ensure that the load of rules into the alternate ruleset worked before
  loading them into the live one too.

PR:             conf/97311
Approved by:    ru
2006-12-31 17:54:41 +00:00
Martin Blapp 38624ed498 MFC Rev. 1.267
Retest tp->t_session because Giant might have been temporarily dropped
while waiting for proctree_lock, allowing for an intervening tty_close()
that cleared tp->t_session.

Submitted by:   tegge
2006-12-21 16:26:28 +00:00
Doug Barton 8547cd3032 MFC version 1.6 of each Makfile, fixing man page markup. 2006-12-19 18:28:03 +00:00
Matt Jacob 89c173ca28 RELENG_6 (5, 4) change to recognize 6 port NetMos
PR:             58953
Submitted by:   Milan Obuch
Reviewed by:    marcel
2006-12-16 02:41:00 +00:00
Bruce A. Mah 4f1ff4b6c1 MFC: BIND 9.3.3 (also move this note from the kernel section to userland
section).
2006-12-14 18:09:00 +00:00
Doug Barton b80e935b33 MFC upgrade to version 9.3.3 2006-12-13 09:57:13 +00:00
cvs2svn 3ddcb1c90e This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2006-12-10 07:09:58 +00:00
Bruce A. Mah b48ad4bf4e MFC: SA-05:25.kmem.
New errata:  SA-05:26.gtar.
2006-12-06 20:57:39 +00:00
Bruce A. Mah 1c613aeb29 MFC: SA-06:25.kmem.
New release note:  SA-06:26.gtar.
2006-12-06 20:13:04 +00:00
Colin Percival b2a9a01bb3 Correct a signedness bug which allowed members of the operator
group to read kernel memory. [1]

Disable handling of GNUTYPE_NAMES tar file entries by default,
since they can be used to extract files outside of the cwd. [2]

Security:	FreeBSD-SA-06:25.kmem [1]
Security:	FreeBSD-SA-06:26.gtar [2]
2006-12-06 09:17:09 +00:00
Dag-Erling Smørgrav 73f3e1ca78 MFC: (1.293) fdalloc() optimization. 2006-11-11 00:42:08 +00:00
Dag-Erling Smørgrav 689c360dad MFC: synch with RELENG_6 2006-11-11 00:16:08 +00:00
Dag-Erling Smørgrav b307d5b81b MFC: Use the correct login class when setting a new password
PR:		65557, 72949
2006-11-11 00:11:36 +00:00
Doug Barton df5636708d MFC the upgrade to BIND 9.3.2-P2. This is mostly a noop in the base,
since if you're compiling the base with this upgraded, you've already
got your openssl upgraded, but it's a good idea to include this for
completeness sake.
2006-11-08 23:55:41 +00:00
Doug Barton 066fecf1e3 Complete the job of removing the FREEBSD-* files from non-HEAD
branches. These files are only meaningful in HEAD since that's
where the imports are done.
2006-11-08 23:52:33 +00:00
Ruslan Ermilov d0f1ea7289 MFC: Updates for newsletters V-11 and V-12. 2006-10-18 09:06:08 +00:00
Ceri Davies 66512b1b63 MFC revision 1.19:
Document the sun4v category.
2006-10-15 15:59:37 +00:00
Bruce A. Mah fae8c29999 MFC: tzdata2006n, GNOME 2.16.1. 2006-10-14 15:15:44 +00:00
Markus Brueffer cdac8d20c7 MFC revs. 1.7
- Add new service class definitions and a new attribute identifier definition
  - Update URL of the Assigned Numbers document for SDP

Approved by:	emax (mentor)
2006-10-14 14:46:28 +00:00
Alan Cox 89568c202c MFC revision 1.229
Change vnode_pager_generic_getpages() so that it does not panic if the
  given file is sparse.  Instead, it zeroes the requested page.

PR: kern/98116
2006-10-14 08:20:00 +00:00
Doug Barton 241e8d5d66 MFC tzdata2006n 2006-10-13 17:51:42 +00:00
Xin LI e256bd6835 MFC rev. 1.16 (iedowse):
Add missing parentheses to fix a segmentation fault that is easily
reproducable with `jot -s " " 400 1 | column -t'. The bug was present
in the the original CSRG 'column -t' added in 1989.
2006-10-08 02:26:53 +00:00
Bruce A. Mah 9d3a1dd00a MFC: SA-06:22.openssh. 2006-10-08 00:28:24 +00:00
Bruce A. Mah be8b89a729 New errata: SA-06:22.openssh. 2006-10-07 15:34:29 +00:00
Matt Jacob 4328757a48 MFC the current state of MPT. 2006-10-05 15:59:32 +00:00
Simon L. B. Nielsen 6029c73e36 Correct multiple vulnerabilities in OpenSSH.
Security:	FreeBSD-SA-06:22.openssh
2006-09-30 19:57:15 +00:00
Olivier Houchard 962fd9fb01 MFC rev 1.15:
date: 2006/09/22 12:45:42;  author: cognet;  state: Exp;  lines: +2 -2
Use usbd_clear_endpoint_stall_async() when clearing endpoint stalls in
an interrupt context.

Obtained from:  NetBSD
2006-09-30 14:08:58 +00:00
Colin Percival 75da7fc721 Correct problem in the 2006-09-28 patch concerning the handling of
excessively large DH moduli.

Reported by:	Steve Kiernan (Juniper SIRT)
Security:	FreeBSD-SA-06:23.openssl
2006-09-29 13:46:23 +00:00
Hajimu UMEMOTO 0433c9de2d MFC 1.44: Listen to a control socket on an IPv4 as well through
an IPv4-mapped IPv6 address.
2006-09-28 16:01:53 +00:00
Bruce A. Mah d561b7159f MFC: SA-06:21.gzip, SA-06:23.openssl. 2006-09-28 15:49:13 +00:00
Bruce A. Mah d382524c92 New errata: SA-06:21.gzip, SA-06:23.openssl. 2006-09-28 15:17:08 +00:00
Colin Percival dd6c53c729 Correct multiple vulnerabilities in crypto(3).
Limit the size of public keys used in order to protect applications
from a denial of service via insane key sizes.

Security:	FreeBSD-SA-06:23.openssl
2006-09-28 13:05:59 +00:00
Xin LI b0fc9fb6cc s/predefine/predefined/
PR:		gnu/86627
Submitted by:	Arne Woerner <arne_woerner at yahoo dot com>
2006-09-27 09:29:29 +00:00
Simon L. B. Nielsen 8a19ee82c6 Correct multiple vulnerabilities in gzip(1).
Security:	FreeBSD-SA-06:21.gzip
2006-09-19 14:06:20 +00:00
Matt Jacob 3fa0a29b42 MFC 1.163- have VMware disks have min/max tags in their quirks. 2006-09-15 20:46:16 +00:00
Bruce A. Mah 0bdd1f4eda MFC: SA-06:19.openssl, SA-06:20.bind, BIND 9.3.2-P1. 2006-09-12 16:05:21 +00:00
Remko Lodder 878eb02790 Add FreeBSD-SA-06:19.openssl and FreeBSD-SA-06:20.bind to the
Errata.
2006-09-06 22:57:30 +00:00
Simon L. B. Nielsen cec7293a63 MFC remaining changes between BIND 9.3.2 and 9.3.2-P1. The
"functional" changes were part of the FreeBSD-SA-06:20.bind commit.

Requested by:	dougb
2006-09-06 22:27:09 +00:00
Simon L. B. Nielsen 51ca5cb563 Correct incorrect PKCS#1 v1.5 padding validation in crypto(3). [1]
Correct multiple denial-of-service vulnerabilities in BIND related to
SIG Query Processing and Excessive Recursive Queries. [2]

Security:	FreeBSD-SA-06:19.openssl [1]
Security:	FreeBSD-SA-06:20.bind [2]
2006-09-06 21:20:54 +00:00
Xin LI bbd32c18af MFC 1.3:
In rev. 1.2 we have introduced a fallback handler for files with unknown
extensions.  This seems to be unnecessary and prevents less(1) from being
able to detect file changes, so remove the part.

Submitted by:	Eric Huss <e-huss netmeridian com>
PR:		bin/102624
Discussed with:	des
2006-09-03 16:10:31 +00:00
Oleg Bulyzhin 6203afccbd MFC rev. 1.141-1.142
- Do not leak memory while flushing rules.
  Noticed by:	yar

- Remove useless NULL pointer check: we are using M_WAITOK flag
  for memory allocation.
  Submitted by:	Andrey Elsukov <bu7cher at yandex dot ru>
2006-09-02 08:07:36 +00:00
Hajimu UMEMOTO a701da39e6 MFC 1.1.1.6 (partly): Set O_LARGEFILE properly. This fixes file
descriptor leak.

Submitted by:	Kouji Ito <kouji__at__cty-net.ne.jp>
2006-08-31 15:11:35 +00:00
Bruce A. Mah 13e3f1951d MFC: net.inet.ip.portrange.reserved{low,high} work for IPv6, bpf
multiple listeners timestamp improvement, netcat from OpenBSD 3.9.
2006-08-31 14:53:57 +00:00
Xin LI f6e66b793c MFC netcat from OpenBSD 3.9-RELEASE.
Requested by:	krion
2006-08-31 08:44:45 +00:00
Bruce A. Mah a983345b2a New errata: SA-06:18.ppp. 2006-08-31 00:39:10 +00:00
Bruce A. Mah 39c3469078 MFC: SA-06:18.ppp. 2006-08-29 22:34:13 +00:00
Colin Percival c32fc0369d Correct buffer overflow in the handling of LCP options in ppp(4)
Security:	FreeBSD-SA-06:18.ppp
2006-08-23 22:06:08 +00:00
Gregory Neil Shapiro 0913aa837b sendmail has been upgraded from 8.13.6 to 8.13.8 2006-08-23 03:48:05 +00:00
Gregory Neil Shapiro e338197811 Forced commit to .mc files to force creation of new .cf files for mergemaster. 2006-08-23 03:40:18 +00:00
Gregory Neil Shapiro 53c8aab796 MFC: sendmail 8.13.8 2006-08-23 03:39:12 +00:00
Ed Maste 3d4ca2e7ae MFC thr_cond.c r1.53, thr_mutex.c r1.49, thr_nanosleep.c r1.25 to RELENG_5:
Eliminate a race condition in timed waits (cv, mutex, and sleeps).
  MFC Candidate.

  PR:	93592
2006-08-21 14:51:21 +00:00
Ed Maste 68c34d0e78 MFC to RELENG_5 r1.117:
Handle failure to malloc() part of the thread structure.

  PR:	83457

r1.118:
  Allocate a thread's tcb last so it is easier to handle failures to
  malloc() siginfo.

  PR:	85468
2006-08-21 14:35:32 +00:00
Ed Maste f6dab905f2 MFC r1.6 to RELENG_5:
Don't attempt to initialize the rtld lock if it can't be malloc()'d.

  PR:	83452
2006-08-21 14:33:04 +00:00
David Malone da3e90b7f7 MFC: 1.300 When we receive an out-of-window SYN for an "ESTABLISHED"
connection, ACK the SYN as required by RFC793.
2006-08-21 12:36:24 +00:00
David Malone af397ae9f8 MFC: Make net.inet.ip.portrange.reservedhigh and
net.inet.ip.portrange.reservedlow apply to IPv6 aswell as IPv4. Update
a cut'n'paste comment so that it is a bit more up to date.
2006-08-21 12:34:03 +00:00
David Malone c33e5f9a61 MFC: 1.27 Avoid unwanted sign extension of indexed byte load in bpf code. 2006-08-21 12:29:31 +00:00
David Malone 6be408344d MFC: 1.170 Give the same timestamp for each packet to all BPF listeners. 2006-08-21 12:28:58 +00:00
David Malone d608959b08 MFC: 1.6 quirk for a motherboard whose acpi timer runs too fast. 2006-08-21 12:27:47 +00:00
David Malone 3519c19ff4 Sync with -current:
1.28: Avoid moving onto a new line while testing syslog prios.
1.27: WARNS=6 cleanup.
1.26: Print a usage message if a non-option is specified.
1.25: Don't add integers to void pointers.
2006-08-21 12:26:30 +00:00
Matt Jacob 5b8909e51b MFC 1.120: Fix RELENG_4 code version- isp_roles wasn't getting
initialized so it ended up defaulting to ISP_ROLE_NONE. My testing
hadn't caught it because I was deliberatly setting role via ioctl.
2006-08-21 00:48:37 +00:00
Maxim Konovalov f7f3a89f8f MFC rev. 1.14: simple strcpy/strcat replacement. 2006-08-20 20:31:10 +00:00
Kirill Ponomarev 8b54d7dc76 MFC: perform.c: 1.16
date: 2006/08/12 18:32:51;  author: krion;  state: Exp;  lines: +1 -1
  Fix "pkg_version -Io" coredump, if some packages have no origin at all

  PR:             bin/101932
  Submitted by:   novel, sat
2006-08-17 08:06:11 +00:00
Giorgos Keramidas 66dfa2ef6a MFC revision 1.73
| Fix two identical harmless typos in ata error messages:
| s/issueing/issuing/
|
| PR:             kern/89481
| Submitted by:   John Nielsen
| Approved by:    sos
2006-08-08 12:44:34 +00:00
Giorgos Keramidas 96bfd6ec46 MFC 1.13 (fron -> from typo fix)
PR:             docs/88015
Submitted by:   Marian Cerny <[email protected]>
2006-08-08 12:40:32 +00:00
Giorgos Keramidas 00065579d0 MFC 1.28
|Note that when -d flag is used, mountd(8) will not detach from the
|controlling terminal.
|
|PR:             docs/96660
|Submitted by:   Jeff Ito <[email protected]>
2006-08-08 12:24:42 +00:00
Yaroslav Tykhiy 8067ea4000 MFC rev. 1.57:
Do not forget to increment the input line counter
  when reading a word spanning multiple lines.
2006-08-06 10:47:45 +00:00
Xin LI b05f6980c7 MFC scsi_cd.c,v 1.96 and scsi_da.c,v 1.191
Drop Giant before returning in error path, thus eliminates
two mutex leaks.

Submitted by:   Beyond Luo <fedora ercist iscas ac cn>
PR:             kern/100046
2006-07-26 07:49:37 +00:00
Xin LI 1d0d0510d3 MFC 1.23:
Unlock aac_io_lock before returning, thus eliminates a mutex
leak.

Submitted by:   Beyond Luo <fedora ercist iscas ac cn>
PR:             kern/100046
2006-07-26 07:46:51 +00:00
Hajimu UMEMOTO 3a5ac38523 MFC 1.84: remove obsolete comments. 2006-07-25 18:29:32 +00:00
Ceri Davies bb9231c2c5 MFC r1.18:
Add the sun4v category
2006-07-17 10:39:01 +00:00
Matt Jacob b3c39e9053 MFC 1.117: don't claim to support the 2422 yet. 2006-07-14 05:19:17 +00:00
Mark Murray a09ecb8dfd MFC: maintainer straggers, and bring on down the LOCKS file for reference. 2006-07-09 22:17:02 +00:00
Mark Murray b0b0ee2f68 MFC: keep the maintainers consistent with HEAD. 2006-07-09 19:49:29 +00:00
Mark Murray b440640844 MFC: update maintainers 2006-07-09 19:44:53 +00:00
Robert Watson 69d8eed876 Merge rpc_svcout.c:1.23 from HEAD to RELENG_5:
In change 1.15, an arbitrary setting of the max RPC record size to
  RPC_MAXDATASIZE was introduced.  This is believed to have been debugging
  code committed accidentally, although I've been unable to reach the
  committer to confirm this.  The effect was to limit the size of RPCs on
  TCP and UDP to 9k, well below the default protocol limits in the libc
  rpc code.  This change simply removes these introduced limits, falling
  back on the libc definitions.

  PR:             88856
  Reported by:    Keith Bostic <bostic at sleepycat dot com>
  Testing by:     Susan LoVerso <sue at loverso dot southborough dot ma dot us>
  Reveiwed by:    cel, rees
  Review timeout: alfred, mbr

Approved by:	mbr
2006-07-05 11:36:23 +00:00
Matt Jacob 48098a1ff7 MFC: Fixes related for VMWare 2006-06-27 18:13:23 +00:00
Matt Jacob 6e300223ff MFC 1.162: Grumble. VMWare ESX and VMWare WorkStation have *slightly*
different inquiry data (pointlessly different I might add). Pick
the common parts.
2006-06-26 05:42:54 +00:00
Matt Jacob 2297bff4fd MFC 1.161: VMware disk volumes are only on LUN 0, and
some VMware HBAs have known bugs with commands sent to
other than LUN 0.
2006-06-25 02:03:18 +00:00
Xin LI 559f3996b1 MFC 1.3: do_file() is called recursively from several places and
cannot safely free() anything related to items that may be
recursed on.

Obtained from:	DragonFly (rev 1.7, dillon)
PR:		bin/94767
2006-06-21 09:59:01 +00:00
Bruce A. Mah 878801f43b MFC: Linux emulation FC4. 2006-06-18 05:03:53 +00:00
Matt Jacob 0c478c4953 MFC 1.34: support for FC919X 2006-06-17 12:48:27 +00:00
Hiroki Sato 3df13a6005 Document FreeBSD-SA-06:17.sendmail. 2006-06-14 16:29:06 +00:00
Colin Percival bef8d8f399 Correct a bug in the handling of multipart messages by sendmail(8)
which can allow a malformed message to crash a sendmail queue
processing process.

Security:	FreeBSD-SA-06:17.sendmail
2006-06-14 16:01:06 +00:00
Matt Jacob bbe313a35c MFC 1.24- add ability to reset individual targets and negotiate specific rates. 2006-06-14 01:38:16 +00:00
Ed Maste 058c3e9db0 MFC r1.184:
Check for non-NULL ac_netgraph field in interface arpcom, instead of
  checking global presence of ng_ether(4).

  Reviewed by:    ru
2006-06-13 01:51:34 +00:00
Bruce A. Mah d60a1785d5 MFC: GNOME 2.14.2, KDE 3.5.3. 2006-06-12 01:47:29 +00:00
Philip Paeps 9e6079a26b MFC acpi_asus(4) documentation.
Forgotten by:	philip
Reminded by:	brueffer
2006-06-11 12:02:34 +00:00
Philip Paeps b27afbfd74 Long-overdue MFC:
r1.28: Add support for Asus W5A laptops
  r1.27: Add support for Asus A4D laptops
  r1.26: Add support for Asus A6VM laptops
2006-06-11 11:53:39 +00:00
Maksim Yevmenkin 896f114359 MFC:
Fix an unwanted gcc4 warning.

Submitted by:	delphij
2006-06-09 21:00:10 +00:00
Matt Jacob b45340bf2c MFC Current state of MPT driver- pick up Makefile that was missing, oops. 2006-06-09 00:15:57 +00:00
Matt Jacob d1f4dfd532 MFC sequential scan probing 2006-06-08 17:51:56 +00:00
Matt Jacob cc8d7f1b73 MFC -current mpt driver to support FC target mode and SAS HBAs plus
probably correct U320 negotiations.
2006-06-08 17:48:35 +00:00
Xin LI 5e36ec770f MFC: Add -u and -U which functions like the jail(8) that allow
commands to be executed under a different credential.

PR:		bin/95777
Submitted by:	clsung
2006-06-08 17:29:05 +00:00
Bruce A. Mah 0babe5fc68 We shouldn't have any MFC markers on any codeline except for HEAD, so
remove the entity definition from RELENG_5.
2006-06-05 22:30:45 +00:00
cvs2svn 2f235b9404 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2006-06-05 22:25:51 +00:00
Christian Brueffer c101450e1d MFC: rev 1.17
Fix a formatting issue.
2006-06-05 19:20:13 +00:00
Matt Jacob 8806e54ac4 MFC: allow this to compile cleanly under RELENG_4 2006-06-03 07:21:09 +00:00
Matt Jacob 08469127f0 MFC: new 2300 firmware 2006-06-01 07:04:23 +00:00
Matt Jacob f671d6860d MFC: current state in RELENG_6 && -current as of 5/31/06. Lots of formatting
changes and type rototilling. Some genuine bug fixes tho.
2006-06-01 06:58:39 +00:00
Bruce A. Mah 86cdf41115 Add SA- prefix to security advisory names. 2006-06-01 04:58:07 +00:00
Bruce A. Mah abc6e5e3f9 New errata: SA-06:15, SA-06:16. 2006-06-01 04:49:01 +00:00
Bruce A. Mah 174bc4ca33 MFC: SA-06:15, SA-06:16. 2006-05-31 23:41:37 +00:00
Colin Percival dba1556e98 Enable inadvertantly disabled "securenet" access controls in ypserv. [1]
Correct a bug in the handling of backslash characters in smbfs which can
allow an attacker to escape from a chroot(2). [2]

Security:	FreeBSD-SA-06:15.ypserv [1]
Security:	FreeBSD-SA-06:16.smbfs [2]
2006-05-31 22:32:22 +00:00
Bruce A. Mah 6db677f99a New errata: Torrents are available. 2006-05-31 15:34:39 +00:00
Colin Percival 5ee49df445 MFC usr.sbin/portsnap/phttpget/phttpget.c rev 1.10,
usr.sbin/portsnap/portsnap/portsnap.8 revs 1.8-1.9,
    usr.sbin/portsnap/portsnap/portsnap.sh revs 1.16-1.24:

* Allow "HTTP_PROXY" to be (mis)spelled "http_proxy".
* Add "-l descfile" option to portsnap, to merge local describes
  output when building INDEX files.
* If a port directory is a symlink, remove the symlink when
  extracting a new version of the port.
* Make portsnap's automatic mirror selection interoperate better
  with HTTP proxies.
* Switch mirrors if the first mirror(s) selected fails.
* During mirror selection, parse the output of host(1) from
  BIND 8 as well as BIND 9.
* NO_BIND -> WITHOUT_BIND in a comment.

PR:		ports/93901, bin/96288
Sponsored by:   FreeBSD security development fundraiser
2006-05-26 23:14:16 +00:00
Ken Smith 255aca99c1 Note the release date of 5.5. 2006-05-26 13:14:46 +00:00
Ken Smith 802cd524d7 Code freeze for 5.5-REL is over, back to normal. 2006-05-26 13:10:18 +00:00
Bruce A. Mah cf705197dd New errata: Unresolved issues in the NFSv4 client.
Approved by:	re (implicitly)
2006-05-24 17:44:51 +00:00
Bruce A. Mah c887c3a23a Trim release notes and errata on the 5-STABLE branch for a
post-5.5 world.  Add bits of text to indicate that 5.5-RELEASE
is the last planned RELENG_5_* release.

Approved by:	re (implicitly)
2006-05-24 17:31:32 +00:00
Bruce A. Mah df413613eb Prepare for a post-5.5 world: Add a quick comment as a reminder that
no 5.6-RELEASE is planned at this time.  The &release.next; entity may
go away in the future to help enforce this in release documentation.

Approved by:	re (implicitly)
2006-05-24 17:10:51 +00:00
Pyun YongHyeon 652673561a MFC if_em.c, 1.92 to RELENG_5:
Add jumbo frame support for architectures with strict alignment.

Requested by:	wilko
Approved by:	re (kensmith)
2006-05-21 23:45:00 +00:00
Xin LI db5ab70ec9 MFen:
errata/article.sgml:	1.69.2.33 -> 1.69.2.35
	hardware/common/artheader.sgml: 1.5.2.1 -> 1.5.2.2
	installation/common/artheader.sgml: 1.5 -> 1.5.2.1
	installation/sparc64/article.sgml (fix)
	relnotes/common/new.sgml: 1.761.2.56 -> 1.761.2.59
	relnotes/sparc64/article.sgml (fix)

Obtained from:	The FreeBSD Simplified Chinese Project
Approved by:	re (murray)
2006-05-13 05:08:28 +00:00
Ken Smith a88388f007 Upate for (future...) existence of 5.5-RELEASE.
Approved by:	re (implicit)
2006-05-12 16:07:15 +00:00
Ken Smith 92ef618c03 Add packages-5.5-release.
Approved by:	re (implicit)
2006-05-12 15:51:55 +00:00
Ken Smith 20f384d311 Adjust FreeBSD_version to note RELENG_5_5 exists.
Approved by:	re (implicit)
2006-05-12 15:48:23 +00:00
Ken Smith 51439528ee 5.4 -> 5.5
Approved by:	re (implicit)
2006-05-12 15:42:35 +00:00
Ken Smith 610f8c101c Update default OS.
Approved by:	re (implicit)
2006-05-12 15:36:50 +00:00
Garrett Wollman c8b0c915cc Merge tzdata2006g from vendor branch. At this point, HEAD, RELENG_6,
and RELENG_5 should have the same data.

Approved by:	re (kensmith)
2006-05-12 01:09:19 +00:00
Bruce A. Mah 690a1b72a1 MFC: Bump copyright year on the hardware notes and installation guide.
hardware/common/artheader.sgml	1.7 -> 1.8
	installation/common/artheader.sgml	1.7 -> 1.8

(Not an exact MFC because the installation document was also missing
2005 in its copyright year list, which I added.)

PR:		97134
Approved by:	re (blanket approval from hrs for RELENG_5 src/doc)
2006-05-11 16:20:21 +00:00
Bruce A. Mah 339a3b5c36 New release note: ndis(4) partial sync with HEAD.
MFC:  if_bridge(4), twa(4) update 9.3.0.1, bsdiff(1)/bspatch(1),
cmp(1) -h, kdump(1) -s, netstat(1) -h, sweeping ping(8), power(8),
rfcomm_sppd(1) service names, rm(1) -I, sh(1) times, snapinfo(8),
rc.d/bluetooth, pkg_add(1) -P, pkg_add(1)/pkg_create(1) -K,
pkg_create(1) -x/-E/-G, pkg_version(1) -o, portsnap(8), ports startup
script suffixes removed, ldconfig_local{,32}_dirs, pkg-plist @cwd.

Also remove a sentence about &merged; features (this sentence only
applies to HEAD).

Approved by:	re (hrs)
2006-05-11 15:57:37 +00:00
Bruce A. Mah d9feec23ed MFC: Second core on dual-core processors enabled. Fix typo in KDE
release note.

Approved by:	re (kensmith)
2006-05-10 19:27:25 +00:00
David Malone 2e8c5170db MFC: 1.37
Stop dump reading off the end of its inode bitmaps when it finds an
invalid inode number in a directory entry.

Approved by:    re
2006-05-02 19:08:58 +00:00
David Malone 8495a95f30 MFC: v1.45, v1.44
Make port 37 time work on machines with 64 bit longs. Also merge a couple
of updates to comments.

Approved by:    re
2006-05-02 18:32:08 +00:00
Ed Maste f9b5f2b5e2 MFC queue.3 1.39 to RELENG_5:
The removal of CIRCLEQ left four queue macro families, but one sentence
  in the man page wasn't updated.

PR:             docs/94938
Submitted by:   Ed Schouten <[email protected]>
Approved by:	re
2006-05-02 03:59:35 +00:00
Maxim Konovalov 2953148ccc MFC rev. 1.7: fix prototype for SYSCALL_MODULE(9).
Approved by:	re (kensmith)
2006-05-01 20:32:56 +00:00
Maxim Konovalov c0c8759eb7 MFC rev. 1.33: document SO_NOSIGPIPE.
Approved by:	re (kensmith)
2006-05-01 20:25:35 +00:00
Maxim Konovalov 52593e6d27 MFC rev. 1.4 netflow.h: replace disappeared URLs to Cisco docs by
new ones, style.

Approved by:	re (kensmith)
2006-05-01 20:18:33 +00:00
Maxim Konovalov 556abc3fc3 MFC rev. 1.59: describe what actually boot(8) -m mutes.
Approved by:	re (kensmith)
2006-05-01 20:01:13 +00:00
Maxim Konovalov 1ba03a445d MFC rev. 1.95: do not double i/o stats for cd(4).
Approved by:	re (kensmith)
2006-05-01 19:55:13 +00:00
Maxim Konovalov 6eca17dd3c MFC rev. 1.9: dbm_close(3) returns void.
Approved by:	re (kensmith)
2006-05-01 19:48:09 +00:00
Maxim Konovalov bd13d07bf8 MFC rev. 1.7: document /dev/fido.
Approved by:	re (kensmith)
2006-05-01 19:44:16 +00:00
Maxim Konovalov b245b1ce78 MFC rev. 1.54: be pedantic and do fts_close() when done.
Approved by:	re (kensmith)
2006-05-01 19:34:34 +00:00
Maxim Konovalov 84c745821c MFC rev. 1.32: reset lineno to 1 for each devd config file.
Approved by:	re (kensmith)
2006-05-01 19:30:43 +00:00
Joe Marcus Clarke d662f50a75 MFC:
Fix a file descriptor leak in cam_lookup_pass() when the ioctl to find
the passthru device fails.

Approved by:	re (scottl)
2006-05-01 00:21:47 +00:00
Andrew Thompson ccd1abaeb4 MFC r1.14-16, sync to HEAD
Approved by:    re (hrs)
2006-04-29 03:31:28 +00:00
Colin Percival d839ba8bed MFC: Allow L2 caches to be shared between processors by default.
Approved by:    re (scottl)
2006-04-28 06:54:34 +00:00
Xin LI 7aa7977a9a MFC 1.2 (tjr):
Fix a one byte off error which causes "less" to crash if you view a
large file, jump to the end, scroll backwards with "b" and try to search
backwards afterwards.

Submitted by:	Matthias Scheler
Approved by:	re (hrs)
2006-04-26 03:46:10 +00:00
Xin LI b2c53a114e MFC: Document SA-06:14.fpu
Approved by:	re (hrs)
2006-04-24 01:06:36 +00:00
Alan Cox ee7124c3c6 Include opt_pmap.h for PMAP_SHPGPERPROC.
PR: 94509
Approved by: re (scottl)
2006-04-22 20:51:04 +00:00
Andrew Thompson 2620d33623 Document a limitation where the bridge may not forward a reassembled fragment,
this is becuase the new packet may be larger than the MTU.

Approved by:    re (hrs)
2006-04-21 10:39:53 +00:00
Brooks Davis aacfa2aa6f MFC rev 1.13:
Fix ypwhich -m.  This should be MFC'ed back at least as far as RELENG_5.

Submitted by:	Gil Kloepfer <[email protected]>
PR:		64445
Approved by:	re (scottl)
2006-04-21 05:16:41 +00:00
SUZUKI Shinsuke 5e8762da71 MFC Rev 1.37
use if_allmulti(0) for disabling the multicast promiscuous mode

Approved by: re(scottl)
2006-04-20 15:16:03 +00:00
Colin Percival 371204695e MFC: Correct a local information leakage bug affecting AMD FPUs.
Security:	FreeBSD-SA-06:14.fpu
Approved by:	re (scottl)
2006-04-19 07:01:30 +00:00
Jonathan Chen e9ded558c2 MFC 1.261 - fix a crash when an nfsv2 mount fails
Approved by:	re
2006-04-18 05:18:47 +00:00
Guy Helmer 8ff6c05d03 MFC: aic79xx_osm.c 1.22 aic7xxx_osm.c 1.43
Correct bug that caused the completed "recovery" scb to have its
  timer reset rather than the timer of an SCB still pending on the
  controller after recovery completed.  This should correct timeout
  loops seen in the field.

This change seems to help with a hang we've seen in the field with
SCB timeout recovery.

Approved by:	re
OK'ed by:	gibbs
2006-04-14 14:11:18 +00:00
Gregory Neil Shapiro 0820af39eb Forced commit to bump the $FreeBSD$ version so mergemaster merges
/etc/mail/freebsd.cf and /etc/mail/freebsd.submit.cf.

PR:		conf/95634
Submitted by:	Rostislav Krasny
Approved by:	re (scottl)
Obtained from:	keramida
2006-04-13 04:08:22 +00:00
Ken Smith 9535c7fea1 MFC v1.887.2.9
> Drop the languages we'll build docs for as part of the release down to
> just English due to a ISO size crisis for disc2.  This is being done
> after consultation with the doceng folks, who basically agreed that
> of the two evils this is less evil than going with the -lite versions
> of gnome/kde.  We are only doing this on RELENG_5/RELENG_6.  On HEAD
> we plan to adjust sysinstall so there will be no packages at all on
> disc1/disc2 and we can have an arbitrary number of dedicated package
> discs but that seems like too much of a change for RELENG_5/RELENG_6
> particularly at this stage in the release.

Discussed with: re@, doceng@
Approved by:    re (scottl)
2006-04-09 04:38:14 +00:00
Bjoern A. Zeeb 414c4c6e5e MFC:
rev. 1.3 src/sys/netipsec/xform.h, rev. 1.12 src/sys/netipsec/xform_ipip.c

  Fix more stack corruptions on amd64.

  Vararg functions have a different calling convention than regular
  functions on amd64. Casting a varag function to a regular one to
  match the function pointer declaration will hide the varargs from
  the caller and we will end up with an incorrectly setup stack.

  Entirely remove the varargs from these functions and change the
  functions to match the declaration of the function pointers.
  Remove the now unnecessary casts.

  Also change static struct ipprotosw[] to two independent
  protosw/ip6protosw definitions to remove an unnecessary cast.

PR:		amd64/95008
Submitted by:	Mats Palmgren
Approved by:	re (scottl)
2006-04-08 22:37:48 +00:00
Xin LI 51f99d81e7 MFen:
Makefile			      1.3 -> 1.5.2.1
  errata/article.sgml		1.69.2.17 -> 1.69.2.33
  hardware/common/dev.sgml     1.227.2.26 -> 1.227.2.35
  installation/sparc64/article.sgml   (redo merge)
  relnotes/common/new.sgml     1.761.2.43 -> 1.761.2.56
  share/sgml/release.dsl	      (typo fix)

Remove EAG.

Obtained from:	FreeBSD Simplified Chinese Project
Approved by:	re (scottl)
2006-04-05 03:44:52 +00:00
Chuck Lever 12fa5afc88 rick says:
The following bug was just identified in OpenBSD and it looks like the same
bug exists in the other BSDen NFS servers.

A Linux client (don't know which version, but you can look at
        http://bugzilla.kernel.org/show_bug.cgi?id=6256)
does a Setattr of mtime to the server's time, where the file is mode 0664 and
the client user has group access (ie. caller is not the file owner).

The BSD servers fail the Setattr with EPERM, since the VA_UTIMES_NULL flag
isn't set before doing the VOP_SETATTR.

It seems to me that this should be allowed, since it is allowed for a local
utimes(2). If so, the fix is to set VA_UTIMES_NULL for the
"set-time-to-server-time" cases of setting atime and/or mtime.

MFC of revision 1.140 to RELENG_5.

Submitted by:	[email protected]
Reviewed by:	cel
Approved by:	re (scottl), silby
2006-04-05 00:33:33 +00:00
Marcus Alves Grando b6b4acbfd8 MFC: Sync with HEAD
Approved by:	re (scottl)
2006-04-04 21:22:35 +00:00
John-Mark Gurney 76a0847746 MFC: kern_event.c v1.97
clear any action flags on the register knote

Approved by:    re (scottl)
2006-04-04 17:32:20 +00:00
Florent Thoumie 62807b64f9 MFC:
- Replace awk parts with shell.

      src/etc/rc.d/nsswitch: rev 1.5 -> 1.6

Approved by:	re (scottl)
2006-04-04 14:28:41 +00:00
Andrew Thompson 80d0b83b2b Fix the build.
Pointy hat:	thompsa
Approved by:	re (implicit)
2006-04-02 23:55:05 +00:00
Robert Watson e9fb978bef Merge ipsec.c:1.44 from HEAD to RELENG_5:
Remove manual assignment of m_pkthdr from one mbuf to another in
  ipsec_copypkt(), as this is already handled by the call to
  M_MOVE_PKTHDR(), which also knows how to correctly handle MAC m_tags.
  This corrects a panic when running with MAC and KAME IPSEC.

  PR:             kern/94599
  Submitted by:   zhouyi zhou <zhouyi04 at ios dot cn>
  Reviewed by:    bz

Approved by:	re (mux)
2006-04-02 11:15:52 +00:00
Robert Watson 8f17f291ab Merge if_ppp.c:113 from HEAD to RELENG_5:
Add IFF_NEEDSGIANT to kernel PPP support.  I have no idea why this wasn't
  here, but it should have been.

Approved by:	re (hrs)
2006-04-02 11:14:10 +00:00
John-Mark Gurney ac903a6b22 MFC: kern_event.c v1.96
fix race condition

Approved by:	re (hrs)
2006-04-02 08:22:43 +00:00
Andrew Thompson d063dbfc49 MFC r1.57-58
Use m_dup rather than m_copypacket as we need a writable mbuf

On behalf of:   rik
Approved by:    re (hrs)
2006-04-02 04:42:37 +00:00
Chuck Lever 6c1779b859 If an NFS server returns more than a few EJUKEBOX errors for a given RPC
request, the FreeBSD NFS client will quickly back off to a excessively
long wait (days, then weeks) before retrying the request.

Change the behavior of the FreeBSD NFS client to match the behavior of
the reference NFS client implementation (Solaris).  This provides a fixed
delay of 10 seconds between each retry by default.  A sysctl, called
nfs3_jukebox_delay, is now available to tune the delay.  Unlike Solaris,
the sysctl value on FreeBSD is in seconds, rather than in HZ.

MFC revision 1.136 to RELENG_5

Sponsored by:   Network Appliance, Incorporated
Reviewed by:    rick
Approved by:    re (kensmith), silby
2006-04-02 04:15:34 +00:00
Hiroki Sato fa91e08654 Document 06:13.sendmail, 06:12.opie, 06:11.ipsec, and 06:10.nfs.
Submitted by:	delphij
Approved by:	re (implicitly)
2006-03-30 15:31:36 +00:00
Brad Davis cd6bb7c69b MFC 1.39
Fix a typo

Approved by:	re@, ceri@
2006-03-30 04:13:19 +00:00
Chuck Lever d36f6f56ed Fix a bug in NFSv3 READDIRPLUS reply processing
The client's READDIRPLUS logic skips the attributes and
filehandle of the ".." entry.  If the server doesn't send
attributes but does send a filehandle for "..", the
client's logic doesn't account for the extra "value
follows" field that indicates whether the filehandle is
present, causing the remaining entries in the reply
to be ignored.

This is an MFC of 1.264 in the CURRENT branch.

Sponsored by:   Network Appliance, Inc.
Reviewed by:    rick, mohans
Approved by:    re, silby
2006-03-29 17:48:10 +00:00
Gregory Neil Shapiro e8eb2b1e18 MFC: Update sendmail 8.13.4 -> 8.13.6 in release note entry.
Approved by:	re (kensmith)
2006-03-29 07:57:00 +00:00
Gregory Neil Shapiro 0b265833fc MFC: Add new libsm file from sendmail 8.13.6
Approved by:	re (kensmith)
2006-03-29 07:41:16 +00:00
Gregory Neil Shapiro 19018fea0e MFC: sendmail 8.13.6
Approved by:	re (kensmith)
2006-03-29 07:40:50 +00:00
Hajimu UMEMOTO c27886f75d MFC:
- When res_send() fails, we should reserve an error code.
  - When res_nquerydomain() returns SERVFAIL, we should try next domain.

	src/lib/libc/net/getaddrinfo.c:		1.75, 1.76
	src/lib/libc/resolv/res_query.c:	1.3

Approved by:	re (hrs)
2006-03-29 03:38:58 +00:00
Ceri Davies 579c623cdb MFC revision 1.71:
The rpc.pcnfsd server was in the base for a little over seven
	minutes back in 1994.  Change the example entry to point at the
	port, as per the entries for uucpd et al.

Approved by:	re (kensmith)
2006-03-28 15:52:12 +00:00
Max Laier ae940990fc MFC pf_norm.c rev. 1.17:
Loopback pf_norm.c rev. 1.106 from OpenBSD:
      fixup IP checksum when modifying IP header fields

  PR:			kern/93849
  Obtained from:	OpenBSD

Approved by:	re (kensmith)
2006-03-28 15:06:03 +00:00
Hiroki Sato c97f5a2821 New release notes:
FreeBSD-SA-06:09.openssh,
	FreeBSD-SA-06:10.nfs,
	FreeBSD-SA-06:11.ipsec,
	FreeBSD-SA-06:12.opie, and
	FreeBSD-SA-06:13.sendmail.

Submitted by:	delphij
Approved by:	re (implicitly)
2006-03-26 16:28:35 +00:00
SUZUKI Shinsuke 69668c6beb MFC Rev 1.27 (avoid heap overrun)
Approved by: re(kensmith)
2006-03-24 15:01:02 +00:00
Xin LI 72434ad7d5 MFC 1.263: a typo fix (diff reduction against -HEAD)
Approved by:	re (hrs)
2006-03-24 04:48:42 +00:00
Pyun YongHyeon 70748c8a6f MFC if_hme.c:1.47 to RELENG_5:
Backout rev. 1.46. It caused Rx checksum offload breakage on little
 endian systems.

Approved by:	re (hrs)
2006-03-24 00:39:23 +00:00
Hiroki Sato e6c7e47534 MFC(rev.1.15):
Revert description of EBUSY.

Approved by:	re (implicitly)
2006-03-23 07:48:50 +00:00
Hiroki Sato fb71a7329c MFC (rev.1.4 and 1.5):
Fix incorrect command line examples.

Submitted by:	Yoshihiko Sarumaru (mistral at imasy dot or dot jp)
PR:		docs/94158
Approved by:	re (kensmith)
2006-03-23 07:37:56 +00:00
cvs2svn 908ebec3a1 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2006-03-22 16:40:06 +00:00
Colin Percival f891a117b0 Add missing code needed for the detection of IPSec packet replays. [1]
Correctly identify the user running opiepasswd(1) when the login name
differs from the account name. [2]

Modify timeout handling logic in sendmail(8) to correct a reported
signal handling race condition. [3]

Approved by:	re (scottl)
Security:	FreeBSD-SA-06:11.ipsec [1]
Security:	FreeBSD-SA-06:12.opie [2]
Security:	FreeBSD-SA-06:13.sendmail [3]
2006-03-22 16:01:56 +00:00
Joseph Koshy eaf7b2ea89 MFC { r1.4,r1.5 etc/periodic/security/security.functions
r1.30 etc/defaults/periodic.conf
      r1.51 share/man/man5/periodic.conf.5 }
 - Add a knob 'daily_status_security_diff_flags' controlling the
   format of the 'diff' output generated during periodic(8) scripts.
 - When looking for new lines in diff output, grep for '^[>+]' instead of
   '^>', in order to catch both normal and unified diffs.

Approved by:	re (hrs)
2006-03-22 12:01:28 +00:00
John-Mark Gurney 2b130039a7 MFC: systat.1 v1.46, vmstat.c v1.69
Properly spell and document ozfod...

Approved by:	re (hrs & kensmith)
2006-03-21 20:56:18 +00:00
Pawel Jakub Dawidek 698259b3b3 MFC: sys/geom/raid3/g_raid3.c 1.54
Fix a race which could lead to a panic under heavy load.

Submitted by:	green, Vsevolod Lobko <[email protected]>
Approved by:	re (mux)
2006-03-20 15:43:50 +00:00
Gleb Smirnoff 277b4ced97 MFC 1.24,1.25:
Fix misinformation in "setconfig" message description.

  Noticed by:	Brian A. Seklecki <lavalamp spiritual-machines.org>

Approved by:	re (mux)
2006-03-18 21:54:09 +00:00
Joerg Wunsch 7a9062a6f5 Add reference to PR for TOSHIBA TransMemory quirk entry.
Approved by:	re (implicitly)
2006-03-18 21:15:40 +00:00
Florent Thoumie bb7d51dd88 MFC:
- Add a scsi_da.c and a umass.c quirk for Genesys 6-in-1 Card Reader.

      src/sys/dev/usb/usbdevs: rev 1.250 -> 1.251
      src/sys/cam/scsi/scsi_da.c: rev 1.185 -> 1.186
      src/sys/dev/usb/umass.c: rev 1.130 -> 1.131

Approved by:	re (mux)
2006-03-18 20:43:51 +00:00
Joerg Wunsch d2710f0bf6 MFC rev 1.187: Add no synchronize cache quirk for TOSHIBA TransMemory
USB stick.

Approved by:	re (scottl)
2006-03-17 21:30:03 +00:00
Alan Cox f4b9e59905 MFC vm_machdep.c 1.261-1.263
Rev: 1.261

  Ensure that a thread stays on same CPU when calculating per CPU
  TLB shootdown requirements. Otherwise a CPU may not get the needed
  TLB invalidation.

  The PTE valid and access flags can not be used here to avoid TLB
  shootdowns unless sf->cpumask == all_cpus.
  ( Otherwise some CPUs may still hold an even older entry in the TLB)
  Since sf_buf_alloc mappings are normally always used this is
  also not really useful and presetting accessed and modified
  allows the CPU to speculatively load the entry into the TLB.

  Both bugs can cause random data corruption.

Rev: 1.262

  Restore optimizations to reduce TLB shootdowns.
  Alan Cox pointed out that they are really useful for
  sendfile().

Rev: 1.263
  Restore the UP optimization to reduce the number of TLB
  invalidations.  The previous revision only restored the MP optimization.

  Describe the optimization strategy for TLB invalidations in a comment.

Approved by:	re@ (scottl)
2006-03-17 19:07:33 +00:00
Xin LI 3b57ab33a9 MFC: Add snapinfo.
Discussed with:	marks
Approved by:	re (scottl)
2006-03-17 05:15:27 +00:00
Ken Smith 5d58e0461f MFC v1.11:
> date: 2006/03/17 02:05:46;  author: kensmith;  state: Exp;  lines: +0 -5
> First pass at trimming package set down.  Disc2 is still too big
> even with this but we're still deciding exactly what to do about
> that.

Approved by:	re (scottl)
2006-03-17 02:14:00 +00:00
Jung-uk Kim 4ff292f7b0 PC98 does not support big disks on RELENG_5 yet. Note that this is to sync
with interactive mode and it is not MFC because it is RELENG_5 specific.

Discussed with:	nyan
Approved by:	re (scottl)
2006-03-16 17:17:14 +00:00
John Baldwin c79e405416 Partially revert the previous revision and only use fixed delivery mode
when interrupts are routed via phyiscal addressing to the BSP during boot.
Once we switch over to logical destinations, it uses low pri delivery mode
just as in earlier 5.x releases.

Tested by:	kensmith
Approved by:	re (scottl)
2006-03-15 17:38:47 +00:00
Joe Marcus Clarke 899955f905 MFC:
Add missing libdata/ldconfig[32] entries.

Approved by:	re (scottl)
2006-03-14 22:13:13 +00:00
Roman Kurakin 6ee1224fcc MFC:
Add support for Cronyx Tau32-PCI adapters.

Approved by:	re(scottl)
2006-03-12 23:44:00 +00:00
Andrew Thompson 30bda38fb7 MFC r1.151
Further refine the bridge hack in the arp code. Only do the special arp
  handling for interfaces which are actually in the bridge group, ignore all
  others.

Approved by:    re (hrs)
2006-03-11 19:33:17 +00:00
Ed Maste d3d5b675db MFC link_elf.c:1.86 to RELENG_5:
Check to see if the hash table is present in link_elf_lookup_symbol()
  before dereferencing it.  Certain corrupt kernel modules might not have
  a valid hash table, and would cause a kernel panic when they were loaded.
  Instead of panic'ing, the kernel now prints out a warning that it is
  missing the symbol hash table.

Approved by:	re (mux)
2006-03-11 14:19:22 +00:00
Yaroslav Tykhiy d34688366a MFC:
Now login.access(5) feature belongs to pam_login_access(8),
not to login(1), unlike it used to.  This appears to apply
to RELENG_5, too.

Approved by:	re (mux)
2006-03-11 08:24:25 +00:00
Yaroslav Tykhiy adbf99ef3a MFC:
Two years ago, in rev. 1.12, a typo slipped in etc/isdn/Makefile:
  a control variable was misspelled as `SCRIPTS_NAME_isdntel.sh'
  (should've been `SCRIPTSNAME_isdntel.sh') when the Makefile was
  converted to using <bsd.prog.mk>.  Consequently, `isdntel.sh' has
  been installed as `isdntel' since then.  Nevertheless, nobody has
  been unhappy with the change.  So it's time to make it official.

Approved by:    re (mux)
2006-03-11 07:36:20 +00:00
Matt Jacob a7ab392824 MFC 1.4 and make sure the ioctl doesn't get smushed.
Approved by:	[email protected]
2006-03-09 21:43:58 +00:00
Hajimu UMEMOTO 87b34ef548 MFC 1.15: Remove trailing dot from the servername in the serverlist to
be able to use portsnap from behind a http proxy.  Some HTTP proxy
don't like trailing dot in the servername.

Approved by:	re (hrs)
2006-03-09 17:17:40 +00:00
Hajimu UMEMOTO 11078fbe4f MFC 1.9: Correct handling of HTTP_PROXY_AUTH. A password may have `:'.
Approved by:	re (hrs)
2006-03-09 17:13:39 +00:00
Xin LI dea3f02e30 MFC recent locale changes for both Simplified and Traditional
Chinese, so that applications like tcsh(1) can handle them
properly.

Approved by:	re (hrs)
2006-03-09 12:48:36 +00:00
George V. Neville-Neil 818d5235b9 Merge updated manual pages from HEAD to RELENG_5.
1.21      src/lib/libipsec/ipsec_set_policy.3
 1.14      src/lib/libipsec/ipsec_strerror.3
 1.17,1.18 src/share/man/man4/ipsec.4

Clean up some descriptions and remove ambiguities in the language.
Add explanations to the examples.

Approved by: re (scottl)
2006-03-09 12:38:36 +00:00
George V. Neville-Neil 715364b1e7 Merge in6.c:1.60 from HEAD to RELENG_5
Fix for an inappropriate bzero of the ICMPv6 stats.  The code was zero'ing the wrong structure member but setting the correct one.

Submitted by:   James dot Juran at baesystems dot com
Approved by: re (scottl)
2006-03-09 11:59:42 +00:00
Christian Brueffer 432d8122ff MFC: rev. 1.30
Remove a useless word.

Approved by:    re (hrs)
2006-03-09 09:19:26 +00:00
Christian Brueffer 0cdec95e40 MFC: rev. 1.29
DDB depends on KDB for some time now.

Approved by:    re (hrs)
2006-03-09 09:17:13 +00:00
Hajimu UMEMOTO 8426480123 MFC 1.210:
- Reduce needless DNS query by lookup only appropriate address
  family.
- Specify appropriate hints to getaddrinfo(3).
- Obtain address family from peername in inetd mode.

Approved by:	re (mux)
2006-03-09 09:15:34 +00:00
Hajimu UMEMOTO c9ebdf8f11 MFC: Handle the errors returned by res_querydomain() in same manner.
lib/libc/net/getaddrinfo.c:	1.72
	lib/libc/net/res_query.c:	1.32

Approved by:	re (mux)
2006-03-09 09:09:00 +00:00
Roman Kurakin 983c7463a9 MFC:
Add support for Cronyx Tau32-PCI. Cross fingers and hook it to the
	system.

Approved by:	re(scottl)
2006-03-07 13:53:57 +00:00
Roman Kurakin c857377452 MFC:
Add support for Cronyx Tau32-PCI adapters.

Approved by:	re(scottl)
2006-03-07 13:44:33 +00:00
Roman Kurakin 33efd96b38 MFC:
Add support for Cronyx Tau32-PCI adapters.

Approved by: re(scottl)
2006-03-07 13:35:39 +00:00
Roman Kurakin 914d4769f5 MFC:
Add support for Cronyx Tau32-PCI adapters.

Approved by:	re(scottl)
2006-03-07 13:32:48 +00:00
Hajimu UMEMOTO cab1031f82 MFC: Sync inet_net_pton() and inet_net_ntop() with latest BIND9's
includes an IPv6 support.

	lib/libc/net/inet_net.3:	1.3
	lib/libc/net/inet_net_ntop.c:	1.8
	lib/libc/net/inet_net_pton.c:	1.10

Approved by:	re (scottl)
2006-03-06 14:55:48 +00:00
Hajimu UMEMOTO f6113c0941 MFC: Decrease the value of RES_DFLRETRY from 4 to 2.
include/resolv.h:		1.26, 1.28
	lib/libc/net/res_init.c:	1.33

Approved by:	re (scottl)
2006-03-06 14:50:09 +00:00
Yaroslav Tykhiy 80ba97eb29 MFC rev. 1.326:
Do not discard the current value of __MAKE_CONF when testing
  whether MAKEOBJDIRPREFIX is set at a wrong place.

Approved by:    re (scottl)
2006-03-06 11:22:53 +00:00
Andrew Thompson 5626e8a6e0 MFC r1.8: Do not use the TSC where its known to be broken.
Approved by:    re (scottl)
2006-03-06 06:39:14 +00:00
Hajimu UMEMOTO 1a6571c894 MFC:
- Just query 'as is', if there is a trailing dot in the name.
- Don't query 'as is' twice.

	lib/libc/net/getaddrinfo.c:	1.71
	lib/libc/net/res_query.c:	1.31

Approved by:	re (scottl)
2006-03-04 17:44:27 +00:00
Hajimu UMEMOTO 0e837b7b8a MFC 1.5: Add definitions of SWIDTH. It fixes the problem that
tcsh 6.14 doesn't work correctly with ko_KR.eucKR locale.

Approved by:	re (scottl)
2006-03-04 17:36:27 +00:00
Ceri Davies d1c70baf86 MFC revision 1.416:
Add new NTP servers for Taiwan.

Approved by:	re (scottl)
2006-03-04 17:24:10 +00:00
David Malone 264791cf0d MFC: Make quot skip unallocated inodes.
Approved by:	re (scottl)
2006-03-04 16:59:09 +00:00
Oleg Bulyzhin 11854a1ffb MFC if_ethersubr.c rev. 1.214, if_bridge.c rev. 1.54
Properly initialize args structure before passing it to ipfw_chk(): having
uninitialized args.inp is unhealthy for uid/gid/jail ipfw rules.

PR:		kern/92589
Approved by:	re (scottl)
2006-03-04 09:24:30 +00:00
Oleg Bulyzhin 1939056d1c MFC rev. 1.315
Fix five years old bug in ip_reass(): if we are using 'full' (i.e. including
pseudo header) hardware rx checksum offloading ip_reass() fails to calculate
TCP/UDP checksum for reassembled packet correctly.

Reviewed by:	sam (earlier version), bde
Approved by:	re (scottl)
2006-03-04 09:16:11 +00:00
Andrew Thompson f296a4e35d MFC r1.11: Fix up the Bridge Identifier field in the BPDU packet.
Approved by:    re (scottl)
2006-03-03 21:37:01 +00:00
cvs2svn a6d7f3f19b This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2006-03-03 18:42:11 +00:00
John Baldwin 84a8358866 Use fixed delivery mode for I/O APIC interrupts rather than low priority
delivery mode.

Approved by:	re (scottl)
2006-03-01 20:42:31 +00:00
Simon L. B. Nielsen ebf5deaaac Add FreeBSD-SA-06:09.openssh and FreeBSD-SA-06:10.nfs.
Approved by:	re (scottl)
2006-03-01 15:37:47 +00:00
Simon L. B. Nielsen e70dc4c152 Correct a remote DoS in OpenSSH when using PAM and privilege
separation. [06:09]

Submitted by:	des

Correct a remote kernel panic when processing zero-length RPC records
via TCP. [06:10]

Security:	FreeBSD-SA-06:09.openssh
Security:	FreeBSD-SA-06:10.nfs
Approved by:	re (scottl)
2006-03-01 14:19:48 +00:00
Ed Maste 5b6efc9869 Belatedly add a note about the i386 loader defaulting to the serial
rate set by the previous boot stage, if the console is already set
to the comconsole.

Approved by:    re (scottl)
2006-02-28 19:15:36 +00:00
Ed Maste 80bf1b8de2 MFC kern_sig.c 1.319 sys_process.c 1.134 to RELENG_5:
Avoid kernel panic when attaching a process which may not be stopped
  by debugger, e.g process is dumping core. Only access p_xthread if
  P_STOPPED_TRACE is set, this means thread is ready to exchange signal
  with debugger, print a warning if P_STOPPED_TRACE is not set due to
  some bugs in other code, if there is.

  The patch has been tested by Anish Mistry mistry.7 at osu dot edu, and
  is slightly adjusted.

Approved by:	re (scottl)
2006-02-28 15:02:51 +00:00
Ed Maste d4f501f78d MFC kern_kse.c 1.215 sys_process.c 1.132 to RELENG_5:
Fix a LOR between sched_lock and sleep queue lock.

kern_kse.c 1.216:

  Add missing brackets.

LOR ID:		060
Approved by:	re (scottl)
2006-02-28 14:58:36 +00:00
Jung-uk Kim 7c38db1e99 MFC: src/gnu/usr.bin/dialog/dialog.1 1.8
src/gnu/usr.bin/dialog/dialog.c	1.15

- Add default choice option for --yesno box.
- Reduce trivial code duplications.

Approved by:	re (scottl)
2006-02-27 20:26:47 +00:00
Jung-uk Kim e124d2d1f3 MFC: usr.sbin/sysinstall/disks.c 1.156
Sanitize BIOS geometry in non-interactive mode.

Approved by:	re (scottl)
2006-02-27 20:19:07 +00:00
Gleb Smirnoff d108b305cf Merge Ruslan's fix to IP fragment handling in dummynet to RELENG_5.
(The struct ip_fw_args is not touched to preserve ABI compatibility).

PR:		kern/93754
Requested by:	Joerg Pernfuss <elessar bsdforen.de>
Approved by:	re (scottl)
2006-02-27 17:24:13 +00:00
Dmitry Morozovsky e2b37f4349 MFC:
Remove &release.prev.historic;.

	This should fix www build.

Approved by:    re (hrs)
2006-02-27 13:30:42 +00:00
Bruce A. Mah e655ff7fe7 MFC: GNOME 2.12.3, KDE 3.5.1, Perl 5.8.8, X.org 6.9.0.
Other new release note:  SA-06:08.

Approved by:	  re (scottl)
2006-02-27 01:18:29 +00:00
Markus Brueffer 499faddbc9 MFC recent updates to hccontrol:
- Use official version strings for LMP and HCI version reporting and add
    version strings up to Bluetooth 2.0
  - Update manufacturer list

Revisions:

	hccontrol.h	rev. 1.5
	info.c		rev. 1.4
	link_control.c	rev. 1.10
	util.c		rev. 1.6

Approved by:   	re (scottl), emax
2006-02-27 00:38:18 +00:00
Ed Maste bfa64fee24 MFC boot2.c r1.74 lib.h r1.3 sio.S r1.10 boot_i386.8 r1.54 r1.55 r1.58
to RELENG_5:

  Add the ability to specify the boot2 serial console speed in
  /boot.config or on the "boot:" prompt line via a "-S<speed>" flag,
  e.g. "-h -S19200". This adds about 50 bytes to the size of boot2
  and required a few other small changes to limit the size impact.

Approved by:	re (scottl)
2006-02-26 17:34:47 +00:00
Ceri Davies a06bcc79a9 Sync with -HEAD.
Approved by:	re (hrs)
2006-02-26 13:21:27 +00:00
John-Mark Gurney 1253e2c153 MFC: sleep.9 v1.47
>  allow timo to be 0 when mtx is not NULL (KASSERT allowed this as
>  pointed out by jhb)

Approved by:    re (scottl)
2006-02-25 21:51:00 +00:00
Ceri Davies 8ca459a80d MFC:
devices.c	revision 1.164
	tcpip.c 	revision 1.135

  s/lp/plip/ for PLIP interfaces.

Approved by:	re (mux)
2006-02-25 18:51:13 +00:00
Ceri Davies b728fb6129 MFC revision 1.14:
The interface for PLIP has been plip0 rather than lp0 for a long time.
  Update to match.

Approved by:	re (mux)
2006-02-25 18:21:06 +00:00
Doug Barton 6d666f12e8 MFC significant overhaul of rc.d/named script, including
addition of named_uid default rc.conf variable.

etc/defaults/rc.conf		1.275
etc/rc.d/named			1.24
share/man/man5/rc.conf.5	1.286

Approved by:	re (scottl)
2006-02-24 09:43:33 +00:00
Christian Brueffer cfae57bbcf MFC: rev. 1.6
Update for the 9550 series of controllers.

Approved by:    re (scottl)
2006-02-24 08:43:51 +00:00
Ed Maste bd7971844d MFC 1.110: clear lock on error in O_LIMIT case of install_state
Approved by:    re (mux)
2006-02-23 23:06:24 +00:00
Hiroki Sato 67e4500bca Update version numbers in &release.*;.
Approved by:	re (implicitly)
2006-02-23 06:28:03 +00:00
Jesus R. Camou 98d9a9aa3e MFC:
s/ConnectionTimeout/ConnectTimeout/

Approved by:	re (hrs)
2006-02-22 19:56:46 +00:00
Kirill Ponomarev 2244a7dc57 MFC: perform.c: 1.15
date: 2006/02/12 16:09:33;  author: krion;  state: Exp;  lines: +5 -4
  Fix pkg_version with the -o argument to print the origin.

Approved by:	re (scottl)
2006-02-22 16:28:42 +00:00
Bruce A. Mah abdb37561e New release notes: SA-05:16 / SA-05:18, SA-05:17, SA-05:19, SA-05:20,
SA-05:21, SA-06:01, SA-06:02, SA-06:03, SA-06:06, SA-06:07, BIND 9.3.2,
tzdata2005r.

While here, bump copyright date.

Approved by:	re (hrs)
2006-02-21 07:31:56 +00:00
Ceri Davies 1dcc6d4498 MFC revision 1.49:
Update a comment to match functionality changed in r1.39 (allow square
  brackets in process names).

Approved by:	re (scottl)
2006-02-19 18:36:20 +00:00
Christian Brueffer 51465cc5ec MFC: rev. 1.29
Xref chkgrp(8).

Approved by:	re (mux)
2006-02-19 18:35:39 +00:00
Markus Brueffer 63e93b2bbf MFC: rev. 1.5 + 1.6
- Sort sections
- Grammar fixes
- Reword one sentence

Approved by:	re (scottl), brueffer
2006-02-19 15:45:06 +00:00
Markus Brueffer 57a02491aa MFC: rev. 1.2
- Fix attribute id of HIDBatteryPower
- Fix two typos in comments

Approved by:	re (scottl), emax
2006-02-19 15:39:31 +00:00
Hajimu UMEMOTO 7976fa9380 MFC 1.20: The libwrap built with NO_INET6=yes cannot parse
an IPv6 address.  So, mention it in comment.

Approved by:	re (scottl)
2006-02-19 14:59:00 +00:00
Hajimu UMEMOTO e6b9c64026 MFC: The wcwidth(3) should return 2 about characters in JISX0208 codeset.
But it returned 1.

	share/mklocale/ja_JP.SJIS.src:	1.5
	share/mklocale/ja_JP.eucJP.src:	1.4

Approved by:	re (scottl)
2006-02-19 05:52:19 +00:00
Dmitry Morozovsky 4f12dad3eb MFC r1.33:
Default number of direct access devices had been changed from three to two.
Reflect this in other paragraphs.

Approved by:	re (scottl)
2006-02-18 15:21:28 +00:00
Christian Brueffer f294d36f8e MFC: rev. 1.285
Correct references to ipnat(8).

Approved by:	re (murray)
2006-02-17 20:27:00 +00:00
Qing Li 588e18e8f4 Remove two unnecessary type casts, of which both had a typo in it anyways.
MFC:		rev 1.40
Approved by:	re (scottl)
2006-02-16 18:10:14 +00:00
Qing Li 1de1f79fd6 Fixes a crash due to the memory of the newly allocated syncache entry
in syncache_lookup() is not cleared and may lead to an arbitrary and
bogus rtentry pointer which later gets free'd.

MFC:		rev 1.84
Approved by:	re (scottl)
2006-02-16 18:05:03 +00:00
Qing Li cfec040194 Require gateways for routes to be of the same address family as the route itself.
MFC:		rev 1.109
Approved by:	re (scottl)
2006-02-16 17:59:18 +00:00
Qing Li e8ee857e86 Patch for PR kern/38752
MFC:		rev 1.38
Approved by:	re (scottl)
2006-02-16 17:51:53 +00:00
Ken Smith 731f1186c4 Update copyright date years to 2006.
Approved by:	re (scottl)
2006-02-16 14:49:38 +00:00
Dag-Erling Smørgrav 085360b386 MFC: (1.77) fix mirror mode.
PR:		bin/86940
Approved by:	re (kensmith)
2006-02-16 13:56:18 +00:00
Gleb Smirnoff 4cdd1d6406 MFC 1.107:
Fix two important typos in watchdog handling:
  - Restart watchdog if we *did* processed any descriptors. [1]
  - Log the watchdog event if the link is *up*. [2]

  PR:		kern/92948 [1]
  Submitted by:	Mihail Balikov <mihail.balikov interbgc.com> [1]
  PR:		kern/92895 [2]
  Submitted by:	Vladimir Ivanov <wawa yandex-team.ru> [2]

Approved by:	re (kensmith)
2006-02-16 12:45:12 +00:00
Gleb Smirnoff 6397ba6acb MFC 1.62:
Refuse to install invalid ARP entries.

  Submitted by:		Vitaliy Ovsyannikov <V.Ovsyannikov kr.ru>

Approved by:	re (kensmith)
2006-02-16 12:41:18 +00:00
Guido van Rooij 1f83fb8dca Reassign the correct value to m after calling fr_makefrip().
The problem is that in fr_makefrip(), pullups can happen.
This fixes a panic later on in m_copydata().

Approved by:	re
2006-02-16 11:26:23 +00:00
Yoshihiro Takahashi 390abe3f70 MFC: revision 1.371
> Clear carry flag in get_mcontext so that setcontext does not
> return a bogus error.

Approved by:	re (kensmith)
2006-02-15 13:54:06 +00:00
Hajimu UMEMOTO 5ae72a44aa MFC 1.63: avoided the use of purged address structure when an
address became invalid in nd6_timer().

Approved by:	re (hrs)
2006-02-14 16:29:22 +00:00
Hiroki Sato bde7085b18 Use more specific expression which means the 5.x stable branch.
Approved by:	re (implicitly)
2006-02-14 02:39:23 +00:00
Hiroki Sato 624b350923 MFC: Fix a bug which puts an incorrect checksum of CHECKSUM.MD5
into the CHECKSUM.MD5 file itself.

Approved by:	re (scottl)
2006-02-14 02:00:24 +00:00
Marius Strobl 724fef32b3 MFC: 1.15 (partial)
- Sync the list of supported chips with pcn_probe() as of sys/pci/if_pcn.c
  rev. 1.77 (also applies to RELENG_%), i.e. remove Am53C974/Am79C970/
  Am79C974 PCnet-PCI and Am79C970A PCnet-PCI II.
- Change the entry of the PCnet-Home in the list of supported chips to
  match the other ones, i.e. s,PCnet/Home HomePNA,Am79C978 PCnet-Home,.

Approved by:	re (scottl)
2006-02-12 22:23:04 +00:00
Hajimu UMEMOTO 97871cbadf MFC 1.168: Never select the PCB that has INP_IPV6 flag and is bound
to :: if we have another PCB which is bound to 0.0.0.0.  If a PCB has
the INP_IPV6 flag, then we set its cost higher than IPv4 only PCBs.

Approved by:	re (scottl)
2006-02-11 09:02:59 +00:00
Hajimu UMEMOTO 4baff16f97 MFC 1.56: make IPV6_V6ONLY socket option work for UDP as well.
Approved by:	re (scottl)
2006-02-09 02:33:14 +00:00
Matt Jacob 1bf64e1ce5 MFC 1.21: update man page for boot stuff plus remove some cards described.
Approved by:	re
2006-02-07 22:03:59 +00:00
David Xu 0b3731a703 MFC amd64/amd64/machdep.c revision 1.646, i386/i386/machdep.c
revision 1.622
>
> Clear carry flag in get_mcontext so that setcontext does not
> return a bogus error.
>
> PR: misc/92110

Approved by:	re (scottl)
2006-02-07 03:10:38 +00:00
Bruce A. Mah 4785ea4c97 Fix misspelling: s/Janurary/January/
Approved by:	re (scottl)
2006-02-05 20:45:04 +00:00
Scott Long ab9240753f Add isp_library.c to the build.
Approved by: re
2006-02-05 16:02:16 +00:00
Matt Jacob 4b748b1531 MFC overflow bug fixes and disable ISP_DAC_SUPPORTED for now; plus sync up
with RELENG_6 && -current for all the rest.

Approved by: re
2006-02-04 23:55:03 +00:00
cvs2svn b5858b4a6b This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2006-02-03 20:55:31 +00:00
Andrew Thompson 8c89a3b587 MFC r1.150, do not send two ARP replies if the bridge has an address.
Approved by:    re (scottl)
2006-02-03 12:55:16 +00:00
Andrew Thompson b754c09123 MFC r1.52, fix inconsistencies with the bridge route table.
Approved by:	re (scottl)
2006-02-03 12:53:58 +00:00
Ken Smith 5251aacf17 Note that we've entered code freeze and the 5.5-RELEASE cycle has
begun but we're not ready to branch yet so we call it PRERELEASE
between now and when we're ready to branch.

Approved by:    re (implicit)
2006-02-01 18:09:05 +00:00
Yoshihiro Takahashi ec786036b0 MFC: Remove unsupported hardware. 2006-02-01 11:12:34 +00:00
Matt Jacob 9a517943e0 Megarollup MFC of the current state of the world. 2006-02-01 04:35:08 +00:00
Matt Jacob cafeae18b7 MFC version 1.8 (11 months late). 2006-02-01 04:34:09 +00:00
Brad Davis c96c4951d3 MFC 1.37
- Mention that users need to be in the wheel group to `su - root' by default, and how to change it.

PR:		docs/70616
Submitted by:	Jilles Tjoelker <jilles at stack dot nl>
Reviewed by:	ru@
Approved by:	ceri@
2006-01-31 20:32:36 +00:00
Andrey A. Chernov c17df275e5 MFC: 1.21 (continue on error) 2006-01-31 20:08:49 +00:00
Kirill Ponomarev 00266f94f8 MFC: pkg_add.1:1.70
date: 2006/01/29 20:30:55;  author: krion;  state: Exp;  lines: +1 -1
  Fix typo.
2006-01-31 18:33:59 +00:00
John Hay e609b17ec5 MFC:
Add AfriNIC as a RIR.

PR:		80421
Submitted by:	Adrian Frith <adrian at frith.homelinux.org>
2006-01-31 18:16:04 +00:00
Oleg Bulyzhin a5aab63523 MFC 1.124:
Fix minor bug in uRPF: if net.link.ether.inet.useloopback=1 and we send
broadcast packet using our own source ip address it may be rejected by
uRPF rules.

PR:		kern/76971
2006-01-31 14:48:03 +00:00
Ariff Abdullah c679bff2bd MFC:
Add bounds checking to the setenv part of the kernel environment.

This has no security implications since only root is allowed to use
kenv(1) (and corrupt the kernel memory after adding too much variables
previous to this commit).

This is based upon the PR [1] mentioned below, but extended to check both
bounds (in case of an overflow of the counting variable) and to comply
to the style of the function. An overflow of the counting variable
shouldn't happen after adding the check for the upper bound, but better
safe than sorry (in case some other function in the kernel overwrites
random memory).

An interested soul may want to add a printf to notify root in case the
bounds are hit.

Also allocate KENV_SIZE+1 entries (the array is NULL-terminated), since
the comment for KENV_SIZE says it's the maximum number of environment
strings. [2]

Reorder statements to avoid accessing unknown memory.
In theory, invoking kenv with very long string can panic
kernel.

PR:		83687 [1]
Submitted by:	Harry Coin <[email protected]> [1]
2006-01-30 12:17:29 +00:00
Ariff Abdullah 8c5c7e92bc MFC:
The resource_xxx routines in subr_hints.c are called before and after the
kenv environment in kern_environment.c switches to dynamic kenv. The prior
call sets the static variable hintp to the static hints in subr_hints.c
(hintmode==0).

However, changes to the environment are not detected by the resource_xxx
lookups after the change to dynamic kernel environment, so the lookup
routines only report the old stuff of hintmode==0, even after the change to
the dynamic kenv. This causes kenv users to see a different environment than
the kernel routines.

This is a problem in the mixer.c code that looks up initial mixer volume
settings from the hints: If the hints are dynamic and not from the
device.hints file, mixer.c doesn't see them, but kenv does.

The patch from the PR (modified to comply to the style of the function)
solves this.

PR:		83686
Submitted by:	Harry Coin <[email protected]>
2006-01-30 12:15:58 +00:00
Colin Percival bd6db32ac6 MFC rev 1.14:
Replace "fetch" with "fetch -r" when downloading the initial ~38MB
  snapshot in order to avoid unnecessary re-downloading.

  Remove the earlier "rm -f ${SNAPSHOTHASH}.tgz" to make this work.
2006-01-30 04:19:09 +00:00
Andrew Thompson fa5b8d2cc8 InstaMFC:
Back out of r1.148, it causes two arp replies to be sent with different mac
 addresses.
2006-01-29 23:22:42 +00:00
Scott Long 4dd75e8008 MFC Rev 1.31: Don't use Giant for fast taskqueues. 2006-01-29 21:51:33 +00:00
Ed Maste 3994da054c Merge IP multicast address list locking from HEAD to RELENG_5.
if_ath.c:1.99 awi.c:1.39 if_bfe.c:1.26 if_bge.c:1.92 if_ed.c:1.255
if_em.c:1.67 if_ex.c:1.57 if_fe.c:1.92 if_fxp.c:1.242 if_gem.c:1.32
if_hme.c:1.38 if_ie.c:1.103 if_ndis.c:1.100 if_ixgb.c:1.12 if_lge.c:1.40
if_lnc.c:1.112 if_my.c:1.30 if_nge.c:1.76 if_nve.c:1.9 if_owi.c:1.11
pdq_ifsubr.c:1.27 if_ray.c:1.80 if_re.c:1.47 if_sn.c:1.47 dp83932.c:1.20
if_tx.c:1.90 if_txp.c:1.32 if_aue.c:1.91 if_axe.c:1.31 if_cue.c:1.58
if_kue.c:1.65 if_rue.c:1.22 if_udav.c:1.15 if_vge.c:1.15 if_wi.c:1.182
if_wl.c:1.67 if_xe.c:1.58 if_dc.c:1.161 if_de.c:1.167 if_pcn.c:1.70
if_rl.c:1.153 if_sf.c:1.83 if_sis.c:1.134 if_sk.c:1.107 if_ste.c:1.85
if_ti.c:1.108 if_tl.c:1.100 if_vr.c:1.105 if_wb.c:1.80 if_xl.c:1.193:

  Modify device drivers supporting multicast addresses to lock if_addr_mtx
  over iteration of their multicast address lists when synchronizing the
  hardware address filter with the network stack-maintained list.

Note that with these changes, these drivers now depend on locking the global
if_addr_mtx, so binary modules of these drivers will not work on 5.4 or
earlier releases.

Approved by:    rwatson (mentor)
2006-01-29 15:39:09 +00:00
Tai-hwa Liang 4dbff24063 MFC: (1.4, 1.5) Allow the gif module to be built without IPv6 support when
NOINET6 is defined.
2006-01-29 07:46:26 +00:00
Florent Thoumie 6bd8c5693e MFC:
Add Product IDs :
  - Sandisk Cruzer Micro 128MB [5]
  - DANE-ELEC zMate 512MB USB flash drive [7]
  - Attache 256MB USB 2.0 Flash Drive [8]
  - Sandisk Cruzer Micro 256MB [9]

  Add scsi_da.c quirks :
  - Samsung USB key 128Mb [1]
  - Kingston DataTraveler 2.0 [2]
  - Creative MuVo Slim [3]
  - United MP 5512 Portable MP3 Player [4]
  - Sandisk Cruzer Micro 128MB [5], [9]
  - PNY USB Flash keys [6], [7], [8]

  Add umass.c quirks :
  - Sandisk Cruzer Micro 128MB [5]
  - DANE-ELEC zMate 512MB USB flash drive [7]
  - Attache 256MB USB 2.0 Flash Drive [8]
  - Sandisk Cruzer Micro 256MB [9]

      src/sys/dev/usb/usbdevs: rev 1.249 -> 1.250
      src/sys/cam/scsi/scsi_da.c: rev 1.184 -> 1.185
      src/sys/dev/usb/umass.c: rev 1.128 -> 1.130

PR:		usb/90081 [1],
		usb/89196 [2],
		kern/86131 [3],
		usb/80487 [4],
		usb/75970 [5],
		usb/75578 [6],
		usb/72344 [7],
		usb/65436 [8],
		usb/70835 [9]
Submitted by:	Henri-Pierre CHARLES <[email protected]> [1],
		Andrey Simonenko <[email protected]> [2],
		Erich Rickheit KSC <[email protected]> [3],
		[email protected] [4],
		Bram Abbekerk <[email protected]> [5],
		Thomas Pornin <[email protected]> [6],
		parv <[email protected]> [7],
		Peter D. Quilty <[email protected]> [8],
		Raymundo M. Vega <[email protected]> [9]
2006-01-29 00:46:57 +00:00
Ian Dowse a41a63b4cc MFC: add a workaround for dropped interrupts on VIA EHCI controllers.
Tested by:	Juergen Lock
2006-01-29 00:02:54 +00:00
Bjoern A. Zeeb 4929255285 MFC:
rev. 1.39 sys/net/if_gre.c
  rev. 1.21 sys/netinet/ip_gre.c      rev. 1.4  sys/netinet/ip_gre.h
  rev. 1.12 sys/netipsec/keysock.c    rev. 1.3  sys/netipsec/keysock.h
  rev. 1.32 sys/netkey/keysock.c      rev. 1.9  sys/netkey/keysock.h

  Fix stack corruptions on amd64.

  Vararg functions have a different calling convention than regular
  functions on amd64. Casting a varag function to a regular one to
  match the function pointer declaration will hide the varargs from
  the caller and we will end up with an incorrectly setup stack.

  Entirely remove the varargs from these functions and change the
  functions to match the declaration of the function pointers.
  Remove the now unnecessary casts.

  Lots of explanations and help from:     peter
  PR:                                     amd64/89261
2006-01-28 14:37:35 +00:00
Yoshihiro Takahashi 7a115c432a MFi386: revision 1.10.4.1 2006-01-28 07:38:15 +00:00
Don Lewis 59c34b7d68 MFC kern_sysctl.c 1.168
Touch all the pages wired by sysctl_wire_old_buffer() to avoid PTE
  modified bit emulation traps on Alpha while holding locks in the
  sysctl handler.
2006-01-28 00:43:53 +00:00
Colin Percival 1b97b22898 Correctly identify the host and port values on a failed
getaddrinfo lookup.

Reported by:	hrs
MFC after:	3 days
2006-01-27 14:37:10 +00:00
Oleg Bulyzhin 12fc60d0cd MFC 1.211:
1) remove useless check of loop_copy
2) convert loop_copy to "non-negative" flag
2006-01-26 23:18:11 +00:00
Matt Jacob 6f6503673e (MFC 1.106)
Incorporate the O_NONBLOCK open semantics of Linux and Solaris.
(MFC 1.103, 1.104 as well)
2006-01-26 05:02:05 +00:00
Don Lewis 939f2a63b2 MFC rmdir.2 1.14 and 1.15, and undelete.2 1.16 and 1.17
rmdir() fails with EINVAL if the last component of the path is "..".
 Document the previously undocumented behaviour of rmdir(".") returning
 EINVAL as required by POSIX and SUSv3.  Bump the man page change date.

 undelete() fails with EINVAL if the last component of the path is "..".
 Bump the man page change date.
2006-01-26 02:36:26 +00:00
Don Lewis 971227756c MFC subr_witness.c 1.198 and 1.200.
Original commit messages:

  Log:
  Track all lock relationships instead of pruning direct relationships
  if an indirect relationship exists (keep both A->B->C and A->C).
  This allows witness_checkorder() to use isitmychild() instead of
  the much more expensive isitmydescendant() to check for valid lock
  ordering.

  Don't do an expensive tree walk to update the w_level values when
  the tree is updated.  Only update the w_level values when using the
  debugger to display the tree.

  Nuke the experimental "witness_watch > 1" mode that only compared
  w_level for the two locks.  This information is no longer maintained
  at run time, and the use of isitmychild() in witness_checkorder
  should bring performance close enough to the acceptable level that
  this hack is not needed.

  Report witness data structure allocation statistics under the
  debug.witness sysctl.

  Reviewed by:    jhb
  MFC after:      30 days

  Log:
  Relocate witness_levelall(), witness_leveldescendents(), and
  witness_displaydescendants() so that they are protected by
  "#ifdef DDB/#endif" to unbreak kernels not using "option DDB".

  MFC after:      3 weeks
2006-01-26 02:33:36 +00:00
Don Lewis 61f5dca3f5 MFC vfs_lookup.c 1.84 and 1.85, and vfs_syscalls.c 1.400
Return EINVAL from lookup() if cn_nameiop is DELETE or RENAME and
 the last component of the path name is "..".  This keeps VOP_LOOKUP()
 from locking vnodes in reverse order.

 In kern_unlink(), remap EINVAL errors returned from namei() to EPERM
 to match existing (and POSIX required) behaviour.
2006-01-26 02:29:53 +00:00
Doug Barton 5c7e017924 MFC version 1.6 of the Makefile, crank WARNS up to 6
MFC version 1.2 of rcorder.c, fix for "chunk is already free" error
2006-01-26 01:34:00 +00:00
Simon L. B. Nielsen 147bc07f34 MFC rev 1.31:
Use the .Fx macro.
2006-01-25 20:56:17 +00:00
Ed Maste 9e55ba60dd MFC loader.8:1.83 loader.conf:1.99 loader.conf.5:1.24 comconsole.c:1.11
from HEAD to RELENG_5:

  Add a "comconsole_speed" loader variable that can be used to change
  the serial console speed (i386 and amd64 only). If the previous
  stage boot loader requested a serial console (RB_SERIAL or RB_MULTIPLE)
  then the default speed is determined from the current serial port
  speed. Otherwise it is set to 9600 or the value of BOOT_COMCONSOLE_SPEED
  at compile time.

Approved by:	rwatson (mentor)
2006-01-25 19:01:26 +00:00
Simon L. B. Nielsen 3180b018f7 Add FreeBSD-SA-06:07. 2006-01-25 10:39:02 +00:00
Colin Percival 54c56f90a5 Make sure buffers in if_bridge are fully initialized before copying
them to userland. [1]

MFC rev. 1.16 of sys/contrib/pf/net/pf_norm.c: Correct an error in pf
handling of IP packet fragments which could result in a kernel panic. [2]

Security:	FreeBSD-SA-06:06.kmem [1]
Security:	FreeBSD-SA-06:07.pf [2]
2006-01-25 10:01:47 +00:00
Ceri Davies 4526e21672 MFC revision 1.280:
It's perfectly valid to run rpc_statd and rpc_lockd as an NFS
	client, so update the documentation to reflect that.
2006-01-24 18:41:30 +00:00
Ceri Davies 7625bbb722 MFC revisions 1.36 and 1.37:
r1.36:
	  Correct obsolete chown syntax.

	r1.37:
	  If sysinstall was used to configure an anonymous FTP area, it
	was possible for information to be copied from the group file to
	the group file in the FTP area.  This patch based on a patch
	from Zak Johnson <zakj at nox dot cx>.
2006-01-24 18:35:28 +00:00
Brooks Davis 8cb964f765 MFC etc/rc.initdiskless rev 1.49: Don't create memory backed file
systems with soft-updates enabled.

PR:		conf/85558
Submitted by:	Ralf Wenk <RZ dash FreeBSD0605 at hs dash karlsruhe dot de>
2006-01-24 05:54:18 +00:00
Mohan Srinivasan 8b3b28fe76 Avoid an infinite loop in sack scoreboard processing when the per-hole
limits or global scoreboard limits are reached, or when memory
exhaustion occurs. This can occur when an existing hole fails to be
split due to limits or memory exhaustion.

Found by:     Scott Wood <[email protected]>
Submitted by: Raja Mukerji <[email protected]>
Reviewed by:  Mohan, Noritoshi, and Scott
2006-01-24 01:16:18 +00:00
Marius Strobl 6911a45725 MFC: sys/sparc64/pci/psycho.c 1.54 - 1.57,
sys/sparc64/pci/psychoreg.h 1.10 - 1.11,
     sys/sparc64/pci/psychovar.h 1.13 - 1.14

Sync psycho(4) with HEAD expect for the UPA_RANGE_* -> OFW_PCI_RANGE_*
and PCI_CS_* -> OFW_PCI_CS_* changes in order to mainly obtain the
following changes:
- Add a workaround for the incorrect interrupt map entry for the EBus
  bridge on E250 machines. [1]
- Register an interrupt handler for the spare hardware interrupt which
  according to OpenSolaris is used as the over-temperature interrupt in
  systems with Psycho bridges.

PR:		88279 [1]
2006-01-23 16:50:41 +00:00
Marius Strobl 5c107dc100 Remove files which are unused in this branch. 2006-01-23 16:39:19 +00:00
Ceri Davies 4e0f1cc1b4 MFC revision 1.4:
Add nofification events to the list of event types.
2006-01-23 14:15:44 +00:00
Diomidis Spinellis 8b298d6215 MFC: Return EINVAL if the tv_usec part of the utimes(2) arguments
contains incorrect fractional second values (outside the range
0-999999).
Prior to this change users could create files with values outside
that range.  Moreover, on 32-bit machines tv_usec offsets larger than
4.3s would result in an unnormalized AND wrong timestamp value,
due to overflow.
2006-01-22 13:52:10 +00:00
Diomidis Spinellis fef13b1b78 MFC change 2005-09-19 10:11:47 UTC
Setting .nofinger will not hide you from root.
2006-01-22 11:56:15 +00:00
Diomidis Spinellis ef3d84be18 MFC 1.47: Document the TMPDIR environment variable. 2006-01-22 11:41:18 +00:00
Marcus Alves Grando 200f76586f MFC: share/man/man4/umass.4 1.42
Add Time DPA20B MP3 Player (1Gb) [1]
Add Qware BeatZkey! Pro [2]
Add Merlin SM300 MP3/WMA Player (256Mb)

PR:		usb/81846 [1], usb/79164 [2]
Approved by:	njl (implict)
2006-01-21 20:39:21 +00:00
Wes Peters 58cafc7323 MFC r1.13: Tell nextboot to clean up after itself.
PR:		88831
2006-01-21 17:29:27 +00:00
Colin Percival bb2b795572 MFC rev. 1.3:
Add a warning pointing out that incomplete ports trees are not
  supported and that users of REFUSE directives should update their
  entire ports tree before asking for help on the mailing lists.
2006-01-21 09:59:07 +00:00
Colin Percival 60d3a7df96 MFC rev 1.5:
Mention that the random time slept by "portsnap cron" is between 1 and
  3600 seconds.
2006-01-21 09:56:28 +00:00
Marcus Alves Grando c67e05c189 MFC: src/sys/cam/scsi/scsi_da.c 1.184
Allow to use Time DPA20B 1GB MP3 Player [1]
Allow to use Qware BeatZkey! Pro [2]

PR:		usb/81846 [1], usb/79164 [2]
Submitted by:	Ruben de Groot <[email protected]> [1], Radek Kozlowski <[email protected]> [2]
Approved by:	njl (implict)
2006-01-20 19:23:47 +00:00
Pyun YongHyeon 81a68fe6ef MFC if_hme.c:1.46 to RELENG_5:
fix Rx checksum computation on little endian systems.
2006-01-20 06:29:24 +00:00
Christian Brueffer 3f3235c6a4 MFC: rev. 1.26 + 1.27
Mention the fire screensaver.
2006-01-19 22:14:20 +00:00
Andrew Thompson 7728683cb7 MFC: sync code to HEAD (excluding etherip support)
- whitespace
 - add net.link.bridge.pfil_onlyip
 - use time_uptime
 - clear IFCAP_TXCSUM while bridging
2006-01-19 04:22:25 +00:00
Andrew Thompson b043d2346a MFC r1.148:
Include the bridge interface itself in the special arp handling.
2006-01-19 01:07:10 +00:00
Ed Maste ba3e4e8781 Merge IP multicast address list locking from HEAD to RELENG_5, with a
few changes to preserve ABI compatibility.

subr_witness.c:1.196:
  Add in_multi_mtx, igmp_mtx, and if_addr_mtx lock order to hard-coded
  lock order in WITNESS, in that order.

in_var.h:1.54 in6_var.h:1.23 mld6.c:1.22:
  Modify network protocol consumers of the ifnet multicast address lists
  to lock if_addr_mtx.

igmp.c:1.49 in.c:1.86: in_var.h:1.55 ip_input.c:1.303 ip_output.c:1.243:
  Introduce in_multi_mtx, which will protect IPv4-layer multicast address
  lists, as well as accessor macros.  For now, this is a recursive mutex
  due code sequences where IPv4 multicast calls into IGMP calls into
  ip_output(), which then tests for a multicast forwarding case.

  For support macros in in_var.h to check multicast address lists, assert
  that in_multi_mtx is held.

  Acquire in_multi_mtx around iteration over the IPv4 multicast address
  lists, such as in ip_input() and ip_output().

  Acquire in_multi_mtx when manipulating the IPv4 layer multicast
  addresses, as well as over the manipulation of ifnet multicast address
  lists in order to keep the two layers in sync.

  Lock down accesses to IPv4 multicast addresses in IGMP, or assert the
  lock when performing IGMP join/leave events.

  Eliminate spl's associated with IPv4 multicast addresses, portions of
  IGMP that weren't previously expunged by IGMP locking.

in.c:1.89 in.c:1.90:
  Acquire Giant conditionally in in_addmulti() and in_delmulti() based on
  whether the interface being accessed is IFF_NEEDSGIANT or not.  This
  avoids lock order reversals when calling into the interface ioctl
  handler, which could potentially lead to deadlock.

  The long term solution is to eliminate non-MPSAFE network drivers.

  Discussed with: jhb

  Unlock Giant symmetrically with respect to lock acquire order as that's
  generally nicer.

  Spotted by:     johan

ip_output.c:1.244:
  Add helper function ip_findmoptions(), which accepts an inpcb, and attempts
  to atomically return either an existing set of IP multicast options for the
  PCB, or a newlly allocated set with default values.  The inpcb is returned
  locked.  This function may sleep.

  Call ip_moptions() to acquire a reference to a PCB's socket options, and
  perform the update of the options while holding the PCB lock.  Release the
  lock before returning.

  Remove garbage collection of multicast options when values return to the
  default, as this complicates locking substantially.  Most applications
  allocate a socket either to be multicast, or not, and don't tend to keep
  around sockets that have previously been used for multicast, then used for
  unicast.

  This closes a number of race conditions involving multiple threads or
  processes modifying the IP multicast state of a socket simultaenously.

Approved by:	rwatson (mentor)
2006-01-18 23:36:49 +00:00
Marcus Alves Grando 88043dd5ae MFC6: Merge quirks differences between RELENG_6 and RELENG_5.
Approved by:	njl
2006-01-17 23:38:46 +00:00
Simon L. B. Nielsen 70ceb6727f - Add FreeBSD-SA-06:0[123].
- Bump copyright year.
2006-01-17 13:01:46 +00:00
Doug Barton 6a7d6355f7 MFC mechanism to include files added by ports which contain
names of directories to include in the base ldconfig script.

Bump __FreeBSD_version to recognize this change
2006-01-17 07:33:33 +00:00
Florent Thoumie e28aef0adc MFC:
Enable NO_GETMAXLUN quirk.

      src/sys/dev/usb/umass.c: rev 1.127 -> 1.128

PR:		usb/81073
Submitted by:	James E. Flemer <[email protected]>
2006-01-16 22:34:20 +00:00
Florent Thoumie 039e1f239e MFC:
Add -K option to pkg_add and pkg_info.
  This option saves packages to PKGDIR (if defined or current directory by default)
  as they are downloaded.
  Silent a warning when -n is used and package has a +DISPLAY file.

      src/usr.sbin/pkg_install/info/perform.c: rev 1.53 -> 1.54
      src/usr.sbin/pkg_install/add/main.c: rev 1.65 -> 1.66
      src/usr.sbin/pkg_install/lib/lib.h: rev 1.56 -> 1.57
      src/usr.sbin/pkg_install/info/pkg_info.1: rev 1.55 -> 1.56
      src/usr.sbin/pkg_install/add/add.h: rev 1.12 -> 1.13
      src/usr.sbin/pkg_install/add/pkg_add.1: rev 1.68 -> 1.69
      src/usr.sbin/pkg_install/add/perform.c: rev 1.78 -> 1.79
      src/usr.sbin/pkg_install/info/info.h: rev 1.28 -> 1.29
      src/usr.sbin/pkg_install/lib/url.c: rev 1.4 -> 1.5
      src/usr.sbin/pkg_install/info/main.c: rev 1.48 -> 1.49
2006-01-16 19:51:41 +00:00
Xin LI 5bc03587f2 MFC revision 1.185
date: 2005/12/16 18:32:39;  author: delphij;  state: Exp;  lines: +2 -0
In pipe_write(): when uiomove() fails, do not spin on it forever.

Submitted by:   Kostik Belousov <kostikbel at gmail.com> on -current@
Message-ID:     <[email protected]>
Security:	Local DoS
2006-01-14 19:57:48 +00:00
Ed Maste 9f9883b4b3 MFC r1.121: Don't send an ICMP response for IP fragments.
Approved by:	rwatson (mentor)
2006-01-14 15:18:02 +00:00
Pav Lucistnik 43c92d953b MFC 1.34: mention the size of the additional header 2006-01-14 12:13:04 +00:00
Doug Barton 90da14c8bd MFC import of BIND 9.3.2 2006-01-14 10:42:13 +00:00
Doug Barton 1e9828eb87 Complete the MFC process for removing thread support 2006-01-14 10:37:51 +00:00
Joel Dahl 188440fdef MFC r1.1343: Fix minor sorting issue. 2006-01-14 10:00:13 +00:00
Ralf S. Engelschall e92d8ee5c8 MFC r1.276:
Fix semantics in the documentation of the "jail_socket_unixiproute_only"
variable ("YES" vs. "NO") and be more precise and intuitive on what is
actually allowed/restricted by this variable ("UNIX/IP/route sockets"
vs. "TCP/IP protocols").
2006-01-14 08:35:27 +00:00
Ralf S. Engelschall 1fd6da83ea MFC r1.16:
Remove superfluous line continuation backslash.
2006-01-14 08:33:33 +00:00
Ralf S. Engelschall f267af8379 MFC r1.13:
1. Add missing semicolon between "warn" and "return" to make sure
   the line continuation backslash doesn't cause "warn" to print
   "return".
2. Group "warn" and "return" together as the "return 1" should be
   performed only if the "kldload nfsclient" also failed (and not
   already if the "vfs.nfs" sysctl(8) check failed).
2006-01-14 08:31:02 +00:00
Doug Barton dfa112d9ed These files are only relevant in HEAD, where the imports are done. 2006-01-14 06:13:17 +00:00
Pav Lucistnik 1256c6f4fb MFC 1.16: fix: documentation for -m option was inserted halfway thru the text
of -l option.
2006-01-13 20:02:56 +00:00
Joel Dahl cbc532da2b MFC: Remove references to snd_vortex1(4). 2006-01-13 14:56:51 +00:00
cvs2svn a7f4d3a87f This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2006-01-13 06:51:44 +00:00
Colin Percival 1c9ec3804f MFC:
Make "portsnap extract" automatically create ${PORTSDIR} if necessary
  instead of complaining that "Directory does not exist or is not
  writable".
2006-01-13 00:53:53 +00:00
Wes Peters 9e7160fb93 MFC r1.239, avoid deadlock on mbuf exhaustion. 2006-01-12 18:31:02 +00:00
Florent Thoumie a5f425426e MFC:
Fix -r causing SIGSEGV due to parse_args() being called before font_current is set.

      src/usr.sbin/kbdmap/kbdmap.c: rev 1.4
2006-01-12 01:26:34 +00:00
Ed Maste 488af50c7b Merge rtsock.c:1.127 from HEAD to RELENG_5:
De-spl parts of the routing socket code now generally protected
  through locking; leave some spl references around code where there
  are open questions about global variable references.

The comment about IF_ADDR_LOCK() and SYSCTL_OUT() in 1.127 does not
apply, as that issue was fixed by the MFC of 1.129.

Approved by:    rwatson (mentor)
2006-01-11 21:45:31 +00:00
Ed Maste 6ffdb4b36b MFC rtsock.c:1.129:
Protect interface and address lists using the appropriate mutex. These
  locks were not aquired because the user buffers were not wired, thus it
  was possible that that SYSCTL_OUT could sleep, causing a number of
  different problems such as lock ordering issues and dead locks.

  -Wire user supplied buffer to ensure SYSCTL_OUT will not sleep.
  -Pickup ifnet locks to protect the list.
  -Where applicable pickup address locks.
  -Pickup radix node head locks.
  -Remove splnet stubs
  -Remove various comments about locking here, because they are no
   longer needed.

  It is the hope that these changes will make sysctl_rtsock MP safe.

Approved by:	rwatson (mentor)
2006-01-11 18:12:35 +00:00
Brooks Davis e88e8bef9f MFC rev 1.38: attempt to mount /usr if we need to populate /var and we
can't find mtree.

PR:		conf/71757
2006-01-11 16:39:09 +00:00
Xin LI 04d05bf82b MFC revision 1.131
date: 2005/12/13 15:32:52;  author: delphij;  state: Exp;  lines: +5 -5
In Linux, kernel parameters passed to ioctl are by value, while in FreeBSD
they are passed by reference.  Handle the difference within the
linux_ioctl_termio on the LINUX_TCFLSH path.

Submitted by:   Jaroslav Drzik <jaro_AT_coop-voz_dot_sk>
Reminded by:	glebius
2006-01-11 15:40:00 +00:00
Gleb Smirnoff 4efd98abc9 MFC 1.76, 1.77:
The receive function em_process_receive_interrupts() unlocks the
  adapter while ether_input() processes the packet, and then locks
  it back. In the meantime, em_init() may be called, either from
  em_watchdog() from softclock interrupt or from the ifconfig(8)
  program. The em_init() resets the card, in particular it sets
  adapter->next_rx_desc_to_check to 0 and resets hardware RX Head
  and Tail descriptor pointers. The loop in
  em_process_receive_interrupts() does not expect these things to
  change, and a mess may result.

  PR:             kern/87418
  Submitted by:   Dmitrij Tejblum <tejblum yandex-team.ru>
2006-01-11 10:31:54 +00:00
Colin Percival d3344df0ec Correct insecure temporary file usage in texindex. [06:01]
Correct insecure temporary file usage in ee. [06:02]
Correct a race condition when setting file permissions, sanitize file
names by default, and fix a buffer overflow when handling files
larger than 4GB in cpio. [06:03]

Security:	FreeBSD-SA-06:01.texindex
Security:	FreeBSD-SA-06:02.ee
Security:	FreeBSD-SA-06:03.cpio
2006-01-11 08:06:47 +00:00
Brooks Davis a5f8a4205d MFC rev 1.6:
When removing the local domain, only do so when the result
	will be a host name.  This is matches the documented behaviro.
	The previous behavior would remove the domain name even if
	the result retained a dot.

	This fixes rsh connections from a.example.com to example.com.

This is also reported to fix rsh connections from host xxx to
yyy.example.com.

PR:             88301
2006-01-11 06:41:30 +00:00
Brooks Davis 914f664b04 MFC revs 1.46 and 1.47 (from src/etc/rc.initdiskless).
Switch from pax to tar for extracting cpio archives.  pax requires a
writable /tmp (or TMPDIR) and thus is unsuitable for this job.

The pax command used was also invalid.

PR:		conf/88293
2006-01-11 06:22:21 +00:00
Brooks Davis 3e18b4a313 MFC:
Allow chkprintcap(8) to be run before lpd is started.  Disabled by
default. Default flags create missing directories.

Remove comment about doing this in etc/rc.d/var.

PR:		conf/71488
2006-01-11 06:06:54 +00:00
Brooks Davis 3ee3e8bf64 MFC revs 1.27 and 1.28.
1.27: don't crash when given an invalid nwkey string
 1.28: parse SSIDs correctly and bail immediatly when invalid

PR:		misc/88159, bin/74509
2006-01-11 05:56:02 +00:00
Florent Thoumie 2453414518 MFC:
- Add an entry for Acer Acerscan 1240U.

      src/share/man/man4/uscanner.4: rev 1.21
2006-01-11 00:37:32 +00:00
Florent Thoumie 43838dfdc3 MFC:
Add Product ID for Acerscan 1240u and the corresponding entry in uscanner.c.

      src/sys/dev/usb/usbdevs: rev 1.247
      src/sys/dev/usb/uscanner.c: rev 1.67
2006-01-11 00:29:16 +00:00
Kirill Ponomarev 1ad49bd592 MFC: add/extract.c:1.44 create/perform.c:1.82 create/pkg_create.1:1.70 create/pl.c:1.28
info/show.c:1.40 lib/plist.c:1.51

  date: 2006/01/07 22:10:57;  author: krion;  state: Exp;  lines: +10 -3
  When using @cwd %%FOO%%, we must ensure to return in the original
  prefix later, but doing so with @cwd %%OLDPREFIX%% (having
  PLIST_SUB+="OLDPREFIX=${PREFIX}") hardcodes the value in the packing
  list. That's not really a problem when dealing with ports but that's
  a problem with packages since pkg_add -p option only overrides the
  first @cwd occurrence.

  This patch allow us to use @cwd without any argument. If no
  directory argument is given, it will set current working directory
  to the first prefix given by the @cwd command.

  PR:             bin/77212
  Submitted by:   flz
2006-01-10 22:17:08 +00:00
John Baldwin 33b674d244 MF6: Fix a couple of issues with the ibcs2 module event handler. 2006-01-10 21:46:19 +00:00
Gleb Smirnoff e0a695f564 MFC 1.11:
In ng_netflow_disconnect() check whether we are working with "iface"
  or with "out" hook, and clear the right pointer.

  Reported by:    Vitaliy Ovsyannikov <V.Ovsyannikov kr.ru>
2006-01-10 10:22:22 +00:00
Gleb Smirnoff 44316718d9 MFC 1.62:
Add \n to log() message.
2006-01-10 10:13:43 +00:00
Yoshihiro Takahashi 14cccfa2ae MFC: revision 1.56
- Add EXTDOCDIR and EXTPORTSDIR.
2006-01-10 03:48:42 +00:00
Yoshihiro Takahashi 9da419e619 MFC: revision 1.894 and 1.895
- Request boot floppy after loading mfsroot floppy.
 - Add EXTPORTSDIR.
2006-01-10 03:47:27 +00:00
Maxim Sobolev 188d6d478e MFC: allow execution of ET_DYN elf binaries (aka shared libraries) when
emulating architectures that allow this (Linux so far).

To preserve kernel modules ABI, unlike the version commited into the trunk,
which adds new flag field into Brandinfo structure for this purpose, this
one checks if brand field of Brandinfo matches ELFOSABI_LINUX.

PR:		kern/87615
Submitted by:	Marcin Koziej <[email protected]>
2006-01-10 02:12:27 +00:00
Stefan Farfeleder 36a9042b4f MFC a small part of the big NetBSD merge that fixes a few bugs and should be
safe for RELENG_5.

el.c:
	Check term_init() and strdup() failure.
history.c and tokenizer.c:
	Check malloc() failure.
makelist and map.c:
	Respect list sentinel.
refresh.c:
	Refresh bug.
2006-01-09 18:02:39 +00:00
Ceri Davies ef87a050c3 MFC revision 1.82:
inetd(8) requires that /etc/netconfig be present, and contain entries
  for each of udp and tcp (and their IPv6 equivalents when INET6 is
  enabled).  Note that dependency here.

  PR:             docs/90435
  Submitted by:   Dmitry Kazarov <kazarov at mcm dot ru>
  Pointed out by: Daniel Gerzo <danger at rulez dot sk>
2006-01-07 13:57:58 +00:00
Don Lewis 89f72137d0 MFC kern_proc.c 1.232, adapted to RELENG_5.
Original commit message:
truckman    2005-10-02 23:27:56 UTC

  FreeBSD src repository

  Modified files:
    sys/kern             kern_proc.c
  Log:
  Always wire the sysctl output buffer in sysctl_kern_proc() before
  calling sysctl_out_proc().  -- fix from jhb

  Move the code in fill_kinfo_thread() that gathers data from struct proc
  into the new function fill_kinfo_proc_only().

  Change all callers of fill_kinfo_thread() to call both
  fill_kinfo_proc_only() and fill_kinfo() thread.  When gathering
  data from a multi-threaded process, fill_kinfo_proc_only() only needs
  to be called once.

  Grab sched_lock before accessing the process thread list or calling
  fill_kinfo_thread().

  PR:             kern/84684
  MFC after:      3 days

Testing this patch on RELENG_5 did not uncover any regressions,
but no testing was done by anyone who was suffering from the problem
this patch is intended to fix.

Tested by:	"Stian Fjeldstad" <sbf AT pcom DOT no>
PR:		kern/84684
2006-01-05 18:57:32 +00:00
Florent Thoumie 82d60c0c86 Fix latest commit, some vendor ids and product ids were missing.
Approved by:	pjd (implicit)
Pointyhat to:	self
2006-01-05 16:54:18 +00:00
Florent Thoumie f52e613ed9 MFC:
Add a hid blacklist quirk.

      src/sys/dev/usb/usbdevs: rev 1.240
      src/sys/dev/usb/usb_quirks.c: rev 1.45
      src/sys/dev/usb/uhid.c: rev 1.78
      src/sys/dev/usb/usb_quirks.h: rev 1.20

Approved by:	pjd
2006-01-05 16:46:10 +00:00
Roman Kurakin 692f703b76 MFC: -j 1.280 -j 1.281
---------------------------
	revision 1.281
	date: 2005/10/04 16:27:54;  author: rik; state: Exp;  lines: +3 -1
	Use FILEDESC_UNLOCK(fdp) after FILE_ULOCK(p), not before to avoid LOR.
	Slightly discussed on current@.

	LOR #055

	MFC after:	14 days
	----------------------------
2006-01-04 10:35:47 +00:00
Ariff Abdullah 67bb69ad07 MFC: - Fix possible memory leak due to repetetive strdup(3) without matching
free(3).
     - print_recsrc() should honor shortflag and give appropriate output for
       later consumption by /etc/rc.d/mixer. This will ensure that recording
       device selections survived across reboot. Output everything to stdout
       instead of stderr.
2006-01-04 00:37:13 +00:00
Ed Maste 327cc58a8d Merge link layer mutlicast address list locking from HEAD to RELENG_5,
with a few changes to preserve ABI compatibility.

if_var.h:1.100:
  Add if_addr_mtx, a mutex to protect ifnet-related address lists.  Add
  accessor macros.

  Unlike FreeBSD 6 and HEAD, share a global mutex (instead of putting it
  in struct ifnet) to maintain ABI backwards compatibility.

if_var.h:1.101:
  - Rename ifmaof_ifpforaddr() to if_findmulti(); assert if_addr_mtx.
    Staticize.

if.c:1.239:
  Protect link layer network interface multicast address list manipulation
  using (global) if_addr_mtx:

  - Initialize if_addr_mtx in if_init().

  - Rename ifmaof_ifpforaddr() to if_findmulti(); assert if_addr_mtx.
    Staticize.

  - Extract ifmultiaddr allocation and initialization into if_allocmulti();
    accept a 'mflags' argument to indicate whether or not sleeping is
    permitted.  This centralizes error handling and address duplication.

  - Extract ifmultiaddr tear-down and deallocation in if_freemulti().

  - Re-structure if_addmulti() to hold if_addr_mtx around manipulation of
    the ifnet multicast address list and reference count manipulation.
    Make use of non-sleeping allocations.  Annotate the fact that we only
    generate routing socket events for explicit address addition, not
    implicit link layer address addition.

  - Re-structure if_delmulti() to hold if_addr_mtx around manipulation of
    the ifnet multicast address list and reference count manipulation.
    Annotate the lack of a routing socket event for implicit link layer
    address removal.

  - De-spl all and sundry.

Approved by:	rwatson (mentor)
2006-01-03 22:42:58 +00:00
Ed Maste a6861c64df MFC kern_clock.c:1.181
In watchdog_config enable the software watchdog iff the WD_ACTIVE flag
  is set.  When watchdogd(1) is terminated intentionally it clears the
  bit, which should then disable it in the kernel.

PR:             kern/74386
Submitted by:   Alex Hoff <ahoff at sandvine dot com>
Approved by:    rwatson (mentor)
2006-01-03 16:34:55 +00:00
Paul Saab 03751f62f0 MFC:
There's no reason to check the valence.  This allows ciss to work
on the P600.
2005-12-31 06:28:06 +00:00
Paul Saab 099a8b7c7e MFC: rev 1.67
It seems ciss should ignore overrun and underrun on a SCSI INQUIRY
command.  This fixes some weird booting issues on newer versions
of the firmware on the MSA20.
2005-12-31 06:25:16 +00:00
Paul Saab f789407191 MFC: rev 1.66
Update PCI ids to add the E200, E200i, P400, and P400i storage
controllers.  Remove the E400 since it is not a real product.
2005-12-31 06:24:44 +00:00
Paul Saab 4fdf2a116e MFC: rev 1.65
There's no reason to check the valence.  This allows ciss to work
on the P600.
2005-12-31 06:23:58 +00:00
Xin LI 4e69839bea MFC revision 1.10:
Suggest the user to use 'diff -urN' instead of 'diff -crN'.

Submitted by:	Jimmie James  <[email protected]>
PR:		docs/88427
2005-12-31 05:36:42 +00:00
Andrew Thompson e7d961ca7c Add the documentation for if_bridge(4) commands which was missed when the code
was MFCed to RELENG_5
2005-12-29 11:16:23 +00:00
Andrew Thompson bf90dda516 MFC: Add support for creating span ports on a bridge 2005-12-29 10:56:10 +00:00
Gleb Smirnoff 3d2923b840 MFC 1.251:
When we drop packet due to no space in output interface output queue, also
  increase the ifp->if_snd.ifq_drops.

  PR:             72440
  Submitted by:   ikob
2005-12-28 13:37:25 +00:00
Ade Lovett 7b81d6457a MFC: 1.171 2005-12-28 08:42:54 +00:00
Garrett Wollman 1de83dbe2a Merge tzdata2005r from vendor branch. 2005-12-27 19:57:37 +00:00
Pav Lucistnik d1f6e64309 MFC umass.c 1.126,1.127 and usbdevs 1.239:
- Ignore incorrect CSW signatures on my PURE PocketDAB 2000 player
2005-12-27 00:35:38 +00:00
Remko Lodder 24b2007e89 MFC v1.28 by ru:
fix a markup nit.

  PR:             docs/88848
  Prodded by:     remko
2005-12-26 19:02:08 +00:00
Stefan Farfeleder 5cfe166afe MFC important changes:
- Add -v and -V to the command builtin.
- Return value from unalias.
- Fixes for the errexit mode.
- Avoid segfaults on signals.
- Add the times builtin.
- Make 'set +o' output POSIX compliant.
- Correctly quoted output of trap.
- Man page updates.
2005-12-26 18:15:37 +00:00
Wilko Bulte 1ecd557fab We will not be responsible for damage to equipment, your ego, county wide
power outages, spontaneously generated mini (or larger) black holes,
planetary disruptions, or personal injury or worse that may result from the
use of this material.
                -- taken from Samuel M. Goldwasser's
                   Sam's Strobe FAQ Notes on the Troubleshooting
                   and Repair of Electronic Flash Units and Strobe Lights
2005-12-25 23:29:59 +00:00
Diomidis Spinellis 1391fc49d1 MFC 1.19
Use the appropriate error function for displaying the error,
instead of printing it to stdout.
2005-12-25 16:26:40 +00:00
Wilko Bulte 50d5f1031d "A life lived in fear is a life half lived" 2005-12-24 17:55:33 +00:00
George V. Neville-Neil b828a19007 MFC of fixes from Kame that didn't make the 5 STABLE branch. 2005-12-24 10:22:50 +00:00
Andrew Thompson 48032c62c8 MFC r1.41, do not BPF_MTAP the packet twice 2005-12-24 01:13:17 +00:00
George V. Neville-Neil 228da36a66 MFC of coverity fixes against IPv6. 2005-12-23 07:09:39 +00:00
Garrett Wollman cb9d457bd8 Merge tzdata2005q from vendor branch. List of territories affected is
the same as for HEAD.
2005-12-22 23:51:56 +00:00
Ed Maste 94ffa2763f MFC r1.84:
ifma_protospec is a pointer. Use NULL when assigning or comparing it.

Approved by:	scottl
Silence from:	rwatson (mentor)
2005-12-22 16:31:07 +00:00
Ed Maste 5a57d98f7e Merge if_arcsubr.c:1.26, if_ethersubr.c:1.195, if_fddisubr.c:1.99,
if_iso88025subr.c:1.68 from HEAD to RELENG_5:

  When allocating link layer ifnet address list entries in
  ifp->if_resolvemulti(), do so with M_NOWAIT rather than M_WAITOK, so
  that a mutex can be held over the call.  In the FDDI code, add a
  missing M_ZERO.  Consumers are already aware that if_resolvemulti()
  can fail.

Approved by:	scottl
Silcence from:	rwatson (mentor)
2005-12-22 16:23:26 +00:00
Ed Maste 69f4fe434c MFC r1.235, r1.237, r1.238:
(1.235)
  - Introduce a helper function if_setflag() containing the code common
    to ifpromisc() and if_allmulti() instead of duplicating the code poorly,
    with different bugs.
  - Call ifp->if_ioctl() in a consistent way: always use more compatible C
    syntax and check whether ifp->if_ioctl is not NULL prior to the call.

  (1.237)
  Rename equal() macro to sa_equal(), which matches the definitions
  of sa_equal() in other files, and makes it more clear what equal()
  is comparing.

  (1.238)
  In multicast routines:

  Compare pointers with NULL rather than treating them as booleans.

  Compare pointers with NULL rather than 0 to make it more clear
  they are pointers.

  Assign pointers value of NULL rather than 0 to make it more clear
  they are pointers.

Approved by:	scottl
Silence from:	rwatson (mentor)
2005-12-22 05:05:00 +00:00
Ed Maste b781740b26 MFC r1.160:
When using m_dup(9) to copy more than MHLEN bytes of data, don't
  create an mbuf chain that starts with a cluster containing just MHLEN
  bytes.  This happened because m_dup called m_get or m_getcl depending
  on the amount of data to copy, but then always set the size available
  in the first mbuf to MHLEN.

Approved by:	jmg
Silence from:	rwatson (mentor)
2005-12-22 04:29:03 +00:00
Florent Thoumie 6dfe8d5f7d MFC: Add ProductID for the iPod Nano.
usb_quirks.c:	1.44
	usbdevs:	1.237

Approved by:	ssouhlal
2005-12-21 23:11:14 +00:00
Andrew Thompson 0f22217371 MFC r1.37: use m_dup rather than m_copypacket 2005-12-21 22:52:48 +00:00
Doug Barton f28574cb01 MFC 1.52, do not delete stale /etc/rc.d files by default 2005-12-21 09:04:24 +00:00
Gleb Smirnoff 547b5aff83 - In upgrade from 4.x paragraph prefer "5.x" instead of "-current". 5.x
isn't CURRENT anymore.
- In upgrade from 4.x paragraph notice that it is important to
  delete /sbin/mountd, otherwise it will be started instead of
  /usr/bin/mountd.
2005-12-19 14:53:30 +00:00
Ken Smith 85f7fc920d Catch up on several MFCs:
> revision 1.9
> date: 2005/12/07 22:25:12;  author: obrien;  state: Exp;  lines: +0 -1
> Remove the ports version of bsdiff - it is now in the base system.
>
> revision 1.8
> date: 2005/12/07 21:41:59;  author: obrien;  state: Exp;  lines: +0 -1
> Remove the ports version of portsnap - it is now in the base system.
>
> revision 1.7
> date: 2005/11/03 00:23:13;  author: kensmith;  state: Exp;  lines: +1 -6
> It had been noticed disc2 was overflowing earlier but committing the
> fix slipped through a crack.  Remove the apache and php packages under
> the assumption someone installing a Web server has network access and
> doesn't *need* the packages on disc2.
2005-12-17 00:12:20 +00:00
Bill Paul e37ee6bb58 MFC^2: merge recent changes from -current (interrupt handler API cleanup,
Ralink RT2500 deadlock with wpa_supplicant).
2005-12-16 17:34:36 +00:00
Maxime Henrion bad873e4cd MFC r1.252:
date: 2005/12/12 14:30:13;  author: mux;  state: Exp;  lines: +1 -0
  Add the device ID of fxp(4) NICs found in Sony Vaio VGN-TX1XP laptops.
2005-12-16 03:26:37 +00:00
Wilko Bulte 1429f7359f Spelling fixes and minor nit.
PR: doc/9035
Submitted by: Gavin Atkinson <[email protected]>
2005-12-14 19:50:55 +00:00
Max Laier 4ab81d9671 MFC: 1.91
Fix calculation of meminfo's swaptotal and swapfree on at least amd64.
2005-12-14 19:07:38 +00:00
Florent Thoumie e32b3b7dd3 MFC: USB Quirk for iPods (should work with some other devices).
usb_quirks.c:	1.43
	usb_quirks.h:	1.19
	usb_subr.c:	1.78
	usbdevs:	1.236

While this might not be the best solution, this has been considered good enough
to be MFC'ed.

Approved by:	ssouhlal
Discussed on:	src-committers@
2005-12-14 01:27:45 +00:00
Maksim Yevmenkin 53a79b901f MFC: Teach sdpd(8) to check peer's credentials before accepting request to
register, remove or change services in the local database. For now only
accept the request if the peer has effective user ID the same as 'root'
user ID.
2005-12-13 00:38:28 +00:00
Maksim Yevmenkin f0eae69a15 MFC: Fix typo in rfcomm_pppd(8) man page.
Noticed by:	Ronald Klop
2005-12-13 00:31:03 +00:00
Maksim Yevmenkin 7d1bb137e6 MFC: Teach rfcomm_sppd(8) to recognize "lan" (for LAN Access Using PPP) service
name in '-c' (RFCOMM channel) option.
2005-12-12 18:00:03 +00:00
Ruslan Ermilov a804439577 MFC: Fix memory leak. 2005-12-09 07:13:06 +00:00
Jesus R. Camou 4b79e19377 MFC: fix couple typos.
Approved by:	trhodes (mentor)
2005-12-08 01:55:53 +00:00
Vinod Kashyap 0ae5b42f9b MFC: twa corresponding to the 9.3.0.1 release on the 3ware website. This driver
has support for the 9xxxSX controllers, along with the earlier 9xxxS series
controllers.

MFC after:4 weeks
2005-12-07 18:20:38 +00:00
Andrew Thompson 2401e9060c MFC r1.35, set IFF_BROADCAST on the interface 2005-12-07 03:10:42 +00:00
Wilko Bulte e13e62ce59 s/Adolph Hitler/Adolf Hitler/
s/hitler/Hitler/
2005-12-05 22:35:37 +00:00
John Baldwin 9c5a1a6a02 MF6: Use >= rather than > to check for a process exceeding its time limit. 2005-12-05 20:14:56 +00:00
John Baldwin 84c657e5f7 MF6: Restore the previous state after a FILL operation in
properties_read().
2005-12-05 20:10:57 +00:00
John Baldwin 092a3a62cc MF6:
- Use .fn to markup untimeout.
- Reword a confusing sentence.
2005-12-05 20:07:52 +00:00
John Baldwin d4b66981a5 MF6: Clarify that si(4) doesn't support the newer SX+ cards from
Specialix/Perle currently.
2005-12-05 20:04:02 +00:00
John Baldwin 13b196effb MF6: Add MLINK for execvP(3). 2005-12-05 20:00:49 +00:00
Maksim Yevmenkin d15c177ea6 MFC: Add bluetooth.device.conf(5) man page 2005-12-05 18:59:43 +00:00
Colin Percival b33e3d0ff5 MFC revision 1.5:
Make "missing dependency" errors more useful by indicating which port
  is trying to depend upon the non-existent port.

  Suggested by:   kris
2005-12-05 05:07:44 +00:00
Philip Paeps e1722e0b82 MFC r1.7:
Check for altq presence during module init, and allow module to work even if
  altq is not present (just disable the altq bits in that case).
2005-12-03 14:45:05 +00:00
Philip Paeps 61953a2cd1 MFC r1.85:
Preserve /etc/sysctl.conf when doing a binary update.  This prevents, for
  instance, the dreaded shared memory problem in PostgreSQL coming back to
  haunt you after a binary update.
2005-12-03 14:37:24 +00:00
cvs2svn e9f2333ad1 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-12-02 00:17:34 +00:00
Colin Percival 6c9ea69621 Revert previous commit; it isn't supposed to be on this branch yet. 2005-12-01 22:14:45 +00:00
Colin Percival 929386ca9e Make "missing dependency" errors more useful by indicating which port
is trying to depend upon the non-existent port.

Suggested by:	kris
MFC after:	3 days
2005-12-01 22:14:44 +00:00
Maksim Yevmenkin 517a5bc694 MFC: Teach rfcomm_sppd(1) about service names, so it is possible to specify
service name instead of channel number with -c command option. Supported
service names are: DUN (Dial-Up Networking), FAX (Fax) and SP (Serial Port).
2005-11-30 18:34:13 +00:00
Tom McLaughlin e6e6befa99 MFC: Revision 1.60
Misspelling in Poul-Henning Kamp's email address under AUTHORS

Approved by:    ade
2005-11-30 04:21:59 +00:00
John Baldwin 7b6d211806 MFC: Always print the trap number for fatal traps and add trap messages
for T_XMMFLT and T_RESERVED.
2005-11-28 20:03:15 +00:00
John Baldwin a44290a0f0 MF6: Include the size of the DL_serpath structures in the total size used
in the RTLD_DI_SERINFOSIZE and RTLD_DI_SERINFO requests.
2005-11-28 19:19:52 +00:00
Yoshihiro Takahashi 7853d6499d Added pc98 support. This problem is only in RELENG_5.
Noticed by:	NOKUBI Hirotaka < nokubi at ff dot iij4u dot or dot jp >
2005-11-28 16:01:57 +00:00
Hidetoshi Shimokawa 1878075462 MFC: revision 1.81
Fix panic when we cannot find self-id of probing nodes.
2005-11-28 06:50:04 +00:00
Hiroki Sato 698e3ea493 MFC: Apply arch= selection to the qandatoc mode. This fixes
link generation with no actual target.

Reported by:	Tim Witthoeft (tim.witthoeft at gmail.com)
2005-11-28 06:26:56 +00:00
Doug Barton 4493618ad8 MFC 1.7, which fixes the failed transfer semantics for BIND 9.3.x,
and cleans up the code slightly.
2005-11-27 00:44:58 +00:00
John Polstra 4af3dfd879 MFC: Fix a bug that caused some /dev entries to continue to exist after
the underlying drive had been hot-unplugged from the system.

This merges the following revisions:

  Revision  Path
  1.94      src/sys/cam/scsi/scsi_cd.c
  1.181     src/sys/cam/scsi/scsi_da.c
  1.98      src/sys/geom/geom_disk.c
  1.5       src/sys/geom/geom_disk.h
  1.88      src/sys/geom/geom_subr.c
2005-11-26 23:20:00 +00:00
Kirill Ponomarev 7ca96b01ac MFC: pkg_info.1:1.55
date: 2005/11/23 10:31:59;  author: krion;  state: Exp;  lines: +4 -1
  Document PKG_PATH enviroment variable.

  Prodded by:     Mark Andrews <Mark_Andrews AT isc DOT org>
2005-11-26 20:58:43 +00:00
John Polstra e842c495ae MFC 1.151: Fix a bug in the loop in sonewconn that makes room on the
incomplete connection queue for a new connection.  It was removing
connections from the wrong list.
2005-11-26 19:32:30 +00:00
Gleb Smirnoff cca289ecc9 MFC 1.38: MFOpenBSD 1.62:
Prevent backup CARP hosts from replying to arp requests, fixes strangeness
    with some layer-3 switches. From Bill Marquette.

  Tested by:      Kazuaki Oda <kaakun highway.ne.jp>
2005-11-25 14:54:59 +00:00
Gleb Smirnoff a6f04c5111 MFC 1.23, 1.24
BCM5752 support
2005-11-25 14:47:32 +00:00
Gleb Smirnoff 283e9b0d88 MFC:
Recognize Broadcom BCM5752 chip, that can be found in HP DC7600.

  PR:             kern/88940
  Submitted by:   Alexander Hausner
2005-11-25 14:44:06 +00:00
Colin Percival 2e0b323538 Synchronize with version of portsnap in HEAD:
1. make_index no longer coredumps if input has zero lines.
2. phttpget no longer enters an infinite loop if the TCP connection is
closed while phttpget is reading HTTP headers.
2005-11-25 12:56:51 +00:00
Maksim Yevmenkin 95e4f7ca28 MFC: Start Bluetooth integration into rc.d system.
Introduce /etc/rc.d/bluetooth script to start/stop Bluetooth devices. It
will be called from devd(8) in response to device arrival/departure events.
It is also possible to call it by hand to start/stop particular device
without unplugging it.

Introduce generic way to set configuration parameters for Bluetooth devices.
By default /etc/rc.d/bluetooth script has hardwired defaults compatible
with old rc.bluetooth from /usr/share/netgraph/bluetooth/examples. These
can be overridden using /etc/defaults/bluetooth.device.conf file (system
wide defaults). Finally, there could be another device specific override
file located in /etc/bluetooth/$device.conf (where $device is ubt0, btccc0
etc.)

The list of configuration parameters and their meaning described in the
/etc/defaults/bluetooth.device.conf file. Even though Bluetooth device
configuration files are not shell scripts, they must follow basic sh(1) syntax.

Add rc.d scripts for the hcsecd(8) and sdpd(8) daemons. Put defaults into
/etc/defaults/rc.conf. Both daemons can run even if no Bluetooth devices
are attached to the system. Both daemons depend on Bluetooth socket layer.

Fix Bluetooth assigned numbers URL in /etc/bluetooth/protocols file.
2005-11-23 22:51:01 +00:00
Wilko Bulte 3987a45308 MFC: add witty remark about serious thought. 2005-11-23 19:16:08 +00:00
Jesus R. Camou 535adb7ea0 MFC:
Rev. 1.37.2.1.

Approved by:	trhodes (mentor)
2005-11-23 07:17:09 +00:00
cvs2svn 762c9ecd33 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-11-22 19:17:42 +00:00
Robert Watson 7e4b442eaf Merge kdump.1:1.14 and kdump.c:1.28 from HEAD to RELENG_5:
Add "-s" argument to kdump to suppress the display of I/O data.
2005-11-19 12:15:10 +00:00
Hajimu UMEMOTO d48e12f90e MFC 1.55: The KAME's getipnodebyaddr() code honor the
MULTI_PTRS_ARE_ALIASES define also, but res_config.h was not
included into libc/net/name6.c.  So getipnodebyaddr() ignored
the multiple PTRs.
2005-11-18 02:32:32 +00:00
Kirill Ponomarev a4ea7ddb00 MFC: add.h:1.12, main.c:1.65, perform.c:1.78, pkg_add.1:1.67
date: 2005/11/12 11:45:01;  author: krion;  state: Exp;  lines: +9 -2
  Add -P flag, it does the same as the -p option, except that the
  given prefix is also used recursively for the dependency packages,
  if any.  If the -P flag appears after any -p flag on the
  command line, it overrides it's effect, causing pkg_add to use the
  given prefix recursively.

  PR:             bin/75742
  Submitted by:   Frerich Raabe <raabe AT kde DOT org>
2005-11-17 18:08:58 +00:00
Andrew Thompson dbb7ad1120 MFC: Sync bridge code up with HEAD
- plug mbuf and refcnt leak
 - make funtions static
 - cleanup on member removal
 - cleanup bridge hooks
2005-11-16 10:20:16 +00:00
Robert Watson 00b9495b9f Merge kern_descrip.c:1.284 from HEAD to RELENG_5:
In closef(), remove the assumption that there is a thread associated
  with the file descriptor.  When a file descriptor is closed as a result
  of garbage collecting a UNIX domain socket, the file descriptor will
  not have any associated thread, so the logic to identify advisory locks
  held by that thread is not appropriate.  Check the thread for NULL to
  avoid this scenario.  Expand an existing comment to say a bit more about
  this.
2005-11-16 08:15:58 +00:00
Andrew Thompson 366a61df03 MFC r1.59, List IFT_BRIDGE as a valid type. 2005-11-14 22:25:33 +00:00
Robert Watson 3b5aad04e5 Merge if_em.c:1.82 from HEAD to RELENG_5:
Put probe-time printf of adapter speed and duplex behind bootverbose:
  since the link takes a bit to negotiate, the information is pretty
  much never available during the probe.  As such, the boot output
  pretty much always prints N/A for speed and duplex.  Since we print
  out the output of ifconfig during the user space boot, this early
  boot information is also generally redundant, and added to the noise.
2005-11-14 10:40:57 +00:00
Tom Rhodes ed60c4c5ca MFC:
revision 1.4
date: 2005/11/01 21:16:39;  author: trhodes;  state: Exp;  lines: +0 -6
Quick kill links to the nsmb(8) manual page, there is no such
utility that I can find.
2005-11-13 14:59:05 +00:00
Colin Percival 0883b6a282 Bump __FreeBSD_version so that the ports tree can respond to the addition
of bsdiff and portsnap to the RELENG_5 base system.
2005-11-13 07:17:31 +00:00
Colin Percival ada974ca74 MFC portsnap to RELENG_5. 2005-11-13 07:13:45 +00:00
Colin Percival 4be8a41316 MFC: connect bsdiff to the build. 2005-11-13 07:01:03 +00:00
Colin Percival 52bf56b866 MFC bsdiff/bspatch to RELENG_5. This should be identical to the version
in HEAD and RELENG_6.
2005-11-13 06:58:36 +00:00
Kirill Ponomarev 2714cf5ceb MFC: create.h:1.26, main.c:1.37, perform.c:1.81, pkg_create.1:1.69
date: 2005/11/08 20:48:26;  author: krion;  state: Exp;  lines: +1 -0
  Introduce 3 new options for pkg_create(1), -x for using basic regular
  expressions for pkg-name, -E for extended regexps and -G for exact matching.
  These new options are only meaningful when using the -b flag of pkg_create(1),
  and that the default for the -b parameter is now to do glob matching, as in
  other pkg_foo utilities that support package patterns.

  Submitted by:   mux
2005-11-11 08:08:04 +00:00
Bill Paul f14716c850 MFC^2: add RtlZeroMemory() and RtlCopyMemory() for Broadcom amd64 driver. 2005-11-10 02:26:50 +00:00
John Baldwin 2130140090 MFC: Get rid of #ifdef for legacy system. Move that into the MD code.
Export minimal symbols to allow this to happen.

This should make the viapm build happy.

Pointy hat to:	jhb
2005-11-09 15:07:44 +00:00
Pav Lucistnik 92777e87d7 Add new ports-net-im collection. 2005-11-09 10:16:26 +00:00
John Baldwin 7ee19618ac MFC: Fix standalone module build. 2005-11-08 17:04:19 +00:00
Max Laier e2adc577bf MFC: rev. 1.79
Fix obvious copy'n'paste-O in rev.1.36  While here nit style.

    PR:			bin/87783
    Submitted by:	Mats Palmgren
2005-11-08 16:45:00 +00:00
John Baldwin 856ac9d368 MFC: Add the device ID for the VIA VT8235 south bridge. 2005-11-08 15:57:39 +00:00
John Baldwin 36c946adb0 MF6: If the viapm device is a PCI-ISA bridge, attach a child ISA bus. 2005-11-08 15:57:17 +00:00
John Baldwin c001e3f373 MFC (sort of, this is actually written from scratch): Fix support for
multiple rocketport cards in the same machine.  Unlike 6.x and 7.x, in 5.x
the tty drivers create the cdevsw entries themselves, so for 5.x I was able
to create compatibility aliases for unit 0 so that the old names will still
work for unit 0.

Reviewed by:	phk
Tested by:	Jim Pazarena paz at qcislands dot net
2005-11-08 15:37:21 +00:00
Bill Paul 2cdad78420 MFC^2: alias EXT_NDIS to EXT_NET_DRV 2005-11-07 16:59:15 +00:00
Bill Paul d0fc093a12 MFC: merge changes from head to support Intel 2200BG/2915ABG driver. 2005-11-06 19:40:51 +00:00
John Baldwin f1625c4c59 MFC: Allow the process name to be in square brackets ([]) in
_find_processes().
2005-11-06 15:54:43 +00:00
John Baldwin 3e7db04161 MFC: Remove spurious newline. 2005-11-06 15:51:47 +00:00
Hajimu UMEMOTO 033ae3ad3a MFC 1.3: AES counter mode uses 8byte IV, not 16 bytes. 2005-11-05 05:04:31 +00:00
Hajimu UMEMOTO fcdb31d877 MFC 1.8: fixed a crush when either -lh or -ls option is used. 2005-11-05 04:56:00 +00:00
John Baldwin 46c5c53d5b MFC: Clarify when softc is allocated and xref DEVICE_PROBE. 2005-11-04 22:17:13 +00:00
John Baldwin 029ce3bd75 Sync with RELENG_6 and HEAD. 2005-11-04 22:15:24 +00:00
Gleb Smirnoff dbf28cda8f MFC 1.91, 1.92:
- First fill in structure with valid values, and only then attach it
    to the global list.
  - In in_addprefix() compare not only route addresses, but their masks,
    too. This fixes problem when connected prefixes overlap.
2005-11-04 18:25:55 +00:00
Colin Percival 119ae8c41b MFC rev. 1.2: Use the "builtin" shell function to make sure that the
requested command is handled as a shell function.
2005-11-04 18:22:17 +00:00
Maxim Konovalov ad75cea775 Sync with HEAD: add NetBSD 2.0.3, OpenBSD 3.8, FreeBSD 6.0, NetBSD 2.1. 2005-11-04 18:12:20 +00:00
Maxim Konovalov 7a858e34ae MFC rev. 1.8: dcons(4) depends on "options GDB". 2005-11-04 18:03:00 +00:00
Maxim Konovalov 33767887a3 MFC rev. 1.40: typo. 2005-11-04 17:58:02 +00:00
John Polstra 7946b35910 MFC 1.24: Fix an erroneous description of the file descriptor
assignments for the "~C" command.
2005-11-04 17:33:21 +00:00
John Polstra 77d7538cec MFC 1.118: Don't include self-dependencies in the file's reference
count.
2005-11-04 17:18:29 +00:00
Gleb Smirnoff b6507584c3 MFC 1.61 (by ru), 1.62:
- Bail if interface is misspelled instead of falling out into the
  "all interfaces" mode.
- Print space character in show_stat(). Remove a lot of priuntf(" ").
- Utilize show_stat() in sidewaysintpr() loop. This makes periodic
  statistics to honor -h flag.
2005-11-03 12:49:10 +00:00
Gleb Smirnoff f93d163859 MFC:
- Understand EADDRINUSE, and forget EDQUOT. [1]
  - Add description for EEXIST.
  - Change description for ENOBUFS. Routing socket can return
    this error for many different reasons, including general
    memory shortage, mbuf memory shortage and rtentry zone.

  PR:		kern/64090 [1]
2005-11-03 12:44:33 +00:00
Gleb Smirnoff c5b6df4306 MFC:
Implement a new feature for ping(8) - sweeping pings. In a sweeping
  ping ICMP payload of packets being sent is increased with given step.
  Sweeping pings are useful for testing problematic channels, MTU
  issues or traffic policing functions in networks.

  PR:		bin/82625
  Submitted by:	Chris Hellberg <chellberg juniper.net> (with some cleanups)
2005-11-03 12:42:21 +00:00
Gleb Smirnoff 916786fa8b MFOpenBSD 1.37, 1.38, 1.41. This is already present in RELENG_6 and
HEAD due to OPENBSD_3_7 pf import

- Increment the states reference counter in the rule attached to the state
  being inserted, so that the counter does not wrap back when the state
  is removed. This fixes pfsync setups with adaptive timeouts.

- Clean up reference counting wrt state creation and destruction. Fixes
  problems with adaptive timeouts, max-states limits, and rules not being
  freed from memory.

- Set creation timestamps correctly on states learnt by pfsync that are
  more than a second old.

PR:		83187
PR:		83186
Submitted by:	Martin Matuska
2005-11-03 12:25:29 +00:00
Gleb Smirnoff a58e936bb3 Several fixes to ARP and route locking, that were done during 6.0 release
cycle, and are also applicable to RELENG_5:

  o Make rt_check() return a locked rtentry.
  o Make rt_check() function more strict:
    - rt0 passed to rt_check() must not be NULL, assert this.
    - rt returned by rt_check() must be valid locked rtentry,
      if no error occured.
  o Modify callers, so that they never pass NULL rt0
    to rt_check().
  o Modify callers, so that they unlock rtentry.

  o Fix races in ARP code. See if_ether.c 1.139 for more information.
  o Fix LORs in ARP code. See if_ether.c 1.141 for more information.

  o Lock rtentry before dropping radix lock.

  o Send published ARP replies only on correct interface. [1]

  o Drop rtentry lock before calling rt_getifa(). [2]

  o Fixes to rt_setgate():
    - To avoid recursive rtentry locking.
    - Do not change routes in case of failure.
    - Return EADDRINUSE instead of bogus EDQUOT [3]

Revisions merged:
  net/if_atmsubr.c	- 1.39, 1.41
  net/if_fwsubr.c	- 1.13, 1.15
  net/if_iso88025subr.c	- 1.69, 1.71
  net/route.c		- 1.110, 1.111, 1.113
  net/rtsock.c		- 1.110, 1.111, 1.126, 1.130
  netinet6/nd6.c	- 1.51-1.53
  netinet/if_ether.c	- 1.139, 1.140, 1.141

PR:		kern/75634 [1]
PR:		kern/69356 [2]
PR:		kern/64090 [3]
2005-11-03 12:02:10 +00:00
Gleb Smirnoff 285fd46d92 MFC:
Implement suspend/resume operation for snd_csa(4)

PR:		kern/82243
Submitted by:	Serge Semenenko
2005-11-03 11:49:12 +00:00
Gleb Smirnoff 4f2a718b24 MFC 1.103:
Avoid recursions in netgraph(4). For more details see original
  commit message.
2005-11-03 11:46:47 +00:00
Gleb Smirnoff f9bc3f516c MFC 1.63, 1.64, 1.65, 1.69:
- Fix build with TRACE_MESSAGES on.
  - Reformat code under TRACE_MESSAGES to make it more readable.
  - Move linker hackery out of #ifdef.
  - Break long lines in linker hackery block.
  - Unwind NG_SEND_MSG_PATH() macro and merge it with already unwinded
    version under TRACE_MESSAGES.
  - Pass NG_WAITOK flag to ng_package_data() in unwinded macro.
  - Remove local error variable, which leads to hiding error from return
    value. [1]
  - When message can't fit into socket receive buffer return ENOBUFS
    to userland program instead of letting it wait until end of days. [2]

PR: 	kern/81371 [1]
PR: 	kern/85907 [2]
2005-11-03 11:44:24 +00:00
Wilko Bulte 8d4e83c639 MFC:
Small changes in the AlphaStation 200 and PC14 area.  PC164 SRM does
not work with 53C896 SCSI chips.

Submitted by: Owen Mann <[email protected]>
2005-11-02 22:21:50 +00:00
Bill Paul a7ec9f941f MFC: pin ourselves to the current CPU when thunking, other minor cleanups 2005-11-02 18:04:29 +00:00
Bill Paul 9252897962 MFC: don't bzero() too many kq_queues in ntoskrnl_libinit(). 2005-11-01 09:25:19 +00:00
Bill Paul 6403f9ef0d MFC: fix channel and authmode reporting for ifconfig (note: authmode
reporting is a no-op in 5.x and always shows up as OPEN)
2005-10-29 02:20:44 +00:00
Brooks Davis 9bdd00f160 MFC rev 1.6:
Don't print anything if we can't do any localpkg shutdown (start already
does this).

Submitted by:	Andre Albsmeier <Andre dot Albsmeier at siemens dot com>
PR:		conf/86606
2005-10-28 22:57:42 +00:00
SUZUKI Shinsuke 635c5e51b5 MFC Rev 1.60
perform NUD on an IPv6-aware point-to-point interface

Approved by: re(scottl)
2005-10-28 14:38:56 +00:00
Ade Lovett f7bc780664 MFC:
Specifically panic() in the case where pmap_insert_entry() fails to
get a new pv under high system load where the available pv entries
have been exhausted before the pagedaemon has a chance to wake up
to reclaim some.
2005-10-28 06:50:36 +00:00
SUZUKI Shinsuke f8eac2a514 MFC rev 1.34
fixed a kernel crash when IPv6 PIM-SM routing is enabled and a PIM register message is received

Approved by: re(scottl)
2005-10-27 14:04:03 +00:00
Bill Paul 64ade8d9d2 MFC: only free child device array if device_get_children() returned a
non-NULL array pointer.
2005-10-26 20:23:29 +00:00
Bill Paul 0a005eab36 MFC: merge the fix for PR 83477.
PR: kern/83477
2005-10-26 18:48:57 +00:00
Bill Paul b0dafce0d9 MFC: implement MmMapIoSpace() and MmUnmapIoSpace(), remove old timer
tracking code to fix deadlock in NdisMInitializeTimer().
2005-10-26 06:56:22 +00:00
Bill Paul acb8581f89 MFC: correct some __FreeBSD_version conditionals, fix link state change
notifications for RELENG_5.
2005-10-25 16:16:01 +00:00
Bill Paul c008a65d5d MFC: don't allow ndis_ticktask() to run after the NIC has been halted 2005-10-24 17:48:47 +00:00
Bill Paul 6f8e15e1a0 MFC: fix handling of message table strings in NdisWriteErrorLogEntry() 2005-10-24 05:06:19 +00:00
Bill Paul 8983684c20 MFC: launch just one DPC thread, to avoid possible panic when calling
sched_bind() during bootstrap before APs are launched.
2005-10-22 05:16:53 +00:00
Bill Paul 7134daca1a MFC from head (fix KeRaiseIrql() API, wait for DPC/workitem thread
termination the right way).
2005-10-21 05:29:54 +00:00
Bill Paul 19b7b82bea MFC all the updates from the HEAD 2005-10-20 17:52:27 +00:00
Bill Paul 8aee8a5f9d MFC updates from the head:
- install ndisgen.8 man page
- fixes for ndisgen.8 man page
- fixes for ndisgen.sh script to make it work correctly on amd64 and
  various documentation cleanups
2005-10-20 17:10:21 +00:00
Kris Kennaway 6dd5bfb048 MFC r1.20:
Add a default value for VM_BCACHE_SIZE_MAX of 400MB.  This is copied from
amd64, and is a factor of 3 less than the value previously auto-sized on
a 12GB machine, which would cause an overflow in calculations involving the
maxbcache int, causing bufinit() to loop forever at boot.
2005-10-17 00:20:47 +00:00
Ken Smith 8fe1548d4b Document the accidental temporary change in the libarchive shared library
version number.
2005-10-15 13:37:04 +00:00
Tim Kientzle e7955a6860 Correct the SHLIB_MAJOR back to 1 for libarchive.
In a recent MFC, I accidentally picked up a SHLIB_MAJOR
version bump for FreeBSD 6.

Anyone that updated their 5-STABLE system
between October 4, 2005 and now should delete
/usr/lib/libarchive.so.2.

Apologies.
2005-10-14 16:06:35 +00:00
Kirill Ponomarev 1a8bb1637a MFC: delete/main.c:1.27 info/main.c:1.48
Fix pkg_info(1) and pkg_delete(1) to handle properly packages which
  names start with a digit.

  PR:             bin/76858
  Submitted by:   Matthew D. Fuller <fullermd@over-yonder dot net>
2005-10-13 08:30:52 +00:00
Kirill Ponomarev 6a03d5a86c MFC: perform.c:1.14 test-pkg_version.sh:1.6
date: 2005/10/10 12:35:30;  author: krion;  state: Exp;  lines: +9 -4
  * pkg_version(1) exits if INDEX files is not found and -I is not
    specified.  The result is that the package will be listed with a '?'
    as if it was not found within the INDEX file, so fix this behaviour.
  * Remove trailing spaces.

  PR:             bin/87136
  Submitted by:   Sean Farley <sean-freebsd at farley dot org>
2005-10-13 08:27:00 +00:00
Colin Percival 20e3c0382e Correct a man-in-the-middle SSL version rollback vulnerability.
Security:       FreeBSD-SA-05:21.openssl
2005-10-11 11:52:01 +00:00
Yaroslav Tykhiy eeb66687b1 MFC: make the -M option to mdmfs configurable and document this.
PR:		bin/87218
2005-10-11 09:20:26 +00:00
Hajimu UMEMOTO 779a279b68 MFC: be consistent on naming advanced API functions; use ip6_XXXpktopt(s).
sys/netinet6/ip6_output.c:	1.93
	sys/netinet6/ip6_var.h:		1.31
	sys/netinet6/mld6.c:		1.20
	sys/netinet6/raw_ip6.c:		1.51
	sys/netinet6/udp6_output.c:	1.20
2005-10-10 12:04:55 +00:00
Hajimu UMEMOTO 26b6940d1c MFC 1.92: NULL is not zero. 2005-10-10 12:02:55 +00:00
Hajimu UMEMOTO 941e6deb19 MFC 1.49: do not hardcode if_mtu values in here, except for IFT_{ARC,FDDI} -
they need special handling.  makes it possible to take advantage of 9k ether
frames.
2005-10-10 12:00:06 +00:00
Hajimu UMEMOTO e4470312cf MFC: move RFC3542 related definitions into ip6.h.
sys/contrib/pf/net/pf_norm.c:	1.12
	sys/netinet/ip6.h:		1.15
2005-10-10 11:55:58 +00:00
Hajimu UMEMOTO 3f93c3131a MFC 1.18: add missing RFC3542 definition. 2005-10-10 11:52:11 +00:00
Hajimu UMEMOTO fd83c911d1 MFC: update comments:
- RFC2292bis -> RFC3542
    - typo fixes

	sys/netinet/icmp6.h		1.17
	sys/netinet/ip6.h:		1.14
	sys/netinet6/in6.h:		1.37
	sys/netinet6/ip6_input.c:	1.82
	sys/netinet6/ip6_mroute.h:	1.7
	sys/netinet6/ip6_output.c:	1.91
2005-10-10 10:42:09 +00:00
Hajimu UMEMOTO 4e570829e6 MFC 1.7: fixed the validation code of routing header length in
inet6_rth_getaddr().
2005-10-10 10:36:45 +00:00
Hajimu UMEMOTO 07e6c8dd9c MFC: refer RFC 3542 rather than RFC 2292bis.
lib/libc/net/ip6opt.c:	1.8
	lib/libc/net/rcmd.3:	1.25
	lib/libc/net/rthdr.c:	1.8
2005-10-10 10:33:28 +00:00
Hajimu UMEMOTO c24843764c MFC 1.16: fix typo. 2005-10-10 10:25:50 +00:00
Hajimu UMEMOTO a153971bd0 MFC 1.16: stop RFC 4193 address on the outside interface. 2005-10-10 09:52:01 +00:00
Kirill Ponomarev d843e8b01c MFC: main.c:1.6, perform.c:1.13, pkg_version.1:1.36, version.h:1.5
Add -o/-O options to pkg_version:

     -o  Show the origin recorded on package generation instead of the
         package name.

     -O  Only list packages whose registered origin is origin.

  Based on PR:    bin/78640
  Submitted by:   Marcus Grando <marcus at corp dot grupos.com.br>, flz
2005-10-09 21:59:32 +00:00
Maxim Konovalov 9f7dad5916 MFC rev. 1.234: teach sysctl_drop() how to deal with the sockets
in TIME_WAIT state.

Approved by:	re (scottl)
2005-10-09 08:21:34 +00:00
Giorgos Keramidas 51eb5756a8 MFC 1.36:
Remove the OPTIONS section, since it only documents FE_DEBUG and wrongly
so.  If the full list of fe(4) options is documented we can revive the
entire section.
2005-10-09 01:03:57 +00:00
Don Lewis c711742b70 MFC kern_exec.c 1.276 (and 1.278)
Original commit messages:

  truckman    2005-10-01 08:33:57 UTC

    FreeBSD src repository

    Modified files:
      sys/kern             kern_exec.c
    Log:
    Copy new process argument list in do_execve() before grabbing PROC_LOCK
    to avoid touching pageable memory while holding a mutex.

    Simplify argument list replacement logic.

    PR:            kern/84935
    Submitted by:  "Antoine Pelisse" apelisse AT gmail.com (in a different form)
    MFC after:     3 days

    Revision  Changes    Path
    1.276     +10 -10    src/sys/kern/kern_exec.c

  truckman    2005-10-04 04:02:33 UTC

    FreeBSD src repository

    Modified files:
      sys/kern             kern_exec.c
    Log:
    Add missing word to comment.

    Revision  Changes    Path
    1.278     +1 -1      src/sys/kern/kern_exec.c

PR:		kern/84935
Submitted by:	"Antoine Pelisse" apelisse AT gmail.com (in a different form)
2005-10-08 20:35:26 +00:00
Don Lewis 803698221e MFC ffs_alloc.c 1.135 - clear i_flag field in recycled inodes
The IN_HASHED bit should not be cleared here in RELENG_5.

Original commit message:
  truckman    2005-10-03 21:57:43 UTC

    FreeBSD src repository

    Modified files:
      sys/ufs/ffs          ffs_alloc.c
    Log:
    Initialize the inode i_flag field in ffs_valloc() to clean up any
    stale flag bits left over from before the inode was recycled.

    Without this change, a leftover IN_SPACECOUNTED flag could prevent
    softdep_freefile() and softdep_releasefile() from incrementing
    fs_pendinginodes.  Because handle_workitem_freefile() unconditionally
    decrements fs_pendinginodes, a negative value could be reported at
    file system unmount time with a message like:
            unmount pending error: blocks 0 files -3
    The pending block count in fs_pendingblocks could also be negative
    for similar reasons.  These errors can cause the data returned by
    statfs() to be slightly incorrect.  Some other cleanup code in
    softdep_releasefile() could also be incorrectly bypassed.

    MFC after:      3 days

    Revision  Changes    Path
    1.135     +1 -0      src/sys/ufs/ffs/ffs_alloc.c
2005-10-08 20:04:28 +00:00
Maxim Konovalov 8f383d5747 MFC rev. 1.77: restore kerneldumpheader.architectureversion bytes
swopping.

Approved by:	re (kensmith)
2005-10-08 17:57:15 +00:00
Doug Barton 99936a7cee MFC through rm.c 1.53, rm.1 1.38, and Makefile 1.18.
This includes the recent change to improve handling of the -P flag
on read-only files, addition of the -I option for better handling
of recursive deletes, a test for removal of / in the argument list,
and related mdoc and comment changes and improvements.

The Makefile change removes a spurious SRCS=
2005-10-08 17:40:01 +00:00
Don Lewis bf2ac7e6f8 MFC ffs_softdep.c 1.185 - Schedule update of parent directory's link count
after rmdir()

Original commit message:
  truckman    2005-09-29 21:50:26 UTC

    FreeBSD src repository

    Modified files:
      sys/ufs/ffs          ffs_softdep.c
    Log:
    After a rmdir()ed directory has been truncated, force an update of
    the directory's inode after queuing the dirrem that will decrement
    the parent directory's link count.  This will force the update of
    the parent directory's actual link to actually be scheduled.  Without
    this change the parent directory's actual link count would not be
    updated until ufs_inactive() cleared the inode of the newly removed
    directory, which might be deferred indefinitely.  ufs_inactive()
    will not be called as long as any process holds a reference to the
    removed directory, and ufs_inactive() will not clear the inode if
    the link count is non-zero, which could be the result of an earlier
    system crash.

    If a background fsck is run before the update of the parent directory's
    actual link count has been performed, or at least scheduled by
    putting the dirrem on the leaf directory's inodedep id_bufwait list,
    fsck will corrupt the file system by decrementing the parent
    directory's effective link count, which was previously correct
    because it already took the removal of the leaf directory into
    account, and setting the actual link count to the same value as the
    effective link count after the dangling, removed, leaf directory
    has been removed.  This happens because fsck acts based on the
    actual link count, which will be too high when fsck creates the
    file system snapshot that it references.

    This change has the fortunate side effect of more quickly cleaning
    up the large number dirrem structures that linger for an extended
    time after the removal of a large directory tree.  It also fixes a
    potential problem with the shutdown of the syncer thread timing out
    if the system is rebooted immediately after removing a large directory
    tree.

    Submitted by:   tegge
    MFC after:      3 days

    Revision  Changes    Path
    1.185     +2 -0      src/sys/ufs/ffs/ffs_softdep.c

Submitted by:	tegge
2005-10-08 05:57:40 +00:00
Ralf S. Engelschall 4f7e246433 MFC to RELENG_5:
| Fix system shutdown timeout handling by again supporting longer running
| shutdown procedures (which have a duration of more than 120 seconds).
|
| We have two user-space affecting shutdown timeouts: a "soft" one in
| /etc/rc.shutdown and a "hard" one in init(8). The first one can be
| configured via /etc/rc.conf variable "rcshutdown_timeout" and defaults
| to 30 seconds. The second one was originally (in 1998) intended to be
| configured via sysctl(8) variable "kern.shutdown_timeout" and defaults
| to 120 seconds.
|
| Unfortunately, the "kern.shutdown_timeout" was declared "unused" in 1999
| (as it obviously is actually not used within the kernel itself) and
| hence was intentionally but misleadingly removed in revision 1.107 from
| init_main.c. Kernel sysctl(8) variables are certainly a wrong way to
| control user-space processes in general, but in this particular case the
| sysctl(8) variable should have remained as it supports init(8), which
| isn't passed command line flags (which in turn could have been set via
| /etc/rc.conf), etc.
|
| As there is already a similar "kern.init_path" sysctl(8) variable which
| directly affects init(8), resurrect the init(8) shutdown timeout under
| sysctl(8) variable "kern.init_shutdown_timeout". But this time document
| it as being intentionally unused within the kernel and used by init(8).
| Also document it in the manpages init(8) and rc.conf(5).
|
| Reviewed by: phk
| MFC after: 2 weeks
|
| Revision  Changes    Path
| 1.48      +7 -1      src/sbin/init/init.8
| 1.61      +1 -1      src/sbin/init/init.c
| 1.264     +16 -1     src/share/man/man5/rc.conf.5
| 1.257     +11 -0     src/sys/kern/init_main.c
2005-10-04 18:00:43 +00:00
Diomidis Spinellis 7c22a8e338 MFC 1.28
Bug fix: a numeric flag specification in the substitute command would
cause the next substitute flag to be ignored.
While working at it, detect and report overflows.

Reported by:	Jingsong Liu
Bugged by:	Xin Li
2005-10-04 15:06:42 +00:00
Ollivier Robert c22fe78be9 MFC of revision 1.16 for chkgrp.8: Markup fixes. 2005-10-04 10:43:21 +00:00
Ollivier Robert 2c4878e2e2 MFC revision 1.10 of chkgrp.c:
The check for invalid characters introduced in 1.9 incorrectly
flags NIS entries as invalid.

Approved by:	re (scottl)
2005-10-04 10:37:53 +00:00
Tim Kientzle a53d6504f2 MFC: Update libarchive to 1.02.033. (Synchronize with -CURRENT.)
Among other fixes:
  * C++ support
  * Portability:  remove C99 requirements
  * Portability:  don't require wchar.h
  * Check for memory allocation failures
  * Portability:  better detection of ACL support
  * Signed/unsigned fixes
  * Fix crash when archive_read_next_header called after an
    open failure
  * Fix archive_read_data
  * Reduce window for attribute restore security race
  * Clean up pathnames before creating leading dirs
  * assign default inode/dev values to extracted tar entries
    to better support tar->cpio conversions
  * Trim mode and time values for inner ustar header when constructing
    pax entries
  * Sample code in archive_read.3 and archive_write.3 works now
  * Many comment and documentation corrections
2005-10-04 05:39:40 +00:00
Andrew Thompson 4cba41cc9b Add a note to UPDATING and bump __FreeBSD_version for if_bridge MFC.
Approved by:	mlaier (mentor)
2005-10-03 22:04:08 +00:00
Andrew Thompson aa5284565d MFC if_bridge support
Connect if_bridge to the build.

Approved by:	mlaier (mentor)
2005-10-03 21:55:15 +00:00
Andrew Thompson defcc86f76 MFC if_bridge support code
Add network hooks and support code for if_bridge, including ipv6 and dummynet
support. Use the if_spare1 pointer from struct ifnet to keep ABI.

Approved by:	mlaier (mentor)
2005-10-03 21:51:32 +00:00
Colin Percival c469c3c1d1 MFC revision 1.11: Fix a bug introduced in revision 1.9 which causes
chkgrp to coredump on certain corrupt files.
2005-10-03 21:41:45 +00:00
Andrew Thompson 3d9f634cd4 MFC if_bridge code; bridgestp.c r1.6, if_bridge.c r1.23, if_bridgevar.h r1.4
Add if_bridge, which provides more advanced Ethernet bridging and 802.1d
 spanning tree support.

 Based on Jason Wright's bridge driver from OpenBSD, and modified by Jason R.
 Thorpe in NetBSD.

Conversion to old-ifconfig taken from green@

Approved by:	mlaier (mentor)
2005-10-03 21:40:42 +00:00
Andrew Thompson 6f2b28a204 MFC m_copyup function, uipc_mbuf.c r1.147
This can be used to help make our ip stack less alignment restrictive, and help
performance on some ethernet cards which currently copy the entire packet a
couple bytes to get the packet aligned properly...

Required for if_bridge support.

Approved by:	mlaier (mentor)
OKed by:	jmg
2005-10-03 21:27:39 +00:00
Joel Dahl 4bf9c65415 MFC rev 1.63:
Fix spelling errors.
2005-10-03 07:02:14 +00:00
cvs2svn 0f9358e032 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-10-02 19:15:57 +00:00
Ruslan Ermilov 1e3dbbb483 MFC: 1.46: -q also affects "route change". 2005-10-02 12:58:24 +00:00
Max Khon 194989e369 MFC g_uzip.c rev. 1.5:
- Fix "end_blk out of range" panic when INVARIANTS.

EROFS check was not MFC'ed because UFS mount tries to access the device
in rw mode even if ro mount is requested.
2005-10-02 11:23:40 +00:00
Robert Watson 83d47f2cf7 Merge subr_pcpu.c:1.7 from HEAD to RELENG_5:
Add "show allpcpu" to DDB, which prints the current CPU id followed by
  the per-cpu data for all CPUs.  This is easier to ask users to do than
  "figure out how many CPUs you have, now run show pcpu, then run it
  once for each CPU you have".
2005-10-02 10:21:33 +00:00
Robert Watson ee1e7001f0 Merge subr_kdb.c:1.13 from HEAD to RELENG_5:
If KDB_STOP_NMI is compiled into the kernel, default
  debug.kdb.stop_cpus_with_nmi to 1 rather than 0.
2005-10-02 10:20:04 +00:00
Robert Watson ce6290283b Merge kern_lock.c:1.94, 1.95 from HEAD to RELENG_5:
In lockstatus(), don't lock and unlock the interlock when testing the
  sleep lock status while kdb_active, or we risk contending with the
  mutex on another CPU, resulting in a panic when using "show
  lockedvnods" while in DDB.

  Reviewed by:    jhb
  Reported by:    kris
2005-10-02 10:11:31 +00:00
Ruslan Ermilov c2938d16e9 Re-add FreeBSD 5.4 which got mistakenly nuked in rev. 1.41.2.5, add 7.0. 2005-10-01 18:17:29 +00:00
Hajimu UMEMOTO 5972ca74e5 MFC: add product ID for Linux Ethernet/RNDIS gadget on pxa210/25x/26x.
sys/dev/usb/if_cdce.c:  1.11
	sys/dev/usb/usbdevs:    1.234
2005-10-01 16:32:27 +00:00
Ken Smith de11444480 MFC revision 1.890:
> date: 2005/09/28 12:39:00;  author: kensmith;  state: Exp;  lines: +17 -6
> Add SHA256 checksums to the release build.
>
> Requested by:           cperciva (so)
> Reviewed/improved by:   ru
2005-09-30 11:48:44 +00:00
Robert Watson 169665e013 Merge subr_prof.c:1.119, 1.120, 1.121 from HEAD to RELENG_6:
Acquire Giant in uprintf() and tprintf() due to the non-MPSAFEty of
  the tty code invoked from these functions.

  Correct age-old comments about uprintf()/tprintf() sleeping: they
  will never sleep.

Unlike in the merge to RELENG_6, it is not necesary to acquire Giant
in the NFS code, as the NFS client runs entirely under Giant in 5.x.
Likewise, this is not a critical fix in 5.x as the vast majority of
relevant calls to uprintf() are in the VFS code, which also runs
with Giant in 5.x.  However, there are some exposed code paths that
make this MFC a good idea.

Much useful feedback from:	bde
Approved by:			re (scottl)
2005-09-29 18:45:02 +00:00
Christian Brueffer 9546c7541f MFC: rev. 1.6
Fix typo.
2005-09-28 16:52:09 +00:00
Ruslan Ermilov 8f9fe3662e MFC: 1.57: Respect IFF_PROMISC. 2005-09-28 16:50:25 +00:00
Jesus R. Camou 917a67f8ef Fix reference paths.
Noticed by:	Ilya Kiselyov <[email protected]>
Approved by:	trhodes (mentor)
2005-09-28 08:04:16 +00:00
Robert Watson 6bef5a1c4a Merge fifo_vnops.c:1.129 from HEAD to RELENG_5:
Lock the read socket receive buffer when frobbing the sb_state flag on
  that socket during open, not the write socket receive buffer.

  Spotted by:     ups
2005-09-28 06:56:14 +00:00
Robert Watson 9ec8b4633b Merge uipc_usrreq.c:1.156 from HEAD to RELENG_5:
Canonicalize the UNIX domain socket copyright layout: original holders
  before more recent holders.
2005-09-28 06:52:35 +00:00
Robert Watson d654d40ebc Merge fifo_vnops.c:1.128 from HEAD to RELENG_5:
For reasons of consistency (and necessity), assert an exclusive vnode
  lock on the fifo vnode in fifo_open(): we rely on the vnode lock to
  serialize access to v_fifoinfo.
2005-09-28 06:48:09 +00:00
Robert Watson 63c0dfd8e8 Merge uipc_socket.c:1.249, socket.h:1.89 from HEAD to RELENG_5:
Add three new read-only socket options, which allow regression tests
  and other applications to query the state of the stack regarding the
  accept queue on a listen socket:

  SO_LISTENQLIMIT    Return the value of so_qlimit (socket backlog)
  SO_LISTENQLEN      Return the value of so_qlen (complete sockets)
  SO_LISTENINCQLEN   Return the value of so_incqlen (incomplete sockets)

  Minor white space tweaks to existing socket options to make them
  consistent.

  Discussed with: andre
2005-09-27 21:54:03 +00:00
Xin LI fa08d4a72a MFC 1.64: Restore a historical ufs_inactive behavior that respect
the RDONLY option, so subsequent call of UFS_TRUNCATE (ffs_truncate)
would not panic the system.  This fixes a panic that can happen
when mounting a corrputed filesystem read-only, and reading data
from it.

Reviewed by:	mckusick
2005-09-27 17:05:46 +00:00
Kirill Ponomarev 308abad7e0 MFC: 1.20
date: 2005/09/24 21:41:47;  author: krion;  state: Exp;  lines: +1 -1
  Do not bitch about bsdpan modules not having origin.

  Based on PR:    bin/82269
  Submitted by:   Steven Hartland <killing at multiplay dot co dot uk>
  MFC after:      3 days
2005-09-27 07:56:03 +00:00
Kirill Ponomarev a444d3926a MFC: 1.39
date: 2005/09/24 19:41:56;  author: krion;  state: Exp;  lines: +1 -1
  Remove '\n' since it's redundant in case if file doesn't exist while
  running 'pkg_info -g'

  Based on PR:    bin/42609
  Submitted by:   Jeff King <peff-freebsd at peff dot net>
  MFC after:      3 days
2005-09-27 07:49:05 +00:00
John Baldwin 8f49385a0d MFC: Explicitly switch to the new TSS when adding one in i386_extend_pcb(). 2005-09-26 19:40:14 +00:00
Robert Watson db5049ed92 Merge missing patch hunk from netisr.c:1.12 from HEAD to RELENG_5:
Include opt_net.h from netisr.c, or compiling in NET_WITH_GIANT
  will not change the default setting for debug.mpsafenet.

Submitted by:	Ed Maste <emaste at phaedrus dot sandvine dot ca>
2005-09-26 18:48:01 +00:00
John Baldwin 12fa1eb277 MFC: Zero donecount on auto request sense.
PR:		kern/81450
Submitted by:	Sean McNeil sean at mcneil dot com
2005-09-26 13:58:56 +00:00
Andre Oppermann 309fea47ca MFC 1.77: Do not ignore all other TCP options when TCP_MD5. 2005-09-26 13:18:19 +00:00
Andre Oppermann af7b039352 MFC 1.160: Undo optimization which broke BIOCGSEESENT handling. 2005-09-26 13:12:01 +00:00
Robert Watson 841f948aac Merge kern_acct.c:1.75 from HEAD to RELENG_5:
Pass 'curthread' into VFS_STATFS() from acctwatch(), rather than passing
  NULL.  The NFS client expects that a thread will always be present for a
  VOP so that it can check for signal conditions, and will dereference a
  NULL pointer if one isn't present.
2005-09-25 19:14:02 +00:00
Robert Watson 1c5fceb949 Merge rc.conf:1.260, kerberos:1.5, rc.conf.5:1.265 from HEAD to RELENG_5:
Add a new rc.conf entry, kerberos5_server_flags, which allows the
  administrator to specify additional start-up flags to the Kerberos
  5 Authentication Server.
2005-09-25 19:06:24 +00:00
Xin LI e6f740ea4f MFC 1.31-1.34: Several style fixes by ru@ and document alternative superblock
location for UFS2.
2005-09-25 12:11:38 +00:00
Christian Brueffer b344f0ed64 MFC: rev. 1.286
Don't claim matcd(4) support, it was removed long ago.
2005-09-24 07:48:04 +00:00
Christian Brueffer db6087d3ac MFC: rev. 1.5
Change the DESCRIPTION section into HARDWARE, since it already lists
the supported hardware.
2005-09-24 07:35:13 +00:00
Christian Brueffer c26ce4cffc MFC:
Sort list of supported hardware.
2005-09-24 07:24:41 +00:00
Christian Brueffer 57aaa73d18 MFC: rev. 1.2
Use the correct function name as .Nm argument.
2005-09-24 07:14:34 +00:00
Robert Watson 1c5f84b344 Merge rc.initdiskless:1.45 from HEAD to RELENG_5:
Use sysctl -q when querying for kern.bootp_cookie in order to avoid
  printing boot-time errors that don't reflect true error conditions.
2005-09-22 17:55:29 +00:00
Robert Watson 5f2bf7eaa4 Merge sysctl.8:1.59, sysctl.c:1.68 from HEAD to RELENG_5:
Add "-q" argument to sysctl(8), which suppresses a limited set of
  warnings/ errors generated.  In particular, it suppresses "unknown oid"
  when attempting to get or set a sysctl not present in the kernel.
2005-09-22 17:53:57 +00:00
Robert Watson 62e7dc8339 Merge uipc_socket.c:1.248 from HEAD to RELENG_5:
Fix spelling in a comment.
2005-09-21 15:36:04 +00:00
Robert Watson e9ab5752e0 Merge fifo_vnops.c:1.126 from HEAD to RELENG_5:
Assert that (vp) is locked in fifo_close(), since we rely on the
  exclusive vnode lock to synchronize the reference counts on struct
  fifoinfo.
2005-09-21 15:35:08 +00:00
Robert Watson 831bff8549 Merge uipc_socket2.c:1.148 from HEAD to RELENG_5:
Re-comment sbcompress() to explain what it is it does; it took me
  quite a bit of reading to figure it out, and I want to avoid figuring
  it out again.

  Convert an if (foo) else printf("this is almost a panic") into a
  KASSERT.
2005-09-21 15:33:26 +00:00
Pyun YongHyeon 2802ab172e MFC rev. 1.29 to RELENG_5:
fix LOR by dropping driver lock before calling resource_int_value(9).
2005-09-21 03:20:36 +00:00
Pyun YongHyeon 5aed97173a MFC rev. 1.21 to RELENG_5: fix module unloading panic 2005-09-21 02:47:12 +00:00
Tor Egge a0cc1f0ec0 MFC: Retain generation count when writing zeroes instead of an inode to disk.
Don't free a struct inodedep if another process is allocating saved
     inode memory for the same struct inodedep in
     initiate_write_inodeblock_ufs[12]().

     Handle disappearing dependencies in softdep_disk_io_initiation().
2005-09-20 22:36:32 +00:00
Tim Kientzle 8c8630dd7b MFC bsdtar.c 1.64: Correct warning message on locale error
(program name was set up incorrectly)
2005-09-20 17:58:59 +00:00
Robert Watson f308376070 Merge fifo_vnops.c:1.125 from HEAD to RELENG_5:
The socket pointers in fifoinfo are not permitted to be NULL, so
  don't check if they are, it just confuses the fifo code more.
2005-09-20 13:58:59 +00:00
Gleb Smirnoff e420757d51 MFC typo fix from 1.75:
Dej'a vu of revision 1.35

  PR:		kern/86258
  Submitted by:	Hiroshi Oota <ghelp excite.co.jp>
2005-09-20 13:47:59 +00:00
Robert Watson 825a392cee Merge fifo_vnops.c:1.123 from HEAD to RELENG_5:
As a result of kqueue locking work, socket buffer locks will always
  be held when entering a kqueue filter for fifos via a socket buffer
  event: as such, assert the lock unconditionally rather than acquiring
  it conditionally.
2005-09-20 13:33:07 +00:00
Robert Watson 0731611ed3 Merge dumpon:1.10 from HEAD to RELENG_5:
Use kenv -q to extract dumpdev rather than kenv, in order to avoid
  spamming the console in the event that a loader tunable 'dumpdev'
  isn't defined, which is not a relevant failure to report.
2005-09-20 13:28:35 +00:00
Robert Watson d495e5b7a9 Merge kenv.1:1.12, kenv.c:1.8 from HEAD to RELENG_5:
Add a "-q" quiet flag to kenv so that warnings can be suppressed.
2005-09-20 13:27:05 +00:00
Max Laier ddafabb235 Properly initialize src-nodes limits.
Reported by:	Andre <andre (a) netvision ! com ! br>
2005-09-19 15:53:22 +00:00
Joe Marcus Clarke 29824b0b9e MFC:
Correct a mis-merge from HEAD, and make sure the socket permissions are set
to 0666.

Reported by:	rwatson via delphij
2005-09-19 14:22:57 +00:00
Gary W. Swearingen 40f16546a1 MFC 1.21
Approved by:	keramida (mentor)
2005-09-17 17:19:42 +00:00
Gary W. Swearingen 04c55947be MFC 1.25
Approved by:	keramida (mentor)
2005-09-17 15:50:50 +00:00
Brian Somers e3505db4e6 MFC: Add a -h option to tell cmp not to follow symbolic links.
Sponsored by:	Sophos/ActiveState
2005-09-17 11:35:24 +00:00
Robert Watson 81777415e9 Merge if.c:1.246 from HEAD to RELENG_5:
In netkqfilter(), return EINVAL instead of 1 (EPERM) when a filter type
  is requested on a network interface file descriptor that is
  non-applicable.
2005-09-16 09:12:36 +00:00
Robert Watson c33ccff783 Merge vfs_subr.c:1.646 (in spirit) from HEAD to RELENG_5:
In vfs_kqfilter(), return EINVAL instead of 1 (EPERM) when an
    unsupported kqueue filter type is requested on a vnode.
2005-09-16 09:11:50 +00:00
Robert Watson 8cd3d94553 Merge fifo_vnops.c:1.120 (in spirit) from HEAD to RELENG_5:
When a request is made to register a filter on a fifo that doesn't
  apply to the fifo (i.e., not EVFILT_READ or EVFILT_WRITE), reject
  it as EINVAL, not by returning 1 (EPERM).
2005-09-16 09:06:16 +00:00
Robert Watson 39d38625d0 Merge fifo_vnops.c:1.116 from HEAD to RELENG_5:
When a writer opens a fifo, wake up the read socket for read, not the
  write socket.
2005-09-16 09:02:25 +00:00
Robert Watson aa67dd1a19 Merge fifo_vnops.c:1.115 from HEAD to RELENG_5:
Add an assertion that fifo_open() doesn't race against other threads
  while sleeping to allocate fifo state: due to using the vnode lock to
  serialize access to a fifo during open, it shouldn't happen (tm).
2005-09-16 09:01:50 +00:00
Robert Watson 9d41d6515c Merge fifo_vnops.c:1.114 from HEAD to RELENG_5:
Rather than reaching into the internals of the UNIX domain socket code
  by calling uipc_connect2() to connect two socket endpoints to create a
  fifo, call soconnect2().
2005-09-16 09:00:58 +00:00
cvs2svn b81803f112 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-09-15 13:29:11 +00:00
Jesus R. Camou 0d62dd639f MFC: rev. 1.22.
Approved by:	trhodes (mentor)
2005-09-15 02:29:37 +00:00
Xin LI 569c05feff MFC 1.118:
When padding with zero, do pad after prefixes rather than padding
before prefixes.

Use cases:
	printf("%05d", -42);   -->   "00-42"   (should be "-0042")
	printf("%#05x", 12);   -->   "000xc"   (should be "0x00c")

Submitted by:	Oliver Fromme
PR:		kern/85520
Approved by:	re (kensmith)
2005-09-14 02:45:50 +00:00
Andre Oppermann 23c6e7466f MFC rev. 1.233: Fix ICMP_UNREACH_NEEDFRAG case where no MTU was proposed
in the ICMP reply.

PR:             kern/81813
Submitted by:   Vitezslav Novy <vita at fio.cz>
2005-09-13 14:44:08 +00:00
Maxim Konovalov d0cc4304b3 MFC rev. 1.10: postpone a temporary file creation until we realize
if ipfw(4) ever used.

Approved by:	re (scottl)
2005-09-13 14:34:11 +00:00
Gleb Smirnoff f6627cfe95 MFC 1.7:
Plug item leak in case when not all hooks are connected.

  Found by:	David Vos <david.vos gmail.com>
2005-09-13 12:44:55 +00:00
Gleb Smirnoff b15e505e2c MFC 1.26 by ru:
Fixed parsing of unsigned integers.
2005-09-13 12:41:52 +00:00
David Schultz 6c2f100428 MFC rev 1.64. Rev 1.51.2.3 claimed to be an MFC of 1.53, 1.55, 1.56,
1.59, 1.60, 1.62, and 1.64, but I left out 1.64.

Reported by:    asmodai@
2005-09-12 21:01:28 +00:00
Maksim Yevmenkin 83823f5a62 MFC to RELENG_5
Fix typo in usage

Submitted by:	Jonatan B <onatan at gmail dot com>
Approved by:	re (scottl)
2005-09-12 16:11:25 +00:00
Max Laier b8bb1ef4ab Commit imported changes to RELENG_5:
pf_ioctl.c Revision 1.153 Sun Aug 7 11:37:33 2005 UTC by dhartmei
 | verify ticket in DIOCADDADDR, from Boris Polevoy, ok deraadt@

 pf_ioctl.c Revision 1.158 Mon Sep 5 14:51:08 2005 UTC by dhartmei
 | in DIOCCHANGERULE, properly initialize table, if used in NAT rule.
 | from Boris Polevoy <vapcom at mail dot ru>, ok mcbride@
2005-09-12 14:46:55 +00:00
Gleb Smirnoff fd7f90e3bb MFC 1.31:
When a carp(4) interface is being destroyed and is in a promiscous mode,
  first interface is detached from parent and then bpfdetach() is called.
  If the interface was the last carp(4) interface attached to parent, then
  the mutex on parent is destroyed. When bpfdetach() calls if_setflags()
  we panic on destroyed mutex.

  To prevent the above scenario, clear pointer to parent, when we detach
  ourselves from parent.
2005-09-12 13:38:35 +00:00
Don Lewis f4dc43c768 MFC src/sys/gnu/fs/ext2fs/fs.h 1.18
src/sys/kern/kern_shutdown.c	1.175
	src/sys/sys/buf.h		1.189

  FreeBSD src repository

  Modified files:
    sys/gnu/fs/ext2fs    fs.h
    sys/kern             kern_shutdown.c
    sys/sys              buf.h
  Log:
  Add a new struct buf flag bit, B_PERSISTENT, and use it to tag
  struct bufs that are persistently held by ext2fs.  Ignore any buffers
  with this flag in the code in boot() that counts "busy" and dirty
  buffers and attempts to sync the dirty buffers, which is done before
  attempting to unmount all the file systems during shutdown.

  This fixes the problem caused by any ext2fs file systems that are
  mounted at system shutdown time, which caused boot() to give up on
  a non-zero number of buffers and skip the call to vfs_unmountall().
  This left all the mounted file systems in a dirty state and caused
  them to all require cleanup by fsck on reboot.

  Move the two separate copies of the "busy" buffer test in boot()
  to a separate function.

  Nuke the useless spl() stuff in the ext2fs ULCK_BUF() macro.

  Bring the PRINT_BUF_FLAGS definition in sys/buf.h up to date with
  this and previous flag changes.

  PR:             kern/56675, kern/85163
  Tested by:      "Matthias Andree" matthias.andree at gmx.de
  Reviewed by:    bde
  MFC after:      3 days

  Revision  Changes    Path
  1.18      +8 -8      src/sys/gnu/fs/ext2fs/fs.h
  1.175     +13 -11    src/sys/kern/kern_shutdown.c
  1.189     +4 -4      src/sys/sys/buf.h

PR:		kern/56675, kern/85163
Tested by:	"Matthias Andree" matthias.andree at gmx.de
Reviewed by:	bde
2005-09-12 04:25:53 +00:00
David E. O'Brien e5b50ac268 MFC rev 1.13: fix bug where static forward declarations weren't accepted. 2005-09-11 17:43:04 +00:00
Doug Barton 097adec131 MFC 1.22 which removes the IP6.INT example per RFC 4159 2005-09-10 08:28:34 +00:00
Wilko Bulte b575df8d90 MFC: Roosevelt quote 2005-09-09 18:27:11 +00:00
Gleb Smirnoff 38e88d72ff MFC 1.57 (see original revision for full description):
- in ng_ksocket_incoming2() clear m_nextpkt on all mbufs
    read from socket.
  - restore rev. 1.54 change in ng_ksocket_incoming().

  PR:		kern/84952
  PR:		kern/82413
  In collaboration with:	rwatson
2005-09-09 06:18:00 +00:00
Gleb Smirnoff 8560648d6c MFC 1.109:
Raise one more bit in READER_MASK. I believe that before this change
  it was possible to have 1 reader and 1 writer thread working on
  a node simultaneously.

  Reviewed by:	julian
2005-09-09 06:11:05 +00:00
Gleb Smirnoff b8d84ef4cc MFC 1.108, 1.110-1.111:
Use non-debug macros inside debugging functions, to prevent
  important information from being rewritten.

  In INVARIANTS case also check that nodes do not pass queues of mbufs
  each other.
2005-09-09 06:09:45 +00:00
R. Imura 7c7e0f40c5 MFC 1.12: Fix panic on sparc64 caused by touching uninitialized address. 2005-09-08 15:49:18 +00:00
R. Imura 5ce3cd4e45 MFC: check capable size of given strings correctly.
1.4 src/contrib/smbfs/lib/smb/kiconv.c
  1.2 src/lib/libkiconv/xlat16_sysctl.c
  1.11 src/sys/libkern/iconv.c
2005-09-08 15:47:04 +00:00
Craig Rodrigues d8cf52c147 MFC:
scmouse.c, 1.39:  In set_mouse_pos(), try to avoid division by zero errors.

  scvidctl.c, 1.36:
        In sc_set_text_mode(), reset fontwidth if it is <= 0.
        Eliminates division by zero errors in syscons driver.
2005-09-07 23:54:22 +00:00
Gary W. Swearingen 2e10e50a75 Added ENVIRONMENT section (PAGER, MANPATH, etc.).
PR:             docs/84485
Approved by:    keramida
2005-09-07 17:41:53 +00:00
Gary W. Swearingen 6c987883cc MFC: Improved descriptions of block size handling.
PR:             docs/84765
Approved by:    keramida
2005-09-07 17:24:53 +00:00
Gary W. Swearingen a486aff385 MFC: Added a sentence to explain what "span" means.
PR:             docs/84850
Approved by:    re
2005-09-07 16:53:21 +00:00
Robert Watson 87dd9adb31 Merge ufs_vnops.c:1.269 from HEAD to RELENG_5:
Allow removal of empty directories with high link counts. These can
  occur on a filesystem running with soft updates after a crash and
  before a background fsck has been run. To prevent discrepancies
  from arising in a background fsck that may already be running,
  the directory is removed but its inode is not freed and is left
  with the residual reference count. When encountered by the
  background fsck it will be reclaimed.

This change was present at the time of the RELENG_6 branch point, so
does not need to be merged to RELENG_6.

Approved by:	mckusick
Bumped into by:	Mikhail Teterin <mi plus mx at aldan dot algebra dot com>
2005-09-07 16:23:06 +00:00
Colin Percival 811045b4a3 MFC: Correct insecure temporary file usage.
Security:	FreeBSD-SA-05:20.cvsbug
2005-09-07 13:44:06 +00:00
Nate Lawson c0b8480022 MFC: ignore non-useful cpufreq levels and change the powerd algorithm to
one that saves more power with possibly more performance loss.  This is
kern_cpu.c:1.20,1.21 and powerd.c:1.9
2005-09-06 18:02:19 +00:00
Warner Losh d762a5e96d MFC: 1.293 1.294:
Treat 0xfffff.... as unassigned as well as 0.
2005-09-05 18:09:20 +00:00
Hajimu UMEMOTO c7a79fabbd MFC 1.74: SADB_UPDATE did not return an error when key length is invalid. 2005-09-03 16:14:52 +00:00
Brian Somers ed0521cec8 MFC: If we fail in chown(2), try to just change the group and continue on to
change the permissions.  Failures are still recorded.

Sponsored by:	Sophos/ActiveState
2005-09-03 11:06:08 +00:00
Maksim Yevmenkin ff13be19ac MFC to RELENG_5
Fix dangling callout problem in the Bluetooth L2CAP code that leads to
panic. The panic happens when outgoing L2CAP connection descriptor is
deleted with the L2CAP command(s) pending in the queue. In this case when
the last L2CAP command is deleted (due to cleanup) and reference counter
for the L2CAP connection goes down to zero the auto disconnect timeout
is incorrectly set. pjd gets credit for tracking this down and committing
bandaid.

Reported by:	Jonatan B <onatan at gmail dot com>
Approved by:	re (scottl)
2005-09-03 03:39:40 +00:00
Craig Rodrigues 41aa0c4c80 MFC:
Prevent division by zero errors in sc_mouse_move()
  by explicitly setting sc->font_width, in the same
  places where sc->font_size is set, instead of
  relying on the default initialized value of 0 for sc->font_width.

PR:             kern/84836
Reported by:    Andrey V. Elsukov <bu7cher at yandex dot ru>
2005-09-02 17:37:46 +00:00
Gleb Smirnoff 8c20d1d593 MFC 1.6 - 1.9:
- Use 'ipfw list'.
  - Correctly parse output, when logging amount is limited in the
    rule itself, not in verbose_limit sysctl. [1]

  PR:		conf/77929
  Submitted by:	Andriy Gapon [1]
  eviewed by:	matteo
2005-09-02 14:20:22 +00:00
Gleb Smirnoff cd62c56dba MFC: net.graph.ngqfreemax has been deprecated. 2005-09-02 14:08:51 +00:00
Jesus R. Camou bc311aa382 MFC rev. 1.05:
o The ways to escape an alias.
	o Fix in the alias syntax lines.
	o Refero to the Aliases subsection.

Approved by:	trhodes (mentor)
2005-09-02 05:52:28 +00:00
Gregory Neil Shapiro c212b48031 MFC: Be sure to execute sendmail_precmd() to check sendmail.cf conflicts and
rebuild the aliases file if necessary.

     Revision  Changes    Path
     1.15      +1 -0      src/etc/rc.d/sendmail
2005-09-02 02:52:55 +00:00
Craig Rodrigues fa15134a75 MFC 1.380:
FDOPT_NORETRY is an option, and must be compared with fd->options,
  not fd->flags.

PR:             kern/85481
Submitted by:   Lev Levinson <llevinson at inbox dot ru>
2005-09-02 00:39:13 +00:00
Philip Paeps b2a23c0fd7 MFC r1.6: fix unhandled malloc errors. 2005-09-01 07:30:03 +00:00
Gleb Smirnoff e8fc69b98c MFC 1.28:
- Document the fact that the real length of listen queue is 1.5 more
    than the value of backlog argument.
  - Document the fact that a subsequent listen(2) calls on the listening
    socket change the backlog argument.
  - Note that current listen queue lengths can be queried using netstat(1).

  Submitted by:   Igor Sysoev <is rambler-co.ru>
  Wording by:     gnn
2005-08-31 14:02:20 +00:00
Gleb Smirnoff b679fa3817 MFC 1.21:
Add newline to debuging printf.

  PR:             kern/85271
  Submitted by:   Simon Morgan
2005-08-31 13:59:00 +00:00
Giorgos Keramidas 9df3767184 MFC 1.23:
Make it clear that the .ko extention of a module to be loaded
is optional.
2005-08-31 13:58:39 +00:00
Gleb Smirnoff dca79f798a MFC 1.76:
- Refuse hashsize of 0, since it is invalid.
  - Use defined constant instead of 512.
2005-08-31 13:57:04 +00:00
Garrett Wollman 2e7d57d28b Insta-MFC rev 1.21: don't build "systemv" when not doing "backward".
This fixes virgin installs (and thus "make release").
2005-08-31 01:37:43 +00:00
Craig Rodrigues c34bcb2f16 MFC: VOP_LISTEXTATTR.9, 1.7
Update man page to reflect the fact that VOP_LISTEXTATTR
  does not return a list of ASCII NUL terminated strings.
  Instead, a list of attribute names is returned, where each
  list entry consists of one byte for the name length, followed
  by the name, without a terminating ASCII NUL.
  This in similar to change 1.17 to extattr_get_file.2

  Reviewed by: rwatson, ru

MFC: VOP_LISTEXTATTR.9, 1.6
  Minor formatting fixes.
2005-08-31 00:33:18 +00:00
Max Laier e731c8638f MFC: if_ethersubr.c, 1.197:
Don't loop back packets that have been routed by pf.  This fixes an
  endless loop where the same packet is sent over and over again.

  Obtained from:  OpenBSD
  Reported by:    Sergey Lapin
  Tested by:      Sergey Lapin
2005-08-30 16:44:31 +00:00
Nate Lawson 151775d1ac Remove p4tcc now that this is supported by cpufreq(4). 2005-08-30 05:03:32 +00:00
Andre Oppermann f950504427 MFC rev. 1.31 (correct layer 2 broad- and multicast handling).
PR:	kern/85052
2005-08-29 18:51:01 +00:00
Garrett Wollman 26388b1a5b Merge tzdata2005m update from vendor branch. 2005-08-29 17:05:54 +00:00
Maksim Yevmenkin 6b53ec9d3a MFC to RELENG_5
Address minor locking issues. Use taskqueue_swi instead of taskqueue_swi_giant.

Approved by:	re (scottl)
2005-08-29 17:03:51 +00:00
Maksim Yevmenkin 49e4ae56d3 MFC to RELENG_5
Make sure ng_fec_init() uses the same calling convention as the rest of
the code, i.e. ng_fec_init() is called with the ifp->if_softc pointer and
NOT with the ifp pointer.

PR:		kern/85239
Reviewed by:	brooks
Approved by:	re (scottl)
2005-08-29 16:31:51 +00:00
Gleb Smirnoff ab8e151540 Backout last revision, because it exposes a worse problem, than
it fixes. I believe the problem lives somewhere outside ng_ksocket,
but until it is found, let the node be working.

PR:		kern/84952
PR:		kern/82413
2005-08-29 09:04:10 +00:00
Gleb Smirnoff 36f5a840ba MFC 1.87:
In order to support CARP interfaces kernel was taught to handle more
  than one interface in one subnet. However, some userland apps rely on
  the believe that this configuration is impossible.

  Add a sysctl switch net.inet.ip.same_prefix_carp_only. If the switch
  is on, then kernel will refuse to add an additional interface to
  already connected subnet unless the interface is CARP. Default
  value is off.

  PR:				bin/82306
  In collaboration with:	mlaier
2005-08-29 08:59:30 +00:00
Murray Stokely 6353a83c0c MFC: r1.240 - update ports count and space requirement. 2005-08-29 01:16:43 +00:00
Gregory Neil Shapiro e53e055a4d MFC: sendmail 8.13.4 and hoststat(8)/purgestat(8) man page linking
Reminder by:	Terry Kennedy
2005-08-28 04:58:25 +00:00
Tor Egge aee6649b95 MFC: Don't set the COMPLETE flag in an inodedep structure before the
related inode has been written.
2005-08-26 20:40:31 +00:00
Garrett Wollman 603bfe7727 Merge tzdata2005l update from vendor. 2005-08-26 18:54:31 +00:00
Giorgos Keramidas 7b59bc706f MFC revision 1.24:
% Add a small paragraph that describes how the current environment
% settings can be displayed, near the end of the DESCRIPTION section,
% immediately after the paragraph that describes how they can be set.
%
% Add a reference to printenv(1) too (and the ``printenv'' csh builtin).
%
% Submitted by:   Gary W. Swearingen <[email protected]>
% PR:             docs/85008
2005-08-26 10:27:02 +00:00
Maxime Henrion 87b08782fe MFC r1.241:
date: 2005/07/29 22:40:06;  author: mux;  state: Exp;  lines: +1 -0
  Add a new PCI id for fxp(4) cards found on ICH7-based systems.

  Submitted by:   Martin Nilsson <[email protected]>

PR:	kern/84559
2005-08-26 09:22:34 +00:00
Wilko Bulte 10b23b6294 MFC: "about life" 2005-08-25 18:25:47 +00:00
Maksim Yevmenkin d35a651b50 MFC to RELENG_5
Fix multiple typos in the mutex names. This fixes false positive (and pretty
strange looking too) LORs I have seen on my system. Pointy hat to goes to me.

Approved by:	re (scottl)
2005-08-25 16:16:18 +00:00
Craig Rodrigues 242b3d6566 MFC 1.89:
Remove EXAMPLES section which gives a non-POSIX compliant use of the sort
command.  The -S flag to ls does the same thing.

PR:		standards/83919
2005-08-25 00:55:52 +00:00
Giorgos Keramidas a6c41d5888 MFC: Spell "partition" correctly:
> 1.34      +1 -1      src/sbin/ccdconfig/ccdconfig.8
> 1.53      +1 -1      src/sbin/reboot/boot_i386.8

Reminded by:	simon
2005-08-24 15:45:39 +00:00
Simon L. B. Nielsen 74cca03c9d MFC rev 1.35:
Remove reference to raid(4), the RAIDframe manual page, which was
  deleted a while ago.
2005-08-24 08:09:14 +00:00
Pyun YongHyeon 753b2c6420 Merge if_re.c:1.46 from HEAD to RELENG_5:
Use correct pointer type. This should fix non-functional re(4)
  driver on 64bit architectures.
2005-08-24 07:03:35 +00:00
SUZUKI Shinsuke 26d12f71fc MFC 1.55
added a missing unlock (just do the same thing as in netinet/raw_ip.c)

Approved by: re(scottl)
2005-08-24 06:46:16 +00:00
Max Laier bbe411a5e6 MFC: if.c, 1.236
Move eventhandler for 'ifnet_departure_event' at the end of the progress.
  Some of the (IPv6) cleanup functions send packets to inform peers of the
  departure.  These packets confused users of ifnet_departure_event (pf at
  the moment).

  PR:             kern/80627
  Tested by:      Divacky Roman

Forgotten by:	mlaier
2005-08-23 14:25:31 +00:00
Brooks Davis 5c966369ba MFC rev 1.28, removal of pointless -I.. from CFLAGS.
PR:		bin/79229
2005-08-21 00:43:28 +00:00
Hajimu UMEMOTO 72767786e5 MFC 1.34, 1.35:
- avoid exclusive sleep mutex witness warning using sx lock.
  - use TAILQ_FOREACH() for readability.
2005-08-20 12:32:33 +00:00
Gleb Smirnoff 29def03b00 MFC 1.27:
When doing ARP load balancing source IP is taken in network byte order,
  so residue of division for all hosts on net is the same, and thus only
  one VHID answers. Change source IP in host byte order.

  Reviewed by:    mlaier
2005-08-20 10:23:19 +00:00
Remko Lodder 4a2dfae294 MFC:
Document the fact that accept(2) may return EINVAL when addrlen is
  negative (in addition to returning EINVAL when called on a descriptor
  that is not a socket).

  Submitted by:   Arne H Juul <[email protected]>
  PR:             docs/80587

PR:		docs/54995, docs/80587
Prodded by:	rionda
2005-08-20 08:36:56 +00:00
Doug Barton 85f86b56e4 MFC 1.1.1.3, a patch to aid in out of memory conditions. 2005-08-19 22:10:48 +00:00
Brian Somers 1e89a6e334 Connect ichsmb to the build. 2005-08-19 18:54:25 +00:00
Brian Somers 2962a4b8ab MFC: Fix up ichsmb.
Sponsored by:	Sophos/ActiveState
2005-08-19 18:50:16 +00:00
Wilko Bulte 0c0d9c6fbd MFC beachhead and FCAL joke 2005-08-19 17:35:42 +00:00
Gleb Smirnoff 80b0090018 MFC:
Add a new switch -h for interface stats mode, which prints all interface
  statistics in human readable form.

  In collaboration with:	vsevolod
  Reviewed by:			cperciva
2005-08-19 15:24:12 +00:00
Pawel Jakub Dawidek 66f1928bb3 MFC: sys/opencrypto/cryptodev.c 1.26
Fix bogus check. It was possible to panic the kernel by giving 0 length.
This is actually a local DoS, as every user can use /dev/crypto if there
is crypto hardware in the system and cryptodev.ko is loaded (or compiled
into the kernel).

Reported by:    Mike Tancsa <[email protected]>
Security:	Local DoS on systems with crypto HW and with /dev/crypto available
2005-08-19 12:06:40 +00:00
Matt Jacob 6edbb598f0 MFC 1.48: The divide by zero panic must have been due to a bogus
period value. I suppose the BT adapter driver should be
fixed, but more importantly we should protect against
dividing by zero.
2005-08-19 05:03:08 +00:00
Marcel Moolenaar 3f9bbc8695 MFC 1.3: Fix backtraces. 2005-08-19 04:05:30 +00:00
Murray Stokely acab433a01 MFC: Catch up with last few months of changes on HEAD. Correct typos,
correct dates, add entries for Pope John Paul II, etc.
2005-08-19 03:30:44 +00:00
Giorgos Keramidas f987d35b75 Merge spelling fixes from CURRENT. The revisions MFC'ed are:
Revision  Path
  1.9     src/lib/libarchive/archive_entry.3
  1.20    src/lib/libarchive/archive_read.3
  1.9     src/lib/libc/net/inet6_rth_space.3
  1.7     src/lib/libc/posix1e/acl_get_entry.3
  1.14    src/lib/libc/posix1e/mac.3
  1.6     src/lib/libc/posix1e/mac_prepare.3
  1.36    src/lib/libc/stdtime/strftime.3
  1.15    src/lib/libc/sys/kse.2
  1.7     src/lib/libc/sys/uuidgen.2
  1.5     src/share/man/man4/man4.i386/acpi_panasonic.4
  1.39    src/share/man/man4/man4.i386/ep.4
  1.4     src/share/man/man4/man4.i386/snc.4
  1.3     src/share/man/man4/man4.sparc64/snd_audiocs.4
  1.10    src/share/man/man4/witness.4
  1.2     src/share/man/man5/devfs.conf.5
  1.50    src/share/man/man9/ifnet.9
  1.6     src/share/man/man9/printf.9
  1.11    src/usr.bin/file2c/file2c.1
  1.26    src/usr.bin/indent/indent.1
  1.16    src/usr.bin/lockf/lockf.1
  1.89    src/usr.bin/make/make.1
  1.44    src/usr.bin/systat/systat.1
  1.18    src/usr.bin/truss/truss.1
  1.32    src/usr.bin/xinstall/install.1
  1.10    src/usr.sbin/bluetooth/rfcomm_pppd/rfcomm_pppd.8
  1.3     src/usr.sbin/bluetooth/sdpd/sdpd.8
  1.35    src/usr.sbin/i4b/isdnd/isdnd.rc.5
  1.52    src/usr.sbin/mtree/mtree.8
  1.7     src/usr.sbin/ndiscvt/ndiscvt.8
  1.12    src/usr.sbin/ntp/doc/ntpdc.8
  1.25    src/usr.sbin/pppd/pppd.8
  1.39    src/usr.sbin/syslogd/syslog.conf.5
2005-08-18 15:22:11 +00:00
Ceri Davies f10656edd9 MFC r1.71.
Correct the description of the TAPE environment variable.
  Based on:

PR:             docs/84200
Submitted by:   Gary W. Swearingen <garys at opusnet dot com>
Approved by:    re (hrs)
2005-08-18 11:41:18 +00:00
SUZUKI Shinsuke 07a5e49892 MFC: IPv6 stealth forwarding
Revision  Changes    Path
   1.39      +3 -1      src/sys/netinet6/in6.h
   1.35      +8 -0      src/sys/netinet6/in6_proto.c
   1.30      +8 -0      src/sys/netinet6/ip6_forward.c
   1.34      +3 -0      src/sys/netinet6/ip6_var.h

PR: kern/54625
Approved by: re(kensmith)
2005-08-18 09:39:35 +00:00
Lukas Ertl 9aa5c7c4c2 MFC:
geom_vinum.c        rev. 1.17
  geom_vinum_drive.c  rev. 1.19
  geom_vinum_plex.c   rev. 1.16
  geom_vinum_rm.c     rev. 1.7
  geom_vinum_var.h    rev. 1.9, 1.10
  geom_vinum_volume.c rev. 1.9
2005-08-16 20:55:33 +00:00
Christian Brueffer 4689b6a487 MFC: rev. 1.11
- add missing ether_poll_deregister
- add per-device polling
- move the setting of if_capenable further down so that the
  VLAN caps are honored as well

Approved by:    ru
2005-08-16 20:51:28 +00:00
Maxim Sobolev 9622c6e8d2 MFC: Do not use vm_pager_init() to initialize vnode_pbuf_freecnt variable.
vm_pager_init() is run before required nswbuf variable has been set
to correct value. This caused system to run with single pbuf available
for vnode_pager. Handle both cluster_pbuf_freecnt and vnode_pbuf_freecnt
variableis in the same way.

Tested by:	pre-release.portaone.com
2005-08-16 15:09:44 +00:00
Marcel Moolenaar bb9391f5b8 Sync up with RELENG_6:
o  main.c:1.7.2.1
o  trgt.c:1.2.2.1
2005-08-16 03:52:30 +00:00
Julian Elischer 4114bb082f MFC: reduce warnings when compiled under -W
Obtained from:	Sandvine inc.
2005-08-15 18:51:45 +00:00
Tor Egge fc76c16104 MFC: Check for marker pages when scanning active and inactive page queues. 2005-08-15 15:01:59 +00:00
Tor Egge 5bf44f90e1 MFC: Don't allow pagedaemon to skip pages while scanning active and
inactive page queues due to the vm object being locked.
2005-08-15 14:59:53 +00:00
Suleiman Souhlal 371e5e7547 MFC rev 1.222:
Use atomic operations on runningbufspace.

 PR:             kern/84318
 Submitted by:   ade
2005-08-15 06:26:52 +00:00
Suleiman Souhlal 0bf0e5c0ed MFC rev 1.73:
The kernel is usually at /boot/kernel/kernel nowadays.

 PR:     i386/81756
 Submitted by:   trasz <[email protected]>
2005-08-15 06:18:07 +00:00
Suleiman Souhlal 740438e8ed MFC re 1.10:
it's actually 11 minutes when the machine is assumed to be down and removed
  from the output.

  Obtained from:  DragonFlyBSD
2005-08-15 06:10:13 +00:00
Murray Stokely 6c3ab0af48 MFC: r1.46 - grammar improvements. 2005-08-14 18:53:50 +00:00
Murray Stokely adf9a7ee9b MFC: r1.15 - fix typo. 2005-08-14 18:49:38 +00:00
Bjoern A. Zeeb a6f3984c18 MFC: rev. 1.33 src/sys/net/if_gre.c, rev. 1.20 src/sys/netinet/ip_gre.c
Add support for IPv6 over GRE [1]. PR kern/80340 includes the
 FreeBSD specific ip_newid() changes NetBSD does not have.
Correct handling of non AF_INET packets passed to bpf [2].

PR:		kern/80340[1], NetBSD PRs 29150[1], 30844[2]
Obtained from:	NetBSD ip_gre.c rev. 1.34,1.35, if_gre.c rev. 1.56
Submitted by:	Gert Doering <gert at greenie.muc.de>[2]
2005-08-13 11:31:00 +00:00
Christian Brueffer fe95c50ee4 MFC: rev. 1.42
Remove stray comma
2005-08-12 22:32:55 +00:00
Christian Brueffer 5415f9c4a5 MFC: rev. 1.18
Sort the list of supported hardware.
2005-08-12 22:32:13 +00:00
Nate Lawson 33cc8de902 MFC rev 1.15: use more reasonable boundary for user setting of lowest 2005-08-12 17:26:37 +00:00
Christian Brueffer 70c131f0ce MFC:
More tcpdump 8->1 cleanup.
2005-08-12 16:16:57 +00:00
Nate Lawson 4051add182 Remove CPU_ENABLE_TCC from options also. 2005-08-11 17:19:25 +00:00
Nate Lawson d464541b51 Remove remaining reference to CPU_ENABLE_TCC. It is obsolete with the
cpufreq MFC.

Reported by:	Tijl Coosemans
2005-08-11 17:17:09 +00:00
Stephan Uphoff 755797ddc1 MFC ffs_softdep.c 1.182, softdep.h 1.18
Delay freeing disk space for file system blocks until all
dirty buffers are safely released. This fixes softdep
problems on truncation (deletion) of files with dirty
buffers.
2005-08-10 15:22:17 +00:00
Gleb Smirnoff f032904c4f MFC 1.66:
Use m_uiotombuf() instead of own implementation. This is not just
  a cosmetic change. m_uiotombuf() produces a packet header mbuf, while
  original implementation did not. When kernel is compiled with MAC
  support, headerless mbuf will cause panic.

  Reported by:    Alexander Nikiforenko <asn rambler-co.ru>
  Reported by:    Andrew Korovin <freeside inbox.ru>
  PR:		  kern/77111
2005-08-10 13:59:44 +00:00
Jesus R. Camou a35a5280b9 MFC: config-recursive target.
Approved by:	trhodes (mentor, implicitly)
2005-08-09 23:01:29 +00:00
Jesus R. Camou ddbb2068cc MFC: Information about starting jails
at boot time if specified in rc.conf.

PR:		docs/81040
Submitted by:	matteo
Approved by:	trhodes (mentor)
2005-08-09 21:10:20 +00:00
Giorgos Keramidas 0f3d165d7d MFC 1.35:
# Some grammar, spelling, and mdoc(7) fixes.  No content changes.
#
# PR:		75581
# Submitted by:	Nobuyuki Koganemaru [email protected] (original version)

PR:		docs/84679
Submitted by:	Chris Jones <[email protected]>
2005-08-08 23:37:06 +00:00
John Baldwin 85a8e80ce7 MFC: Fix a bug in pmap_protect() in the PAE case where it could look up the
wrong vm_page_t associated with a pte.

Requested by:	alc
2005-08-08 15:33:53 +00:00
Diomidis Spinellis 259da6636c MFC 1.12 to 1.13
PR:	22612
2005-08-08 12:50:57 +00:00
Diomidis Spinellis 2c864c8a18 MFC 1.19 to 1.22
PR:	22612
2005-08-08 12:50:20 +00:00
Thomas Quinot 70a1fbf024 (atapi_cam_reinit_bus): Guard against the case where atapi_softc_mutex is
not initialized yet (case of the bus being reinitialized during the boot
process).

Note that this change is a fix for RELENG_5 only, not relevant to HEAD.

PR:		kern/84567
Tested by:	Chris Jones <[email protected]>
2005-08-07 20:34:03 +00:00
Christian Brueffer a2e3f00de7 MFC: rev. 1.5
Remove Xref to non-existant usb(3) manpage.
2005-08-07 15:50:59 +00:00
R. Imura 7b5c517906 MFC 1.2: Correctly use a size_t so 64-bit hosts can mount SMB FS's
when using character set conversions.
2005-08-07 10:30:56 +00:00
Markus Brueffer 940839b671 MFC Rev. 1.13
s/Lefler/Leffler/

Approved by:	brueffer
2005-08-06 14:53:25 +00:00
Christian Brueffer 243b787309 MFC: rev. 1.11
Mention that the softc is zeroed after allocation.
2005-08-06 07:27:23 +00:00
Doug Barton e5a60c0362 MFC the removal of threading from BIND.
Original work by:	des
2005-08-06 03:48:18 +00:00
Max Laier d389736d79 MFC: pf.c, 1.35 pfvar.h, 1.12
Prevent a race condition.  As pf_send_tcp() - called for expired synproxy
  states - has to drop the lock when calling back to ip_output(), the state
  purge timeout might run and gc the state. This results in a rb-tree
  inconsistency.  With this change we flag expiring states while holding the
  lock and back off if the flag is already set.

  Reported by:	glebius
2005-08-06 01:54:11 +00:00
Remko Lodder f10df9fc9e Ofcourse FreeBSD-SA-05:19.zlib should have been FreeBSD-SA-05:19.ipsec
Pointed out by:		simon
2005-08-05 21:46:12 +00:00
Remko Lodder ca24bd8c02 Add FreeBSD-SA-05:18.zlib and FreeBSD-SA-05:19.zlib to the errata page's 2005-08-05 21:43:16 +00:00
Bjoern A. Zeeb b7f0ed2f4b MFC rev. 1.220
Correct 32 vs 64 bit signedness issues.
2005-08-05 19:50:05 +00:00
Bjoern A. Zeeb 3b5c7164e2 MFC rev. 1.104
Deal with failed malloc calls[1].
While there also check for failed device_add_child calls.

Found by:	Coventry Analysis tool[1].
Submitted by:	sam[1]
2005-08-05 18:12:17 +00:00
George V. Neville-Neil e709114e46 MFC
Fix for PR 83885.

Make sure that there actually is a next packet before setting
nextrecord to that field.

PR: 83885
Submitted by: [email protected]
Obtained from:  Patch suggested in the PR
2005-08-05 13:30:10 +00:00
George V. Neville-Neil 776b02ae04 Fix for PR 82974. We were not checking that the route looked up in
the case of an RTM_CHANGE was specific, i.e. that it matched completely.  This
led to a route change of a non-existent route changing the default route
as the radix code would simply back track to that point and hand that
route back to the routing socket code.

PR: 82974
Reviewed by: Tai-hwa Liang <[email protected]>
               Ben Kaduk <[email protected]>
               Bjoern A. Zeeb <[email protected]>
Obtained from:  OpenBSD with modifications.
2005-08-05 12:21:14 +00:00
Diomidis Spinellis 667edbb708 MFC version 1.18
Interpret correctly the glob(3) return value.
Previously, interactive commands specifying a non-existent file or
directory used to display an "out of memory error".
2005-08-05 11:14:25 +00:00
Christian Brueffer 1247143223 MFC: rev. 1.28
Mention the default value of PATH and that it may be overridden.
2005-08-04 19:59:32 +00:00
John-Mark Gurney 7ba91eea16 MFC: v1.40 help.common, v1.45 intro.2
Fix a couple documentation issues...
2005-08-01 20:25:41 +00:00
Ruslan Ermilov b96c83eee3 MFC:
1.72: deref correct mbuf ptr to collect any vlan tag
1.73: fix null ptr deref when nge_newbuf is called with an existing mbuf

PR:		75201
2005-08-01 10:05:04 +00:00
Garance A Drosehn c094557f3c MFC *: Add the recently-implemented -v, -P, and -S options, along with
subsequent bug fixes.  While the -S feature is not as useful in RELENG_5
as it is in RELENG_6 and HEAD, for people writing scripts it is useful
if the same features are available in all recent releases.  I intend to
commit this to RELENG_4 too, after a few more weeks.  Since these are
new features, they should not effect any presently-working scripts.

[* = 1.6 env/Makefile, 1.6->1.9 env.1, 1.12->1.16 env.c,
     1.1->1.4 envopts.c, 1.1 envopts.h]

MFC after:	12 days
2005-08-01 02:24:19 +00:00
Maksim Yevmenkin 43f9b51ef6 Insta-MFC to RELENG_5
Fix typo and check correct (rsp) pointer against the NULL value.

Submitted by:	Oliver < urnenfel at tiscali dot es >
Approved by:	re (kensmith)
2005-07-29 16:45:21 +00:00
Hajimu UMEMOTO e37e667814 MFC 1.12: don't accept invalid form of an address like 1:2:3:4:5:6:7::8. 2005-07-29 16:21:33 +00:00
R. Imura d958cd4ffd MFC rev 1.2: Fix core dump when "smbutil lc". 2005-07-29 16:11:18 +00:00
Xin LI 0d3168ebac MFC 1.123:
Allow PLAY_MSF, PLAY_TRACK, PLAY_TRACK_REL, PAUSE, PLAY_12 commands to pass
through umass(4), in order to make cdcontrol(1) to issue commands to a USB
CD driver.

The command IDs were obtained from the CAM subsystem.  This was tested
on half dozen of USB CD drivers from different vendors.

Suggested by:   "intron" <intron at intron dot ac>
PR:             usb/83439
Reviewed by:    sanpei
Approved by:    re (kensmith)
2005-07-29 15:40:34 +00:00
Tai-hwa Liang 921bc0d60a MFC: (1.5) Fixing an off-by-one error. 2005-07-28 14:40:08 +00:00
Giorgos Keramidas 9e6fd8f3c0 MFC:
Makefile	-> 1.58
devfs.conf.5	-> 1.1
devfs.rules.5	-> 1.1

# Add manpages for devfs.conf and devfs.rules.  These have been
# initially written by Roland, but hacked for a while by me.  Any
# good parts are the results of Roland's hard work.  Any typos or
# style mistakes are mine.
#
# Submitted by:   Roland Smith <[email protected]>
# PR:             docs/63808, docs/75433, docs/80458, docs/80459
# MFC after:      2 weeks
2005-07-27 12:03:48 +00:00
Giorgos Keramidas e07638f114 MFC 1.17:
# Expand n't contractions.

MFC: 1.18:
# Document that /etc/rc.d/ntpdate will read this file to find out a
# list of NTP hosts, if ntpdate_hosts is unset or empty.
#
# PR:             conf/79712
# Submitted by:   Tsurutani Naoki <[email protected]>
# mdoc text by:   Matteo Riondato <[email protected]>
2005-07-27 11:53:19 +00:00
Colin Percival 08f9a01323 Correct a buffer overflow which can occur when decompressing a
carefully crafted deflated data stream. [1]

Correct problems in the AES-XCBC-MAC IPsec authentication algorithm. [2]

Submitted by:   suz [2]
Security:       FreeBSD-SA-05:18.zlib [1], FreeBSD-SA-05:19.ipsec [2]
2005-07-27 08:41:56 +00:00
Matthew N. Dodd c958938be7 MFC: 1.13
Move initialization above point of first possible reference to
avoid overwriting ty_status values set from the 'type' field.
2005-07-25 20:22:49 +00:00
Jonathan Chen 32a8fab4a8 MFC of 1.34: fix innetgr() returning false positives and negatives when reverse netgroup matching is used.
PR: 35506
2005-07-25 18:09:03 +00:00
Maksim Yevmenkin 968706d8da MFC to RELENG_5 ng_ubt.c v1.25
Add support for AVM BlueFRITZ! USB Bluetooth Adapter v2.0. It appears that
there are at least two versions of the adapter. Version 1 (product ID 0x2200)
of the adapter does not work with ng_ubt(4) and require special driver and
firmware. Version 2 (product ID 0x3800) seems to work just fine, except it
does not have bDeviceClass, bDeviceSubClass and bDeviceProtocol set to required
(by specification) values. This change forces ng_ubt(4) to attach to the
version 2 adapter.

Ignore AVM BlueFRITZ! USB Bluetooth Adapter v1.0 (product ID 0x2200).
It does not work with ng_ubt(4) and require special driver and firmware.

Submitted by:	Rainer Goellner < rainer at jabbe dot de >
Approved by:	re (kensmith)
Obtained from:	Marcel Holtmann < marcel at holtmann dot org >
2005-07-25 16:24:44 +00:00
Robert Watson f5fe66e28e Merge mac_stub.c:1.54 from HEAD to RELENG_5:
Remove duplicate initialization of mpo_create_stub pointer.

  PR:             83779
  Submitted by:   Wojciech A. Koszek <dunstan at freebsd dot czest dot pl>
2005-07-25 09:46:17 +00:00
Roman Kurakin 3e59971055 MFC cx/if_cx.c:
----------------------------
	revision 1.45
	date: 2005/07/09 16:14:05;  author: rik;  state: Exp;  lines: +1 -1
	Use m_length (m, NULL) instead of m->m_pkthdr.len.

	Problems reported by: strijar at urai dot ru
	Approved by:	re (scottl)
	----------------------------
	revision 1.44
	date: 2005/07/09 14:31:48;  author: rik;  state: Exp;  lines: +3 -2
	Lost cx_mpsafenet check.

	Pointy hat:	me
	Approved by:	re (scottl)
	----------------------------
	revision 1.42
	date: 2005/07/09 14:23:42;  author: rik;  state: Exp;  lines: +4 -0
	Lost CX_UNLOCK().

	Pointy hat:	me
	Approved by:	re (scottl)
	----------------------------
	revision 1.41
	date: 2005/07/09 14:03:02;  author: rik;  state: Exp;  lines: +2 -0
	Protect from partially initialized channels.

	Approved by:	re (scottl)
2005-07-25 07:09:52 +00:00
Roman Kurakin a7df01c10f MFC ctau/if_ct.c:
----------------------------
	revision 1.25
	date: 2005/07/09 16:14:05;  author: rik;  state: Exp;  lines: +1 -1
	Use m_length (m, NULL) instead of m->m_pkthdr.len.

	Problems reported by: strijar at urai dot ru
	Approved by:	re (scottl)
	----------------------------
	revision 1.24
	date: 2005/07/09 14:03:02;  author: rik;  state: Exp;  lines: +2 -0
	Protect from partially initialized channels.

	Approved by:	re (scottl)
2005-07-25 07:09:15 +00:00
Roman Kurakin 74932b319e MFC cp/if_cp.c:
----------------------------
	revision 1.24
	date: 2005/07/09 16:14:04;  author: rik;  state: Exp;  lines: +1 -1
	Use m_length (m, NULL) instead of m->m_pkthdr.len.

	Problems reported by: strijar at urai dot ru
	Approved by:	re (scottl)
	----------------------------
	revision 1.23
	date: 2005/07/09 14:03:02;  author: rik;  state: Exp;  lines: +2 -0
	Protect from partially initialized channels.

	Approved by:	re (scottl)
2005-07-25 07:08:26 +00:00
R. Imura a7d649dfcb MFC 1.45: Fix looking up files having invalid short name.
PR:		77074
2005-07-23 17:05:00 +00:00
Pawel Jakub Dawidek 5ebb071577 MFC: pf 1.7
When reloading rules via rc.d/pf, flush everything but existing state
entries that way when rules are read in, it doesn't break established
connections.

OK'ed by:	mlaier
Forgotten by:	seanc
2005-07-23 12:18:35 +00:00
Jonathan Chen 17511c8cd7 fix that little lie I told six months ago about doing an MFC in 3 days...
MFC from 1.33: remember to reset nextgrp in getnetgrent(), so that subsequent calls to getnetgrent() doesn't return bogus information.
2005-07-22 22:11:13 +00:00
Bruno Ducrot bb824b7b7b MFC: cpufreq man pages updates, revs 1.6 through 1.11.
Approved by:	ru, njl, imp (mentor)
2005-07-22 06:58:04 +00:00
Bruno Ducrot 4cac1d5851 MFC: Import the powerd(8) daemon.
Approved by:	njl, imp (mentor)
2005-07-21 09:35:33 +00:00
Bruno Ducrot c1ad43f11f MFC: add all other cpufreq specific drivers that do not belong to acpi.
Approved by:	njl, imp (mentor)
2005-07-21 09:20:10 +00:00
Bruno Ducrot a861b1a1cb MFC: update acpi to current cpufreq interface, add the acpi_perf cpufreq
driver.  Do not include yet thermal stuff from ume@ since this need more
testing in -current.

Approved by:	njl, imp (mentor)
2005-07-21 08:50:26 +00:00
Bruno Ducrot 3866abd679 MFC 1.14: bring up cpufreq interface up to date.
Approved by:	njl, imp (mentor)
2005-07-21 08:46:20 +00:00
Hartmut Brandt a8100eca2f MFC 1.123
Fix a longstanding bug with the .END target. Need to pass the ENDNode
to the Run function instead of some random node.

PR:		bin/83698
Submitted by:	Max Okumoto <[email protected]>
2005-07-20 19:16:25 +00:00
cvs2svn 75b4dab603 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-07-20 18:59:26 +00:00
Simon L. B. Nielsen 6468264ebf Add FreeBSD-SA-05:17.devfs. 2005-07-20 14:04:14 +00:00
Simon L. B. Nielsen ef3afc272d MFC rev 1.116 of src/sys/fs/devfs/devfs_vnops.c:
Correct devfs ruleset bypass.

Submitted by:	csjp
Reviewed by:	phk
Security:	FreeBSD-SA-05:17.devfs
Approved by:	cperciva
2005-07-20 13:35:44 +00:00
Pawel Jakub Dawidek aa4c13e62d MFC: g_concat.c 1.25
g_stripe.c	1.26

Before calling g_orphan_provider(), add G_PF_WITHER flag, so GEOM will know
to destroy it.

PR:		kern/81758
Submitted by:	trasz <[email protected]>
2005-07-20 13:15:11 +00:00
Robert Watson e38324af70 Merge ip_input.c:1.302 from HEAD to RELENG_5:
Remove spl() calls from ip_slowtimo(), as IP fragment queue locking was
  merged several years ago.
2005-07-20 12:04:14 +00:00
Robert Watson c9879bb61f Merge if_sbsh.c:1.13 from HEAD to RELENG_5:
Mark if_sbsh as IFF_NEEDSGIANT, because it does.
2005-07-20 10:01:36 +00:00
Robert Watson 7daec6c566 Merge if_cnw.c:1.19 from HEAD to RELENG_5:
Mark if_cnw as IFF_NEEDSGIANT, because it does.
2005-07-20 10:01:15 +00:00
Doug White 2e2642d737 MFC: Undo 5.4-R bge hacks by default and provide kernel option to override. 2005-07-20 06:04:21 +00:00
Pawel Jakub Dawidek 424772c7d7 MFC: geom_raid3.c 1.12
Don't forget to initialize 'id' field.
2005-07-18 16:15:56 +00:00
Joe Marcus Clarke db1e62a42c MFC: revs 1.23 and 1.24
* Replace fch{mod,own} with straight ch{mod,own} as the former cannot be used
  on socket file descriptors
* Open permissions on /var/run/devd.pipe so that any user can read devd events
  from this socket
* Enable non-blocking I/O on devd.pipe to keep clients from wedging devd.
  If a write(2) on devd.pipe would block, the client in question will be
  removed

Approved by:	imp
2005-07-18 14:13:18 +00:00
Sheldon Hearn 6c51de9f3a MFC rev 1.34: regen 2005-07-18 07:46:21 +00:00
Robert Watson ed1e925594 Merge sem_init.3:1.18, sem_post.3:1.15, sem_wait.3:1.13 from HEAD to
RELENG_5:

  Cross-reference sem_getvalue(3) from several other semaphore-related
  functions.
2005-07-17 19:34:37 +00:00
Xin LI f6d4ae3d07 MFC revision 1.13
date: 2005/07/13 10:40:07;  author: delphij;  state: Exp;  lines: +7 -4
Better memory handling:

 - It is acceptable to call free(3) when the given pointer itself
   is NULL, so we do not need to determine NULL before passing
   a pointer to free(3)
 - Handle failure of malloc(3)

Submitted by:	Dan Lukes <dan at obluda cz>
PR:		bin/83352
Approved by:	re (scottl)
2005-07-17 17:29:22 +00:00
Christian Brueffer 6d272bfc1b MFC: rev. 1.321
MLINK firewire.4 to ieee1394.4
2005-07-17 14:50:07 +00:00
Hiroki Sato 003850028e MFC: Add support for IODATA USB-RSAQ3 USB-Serial Adapter.
Reported by:    Tomokazu Hirai
2005-07-16 09:15:55 +00:00
Ruslan Ermilov 09ba3c738f MFC: 1.3: Fixed two bugs in the Perl to C conversion. 2005-07-15 15:32:00 +00:00
Markus Brueffer 4635e9f5cd MFC: rev. 1.5 + 1.6
- Grammar fixes
- s/spdcontrol/sdpcontrol/
- Added the EXIT STATUS section where appropriate

Approved by:	brueffer
2005-07-14 20:17:18 +00:00
John Baldwin 3d254d5163 Regen. 2005-07-14 19:09:49 +00:00
John Baldwin 75bb308049 MFC: Add the preadv() and pwritev() system calls. 2005-07-14 19:08:22 +00:00
John Baldwin a1407e0211 MFC 1.143: Use ssize_t for cnt in dofile{read,write}() rather than long. 2005-07-14 18:59:58 +00:00
John-Mark Gurney 84d388d310 MFC: v1.68 of pkg_create.1, v1.50 of plist.c
remove a few uses of the word `really'
2005-07-12 06:58:03 +00:00
John Baldwin 6954165841 MFC: Increase the maximum number of USB busses to 40. 2005-07-11 17:22:13 +00:00
John Baldwin 9e9ec8ce76 MFC: Fix what(1) on kernel binaries by axeing sccspad[] and duplicating the
first line of version[] in sccs[].
2005-07-11 17:18:53 +00:00
John Baldwin 3dfd97543f MFC: Increase MAXCPU to 16 for SMP kernels to cope with APIC IDs >= 8. 2005-07-11 17:16:18 +00:00
Ken Smith 3483214d1e MFC v1.2, Add -D_FREEFALL_CONFIG to CFLAGS via Makefile so that just
defining _FREEFALL_CONFIG in /etc/make.conf is all that is required
for the clusterisms to take effect.
2005-07-11 13:25:54 +00:00
Ken Smith 0d94b93828 MFC v1.16, Add -D_FREEFALL_CONFIG to CFLAGS via Makefile so that just
defining _FREEFALL_CONFIG in /etc/make.conf is all that is required
for the clusterisms to take effect.
2005-07-11 13:22:13 +00:00
Ken Smith 5af2ffc7cb MFC v1.15, Add -D_FREEFALL_CONFIG to CFLAGS via Makefile so that just
defining _FREEFALL_CONFIG in /etc/make.conf is all that is required
for the clusterisms to take effect.
2005-07-11 13:16:26 +00:00
Xin LI 9ba0d4d4d8 MFC 1.47:
Fix a bug when shell expansion is done against dangling symlinks, by
converting the stat() call to a lstat() call, which will cover the
situation.  One can exercise this bug by referring a dangling link with
something like */the-link.

Submitted by:   Simon 'corecode' Schubert [corecode fs ei tum de]
Obtained from:  NetBSD via DragonFlyBSD (NetBSD rev. 1.51 and DragonFly
                rev. 1.6)
2005-07-10 15:17:53 +00:00
Hiroki Sato d3f44a4d17 MFC:
$jail_<name>_flags for rc.d/jail, and
	pkg_version(1) -I flag.
2005-07-10 03:47:21 +00:00
Maxim Sobolev df27ad23e3 MFC (sort of): revert k_lock member to be of type void* and use explicit
casts to struct mtx* where necessary, like it's done the version that
has been committed into the HEAD.

Light shed by:	scottl
2005-07-09 04:00:42 +00:00
David E. O'Brien 23059e6635 Add additional sub-systems to the warning users get when they build a
kernel that has become GPL infected.
2005-07-08 00:00:05 +00:00
David E. O'Brien acc961c873 MFC: rev. 1.5: later options nullify mutually exclusive earlier options. 2005-07-07 22:55:40 +00:00
Marcel Moolenaar 5160e33f11 MFC rev. 1.113: Handle B-unit break instructions. 2005-07-06 20:02:05 +00:00
Marcel Moolenaar 1f74b10f72 MFC rev. 1.112: Copyright update. 2005-07-06 19:56:34 +00:00
Marcel Moolenaar fbbb9c7b3c MFC rev. 1.111: Cosmetic: s/u_int64_t/uint64_t/g 2005-07-06 19:53:38 +00:00
Simon L. B. Nielsen f20375f4d4 Add FreeBSD-SA-05:16.zlib. 2005-07-06 14:27:35 +00:00
Colin Percival a0a4f0c485 MFC rev. 1.6 of src/lib/libz/inftrees.c:
Correct a buffer overflow which occurred in the handling of some
  particularly corrupt deflated data streams.

Security:	FreeBSD-SA-05:16.zlib
2005-07-06 14:01:11 +00:00
Paul Saab 892f3e2166 MFC: 1.279
Fix for a SACK crash caused by a bug in tcp_reass(). tcp_reass()
does not clear tlen and frees the mbuf (leaving th pointing at freed
memory), if the data segment is a complete duplicate.
2005-07-05 19:25:42 +00:00
Hideyuki KURASHINA f42c16eb99 MFC: dev.sgml (rev 1.282)
bs driver was already removed.

    Reviewed by:	nyan
2005-07-04 14:30:18 +00:00
Colin Percival dd958362c5 MFC revisions 1.174-1.175: Document some limitations of uid/gid rules. 2005-07-04 08:29:11 +00:00
Dag-Erling Smørgrav 8fe97c87d2 MFC: (1.9) honor dumpdev kenv variable if rc.conf specifies AUTO. 2005-07-04 02:36:17 +00:00
Maxim Sobolev 869d818c8c Unbreak ndis(4) when it's statically compiled into the kernel. 2005-07-03 20:46:57 +00:00
Stephan Uphoff 9fbfd56d6a MFC: kern/kern_switch.c 1.112, 1.114-1.116
kern/sched_4bsd.c 1.74 1.75

Fix some race conditions for pinned threads that may cause them to run
on the wrong CPU.

Add IPI support for preempting a thread on another CPU.
( To reduce diff for future MFCs, The required MD Part to support
  IPI preemption is not part of this MFC)
2005-07-03 20:08:04 +00:00
Stephan Uphoff 703ac63cc3 MFC: 1.9 Zero terminate empty string in kdb_sysctl_available. 2005-07-03 19:35:15 +00:00
Hiroki Sato b55d92224b Remove SA-05:12.bind9 because it is not applicable to 5.4R.
Submitted by:	Daniel Gerzo
PR:		www/82798
2005-07-03 13:46:30 +00:00
Pawel Jakub Dawidek 51b4b5f957 MFC: rc.d/jail 1.23
defaults/rc.conf	1.252

Introduce new per-jail variable jail_<name>_flags, which allows to specify
jail(8) flags (before the change we had hardcoded "-l -U root").

Submitted by:	Frank Behrens <[email protected]>
PR:		conf/80244
2005-07-03 12:40:13 +00:00
Dag-Erling Smørgrav 8779fc1a28 MFC: (1.75, 1.76) flush the send side rather than shut it down. 2005-07-03 10:40:23 +00:00
Daniel Harris 5851dfeecf MFC revs 1.23-4 and re-add the "command" command. 2005-07-03 01:49:58 +00:00
Xin LI c35c0f73fb MFC revision 1.52
date: 2005/06/28 02:23:56;  author: delphij;  state: Exp;  lines: +1 -1
Correct a comment in ucred.h.

Submitted by:	Wojciech A. Koszek <dunstan at freebsd czest pl>
PR:		kern/82708
2005-07-02 20:14:18 +00:00
Stefan Farfeleder 0bc528c465 MFC 1.7: Add _Qp_cmp() and _Qp_cmpe(). 2005-07-01 16:55:50 +00:00
Pawel Jakub Dawidek dbe6084140 MFC: kern_ktrace.c 1.100,1.101
Fix information leaks from ktrace(2).

OK'ed by:	rwatson
2005-07-01 00:30:50 +00:00
Bruce A. Mah 5951c223b4 List new security advisories: SA-05:13.ipfw, SA-05:14.bzip2,
SA-05:15.tcp.
2005-06-30 19:39:45 +00:00
Bruce A. Mah 12b17b1ab7 MFC: SA-05:10.tcpdump, SA-05:11.gzip, SA-05:13.ipfw, SA-05:14.bzip2,
SA-05:15.tcp.  (Basically make sure all applicable security advisories
are listed.)

While here, also add a missing word in autoboot note.
2005-06-30 18:40:37 +00:00
Mike Makonnen df5647e6e8 MFC:
Sync description of IP portrange sysctls with reality.
2005-06-30 13:11:48 +00:00
Simon L. B. Nielsen 9ce41d7659 Correct ipfw packet matching errors with address tables.
Security:	CAN-2005-2019
Security:	FreeBSD-SA-05:13.ipfw

Correct bzip2 denial of service and permission race vulnerabilities.

Obtained from:	Redhat, Steve Grubb via RedHat
Security:	CAN-2005-0953, CAN-2005-1260
Security:	FreeBSD-SA-05:14.bzip2
Approved by:	obrien

Correct TCP connection stall denial of service vulnerability.

A TCP packets with the SYN flag set is accepted for established
connections, allowing an attacker to overwrite certain TCP options.

Security:	CAN-2005-2068
Security:	FreeBSD-SA-05:15.tcp

Approved by:	cperciva
2005-06-29 21:38:48 +00:00
Max Laier 8781a3f0b4 MFC: pf_ioctl.c, 1.20 if_pfsync.h, 1.7 and if_pfsync.c, 1.16-1.19
Defer ip_output of pfsync updates to an independent callout thread instead
  of just dropping the lock around the ip_output call.  This used to cause
  corrupted state tree walks for some call-paths.

  Mark pf callouts as NET_MPSAFE.

Tested by:  Sascha Luck, Matthew Grooms and pfsense.org (via Scott Ullrich)
2005-06-29 19:12:14 +00:00
Paul Saab 10f5839822 MFC:
Wrap copyin/copyout for kevent so the 32bit wrapper does not have
to malloc nchanges * sizeof(struct kevent) AND/OR nevents *
sizeof(struct kevent) on every syscall.
2005-06-29 18:08:31 +00:00
John Baldwin 5c8d132dcc MFC: Clear devinfo_generation in devinfo_free(). 2005-06-29 15:37:01 +00:00
John Baldwin 896e632e04 MFC 1.50: Don't ignore VESA devices that claim to be non-VGA devices. This
fixes VESA on vmware.
2005-06-29 15:33:23 +00:00
John Baldwin acd7249a15 MFC revs 1.290 and 1.291: Don't enable I/O or memory mode in a device's
command register for BARs with a base of 0.
2005-06-29 15:25:01 +00:00
John Baldwin f22f32f8d2 MFC revs 1.18 and 1.19 to fix random(6) on 64-bit platforms.
PR:		amd64/81279
2005-06-29 15:20:05 +00:00
Hideyuki KURASHINA ac600ee433 Merge the following from the English version:
1.227.2.26.2.2 -> 1.227.2.31	hardware/common/dev.sgml

Update a Japanese override of dev-auto.sgml.
2005-06-28 16:46:19 +00:00
Hideyuki KURASHINA c8f4ac20d3 Merge the following from the English version:
1.5   -> 1.5.2.1	hardware/common/artheader.sgml
	1.256 -> 1.227.2.26.2.2	hardware/common/dev.sgml
	1.7   -> 1.9		hardware/ia64/proc-ia64.sgml

Update a Japanese override of dev-auto.sgml.

Submitted by:	Ryusuke Suzuki <ryusuke at nucl dot sci dot hokudai dot ac dot jp>
Reference:	[doc-jp-work 1116, 1158]
2005-06-28 15:57:30 +00:00
David Xu d245115713 MFC Revision 1.123:
Fix off-by-one nanosecond in macro TIMESPEC_ADD.
2005-06-28 05:46:49 +00:00
Xin LI 5147c56095 MFC revision 1.20
date: 2005/06/14 10:56:02;  author: ru;  state: Exp;  lines: +3 -3
When IPC_NOWAIT is set and there is no message, msgrcv() fails
with errno set to ENOMSG.

PR:		docs/82217
2005-06-27 11:07:48 +00:00
Tai-hwa Liang 480c21d448 MFC: (1.154) Fixing a memory leak in xpt_release_device(). 2005-06-27 02:51:03 +00:00
Tom Rhodes 6b8fa54310 MFC:
According to the information on:
http://www.opengroup.org/onlinepubs/009695399/functions/swab.html
the prototype for swab() should be in <unistd.h> and not in <string.h>.
Move it, and update to match SUS.  Leave the prototype in string.h for
now, for backwards compat.

PR:		74751
Submitted by:	Craig Rodrigues <[email protected]>
Discussed with:	das
2005-06-27 01:54:40 +00:00
Tom Rhodes 82bee6bb58 Sync up to CURRENT, effectively closing:
PR:	76981
2005-06-27 00:04:24 +00:00
Brian Feldman d35720f9db MFC: fix for NFS client deadlock with exceptionally large write sizes.
src/sys/kern/vfs_bio.c r1.489, src/sys/nfsclient/nfs_bio.c r1.151-152,
     src/sys/nfsclient/nfs_vfsops.c r1.177, src/sys/nfsclient/nfsargs.h r1.68,
     src/sys/nfsclient/nfsmount.h r1.30, src/sys/sys/buf.h r1.186,
     src/sys/sys/bufobj.h r1.15
2005-06-26 23:55:50 +00:00
Eric Anholt 74fb73dfc2 MFC r1.24, which should fix failure to probe for many:
Backout the code which tries to use undocumented way to determine if
  fm801 has sound capabilities or not. Unfortunately this code doesn't
  work as expected.

PR:		kern/45182, kern/48738, kern/82107
Submitted by:	many
2005-06-26 20:51:17 +00:00
Maxim Konovalov 4487f22b09 MFC rev. 1.19 sys/kern/uipc_accf.c to sys/kern/uipc_accf.c and
sys/kern/uipc_socket.c, bug fixes for: setsockopt(2) cannot remove accept
filter, getsockopt(SO_ACCEPTFILTER) always returns success on listen socket.

MFC rev. 1.4 tools/regression/sockets/accf_data_attach/accf_data_attach.c:
Add regression tests for these bugs.
2005-06-26 06:59:50 +00:00
R. Imura b5d5f717ab MFC r1.57: Fix udf_iconv on amd64. 2005-06-25 15:01:00 +00:00
R. Imura 5f9c72b7c3 MFC: iconv_xlat16.c r1.3, iconv.h r1.10
Fix kiconv on the 64bit plathomes.

PR:	amd64/75488, amd64/77470
2005-06-25 14:59:11 +00:00
Hiroki Sato 8f9dc78a57 MFC: Document NetBSD 2.0.2.
Submitted by:	SODA Noriyuki (soda at NetBSD dot org)
PR:		doc/82619
2005-06-25 07:10:09 +00:00
Christian Brueffer fc56901150 MFC: rev. 1.19
Whitespace cleanup from last commit.

Translators can ignore this.
2005-06-24 16:06:49 +00:00
Christian Brueffer 70087308bb MFC: rev. 1.18
Limit entries to their respective architectures.  We don't need e.g.
ISA troubleshooting in the amd64 installation guide.

Also note that amd64 and ia64 use ACPI.
2005-06-24 16:03:56 +00:00
Colin Percival d8c70ae2fc MFC the addition of sha256 to libmd and md5(1).
Also, bump __FreeBSD_version so that ports code knows that sha256 is
now in the base system.

Requested by:	Lots of people
2005-06-24 13:32:25 +00:00
Hiroki Sato 1997ef73a5 Document floppy disk based installation is not supported
on FreeBSD/sparc64 now.

Pointed out by:	Brett D.Estrade (estrabd at mailcan dot com)
2005-06-24 09:05:49 +00:00
Hiroki Sato bd01763e27 Document FreeBSD/sparc64 graphical console issue on 5.4R.
Discussed with and submitted by:	marius
2005-06-24 08:52:41 +00:00
Ceri Davies acf2812fdc Remove an extra 't' that I inexplicably managed to insert during the
last commit.

Pointy hat awarded by: 	ru
2005-06-23 22:45:22 +00:00
Ceri Davies 17b5272619 MFC r1.17:
A lot of people may want to submit PRs from systems that are not
    connected to the Internet or systems that do not have a correctly
    configured email subsystem.  Now that the send-pr web interface has
    antispam protection, mention that it is ok to use it for submitting
    problem reports.
2005-06-23 22:31:08 +00:00
Ceri Davies 682e317946 MFC r1.18:
1. Add the threads and usb categories.
	2. Fill in the blanks on the advocacy category.
	3. Expand a contraction while I'm in here.
2005-06-23 22:28:05 +00:00
Peter Wemm 0fff3093a2 MFp4: oops, the amd64 crash dump code was using the i386 dump version. 2005-06-23 19:54:26 +00:00
Peter Wemm 5c6fe3a2eb MFp4: fix comment about copyin/out and fubyte family. There is no dos
emulator and no 386 protection emulation needed.
2005-06-23 19:51:25 +00:00
Peter Wemm 0a9e58c15b MFp4: Various s/386/amd64/ fixes 2005-06-23 19:49:20 +00:00
Peter Wemm b026ada0ea Fix a source of 'trap xxx with interrupts disabled'. This was a cut/pasto. 2005-06-23 19:46:29 +00:00
Gleb Smirnoff 693491651b MFC:
- style(9) fixes from ru (rev. 1.58)
 - fix exit status for get and set command (rev. 1.57, 1.58)
2005-06-23 07:34:07 +00:00
David Xu 5485a173c5 MFC Revision 1.306:
> Fix a bug relavant to debugging, a masked signal unexpectedly interrupts
> a sleeping thread when process is being debugged.
>
> PR: GNU/77818
> Tested by: Sean C. Farley <sean-freebsd at farley org>
2005-06-23 05:50:58 +00:00
David Xu 9f2a7175bf MFC Revision 1.216:
> Remove sleep queue hack, it is no longer needed with current sleep queue.
> Actually, it causes process to hang when it is being debugged.
>
> PR: gnu/77818
2005-06-23 04:44:09 +00:00
Greg Lehey e2c795e172 MFC: Clarify that gif doesn't do GRE tunnels. 2005-06-22 03:06:12 +00:00
Dag-Erling Smørgrav 746fb98fdd MFC: (1.9) add zless script 2005-06-20 07:13:01 +00:00
Dag-Erling Smørgrav 2fb5c15c16 Bring in from HEAD. 2005-06-20 07:12:48 +00:00
Dag-Erling Smørgrav b4b31e9f27 MFC: (1.2) fall back on cat, exec the handlers 2005-06-20 07:11:24 +00:00
Dag-Erling Smørgrav 0c57e0a6c2 MFC: (1.23) don't use cast as lvalue; make it obvious we don't support IPv6 2005-06-20 07:07:36 +00:00
Dag-Erling Smørgrav ea2b8cc1d8 MFC: (1.13) don't free(sock) before it's even allocated. 2005-06-20 07:06:32 +00:00
cvs2svn 43d4dcaacc This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-06-20 03:43:26 +00:00
Marcel Moolenaar 12377f8dcd MFC: Include the puc(4) bus frontend for ppc(4).
PR: kern/80737
2005-06-20 01:25:34 +00:00
Doug White 6995a0cf48 MFC rev 1.292: Mask off the type bits when comparing the base address,
and restore the old value if zero.
2005-06-19 20:06:05 +00:00
Doug White 9df7e8c482 MFC rev 1.214: Fix passthrough allocation case 2005-06-19 20:02:24 +00:00
Christian S.J. Peron a6c33bb510 MFC revision 1.105
date: 2005/06/10 04:44:38;  author: csjp;  state: Exp;  lines: +1 -1
Correct grammar error in comment
2005-06-19 07:30:09 +00:00
Christian Brueffer bf3f44ae80 MFC: rev. 1.24
Remove the obsolete device count.
2005-06-19 06:48:42 +00:00
Christian Brueffer 262d39c7bb MFC: rev. 1.73
Remove Xref to mount_hpfs(8), it's not hooked up to the build.
2005-06-19 06:47:29 +00:00
Christian Brueffer 98c3a5aaea MFC: rev. 1.2
Remove Xref to nonexistant smapi(9).

Submitted by:	markus
2005-06-19 06:46:28 +00:00
Marcel Moolenaar db36695fc3 MFC rev 1.22: In uart_cnprobe(), fill in the cn_name field of the
consdev structure.
2005-06-18 01:04:48 +00:00
Marcel Moolenaar a33574b88f MFC rev 1.11: Fix using uart(4) as the serial console on a ds10. 2005-06-18 00:48:53 +00:00
Brian Feldman 260df4b8ea MFC: r1.101
Invoke the transmission of IPFW's stateful keep-alives once the
     locks have been dropped, thus preventing a deadlock between
     IPFW and the ifnet.
2005-06-17 23:56:59 +00:00
Brian Feldman a02fbaf8a5 MFC: ipfw.8 r.1.172, ip_fw2.c r.1.100
Properly document the IPFW ALTQ first-match behavior that was
     intended, as well as actually implementing it.
2005-06-17 23:30:32 +00:00
Bernd Walter ff3ee9ac58 MFC: usbdevs Rev 1.227 device ID for FT2232 chips
uftdi.c Rev 1.22 support for FT2232 chips
	     Rev 1.21 remove useless usbd_errstr

Reminded by: Mike Tancsa <[email protected]>
2005-06-17 14:15:27 +00:00
John Baldwin 63ccfdabb9 MFC: Remove the remaining references to boot_userconfig and RB_CONFIG. 2005-06-16 18:54:26 +00:00
John Baldwin 4c17fa639c MFC: Remove obsolete and scary note. The loader has worked fine for
several years now.
2005-06-16 18:42:02 +00:00
John Baldwin 4b6509a768 MFC: Add support to the loader for multiple consoles. 2005-06-16 18:40:34 +00:00
John Baldwin 6fbb9ac342 MFC: Remove some more userconfig cruft. 2005-06-16 18:36:34 +00:00
John Baldwin da6888ab83 MFC: Fix a warning by adding a missing 'const'. 2005-06-16 18:25:48 +00:00
John Baldwin 296b4b859d MFC: Remove one of the last vestiges of the old userconfig support. 2005-06-16 18:23:32 +00:00
John Baldwin 0b10be7b8e MFC: Print out the commands from /boot.config after parsing them so that
the output is sent to the correct console(s).
2005-06-16 18:22:06 +00:00
Dejan Lesjak 991e283673 MFC BSD.x11-4.dist rev. 1.27:
Move couple of directories out of mtree and into their respective
ports. This mtree now specifies basic structure of X11BASE, similarly
to BSD.local.dist.
2005-06-16 08:50:41 +00:00
Christian Brueffer 1ef10bced0 MFC: rev. 1.92 + 1.93
Hex strings are _pre_ceded by 0x, not _pro_ceeded.

PR:		82187
Submitted by:	Anthony Rogers <[email protected]>
		David Adam <[email protected]>
2005-06-16 08:03:58 +00:00
Pawel Jakub Dawidek 088cc64077 MFC: kern_ktrace.c 1.99
Remove process information leak from inside a jail, when
security.bsd.see_other_uids is set to 0, etc.
One can check if invisible process is active, by doing:

	# ktrace -p <pid>

If ktrace returns 'Operation not permitted' the process is alive and
if returns 'No such process' there is no such process.
2005-06-16 07:25:27 +00:00
Maxim Sobolev 8ac6613e87 MFC: recursive package creation move (-R). 2005-06-15 10:35:14 +00:00
Hiroki Sato 92aefb2eb0 Enable table endnotes in printed version. The footnote number
will be "a,b,c,..." independently from footnotes in the document
body, and content of the footnotes will be put just after the table.
2005-06-15 08:46:01 +00:00
Wilko Bulte 771a93d179 MFC:
Empty CMOS batteries can cause agony with your AlphaBIOS versus
SRM selection.

Found out the hard way by: gallatin
2005-06-14 17:43:40 +00:00
Robert Watson 99157b4eda Merge tcp_usrreq.c:1.123 from HEAD to RELENG_5:
Assert tcbinfo lock, inpcb lock in tcp_disconnect().
  Assert tcbinfo lock, inpcb lock in in tcp_usrclosed().
2005-06-14 12:01:03 +00:00
Robert Watson 55177f9e7f Merge tcp_subr.c:1.227 from HEAD to RELENG_5:
Assert that tcbinfo is locked in tcp_input() before calling into
  tcp_drop().
2005-06-14 11:59:46 +00:00
Robert Watson 6aa557d286 Merge tcp_input.c:1.275 from HEAD to RELENG_5:
Assert that tcbinfo is locked in tcp_input() before calling into
  tcp_drop().
2005-06-14 11:59:20 +00:00
Robert Watson 24f06cc8d8 Merge tcp_input.c:1.274 from HEAD to RELENG_5:
Assert the tcbinfo lock whenever tcp_close() is to be called by
  tcp_input().
2005-06-14 11:58:40 +00:00
Robert Watson 4728af25c8 Merge tcp_usrreq.c:1.122 from HEAD to RELENG_5:
Assert tcbinfo lock in tcp_attach(), as it is required; the caller
  (tcp_usr_attach()) currently grabs it.
2005-06-14 11:57:44 +00:00
Robert Watson 6e52e2c899 Merge in_pcb.c:1.164-1.165 from HEAD to RELENG_5:
Assert pcbinfo lock in in_pcbdisconnect() and in_pcbdetach(), as the
  global pcb lists are modified.

  Commit correct version of previous commit (in_pcb.c:1.164).  Use the
  local variables as currently named.
2005-06-14 11:57:06 +00:00
Vinod Kashyap 00692201fa Update the driver version. 2005-06-13 17:47:10 +00:00
Vinod Kashyap 39b2e4f116 MFC: Acquire Giant before making some CAM calls that need Giant to be held.
MFC after:2 days
2005-06-13 17:46:10 +00:00
Hiroki Sato 1e786660a9 Fix security advisory table in the printed version.
XXX: generating footnotes from <ulink> in <table> has
     been disabled temporarily because it will put wrong
     footnote number and does not respect (define bop-footnotes #t).
2005-06-13 17:13:24 +00:00
Maxim Konovalov 95048f37a6 MFC rev. 1.99: teach login(1) to respect "hushlogin" and "nocheckmail"
attributes defined in user's $HOME/.login_conf.
2005-06-13 12:27:06 +00:00
Maxim Konovalov 7eeff881af MFC rev. 1.37: missed colon in getopt(3) argument makes tftpd(8) crash. 2005-06-13 12:19:31 +00:00
Benno Rice 84ca6d262d MFC: Identify the Intel ICH4 EHCI controller. 2005-06-13 09:00:19 +00:00
Marcel Moolenaar d2a2f1a168 MFC: Refactor the NETSMBCRYPTO option. 2005-06-13 04:45:58 +00:00
Hiroki Sato 3bad2663ce Use a simple table for security advisories applicable to the
release.  This will be automated in some way.

Discussed with:	bmah and simon
2005-06-12 13:51:51 +00:00
Lukas Ertl 70443ffdf2 MFC:
When a drive dies, don't call g_wither_geom() directly, but instead
   post an event to the geom event queue that will take care of it,
   letting outstanding bios finish, and closing the consumers.

   Plus some cosmetic clean ups.
2005-06-12 12:18:22 +00:00
Christian Brueffer 6cfd7d2c39 MFC: rev. 1.32
Add the Dell PERC 4/IM as supported.
2005-06-12 11:34:37 +00:00
Kirill Ponomarev bf6bb7bcc9 MFC: main.c:1.5, perform.c:1.12, pkg_version:1.33, version.h:1.4
date: 2005/05/24 08:26:44;  author: cperciva;  state: Exp;  lines: +1 -0
  Add an -I option to pkg_version:

    -I  Use only the index file for determining if a package is out of
        date.  This is much faster than using the version number from a
        port's Makefile, at the expense of potentially giving an incor-
        rect result if the index file is out of date.

  Without this option, the index file is only consulted if "make -V PKGNAME"
  cannot be used.
2005-06-12 08:24:09 +00:00
Pawel Jakub Dawidek 70867fd404 MFC: kern_linker.c 1.116,1.117
Prevent loading modules with are compiled into the kernel.
2005-06-11 13:12:39 +00:00
Max Laier 1c951642e0 MFC: pfil.c, 1.13:
Fix semantics of ph_busy_count == -1 to pass instead of block.

  PR:             kern/81128
  Submitted by:   Joost Bekkers
2005-06-11 06:21:37 +00:00
Marcel Moolenaar 6c0dfabdc7 MFC rev. 1.4: Fix getsecs(). 2005-06-11 05:44:54 +00:00
Marcel Moolenaar b314b57dd5 MFC rev. 1.4: Fix delay(). 2005-06-11 05:42:51 +00:00
Colin Percival 9dc4a9f998 Belatedly document the disabling of Hyper-Threading. Security issues
are not normally documented in UPDATING on the stable branches, but
since this is a user-visible change, it needs to be here.

This is not an MFC since Hyper-Threading is enabled by default in HEAD.

Pointed out by:	Erik Trulsson, via freebsd-stable
2005-06-11 00:08:45 +00:00
Stefan Farfeleder 1cd72a7c3a MFC s_ceill.c 1.2 and s_floorl.c 1.2:
Fix raising the inexact exception (FE_INEXACT) if the result differs from the
  argument.
2005-06-10 21:36:51 +00:00
Stefan Farfeleder b6ec8278cb MFC fpu_explode.c 1.6 and fpu_qp.c 1.6:
Fix long (and long long) to long double, unsigned to long double and unsigned
  long (and unsigned long long) to long double conversions.
  - Add a parameter that specifies the position of the sign bit to the _QP_TTOQ
    macro, previously it always looked at bit 31.  Pass a negative number to
    disable sign inspection for unsigned types.  This fixes _Qp_xtoq(),
    _Qp_uitoq() and _Qp_uxtoq().
  - In the functions __fpu_itof() and __fpu_xtof(), look at the sign bit to
    decide whether we're doing a conversion from an unsigned type.  If so, don't
    negate the mantissa if the integer exceeds the biggest signed number.
2005-06-10 19:00:51 +00:00
Ollivier Robert 26eaa96a4f MFC chkgrp.8: 1.15 & chkgrp.c: 1.9
- Add further functionality to check for invalid characters
  - Remove keyword 'continue' for more indepth error reporting on each line
  - WARNS 6 Clean

  Submitted by:   Liam J. Foy <[email protected]>
2005-06-10 15:33:13 +00:00
Pyun YongHyeon 58bb0ad701 MFC rev. 1.6:
Clarify that systems that have the GPIO pins wired to the hardware
  volume control need a device resource hint.
2005-06-10 10:16:32 +00:00
Robert Watson adb2dba170 Merge udp_usrreq.c:1.175 from HEAD to RELENG_5:
De-spl UDP.
2005-06-10 08:50:31 +00:00
Robert Watson 19e69f4034 Merge ipx.h:1.21 from HEAD to RELENG_5:
Back out ipx.h:1.18, which introduced a Linux API compatibility field in
  the ipx_net data structure.  Doing so introduced a stronger alignment
  requirement for the address structure, which in turn propagated into
  other dependent data structures, which turns out not to be suported by
  the available IPX source code.  As a result, a number of user space
  applications, such as IPX routing components, failed to operate
  correctly.

  RELENG_5_3 candidate?

  PRs:            74059, 80266
  Pointy hat to:  bms
  Fix by:         bde
  Tested by:      Keith White <Keith dot White at site dot uottawa dot ca>
  Suffering:      great
2005-06-10 08:49:12 +00:00
Robert Watson 3f91c3f56f Merge pcpu.h:1.15 from HEAD to RELENG_5:
Add 'curcpu', a shortcut to the current CPU ID, similar to curthread,
  curproc, et al.  Useful for indexing into per-CPU data structures.
2005-06-10 08:47:05 +00:00
Robert Watson a17d47fe8a Merge nfs.h:1.78 and nfs_serv.c:1.156 from HEAD to RELENG_5:
NFS write gathering defers execution of NFS server write requests to wait
  to see if additional write requests will arrive that can be coalesced and
  clustered with earlier ones.  When doing so, it must determine whether
  the two requests are made by credentials with the same access writes, so
  as not to coalesce improperly.  NFSW_SAMECRED() implements a test of two
  credentials using a binary compare.

  Replace NFSW_SAMECRED() macro with nfsrv_samecred() function, which is
  aware of the contents and layout of a struct ucred, rather than a simple
  binary compare.  While the binary compare works when ucred is simply a
  zero'd and embedded 'struct ucred' in the NFS descriptor, it will work
  less well when the ucred associated with an NFS descriptor is "real", so
  has defined and populated reference count, mutex, etc.

  Obtained from:  TrustedBSD Project
2005-06-10 08:45:58 +00:00
Robert Watson aba09a60fa Merge uipc_syscalls.c:1.215 and 1.216 from HEAD to RELENG_5:
De-spl kern_connect().

  Remove now unused 'int s' from spl().
2005-06-10 08:41:56 +00:00
Robert Watson 1ef20a2982 Merge uipc_socket2.c:1.146 from HEAD to RELENG_5:
In the current world order, each socket has two mutexes: a mutex
  that protects socket and receive socket buffer state, and a second
  mutex to protect send socket buffer state.  In some places, the
  mutex shared between the socket and receive socket buffer will be
  acquired twice, once by each layer, resulting in some
  inconsistency, but providing the abstraction benefit of being able
  to more easily separate the two mutexes in the future if desired.

  When transitioning a socket to the SS_ISDISCONNECTING or
  SS_ISDISCONNECTED states, grab the socket/receive socket buffer lock
  once rather than grabbing it as the socket lock, modifying socket
  state, then grabbing a second time as the receive lock in order to
  modify the socket buffer state to indicate no further data can be
  read.  This change is believed to close a race between the change in
  socket state and the change in socket buffer state, which for a
  remotely initiated close on a UNIX domain socket, resulted in
  soreceive() returning ENOTCONN rather than an EOF condition.

  A similar race still exists in the case of send, however, and is
  harder to fix as the socket and send socket buffer mutexes are not
  the same, and we would like to avoid holding combinations of socket
  mutexes over sb_upcall until we've finished clarifying the locking
  protocol for upcalls.

  This change has the side affect of reducing the number of mutex
  operations to initiate disconnect or perform disconnect on a
  socket by two.

  PR:             78824
  Reported by:   Marc Olzheim <[email protected]>
2005-06-10 08:35:40 +00:00
Gleb Smirnoff 57611c2b83 MFC 1.23:
MPPC node is not thread safe.

  PR:             kern/79990
  Reported by:    Arcadiy Ivanov
  Reported by:    atckoe.zlo @ gmail.com
2005-06-10 06:48:48 +00:00
Suleiman Souhlal d83784cec3 MFC 1.23:
- Avoid a memory leak if realloc(3) fails by using reallocf(3)

  Submitted by:   Liam J. Foy <[email protected]>
  Approved by:    mdodd (in-lieu of mentor who is away)
2005-06-10 00:40:05 +00:00
SUZUKI Shinsuke 160a74730e MFC 1.20 and 1.21 (typo and grammar fix) 2005-06-10 00:37:35 +00:00
John-Mark Gurney 7d8567585e back out previous commit as it breaks NFS.. 2005-06-09 20:04:04 +00:00
Wilko Bulte e1023bdedf Lucent FW322/323 == Lucent / Agere FW322/323
Triggered by: reading the chip markings when adding a FW card to my system.
2005-06-09 17:46:06 +00:00
Mark Santcroos 1b25bd644d MFC rev. 1.64: Use AcpiUtStrupr() instead of strupr() as the latter will
disappear in future versions of acpica.
2005-06-09 09:46:56 +00:00
Robert Watson 0fda32a251 Merge tcp_usrreq.c:1.124 from HEAD to RELENG_5:
When aborting tcp_attach() due to a problem allocating or attaching the
  tcpcb, lock the inpcb before calling in_pcbdetach() or in6_pcbdetach(),
  as they expect the inpcb to be passed locked.
2005-06-09 07:32:50 +00:00
Robert Watson 56e16ce2bb Merge raw_ip.c:1.150 from HEAD to RELENG_5:
Slight white space tweak.
2005-06-09 07:31:24 +00:00
Robert Watson bda82589ec Merge udp6_usrreq.c:1.54 from HEAD to RELENG_5:
Lock udbinfo and inp before calling in6_pcbdetach() from udp6_abort().
2005-06-09 07:30:20 +00:00
Simon L. B. Nielsen 2947f63b06 Fix several denial-of-service vulnerabilities in tcpdump.
Security:	FreeBSD-SA-05:10.tcpdump
Security:	CAN-2005-1267, CAN-2005-1278, CAN-2005-1279, CAN-2005-1280
Obtained from:	tcpdump.org

Correct directory traversal and race condition vulnerabilities in gzip.

Security:	FreeBSD-SA-05:11.gzip
Security:	CAN-2005-0988, CAN-2005-1228
Obtained from:	Steve Grubb via RedHat, Debian

Approved by:	nectar
2005-06-08 21:26:27 +00:00
Pyun YongHyeon f4bf1b1c9c MFC rev. 1.28: make snd_maestro3(4) mpsafe 2005-06-08 05:44:27 +00:00
Pyun YongHyeon f5aaf7b400 MFC rev. 1.36
According to STP2002QFP User's Guide, it seems that driver should
  program RXMAC to discard frames with SA field matching the stations's
  MAC address. Experimentation shows that HME receives its own frames
  when it operates at 10Mbps half-duplex. With this change HME runs at
  10Mbps half-duplx should work with IPv6.
2005-06-08 05:36:13 +00:00
Maxim Konovalov 55e16da3be MFC revs. 1.90 - 1.94: FreeBSD 5.4, MacOS 10.4, OpenBSD 3.7,
FreeBSD 1.1, 1.1.5, 1.1.5.1, 2.0 release dates.
2005-06-08 03:58:46 +00:00
Tim Kientzle e5030828be MFC: ZLib 1.2.2 (Part 2: Files unchanged from vendor distribution) 2005-06-08 03:41:03 +00:00
Tim Kientzle 3d1039f8d0 MFC: ZLib 1.2.2 (Part 1: files with FreeBSD-local changes) 2005-06-08 03:38:28 +00:00
Christian S.J. Peron d9b6918f3b MFC revision 1.11
date: 2005/06/05 23:49:35;  author: csjp;  state: Exp;  lines: +1 -1
Append a newline character to the usage string.
2005-06-08 02:48:16 +00:00
Andre Oppermann 2fb87a7972 MFC:
tcp_subr.c rev 1.225

 If we don't get a suggested MTU during path MTU discovery
 look up the packet size of the packet that generated the
 response, step down the MTU by one step through ip_next_mtu()
 and try again.

 Suggested by:	dwmalone
2005-06-07 11:43:15 +00:00
Andre Oppermann b62077d213 MFC:
ip_icmp.c 1.101

 Add another step of 1280 (gif(4) tunnels) to ip_next_mtu().
2005-06-07 11:41:07 +00:00
Andre Oppermann f7edcd10a2 MFC:
ip_icmp.c rev 1.99, ip_icmp.h rev 1.24, tcp_subr.c rev 1.223

 Move Path MTU discovery ICMP processing from icmp_input() to
 tcp_ctlinput() and subject it to active tcpcb and sequence
 number checking.

 Security:	draft-gont-tcpm-icmp-attacks-03.txt Section 7.2
2005-06-07 11:38:42 +00:00
Gleb Smirnoff 0d2e82b555 MFC 1.8:
Fix module build.
2005-06-07 07:49:49 +00:00
John-Mark Gurney 627f280059 MFC: v1.209
make sure that the socket is either accepting connections or is connected
when attaching a knote to it...  otherwise return EINVAL...
2005-06-07 07:11:03 +00:00
John-Mark Gurney 713f8e8d5c MFC: v1.91
make stat return an zero'd struct, and be a FIFO again...  This is only
  to fix libc_r since it requires stat to close fd's, and so commented in
  the code...
2005-06-07 06:35:10 +00:00
Wilko Bulte 1cda590cda When operating the diopter adjustment knob with your eye to the view-
finder, be careful not to put your fingers or fingernails in your eye.
                -- found in the users manual of the Nikon D2x camera,
                   a camera for professional photographers
%
2005-06-06 15:43:00 +00:00
Maxim Sobolev b784e5d367 MFC: wonderful recoverdisk utility. 2005-06-06 00:24:46 +00:00
Jens Schweikhardt cb9bd97c2a MFC: Chop a '>' in a feature name (RSVD2>) that snuck in;
this now balances the <> flags displayed at boot, e.g. without this
Features2=0x41d<SSE3,RSVD2>,MON,DS_CPL,CNTX-ID>
2005-06-05 08:44:08 +00:00
Christian S.J. Peron 08a5c36007 MFC revision 1.27
date: 2005/05/24 23:42:09;  author: csjp;  state: Exp;  lines: +1 -1
If sysctlbyname fails for kernel related reasons, tag the errno
string to the end of the error message. I think we used errx()
there when we really wanted an err().
2005-06-05 03:44:34 +00:00
Mark Murray 0566b9d73f MFC: Say what I really mean by my MAINTAINER status. 2005-06-04 11:55:39 +00:00
Marcel Moolenaar 02c58518f0 MFC rev. 1.20: Fix the load64 and store64 macros. 2005-06-04 05:38:31 +00:00
Hajimu UMEMOTO 8e80413c87 MFC 1.54: reduce cast. 2005-06-03 04:57:50 +00:00
Hajimu UMEMOTO 2513da796e MFC 1.21 (partly): reflect type change of n_net. 2005-06-03 04:51:49 +00:00
Hartmut Brandt 8e878407dd Fix a bug in suffix parsing. Under certain circumstances the code
would access memory before the beginning of the string to match (the
suffix match starts from the end of both the suffix and the string
to match and proceedes until either the start of the suffix is hit or
the character does not match). This could lead to a memcpy copying
into random memory. This leads to make dumping core on amd64 (on i386
the overwritten memory for some reason does not cause a core dump).
Fix this by checking the length of the string too.

MFC of:		1.57
Submitted by:	Matt Dillon <[email protected]>
Tested by:	Julian H. Stacey <[email protected]>
MFC after:	2 weeks
2005-06-02 09:17:22 +00:00
Warner Losh db1bf4d6ab Update details for updating to 5.x from 4.x:
o Note non-standard /usr/src and /usr/obj gotchas
o No need for mount -u / before mount -a
o Note pam gotchas
o Note /lib
o Note named issue
2005-06-02 09:04:00 +00:00
Warner Losh cb22666396 Minor simplification 2005-06-02 08:27:26 +00:00
John Baldwin 5b955be72d Add support for the SATA controller in the ICH6 mobile part. Note this
isn't really an MFC since support for this part was part of the ata mkIII
mega commit.

PR:		kern/80656
Submitted by:	Vlad Galu vladgalu at gmail dot com
2005-06-01 14:39:23 +00:00
John Baldwin d27669234d MFC: Actually use the iterating variable in the for loop to set
shminfo.shmmax.
2005-06-01 14:17:35 +00:00
John Baldwin b25c2180cc MFC: Add NTP servers for Japan. 2005-06-01 14:12:24 +00:00
John Baldwin 0dac1c2ff8 MFC: Update the current NTP servers for .nl.
PR:		bin/80659
2005-06-01 14:11:25 +00:00
Marcel Moolenaar 587add233a MFC 1.51: In bus_dmamap_load(), temporarily point the segments pointer
in the DMA tag to a local variable so that we don't dereference a NULL
pointer.

PR: alpha/30486
2005-06-01 05:14:57 +00:00
David Schultz 967e483e60 MFC rev 1.1, 1.2:
More optimized math functions.

  Prevent these functions from using stack outside of their frame.
2005-05-31 22:17:08 +00:00
David Schultz f768ec06e6 MFC rev 1.2:
Prevent these functions from using stack outside of their frame.
2005-05-31 22:16:54 +00:00
Maksim Yevmenkin f792d29609 MFC to RELENG_5
Do not treat 128-bit UUID as int128. Provide separate macros to get/put
128-bit UUID in libsdp(3). Fix 128-bit UUID printing in sdpcontrol(8).
2005-05-31 16:55:05 +00:00
Maksim Yevmenkin c3d5784aff MFC to RELENG_5
Move AVM USB Bluetooth-Adapter BlueFritz! from "broken" devices list
(where I incorrectly put it initially) to "ignored" devices list (where
it should be). Pointy hat goes to me.
2005-05-31 16:47:19 +00:00
Peter Wemm 84513296aa Remove unused (but initialized) variables. Merge 1.635 - set PCB_FULLCTX
so that all of the registers that a debugger tries to set are used..
2005-05-30 18:22:28 +00:00
Maxim Konovalov 589940d872 MFC rev. 1.68: terminate an endless loop sh -T goes into in dowait()
around waitproc().
2005-05-30 13:41:59 +00:00
Hajimu UMEMOTO cd45841cb7 MFC 1.79:
- do DNS lookup for symbolic names specified for a destination
  or gateway.
- improves error reporting using gai_strerror(3) instead of
  printing "bad value".
- remove "0" for servname argument for getaddrinfo(3).
2005-05-30 04:04:54 +00:00
Bruce A. Mah a9cb8645d5 Remove dangling reference to the no-longer-existant-in-this-branch
Migration Guide.

Pointed out by:	keramida
2005-05-29 17:32:27 +00:00
Hajimu UMEMOTO 05fc4073c5 MFC 1.36: add targets for ipnodes.byname and ipnodes.byaddr which
carries IPv6 addresses.  these targets are off by default, and
these are built when there is /var/yp/ipnodes.
2005-05-29 17:06:09 +00:00
Hajimu UMEMOTO 0ef3664db0 MFC: teach IPv6 to async DNS resolver in ypserv:
- query AAAA RR on ipnodes.byname query.
  - query .ip6.arpa. on ipnodes.byaddr query.

	usr.sbin/ypserv/yp_dnslookup.c:	1.26
	usr.sbin/ypserv/yp_extern.h:	1.17
	usr.sbin/ypserv/yp_server.c:	1.38, 1.39
2005-05-29 16:08:39 +00:00
Pawel Jakub Dawidek d8c7f0e775 MFC: named 1.22
We need to use 'applyset' command for devfs, 'apply hide' is not enough,
because new devfs entries can show up later and one can access such entires
from inside named's chroot.
In rc.d scripts we can use devfs_domount() function with devfsrules_hide_all
policy and unhide 'null' and 'random' manually.
2005-05-29 10:36:37 +00:00
Christian Brueffer 902a145612 MFC: rev. 1.264 by simon
Add snd_audiocs(4).
2005-05-29 10:34:38 +00:00
Christian Brueffer 42586860f1 MFC: rev. 1.281
Sort the sound section by driver name.  The exception to this is sound(4),
which is the master driver and will hopefully be renamed to snd(4) soon.
2005-05-29 10:29:21 +00:00
Hajimu UMEMOTO 33bfde0a40 MFC: The ai_addrlen of a struct addrinfo used to be a size_t, per RFC
2553.  In XNS5.2, and subsequently in POSIX-2001 and RFC 3493, it was
changed to a socklen_t.  And, the n_net of a struct netent used to be
an unsigned long integer.  In XNS5, and subsequently in POSIX-2001, it
was changed to an uint32_t.  To accomodate for this while preserving
ABI compatibility with the old interface, we need to prepend or append
32 bits of padding, depending on the (LP64) architecture's endianness.

	include/netdb.h:		1.36 (partly)
	lib/libc/net/getaddrinfo.c:	1.69
	lib/libc/net/getnetbydns.c:	1.30
	lib/libc/net/getnetbyht.c:	1.15
	lib/libc/net/getnetbynis.c:	1.18
	lib/libc/net/getnetnamadr.c:	1.20 (partly)
	lib/libc/net/netdb_private.h:	1.9
2005-05-29 10:21:38 +00:00
Christian Brueffer 1207bdd88d MFC:
- Autogenerate device listings for sound(4) aka pcm(4)
- Rename the Audio Devices section into Sound Devices, this is more
  in line with out sound and snd_* drivers
2005-05-29 10:20:13 +00:00
Christian Brueffer 4775fdc8e6 MFC: rev. 1.39
- Add a HARDWARE section based on the previous 'Supported Cards'
  subsection and the hardware notes.
- Xref all snd_* drivers
2005-05-29 10:17:29 +00:00
Gleb Smirnoff dc1bedc34f Fix mismerge. Unbreak kernel build. Please tinderbox. Put on pointy hat.
Phone call from:	maxim
2005-05-28 18:25:52 +00:00
Hajimu UMEMOTO e956878508 MFC: NI_WITHSCOPEID cleanup
contrib/tcp_wrappers/hosts_access.c:		1.5
	contrib/tcp_wrappers/socket.c:			1.8
	contrib/telnet/telnetd/telnetd.c:		1.28
	lib/libc/net/rcmd.c:				1.41
	lib/libc/net/res_send.c:			1.50
	lib/libpam/modules/pam_unix/pam_unix.c:		1.50
	lib/libutil/logwtmp.c:				1.20
	lib/libutil/realhostname.c:			1.18
	libexec/rlogind/rlogind.c:			1.44
	libexec/tftpd/tftpd.c:				1.36
	release/picobsd/tinyware/login/pico-login.c:	1.6
	sbin/ifconfig/af_inet6.c:			1.2
	sbin/route/route.c:				1.78
	usr.bin/netstat/route.c:			1.76
	usr.sbin/inetd/inetd.c:				1.129
	usr.sbin/lpr/common_source/net.c:		1.9
	usr.sbin/lpr/lpd/lpd.c:				1.41
	usr.sbin/mountd/mountd.c:			1.81
	usr.sbin/ppp/ncpaddr.c:				1.16
	usr.sbin/rip6query/rip6query.c:			1.7
	usr.sbin/syslogd/syslogd.c:			1.143
2005-05-28 11:54:38 +00:00
Seigo Tanimura eb25d55723 MFC 1.52: 6300ESB. 2005-05-28 09:41:40 +00:00
Christian Brueffer 99cd132bc7 MFC: rev. 1.31
Document support for some Dell PERC adapters.
2005-05-28 07:17:51 +00:00
Hajimu UMEMOTO 0fa05f1d52 MFC 1.38: fixed a bug that incorrect IPsec request level may be
returned for proto AH
2005-05-27 19:49:16 +00:00
Gleb Smirnoff 5d413408d2 MFC:
Make netgraph ISR and callout MPSAFE.
2005-05-27 14:51:32 +00:00
Gleb Smirnoff 4a35053bc8 MFC:
Use uma(9) for allocating netgraph items:
    - ng_getqblk() simply runs uma_zalloc().
    - ng_free_item() simply frees.
    - ngq_mtx is pushed down under NETGRAPH_DEBUG.
    - NGQF_FREE is removed.

  Increase default maxalloc to 512.

  Reviewed by:    julian
2005-05-27 14:48:35 +00:00
Gleb Smirnoff 1c1d04785d Make NETGRAPH_DEBUG a kernel option, so that it can be turned off
without hacking source.

  In collaboration with:  ru, julian
2005-05-27 14:22:30 +00:00
Gleb Smirnoff 69be04639a MFC:
In div_output() explicitly set m->m_nextpkt to NULL. If divert socket
  is not userland, but ng_ksocket, then m->m_nextpkt may be non-NULL. In
  this case we would panic in sbappend.
2005-05-27 12:32:29 +00:00
Gleb Smirnoff d7c2f304d4 MFC:
When used as divert socket we need to decouple stack when node is entered
  from socket side. Use ng_queue_fn() instead of ng_send_fn().
2005-05-27 12:31:49 +00:00
Gleb Smirnoff 91c01004cf MFC:
Since there is no way to queue a function call to node, create
  ng_queue_fn() - a queue version of ng_send_fn().
2005-05-27 12:31:29 +00:00
Gleb Smirnoff bc3ce4b770 Add vnode_if.h to SRCS. 2005-05-27 12:05:24 +00:00
Gleb Smirnoff 35727aa6dc MFC:
1.30: Remove extra ifnet pointer from private data. It can be accessed via arpcom.
  1.29: Remove ng_connect_t where it is unused.
  1.28: Use subr_unit allocator instead of own functions.
2005-05-27 12:04:13 +00:00
Gleb Smirnoff 49a3518f77 MFC 1.40:
Use subr_unit allocator instead of own functions.
2005-05-27 12:03:11 +00:00
Gleb Smirnoff abd3224c1b MFC:
o Use subr_unit allocator. This simplifies code much:
    - Remove get_free_unit().
    - Remove SLIST of nodes.
    - Remove global mutex.

  o Increase NGD_MAX to 999.
  o Move ngd_mod_event() up to netgraph methods.
2005-05-27 12:02:35 +00:00
Gleb Smirnoff a8ae72f3a2 Merge kernel unit allocator.
Approved by:	phk
2005-05-27 11:58:01 +00:00
Olivier Houchard 145291ba4a MFC rev 1.50:
Fix one more misuse of u_long when uint32_t is actually meant.

Submitted by:   oliver
2005-05-27 00:40:06 +00:00
Alfred Perlstein f5a9deaef7 MFC: 1.48 utimes/chflags. 2005-05-26 22:51:04 +00:00
Alfred Perlstein be3cdfdd1c MFC:
When doing the initial open of the proc via procfs, complain if we are
unable to open the /proc/pid/mem file.  Otherwise doing a truss on
a nonexistant pid makes us return success even though no such process
exists.

I've been working on this somewhat so I'm moving the
parts I'm touching to be as style(9) compliant as I can.
2005-05-26 21:26:00 +00:00
Alfred Perlstein f822c551c8 MFC: procctl doc xref. 2005-05-26 20:50:46 +00:00
Alfred Perlstein 839dac6f63 MFC: 1.46, 1.47 2005-05-26 20:47:29 +00:00
Stefan Farfeleder 03487716fb MFC 1.3:
The header glue.h should provide just a declaration for the variable
__sglue, not a definition.
2005-05-26 19:51:59 +00:00
Bruce A. Mah 2fdafa2304 MFC: autoboot_delay -1, sed(1) -l. 2005-05-26 14:43:26 +00:00
Andrey A. Chernov dcd5cd68a1 MFC: 1.20 printed output flags (onocr) and (onlret)
PR:             81256
2005-05-26 09:42:18 +00:00
Doug Rabson 36eb82ceb5 MFC: Align stack for SSE. 2005-05-26 09:33:28 +00:00
Doug Rabson a9c42fe97f MFC: r1.4 - align stack for SSE. 2005-05-26 09:32:41 +00:00
Adam Weinberger ca5abd1961 MFC rmuser.sh 1.9: Fix a particularly egregious grammar error.
It's not that I mind the implication that a user's name owns a
punctuation mark, but I think life is simpler this way.

Approved by:	ssouhlal and wes
2005-05-26 04:21:53 +00:00
Christian S.J. Peron 8ac172db52 MFC revision 1.144
date: 2005/05/19 21:09:44;  author: csjp;  state: Exp;  lines: +2 -0
Add cases for ENOBUFS and ENETDOWN. We need to make sure that we
catch all transient errors. This fixes situations where transient
error conditions such as network interfaces losing carrier signals
or the system running out of mbufs would result in the permanent
removal of forwarding syslog messages.
2005-05-26 00:31:38 +00:00
Sheldon Hearn 8299c3e96e MFC rev 1.11: release maintainership 2005-05-25 16:32:14 +00:00
Peter Edwards 6536ab4a13 MFC 1.15:
lockmgr(...,LK_DRAIN,...) requires a balancing LK_RELEASE.
    Remove an unused variable.
2005-05-25 16:27:43 +00:00
Christian Brueffer 49512f0545 MFC: rev. 1.17 + 1.18
Document support for the 5714 and 5789.
2005-05-25 15:44:10 +00:00
Christian Brueffer 8b95e9320b MFC:
soundcard -> sound card
2005-05-25 15:41:28 +00:00
Xin LI 32f06706ad MFC 1.65(phk):
Do not attach MBR on top of an MBR.

Approved by:	phk
2005-05-25 12:57:02 +00:00
Paul Saab 99ebad331c MFC: rev 1.32 copyout to userland if kern_sigaction succeeds 2005-05-24 17:53:27 +00:00
Christian Brueffer 9f5f99f45d MFC:
3Com 3C2000-T reported as working.
2005-05-24 15:44:02 +00:00
Maksim Yevmenkin eaa9a6b2a9 MFC to RELENG_5
Fix problem with session termination. bthidd(8) maintains two L2CAP
connections to Bluetooth HID device. As soon as Bluetooth HID device
is powered off (or goes out of RF range) the stack will terminate both
connections. File descriptors for both connections will become active
on next select(2) call. Because bthidd(8) processes file descriptors
in order, it will detect descriptor for one of the closed connections
first and kill the session. However, there is still a second (active)
descriptor that used to point to the same session. bthidd(8) used to
assert() if it cant find session by file descriptor, which was wrong.

While I'm here fix a couple of typos in parser.y

Reported by:    Eric Anderson anderson AT centtech DOT com
2005-05-23 19:52:54 +00:00
Maxim Sobolev fa5cbb8f84 MFC: add cdce(4). 2005-05-23 16:25:11 +00:00
Maxim Sobolev 8c2fe34d77 MFC: Don't allow user to interrupt autoboot from console when autoboot_delay
is set to -1.
2005-05-23 14:59:33 +00:00
Gleb Smirnoff 1081fe35be MFC:
Add option -l, to make output line buffered.

  PR:             bin/78692
  Submitted by:   Eugene Grosbein
2005-05-23 13:27:49 +00:00
Christian Brueffer ea41a50b34 MFC:
New release notes:

- uaudio(4) sync
- bge(4) support for BCM5714 and 5789
- ixgb(4) MPSAFE
- xl(4) polling
2005-05-23 12:25:15 +00:00
Bruce A. Mah 833b638749 Grrr. Put the SA-05:09.htt item in the security advisories section,
not the open issues section.

Pointy hat to:			bmah
Needs to call it a night:	bmah
2005-05-23 03:35:17 +00:00
Bruce A. Mah ce35c6ad5b Somewhat belatedly, add an errata entry for SA-05:09.htt. 2005-05-23 02:47:21 +00:00
Bruce A. Mah 4eff86bc80 MFC: gethostby*(3) thread-safe, getnetby*(3) thread-safe. 2005-05-23 02:39:51 +00:00
Bruce A. Mah ab161a08c8 MFC: New ndisulator driver generation procedure, getproto*(3)
thread-safe, getserv*(3) thread-safe, kldstat(8) -m, default stack
size increases.
2005-05-22 18:25:20 +00:00
Bill Paul dd88210dac Sync everything up with -current, except for the WPA support, which
won't work with the 5.x version of net80211. This includes all fixes
to date, and support for new cards such as the AirGo MIMO and Ralink
RT2500. This also includes the new driver configuration/conversion
mechanism. Remember that you should use ndisgen(8) to create new
drivers now, and if_ndis.ko will always be pre-built.
2005-05-22 18:18:13 +00:00
Mike Silbersack 8b0d180036 MFC: Add PCI ID for BCM5789. 2005-05-22 03:17:49 +00:00
Poul-Henning Kamp 556b0da6c4 MFC:
Make make.conf overridable (remember absolute path!)
	Add newfs params for space saving
	call Customize/files by default
2005-05-20 11:04:50 +00:00
Poul-Henning Kamp 183a0e6335 MFC:
Add standard admin scripts
2005-05-20 09:54:23 +00:00
Poul-Henning Kamp b02ba21078 MFC:
add the files and pkgs customize scripts
2005-05-20 09:51:46 +00:00
Christian S.J. Peron 27bdbb77fb MFC revision 1.622
date: 2005/05/02 02:07:55;  author: csjp;  state: Exp;  lines: +2 -4
Since it is not possible for curthread to be NULL in this context,
drop the check+initialization for a straight initialization. Also
assert that curthread will never be NULL just to be sure.
2005-05-20 04:16:47 +00:00
Paul Saab af26cc7b01 MFC: support for the 5714 2005-05-19 21:12:04 +00:00
Jesus R. Camou ee041169c6 MFC: Correct path to package-split.py.
Approved by:	trhodes (mentor)
2005-05-19 16:10:31 +00:00
cvs2svn 72d8960f33 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-05-19 15:23:48 +00:00
Bruce A. Mah 660675189b MFC: SA-05:09.htt. 2005-05-19 14:46:54 +00:00
Gleb Smirnoff ee22597c16 MFC:
Add startup script and default configuration file for bsnmpd.
  Reviewed by:    harti
2005-05-19 11:35:15 +00:00
Poul-Henning Kamp 6ae6de50c7 MFC:
reorganize pruning in size order.
2005-05-19 11:27:18 +00:00
Poul-Henning Kamp 92cf63c022 MFC:
add NANOBSD_PRUNE support
2005-05-19 11:26:25 +00:00
Poul-Henning Kamp 7e3c7a43a5 MFC:
use df -i, we can run out of inodes as well.
2005-05-19 11:25:58 +00:00
Hajimu UMEMOTO 15441213d8 MFC: our get{addr,name}info() is considered thread-safe.
lib/libc/net/getaddrinfo.3:	1.31
	lib/libc/net/getnameinfo.3:	1.23
2005-05-19 11:12:45 +00:00
Hajimu UMEMOTO 06ac63058e MFC:
- _gethostbynis{addr,name}() can handle an IPv6, now.
- we don't need mutex lock to call _gethostbynis*(), anymore.
- raise readability bit.

	lib/libc/net/getipnodebyname.3:	1.17
	lib/libc/net/name6.c:		1.47-1.50, 1.52
2005-05-19 11:11:09 +00:00
Gleb Smirnoff 2047c23a11 Merge a small piece of code from HEAD, that suppresses carp(4) preemption
until pfsync(4) has synchronized.

Reviewed by:	dhartmei, mlaier
Sponsored by:	Rambler
2005-05-19 10:59:22 +00:00
Gleb Smirnoff 9f5d8f34ef MFC 1.7:
- Document net.inet.carp.suppress_preempt MIB.
  - Xref pfsync(4)
2005-05-19 10:57:01 +00:00
Hajimu UMEMOTO cdcf6a56c3 MFC: sync _map_v4v6_host*() with bind9's. it treats align better bit.
lib/libc/net/gethostbydns.c:	1.52
	lib/libc/net/gethostnamadr.c:	1.26
	lib/libc/net/map_v4v6.c:	1.9
	lib/libc/net/netdb_private.h:	1.8
2005-05-19 10:57:00 +00:00
Gleb Smirnoff 1c554fdde5 MFC 1.24:
- When carp interface is destroyed, and it affects global preemption
    suppresion counter, decrease the latter. [1]
  - Add sysctl to monitor preemption suppression.

  PR:             kern/80972 [1]
  Submitted by:   Frank Volf [1]
2005-05-19 10:55:14 +00:00
Hajimu UMEMOTO 650ffd58c5 MFC:
- add IPv6 awareness for NIS query of gethostby*().
- make gethostby*() thread-safe.
- do validation check and IPv4-mapped IPv6 address handling before
  any query.
- don't query against IPv6 link-local address.
- use IN6_IS_ADDR_V4{MAPPED,COMPAT} macros.
- use memcpy() instead of bcopy().

	lib/libc/net/gethostbydns.c:	1.51, 1.53, 1.54
	lib/libc/net/gethostbyht.c:	1.19-1.23
	lib/libc/net/gethostbyname.3:	1.33, 1.34
	lib/libc/net/gethostbynis.c:	1.18-1.25
	lib/libc/net/gethostnamadr.c:	1.25, 1.27, 1.28
	lib/libc/net/netdb_private.h:	1.7
2005-05-19 10:46:14 +00:00
Gleb Smirnoff 3490112e9f MFC 1.63:
Run em_local_timer() once per second instead of running it once per 2 seconds.
  This makes gathering of error stats more precise, and netstat(1) output look
  right.

  Reviewed by:    tackerman
2005-05-19 08:23:06 +00:00
Pawel Jakub Dawidek cf53a3fdba MFC: geom_sunlabel.c 1.44
Protect against recursive labels creation in simlar way as it is done
in BSD and MBR classes, ie. if provider below us uses the same metadata,
don't create labels based on the metadata.
This allows to create labels on geoms with rank != 1 without hacks.
2005-05-18 21:50:14 +00:00
Hajimu UMEMOTO ebcfd3e3d0 ensure parsing numeric address before any host query.
lib/libc/net/gethostbydns.c:	1.49
	lib/libc/net/gethostnamadr.c:	1.23
2005-05-18 16:01:24 +00:00
Hajimu UMEMOTO 22c6fe4a87 make getnetby*() thread-safe.
lib/libc/net/getnetbydns.c:	1.29
	lib/libc/net/getnetbyht.c:	1.13, 1.14
	lib/libc/net/getnetbynis.c:	1.16, 1.17
	lib/libc/net/getnetent.3:	1.20
	lib/libc/net/getnetnamadr.c:	1.19
	lib/libc/net/getprotoent.c:	1.5
	lib/libc/net/getservent.c:	1.19
	lib/libc/net/netdb_private.h:	1.6
2005-05-18 15:58:15 +00:00
Christian S.J. Peron 4818dd318b MFC
Move MAC check_vnode_mmap entry point out from being exclusive to
MAP_SHARED so that the entry point gets executed un-conditionally.
This may be useful for security policies which want to perform access
control checks around run-time linking.

-add the mmap(2) flags argument to the check_vnode_mmap entry point
 so that we can make access control decisions based on the type of
 mapped object.
-update any dependent API around this parameter addition such as
 function prototype modifications, entry point parameter additions
 and the inclusion of sys/mman.h header file.
-Change the MLS, BIBA and LOMAC security policies so that subject
 domination routines are not executed unless the type of mapping is
 shared. This is done to maintain compatibility between the old
 vm_mmap_vnode(9) and these policies.
2005-05-18 00:32:05 +00:00
Alan Cox 95a341165c MFC
Add locking and enable INTR_MPSAFE.  Eliminate spl calls.
2005-05-17 21:41:11 +00:00
Maksim Yevmenkin cc6189faf2 MFC to RELENG_5
while i'm here MFC ru's changes as well. Sort sections.
2005-05-17 18:06:23 +00:00
Maksim Yevmenkin 33206b52ef MFC to RELENG_5
ng_ubt(4) no longer provides device nodes interface. Update the
man page to document this.
2005-05-17 18:01:01 +00:00
Maksim Yevmenkin f33f4ec792 MFC to RELENG_5
Get rid of device nodes interface. It is useless and confusing.
The original idea was to use it for firmware upgrading and similar
operations. In real life almost all Bluetooth USB devices do not
need firmware download. If device does require firmware download
then ugen(4) (or specialized driver like ubtbcmfw(8)) should be
used instead.
2005-05-17 17:56:28 +00:00
Maksim Yevmenkin b412b2b7d3 MFC to RELENG_5
Mark AVM USB Bluetooth-Adapter BlueFritz! as "broken". This device is not
supported by ng_ubt(4) driver and needs its own driver.

PR:		kern/76205
Submitted by:	Tim Hemel < bsd AT timit DOT nl >
2005-05-17 17:30:25 +00:00
Kris Kennaway 2e1cd80a4f MFC: Enable mpsafevm by default on sparc64.
Approved by:	alc
2005-05-16 19:10:58 +00:00
Hajimu UMEMOTO c90a8bac77 MFC: hide implementation specific internal functions from netdb.h.
include/netdb.h:		1.35
	lib/libc/net/gethostbydns.c:	1.50
	lib/libc/net/gethostbyht.c:	1.18
	lib/libc/net/gethostnamadr.c:	1.24
	lib/libc/net/getnetnamadr.c:	1.18
	lib/libc/net/name6.c:		1.46
	lib/libc/net/netdb_private.h:	1.5
2005-05-16 18:28:19 +00:00
Hajimu UMEMOTO c96e7f66f3 MFC: our get{proto,serv}by*() use a thread-specific data space.
lib/libc/net/getprotoent.3:	1.11
	lib/libc/net/getservent.3:	1.14
2005-05-16 17:18:50 +00:00
Hajimu UMEMOTO b1be707c9c MFC: make getproto{byname,bynumber,ent} thread-safe.
lib/libc/net/getproto.c:	1.4
	lib/libc/net/getprotoent.c:	1.4
	lib/libc/net/getprotoname.c:	1.4
	lib/libc/net/netdb_private.h:	1.4
2005-05-16 17:13:21 +00:00
Hajimu UMEMOTO 34d949d43c MFC:
- we are no longer shareing any resources to be locked between
  getaddrinfo(3) and getipnodeby*(3).
- use definitions in reentrant.h.
- remove obsolete comment.
- now, our getservbyname(3) is thread-safe.  So, we don't need
  to protect it with mutex lock.

	lib/libc/net/getaddrinfo.c:	1.62, 1.65
	lib/libc/net/name6.c:		1.43, 1.44
2005-05-16 17:02:01 +00:00
Hajimu UMEMOTO b051132820 MFC: make getserv{byname,byport,ent} thread-safe.
lib/libc/net/getservbyname.c:	1.5-1.7
	lib/libc/net/getservbyport.c:	1.5-1.7
	lib/libc/net/getservent.c:	1.14-1.18
	lib/libc/net/netdb_private.h:	1.1-1.3
2005-05-16 16:29:04 +00:00
Hajimu UMEMOTO 2507ae8a57 MFC 1.17: fix signed/unsigned comparison warnings. 2005-05-16 16:07:45 +00:00
Hajimu UMEMOTO e59ca104fe MFC 1.60, 1.67: make yp stuff re-entrant. 2005-05-16 15:53:50 +00:00
Max Khon 12cbe5a1b2 MFC:
- Use kldstat -m (finds geom_uzip even if it is compiled in statically).
- Create output files with x bit set.
- Make mkuzip 64-bit clean.
- Fix typo in error message.
- Enable mkuzip on all archs.
2005-05-16 15:10:15 +00:00
Max Khon a5a18ace3a MFC: Document kldstat -m modname. 2005-05-16 15:05:22 +00:00
Max Khon 75c8bc2bab MFC: Add -m modname option (find module by name). 2005-05-16 15:01:00 +00:00
Gleb Smirnoff 0105a9d1aa MFC 1.13:
- Return error, if there was one.
  - No need to initialize error here.
2005-05-16 12:44:32 +00:00
Gleb Smirnoff 4a1479121a MFC 1.28:
NG_MKRESPONSE() macro includes sizeof struct ng_mesg when doing allocation.
2005-05-16 12:43:36 +00:00
Tim Kientzle f54806cfe2 MFC several libarchive bugfixes:
* "make distfile" uses correct automake/autoconf commands
   * Rewrite path shortening to avoid crash on certain paths
       between 245 and 255 characters long
   * Fix broken ACL configuration on FreeBSD 4 and Linux
   * Fix GNU tar long symlink handling
2005-05-16 04:37:59 +00:00
Tim Kientzle c8b6063b2c MFC: Zip improvements (large files, Unix metadata, faster listing)
The bulk of this is from archive_read_support_format_zip.c 1.5 with
minor supporting changes to several other files.
2005-05-16 04:32:16 +00:00
Tim Kientzle baf971cc70 MFC
Makefile 1.32, archive_entry.c 1.25, archive_entry.h 1.13,
   archive_read_extract.c 1.38

Support extracting very long pathnames.
2005-05-16 02:54:04 +00:00
Tim Kientzle c18fffe04c MFC a number of small changes from about 2 months ago:
archive_write_open_file.c 1.11: Non-regular files can be added
         to an archive, even if output is going to that file.
 archive_read_support_compression_gzip.c 1.9: better error messages
 archive_read_open_file.c 1.8: better error messages
 archive_read_support_format_cpio.c 1.12: better handling of I/O errors
 archive_read_support_format_tar.c 1.31: better error handling
2005-05-16 02:47:34 +00:00
Robert Watson a5c0564437 Merge in_pcb.c:1.163 from HEAD to RELENG_5:
o Tweak the comment a bit.
2005-05-16 00:00:38 +00:00
Alan Cox be6cc49b5f MFC
Add machine-specific, optimized implementations of bcmp, bcopy, bzero,
 memcmp, memcpy, memmove, and memset.
2005-05-15 20:26:48 +00:00
cvs2svn e5a62f0b6a This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-05-15 20:15:16 +00:00
Dag-Erling Smørgrav 94dc8f1835 MFC: add pentium-m, spell pentiumpro correctly, move nocona to Intel 2005-05-15 11:46:20 +00:00
Christian Brueffer 2a5a80dc7d MFC: rev. 1.14
Fix typo.
2005-05-15 07:19:51 +00:00
Christian Brueffer 16fed7ad89 MFC: rev. 1.15
Wordsmithing.
2005-05-15 07:15:06 +00:00
Joe Marcus Clarke 1bf995915e MFC rev 1.115:
Add libdata/pkgconfig.  It is used under ${LOCALBASE} as much (if not more)
than under ${X11BASE}.
2005-05-14 19:47:53 +00:00
Lukas Ertl 40a119731a MFC:
Only allow RAID5 plexes to be parity checked.

   PR:           kern/80427
   Submitty by:  Stijn Hoop <[email protected]>
--
   Don't allow to synchronize a plex that is already sychronizing.

   Reset the 'syncing' flag in case of errors, too.

   Some cosmetics.
2005-05-14 14:55:47 +00:00
Lukas Ertl 4ec0abac24 MFC:
Remove test for zero sectorsize when tasting.  This check doesn't
  seem to be necessary anymore, and it prevents tasting a valid drive
  when booting with geom_vinum already loaded, since SCSI disks set their
  sectorsize not until first opening them.
2005-05-14 14:54:49 +00:00
Lukas Ertl ba4933de51 MFC:
Add support for Sitecom USB to serial cable (v2)

    PR:            usb/79230
    Submitted by:  Rick van der Zwet <[email protected]>

MFC reminder by: n_hibma
2005-05-14 14:47:19 +00:00
Christian Brueffer 70da2f9c71 MFC: rev. 1.56
Fix three typos in comments.  Two of them obtained from OpenBSD.
2005-05-14 08:50:35 +00:00
Vinod Kashyap 675ac7d678 Corrected driver version. 2005-05-13 19:59:09 +00:00
Hajimu UMEMOTO 2aa8f2cdaa MFC 1.47-1.49: do mutex lock for each yp calls. 2005-05-13 17:06:52 +00:00
Gleb Smirnoff 58528668ff MFC 1.109:
- refactor changes introduced in rev. 1.100: do not prepend a new tag
  unconditionally. Before doing this check whether we have one.
2005-05-13 11:47:41 +00:00
Christian Brueffer 0284a2d2bc MFC:
Manual page for the "mn" Siemens Easy321-R1 E1/T1 device driver.
This is based on the comments in if_mn.c.
2005-05-13 07:08:06 +00:00
Jacques Vidrine 7ddcececdc Add a knob for disabling/enabling HTT, "machdep.hyperthreading_allowed".
Default off due to information disclosure on multi-user systems.

Submitted by:	cperciva
Reviewed by:	jhb
2005-05-13 00:10:56 +00:00
Maksim Yevmenkin e0ba1610eb MFC to RELENG_5 src/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c, v1.17
In ng_btsocket_rfcomm_receive_frame() correctly set length variable when
EA bit is set in hdr->length (16-bit length). This currently has no effect
on the rest of the code. It just fixes the debug message.
2005-05-12 16:48:24 +00:00
Maksim Yevmenkin 0b88d9c070 MFC sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c,v 1.16
move ptr use down to after null check

Noticed by:	Coverity Prevent analysis tool
Submitted by:	sam
2005-05-12 16:45:10 +00:00
Brian Feldman efb93e779a MFC: IPFW ALTQ(4) classification support, diverted traffic match rules,
and the TCP packet data length match rule.
2005-05-12 15:11:30 +00:00
Philip Paeps 81791e665b The long-procrastinated sync of acpi_asus(4) with CURRENT.
MFC acpi_asus.c r1.12 - r1.24
    acpi_asus.4 r1.5 - 1.9
2005-05-12 12:37:19 +00:00
Giorgos Keramidas 36c98d9ba9 MFC 1.18: There is no /etc/rc.network anymore. 2005-05-12 10:08:45 +00:00
Dag-Erling Smørgrav 6b25dcdcea MFC: (1.10) record xdm logins in lastlog / wtmp / utmp. 2005-05-12 08:36:40 +00:00
Maksim Yevmenkin a47e52c295 MFC to RELENG_5
Change m_uiotombuf so it will accept offset at which data should be copied
to the mbuf. Offset cannot exceed MHLEN bytes. This is currently used to
fix Ethernet header alignment problem on alpha and sparc64. Also change all
users of m_uiotombuf to pass proper offset.

Reviewed by:	jmg, sam
Approved by:	re
2005-05-11 21:54:44 +00:00
Matthew N. Dodd a5c692532b MFC: 1.219
Replace spl protection in rtcin() and writertc() with spinlocks
using the existing clock_lock mutex.
2005-05-11 20:02:16 +00:00
Jesus R. Camou 909553e66d o Revert the cuaa->cuaad changes done by error
in previous MFC.

o MFC the last change done in HEAD by brian@:
  Delete the tun N section.

Reviewed by:	brian
Approved by:	trhodes (mentor, implicitly)
2005-05-11 18:51:06 +00:00
Joe Marcus Clarke 9398b7a4d0 Increment __FreeBSD_version for the thread stacksize changes. 2005-05-11 15:57:39 +00:00
Joe Marcus Clarke 6cefbed18f MFC:
Increase the default stacksizes:

              32-bit  64-bit
main thread     2MB     4MB
other threads   1MB     2MB

Approved by:    eischen
                re (scottl no longer objects since 5.4 is out)
2005-05-11 15:56:04 +00:00
Joe Marcus Clarke 5f82bdf6f2 MFC:
Increase the default stacksizes:

              32-bit  64-bit
main thread     2MB     4MB
other threads   1MB     2MB

Approved by:    mtm
                re (scottl no longer objects since 5.4 is out)
2005-05-11 15:55:41 +00:00
Joe Marcus Clarke 9f01ba12a0 MFC:
Increase the default stacksizes:

		32-bit	64-bit
main thread	2MB	4MB
other threads	1MB	2MB

Approved by:	eischen
		re (scottl no longer objects since 5.4 is out)
2005-05-11 15:54:51 +00:00
Gleb Smirnoff 62bb875101 MFC 1.94:
With recent changes to _callout_stop_safe() we can remove a hack
  in ng_uncallout().
2005-05-11 11:41:26 +00:00
Gleb Smirnoff 785c2b576c MFC 1.94, 1.95 (cperciva):
Make "c->c_func = NULL" conditional on the CALLOUT_LOCAL_ALLOC flag,
  i.e., only clear c->c_func if the callout c is being used via the old
  timeout(9) interface.
2005-05-11 11:38:14 +00:00
Maxim Konovalov de2b6114c6 MFC rev. 1.22 and rev. 1.23: fix a comment. 2005-05-11 10:59:47 +00:00
Gleb Smirnoff a103ade72e Sync with HEAD:
- 1.9, joel. Expand contractions.
- 1.8, Reword HOOKS paragraph also mentioning how data received on out* hooks
       is handled.
- 1.7, Describe usage of newly implemented out* hooks.
2005-05-11 10:52:17 +00:00
Gleb Smirnoff 3fd47ac3e9 MFC:
Implement "verbose" optional keyword for "show" command. This is analog
  of Cisco's "show ip cache verbose flow" command.
2005-05-11 10:48:48 +00:00
Gleb Smirnoff 57efdd2be2 MFC the following changes:
Add a possibility to bypass unmodified accounted data to special
  hook(s). Data received on these hook(s) is sent back to ifaceX hook(s).

  Refactor node so that it does not modify mbuf contents:
  - In ng_netflow_rcvdata() do all necessary pulluping: Ethernet header,
    IP header, and TCP/UDP header.
  - Pass only pointer to struct ip to ng_netflow_flow_add(). Any TCP/UDP
    headers are guaranteed to by after it.
  - Merge make_flow_rec() function into ng_netflow_flow_add().
2005-05-11 10:45:31 +00:00
Denis Peplin b8a8f6d594 Merge the following from the English version:
1.69.2.16 -> 1.69.2.17 errata/article.sgml
2005-05-11 09:11:12 +00:00
Dag-Erling Smørgrav 6e40d81632 MFC: (1.19) tweak description of "w" mode. 2005-05-11 08:28:00 +00:00
Eric Anholt ee93840bde MFC: Add the agp driver to GENERIC. 2005-05-10 22:45:14 +00:00
Ken Smith 1154929592 Note date of 5.4-REL here too. I've been forgetting to do it in the
development branches.

Prodded by:	cperciva and others
2005-05-10 17:28:52 +00:00
cvs2svn 55f89ab8af This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-05-10 16:48:04 +00:00
Hajimu UMEMOTO 5d7d68e6ed MFC 1.63: remove needless res_init() call. 2005-05-09 19:04:27 +00:00
Hajimu UMEMOTO fc305b6112 MFC: the 3rd argument of getsockname() should be socklen_t*.
lib/libc/net/getaddrinfo.c:	1.66
	lib/libc/net/name6.c:		1.51
2005-05-09 18:57:13 +00:00
Hajimu UMEMOTO 04a0c9ecf4 MFC 1.48: remove unused variable. 2005-05-09 18:51:57 +00:00
Hajimu UMEMOTO c28a5145ef MFC 1.59: make _files_getaddrinfo() re-entrant. 2005-05-09 18:47:41 +00:00
Hajimu UMEMOTO 3047e5eecc MFC: hostalias() is not thread-safe. So, introduce _res_hostalias()
and use it.

	lib/libc/net/getaddrinfo.c:	1.64
	lib/libc/net/gethostbydns.c:	1.47
	lib/libc/net/res_query.c:	1.30
2005-05-09 18:40:11 +00:00
Hajimu UMEMOTO 01bd664a45 MFC 1.12: if last line didn't have trailing space, network address
was also treated as an alias.
2005-05-09 18:32:38 +00:00
Hajimu UMEMOTO 5de644835e MFC 1.45:
- nuke deprecated and unused getnodeby(3).
- remove unused variable.
2005-05-09 17:19:40 +00:00
Hajimu UMEMOTO 67ffe95961 MFC 1.41, 1.42:
- nuke the logic for AF_UNSPEC and simplify.  once, it was introduced
  to improve getaddrinfo(3).  but, it is not needed for a long time
  since getaddrinfo(3) became providing its own res_*N() functions.
- add missing mutex unlock.
2005-05-09 17:16:36 +00:00
Xin LI ca13161f0a MFC 1.15+1.16: Remove a check about whether sa->sa_len is equal to salen
from getnameinfo(3).  This improves API compatibility with other POSIX
complaint operating systems.

PR:		standards/80008
Requested by:	Xin Liu <[email protected]>
Reviewed by:	freebsd-standards (das)
MFC After:	2 weeks
2005-05-09 13:11:47 +00:00
Ian Dowse 7d04e61560 MFC 1.174: don't copy the NFSMNT_* flags into struct statfs's f_flags
field, as they have no connection with the expected MNT_* flags.
2005-05-09 01:09:48 +00:00
Dag-Erling Smørgrav 1cc43173b5 MFC: report added / removed partitions, require -a to remove all partitions 2005-05-08 13:26:59 +00:00
Colin Percival 2b927f8843 MFC: Fix two issues which were missed in FreeBSD-SA-05:08.kmem.
Reported by:	Uwe Doering
2005-05-08 10:19:37 +00:00
Maxime Henrion 19d48c1be6 MFC: Use BUS_PROBE_DEFAULT for pci probe return value. 2005-05-08 01:36:02 +00:00
Maxime Henrion 4c9f0486a4 MFC: Remove an outdated comment about ifnet not being locked. 2005-05-08 01:31:58 +00:00
Maxime Henrion 245beb126c MFC: Enable extended RFDs and TCBs, and thus checksum offloading, for
82551 chipsets (revision IDs 0x0e, 0x0f and 0x10).
2005-05-08 01:27:29 +00:00
Maxime Henrion 9e97a8f2d6 MFC the conversion to C99 types to reduce differences with HEAD. 2005-05-08 01:16:41 +00:00
Scott Long 3426f0d419 Revert 1.228.2.4, it causes more problems than it solves. 2005-05-07 17:47:39 +00:00
SUZUKI Shinsuke 5e05b0be8a MFC Rev 1.12
fixed a possible reference to a broken memory
2005-05-07 08:31:55 +00:00
Bruce A. Mah 2248b93893 New errata items: SA-05:06.iir, SA-05:07.ldt, SA-05:08.kmem.
While 5.4-RELEASE contains the fixes for these bugs, it would have
been too difficult, at this stage in the release cycle, to add these
items to the 5.4 release notes and get all the various translations
updated.  Thus we put them in the not-as-time-critical errata
document.

Approved by:	re (hrs)
2005-05-07 04:22:54 +00:00
Colin Percival b9d1474367 If we are going to
1. Copy a NULL-terminated string into a fixed-length buffer, and
2. copyout that buffer to userland,
we really ought to
0. Zero the entire buffer
first.

Security: FreeBSD-SA-05:08.kmem
2005-05-06 02:50:00 +00:00
Colin Percival 370ca70d9d Correctly validate inputs to the i386_get_ldt syscall.
Security: FreeBSD-SA-05:07.ldt
2005-05-06 02:40:18 +00:00
Colin Percival 5d3dd1a9ec Correct improper permissions on /dev/iir. The earlier permissions
of 0644 allowed for people to do Evil Things via ioctl(2).

Security: FreeBSD-SA-05:06.iir
2005-05-06 02:33:46 +00:00
Doug White 389cbb3b60 Insta-MFC 1.86:
Fix 5704S on IBM/Intel blade servers.

Approved by:	re
2005-05-06 00:38:02 +00:00
Paul Saab 74f1081d20 MFC:
- Tweak kern_msgctl() to return a copy of the requested message queue id
  structure in the struct pointed to by the 3rd argument for IPC_STAT and
  get rid of the 4th argument.  The old way returned a pointer into the
  kernel array that the calling function would then access afterwards
  without holding the appropriate locks and doing non-lock-safe things like
  copyout() with the data anyways.  This change removes that unsafeness and
  resulting race conditions as well as simplifying the interface.
2005-05-05 19:57:04 +00:00
Paul Saab 19833d34ae MFC:
Split out kernel side of msgctl(2) into two parts.
2005-05-05 19:55:08 +00:00
Christian Brueffer f0bf293b38 MFC: rev. 1.37
Document the device burncd uses by default.
2005-05-05 19:30:28 +00:00
Tom Rhodes 2a0568049c MFC: Spell default correctly in a comment. 2005-05-05 19:05:19 +00:00
Tom Rhodes 3426dd29b0 MFC: 1.10
Fix two typos in comments.
2005-05-05 19:01:31 +00:00
Robert Watson cf65c1664c Merge ipcs.c:1.24 from HEAD to RELENG_5:
third of several commits to allow kernel System V IPC data structures
  to be modified and extended without breaking the user space ABI:

  Make the "ipcs" tool, which grubs around in kernel memory to report
  status relating to System V IPC, use the _kernel variants on the
  System V IPC data structures.

  Submitted by:   Dandekar Hrishikesh <rishi_dandekar at sbcglobal dot net>
  Obtained from:  TrustedBSD Project
  Sponsored by:   DARPA, SPAWAR, McAfee Research

Requested by:	ps
2005-05-05 18:54:58 +00:00
Robert Watson b7f1bdbe66 Merge sysv_msg.c:1.54, sysv_sem.c:1.71-1.72, sysv_shm.c:1.98,
msg.h:1.18:

  Second of several commits to allow kernel System V IPC data structures
  to be modified and extended without breaking the user space ABI:

  Use _kernel variants on _ds structures for System V sempahores, message
  queues, and shared memory.  When interfacing with userspace, export
  only the _ds subsets of the _kernel data structures.  A lot of search
  and replace.

  Define the message structure in the _KERNEL portion of msg.h so that it
  can be used by other kernel consumers, but not exposed to user space.

  Submitted by:   Dandekar Hrishikesh <rishi_dandekar at sbcglobal dot net>
  Obtained from:  TrustedBSD Project
  Sponsored by:   DARPA, SPAWAR, McAfee Research

  Correct two incorrectly merged changes introduced in sysv_sem.c:1.71:
  return EINVAL rather than setting error, and don't free sops
  unconditionally.  The first change was merged accidentally as part of
  the larger set of changes to introduce MAC labels and access control,
  and potentially lead to continued processing of a request even after
  it was determined to be invalid.  The second change was due to changes
  in the semaphore code since the original work was performed.

  Pointed out by: truckman

NOTE: Change to ipcs.c in user space that catches up with kernel header
changes to follow shortly in a second commit.  The API has changed, but
not the ABI.

Requested by:	ps
2005-05-05 18:53:13 +00:00
Tom Rhodes 9735517718 MFC: 1.117:
Get the directory structure correct in a comment.

Submitted by:	Samy Al Bahra
2005-05-05 18:36:03 +00:00
Robert Watson 56089485cc Merge msg.h:1.17, sem.h:1.28, shm.h:1.20 from HEAD to RELENG_5:
First of several commits to allow kernel System V IPC data structures
  to be modified and extended without breaking the user space ABI:

  Define _kernel wrapper data structures for the user-exposed data
  structures that current server as the internal data structures for
  the implementation:

  - struct msqid_kernel wraps struct msqid_ds.
  - struct semid_kernel wraps truct semid_ds.
  - struct shmid_kernel wraps struct shmid_ds.
  - Don't expose extern definition 'shmsegs' outside of sysv_shm.c.

  Submitted by:   Dandekar Hrishikesh <rishi_dandekar at sbcglobal dot net>
  Obtained from:  TrustedBSD Project
  Sponsored by:   DARPA, SPAWAR, McAfee Research

Requested by:	ps
2005-05-05 18:25:14 +00:00
Wilko Bulte 26b8114997 ICH5 is also supported by ichsmb 2005-05-05 12:03:36 +00:00
Doug White abe1c89707 Commit a workaround to panics in ttwwakeup() during open and closes of the
terminal sharing /dev/console. Peek at tty structs passing through ttymalloc()
and pass them to ttyrel() if they'd get reaped due to the refcount dropping
to 0. Also loosen up the refcount check in ttyrel() to account for
refcounting problems caused by the incestuous relationship. I left the
KASSERT alone in case people want to look into the underlying issue.

Reaping dying tty structs helps keep stale data from growing in the knote
lists, which eventually get tripped over, causing the panic.

This change does not apply to -CURRENT due to differences in tty handling.

MFC after:	3 days
2005-05-05 03:48:08 +00:00
Marcel Moolenaar ad82ba4279 MFC 1.6: Put gnome-lite and kde-lite on disc2 for ia64.
MT5.4 after: 2 days
2005-05-05 01:14:39 +00:00
Marcel Moolenaar 86d86bf0c3 MFC 1.2: Remove only the packages sub-directory before recreating it. 2005-05-05 01:02:39 +00:00
Marcel Moolenaar b817c338b7 MFC 1.883: Allow specifying which INDEX file to use by setting PKG_INDEX. 2005-05-05 00:53:29 +00:00
Vinod Kashyap 8f055ea1ec MFC of recent changes corresponding to the 9.2 release of twa.
MFC after:3 weeks
2005-05-04 19:26:30 +00:00
Hajimu UMEMOTO c472ad315c add missing mutex unlock in previous commit. 2005-05-04 18:49:00 +00:00
Hajimu UMEMOTO c44677fc7e enclose getservbyport(3) call with mutex lock.
since our getservbyport(3) is thread-safe on CURRENT, we don't need
this workaround on CURRENT.  however, it is not MFC'ed to RELENG_5,
yet.  so, we need this for RELENG_5.
this fix is candidate for MFS to be in time for 5.4-RELEASE.

Found by:	tools/regression/lib/libc/resolv/resolv -r
Reviewed by:	hrs
Tested by:	hrs
2005-05-04 18:00:33 +00:00
Peter Wemm 091d04ffc9 Record the freebsd.org cluster's configs to aid 5.x conversion. For
pam_krb5:
* disable pam_setcred, it fails very noisily on the cluster
* disable WARNS for the now-unused things from the first item
2005-05-04 16:30:10 +00:00
Peter Wemm 6cfa970556 Add the freebsd.org custer's source modifications under #ifdefs to aid
keeping things in sync.  For ksu:
* install suid-root by default
* don't fall back to asking for a unix password (ie: be pure kerberos)
* allow custom user instances for things like www and not just root
2005-05-04 16:26:58 +00:00
Andre Oppermann e108f29514 MFC:
tcp_output.c rev 1.109, tcp_subr.c rev 1.222, tcp_var.h rev 1.120.

  Ignore ICMP Source Quench messages for TCP sessions.  Source Quench is
  ineffective, depreciated and can be abused to degrade the performance
  of active TCP sessions if spoofed.

  Replace a bogus call to tcp_quench() in tcp_output() with the direct
  equivalent tcpcb variable assignment.

  Security:	draft-gont-tcpm-icmp-attacks-03.txt Section 7.1
2005-05-04 13:59:26 +00:00
Scott Long 66b5ee4769 Do the Giant locking dance when calling xpt_done(). This is not an MFC since
6-CURRENT solves the problem differently.  Thanks to Marcus Grando for
reporting and testing this.  5.4 candidate.
2005-05-03 20:10:40 +00:00
Scott Long a5b395531b Bugger, made the same typo in the previosu commit as the one to HEAD. Add a
needed comma.
2005-05-03 19:20:17 +00:00
Scott Long 48a4b414dd MFC rev 1.156: Don't ask busdma for an alignment for buffers. Fixes busdma
from trying to exhaust all virtual memory.  5.4 candidate.
2005-05-03 19:09:15 +00:00
Scott Long 7106495c4a MFC rev 1.17: Remove an extra mutex unlock. 5.4 candidate. 2005-05-03 19:04:56 +00:00
Jesus R. Camou 55bdc3177f MFC: Updates to the ppp(8) man page.
Approved by:	trhodes (mentor)
2005-05-02 07:22:37 +00:00
Maxim Konovalov 0e2d5e2faa MFC rev. 1.86: fix a typo. 2005-05-01 14:37:21 +00:00
Scott Long 7865825003 MFC rev 1.57: Fix speaker output for the AD1888 codec.
Submitted by: David Cross
2005-05-01 14:31:06 +00:00
Poul-Henning Kamp a2279c08c0 MFC:
open slices for write, otherwise we cannot modify the layout.
2005-05-01 07:35:23 +00:00
Yoshihiro Takahashi aa2d114f72 MFC: Add KDB_STOP_NMI option. 2005-05-01 06:06:27 +00:00
Doug White 08bcc11413 MFC: KDB_STOP_NMI functionality
Insta-MFC approved by:	re
2005-05-01 05:34:47 +00:00
Yoshihiro Takahashi 29f27abb52 MFC: Remove the wl driver. 2005-05-01 04:15:37 +00:00
Colin Percival 536789b006 MFC revision 1.26: Add PROC_UNLOCK(p) to PTRACESTOP_SC(p, td, flag), in
order to catch up to changes in the behaviour of ptracestop().

Approved by:	re (kensmith)
2005-05-01 04:03:06 +00:00
Christian S.J. Peron 114c3a9849 MFC revision 1.8
date: 2005/04/14 03:56:06;  author: csjp;  state: Exp;  lines: +2 -0
Do not remove logging sockets. This fixes an issue where logging
sockets placed into prisons from the host environment get clobbered
by the prison's instance of cleanvar. (assuming /etc/rc is run in
the prison).
2005-05-01 01:28:57 +00:00
Christian S.J. Peron 847397aa21 MFC revision 1.228
date: 2005/04/05 01:11:43;  author: csjp;  state: Exp;  lines: +1 -0
Assert that the vnode is locked. This is meant to catch bugs or
mis-use of the vnode API in conditions where IO_NODELOCKED has been
used without the vnode actually being locked.
2005-05-01 01:26:25 +00:00
Doug White 036888e19a Enable interrupts in smp_tlb_shootdown() and smp_targeted_tlb_shootdown()
to workaround Opteron Errata 106.  The while loop runs entirely out of
the instruction cache, which blocks updates to the cache from other CPUs.
Interrupts break the lock, allowing the write to post.

Many thanks to Paul Vixie and Peter Losher at ISC for providing resources
to troubleshoot the issue; Stephen Uphoff and Alan Cox for their
expertise; and the rest of the RE team for pushing the resolution along
so we can ship 5.4 with this fix.
2005-04-30 19:39:28 +00:00
Dag-Erling Smørgrav 5a26379573 MFC: (1.52) fix two long-standing bugs in pfs_readdir()
(1.56) fix an old cosmetic pasto
2005-04-30 18:40:47 +00:00
Poul-Henning Kamp 8161fe1b0c MFC:
Add Solaris new slice identifier.
	Don't prepend /dev if already absolute path.
	Open in correct mode if we resort to trying the slices.

Approved by:	re
2005-04-30 18:29:07 +00:00
Dag-Erling Smørgrav e7f31b123b MFC: if dumpdev is "AUTO", pick the first usable swap device from fstab. 2005-04-30 16:21:04 +00:00
Colin Percival 3e8db597ec MFC rev. 1.65: netstart is now obsoleted by /etc/rc.d/*, not by
/etc/rc.network.
2005-04-29 22:40:47 +00:00
cvs2svn 8f7e5c59f1 This commit was manufactured by cvs2svn to create branch 'RELENG_5'. 2005-04-29 20:03:21 +00:00
Pawel Jakub Dawidek 1223d0f6c4 MFC: g_raid3.c 1.40
If an error occurs, clean up before returning from g_raid3_connect_disk().
2005-04-29 08:27:40 +00:00
Pawel Jakub Dawidek 74065fbff0 MFC: g_mirror.c 1.61
Make the code more obvious - when an error occurs in g_mirror_connect_disk(),
detach and destroy consumer before returning.
2005-04-29 08:24:56 +00:00
Pawel Jakub Dawidek 097f458c09 MFC: g_raid3_ctl.c 1.9
Check for return values.

Found by:	Coverity Prevent analysis tool
2005-04-29 08:17:15 +00:00
Pawel Jakub Dawidek 97a7014a42 MFC: g_mirror_ctl.c 1.10
Check for return values.

Found by:	Coverity Prevent analysis tool
2005-04-29 08:15:39 +00:00
Pawel Jakub Dawidek 59586b1b69 MFC: gstripe.8 1.25
Fix stripe size in example.

Found by:	kris
2005-04-29 08:08:28 +00:00
Pawel Jakub Dawidek 2b97510d13 MFC: g_mirror_ctl.c 1.11
Fix provider's size check for 'insert' command.
Before this fix one was able to insert one sector too small provider.
2005-04-29 08:07:00 +00:00
Pawel Jakub Dawidek 833ef1cb27 MFC: Makefile.inc 1.7
Allow classes to specify local source files.
2005-04-29 08:00:46 +00:00
Pawel Jakub Dawidek d92bedd8f2 MFC: geom.c 1.21
Empty error buffer is not an error.
2005-04-29 07:58:29 +00:00
Scott Long ae19aa7439 MFC rev 1.67 and 1.68: Create /dev/rdpt alias for /dev/asr to make the
management tools happy.
2005-04-29 04:48:12 +00:00
Scott Long 590a80f662 MFC: Don't compile EHCI for PAE. 2005-04-29 04:12:12 +00:00
Scott Long d82f9d42e1 MFC: Don't pretend to support CAM_DATA_PHYS 2005-04-29 04:11:30 +00:00
Marcel Moolenaar d9938f0d6e MFC rev. 1.12: Make the Z8530 more reliable as low-level console. 2005-04-28 18:59:52 +00:00
Paul Saab d7bf16f886 MFC:
Add support for the P600 and name the E400.
2005-04-28 14:49:52 +00:00
Paul Saab 6324f43600 MFC:
Provide a way to soft reset a proxy controller such as an MSA20 or
MSA500.
2005-04-28 14:47:05 +00:00
Yoshihiro Takahashi 6a952d8e09 MFi386: revision 1.597.2.7. 2005-04-28 13:48:34 +00:00
Kris Kennaway dfca97f5b3 MFC:
Add the vm.exec_map_entries tunable and read-only sysctl, which controls
  the number of entries in exec_map (maximum number of simultaneous execs
  that can be handled by the kernel).  The default value of 16 is
  insufficient on heavily loaded machines (particularly SMP machines), and
  if it is exceeded then executing further processes will generate a SIGABRT.

  This is a workaround until a better solution can be implemented.
2005-04-28 00:29:24 +00:00
Ken Smith e40f5853d7 MFC of revision 1.5 :
> date: 2005/04/17 23:30:20;  author: kensmith;  state: Exp;  lines: +0 -3
> Needed to drop "lang/gnat", "print/teTeX", and "textproc/docproj-jadetex"
> to make the packages fit on the CDs...
2005-04-27 13:52:45 +00:00
Hartmut Brandt dfceb6eb92 MFC: insert a comment character between .else/.endif and strings following
on the same line.
2005-04-27 13:52:35 +00:00
David Xu 9abd505d04 MFC Revision 1.261:
Wake up swapper process.
2005-04-27 13:00:29 +00:00
David Xu 9323e6b75a MFC Revision 1.251:
Inherit signal mask from parent process.
2005-04-27 11:32:23 +00:00
Doug Barton 4d1a9ca6d2 MFC 1.17 - 1.21:
1. Make sure that the /etc/namedb symlink is pointing to the right place.
2. Unmount the devfs when stop'ing (including on shutdown).
3. Require cleanvar.
2005-04-27 05:16:31 +00:00
Peter Wemm 3715713ded Partial MFC:
implement kernel side of i386_set_gsbase(2) and friends.
Add symbol to tell NDIS which slot to use.
Notable differences to -current:
  * gdt renumber not merged
  * user %cs/%ds still live in the ldt.
  * NDIS_SEL defined to same value as ndis code had hardcoded(!).

We could have libc and rtld switch to using this as the primary API
to implement TLS and avoid having a custom LDT for every process.
2005-04-26 21:20:20 +00:00
John Baldwin ff7a604c34 MFC: Close a race between sleepq_broadcast() and sleepq_catch_signals() by
merging sleepq_resume_thread() and sleepq_remove_thread().  This also
reduces the overall number of lock operations for sleep queue operations.
2005-04-26 18:01:31 +00:00
Marcel Moolenaar 66ba1d0808 Intend: unbreak the alpha tinderbox: The use of INT_MAX in the kernel
requires the explicit inclusion of <sys/limits.h>

Tested: not -- not even compiled. Just like the previous revision.
2005-04-25 23:02:21 +00:00
Peter Wemm 4b28631e8d Add 6.x-compatable fs/gsbase functions. This means we can use libraries with
these symbols to satisfy things like libpthread.so.0 when running on
a 6.x machine when the app is linked against libc.so.5.  Note that these
don't actually do anything on 5.x kernels yet.  I'd actually like to have
5.x use these in the future though, in order to get rid of the evil
#ifdef COMPAT_32BIT stuff.
2005-04-25 20:30:24 +00:00
Alexander Kabaev 1a26cdb57a MFC r1.14:
Do not try to store 64 bits into 32 bit errno variable.

Approved by:	re (kensmith)
2005-04-25 20:04:53 +00:00
Scott Long f3ac963ae1 Remove the ACPI_MAX_THREADS option. 2005-04-25 19:59:09 +00:00
Gleb Smirnoff 705b6b203e MFC 1.53:
Fix panics with misconfigured routing:
  - Backout previous revision, the check is useless.
  - Turn node to queue mode, since it is edge node.

Approved by:	re (kensmith)
2005-04-25 17:04:13 +00:00
Gleb Smirnoff f62e665c1c MFC 1.28:
Fix error in synproxy connection completion. Source and
  destination windows were confused, one instead of other.

Approved by:	re (kensmith)
2005-04-25 15:24:30 +00:00
Denis Peplin c53adaec59 Merge the following from the English version:
1.227.2.25 -> 1.227.2.28 hardware/common/dev.sgml

Update also Russian override of dev-auto.sgml
CVg:
2005-04-25 12:49:57 +00:00
David Xu 389c989106 MFC:
Fix race between thread_stopped and kern_wait.
2005-04-24 23:20:52 +00:00
Bjoern A. Zeeb 2751ae3f40 MFC: rev. 1.13
Add note to remove nis entries when compiling with NO_NIS.

Approved by:	pjd (mentor)
2005-04-24 20:33:06 +00:00
Bjoern A. Zeeb 40ef237a98 MFC: rev. 1.25 (HARDWARE section only)
Add D-Link DGE-530T to list of supported hardware.

Approved by:	pjd (mentor)
2005-04-24 20:31:14 +00:00
Paul Saab 04bb8ef07a MFC:
- Implement linux_nanosleep() using the recently added kern_nanosleep().
- Use linux_emul_convpath() instead of linux_emul_find() in
  exec_linux_imgact_try().
2005-04-23 22:47:57 +00:00
Paul Saab 144ab4604c MFC:
- Use kern_setitimer(), kern_getitimer(), kern_select(), kern_utimes(),
  kern_statfs(), kern_fstatfs(), kern_fhstatfs(), kern_stat(),
  kern_fstat(), and kern_lstat().
2005-04-23 22:09:17 +00:00
Paul Saab e33e91e75e MFC:
Implement a kern_pathconf() wrapper for pathconf() which can take the
filename from either a user space or a kernel space pointer.
2005-04-23 22:02:07 +00:00
Paul Saab 5916f35031 MFC: rev 1.65
- Use kern_{l,f,}stat() and kern_{f,}statfs() functions rather than
  duplicating the contents of the same functions inline.
- Consolidate common code to convert a BSD statfs struct to a Linux struct
  into a static worker function.
2005-04-23 21:57:43 +00:00
Paul Saab 1140444cf4 MFC: rev 1.28
Make linux_emul_convpath() a simple wrapper for kern_alternate_path().
2005-04-23 21:56:04 +00:00
Paul Saab a55c931f30 MFC:
- Implement kern_foo wrappers for stat(), lstat(), fstat(), statfs(),
  fstatfs(), and fhstatfs().  Use these wrappers to cut out a lot of
  code duplication for freebsd4 and netbsd compatability system calls.
- Add a new lookup function kern_alternate_path() that looks up a filename
  under an alternate prefix and determines which filename should be used.
  This is basically a more general version of linux_emul_convpath() that
  can be shared by all the ABIs thus allowing for further reduction of
  code duplication.
2005-04-23 21:53:05 +00:00
Simon L. B. Nielsen d915db9929 MFC:
Cross reference ehci(4).
2005-04-23 21:42:29 +00:00
Paul Saab bba7788260 MFC rev 1.114 & 1.115
- Various and sundry style fixes.
- If the pointer to the new itimerval is NULL in kern_setitimer(),
  just read the old value via kern_getitimer().
2005-04-23 17:28:40 +00:00
Paul Saab d52f834a5f MFC: rev 1.165
Use kern_setitimer() to implement linux_alarm() instead of fondling the
real interval timer directly.
2005-04-23 16:38:27 +00:00
Paul Saab a6306d69d4 MFC: rev 1.50
Use kern_open() directly rather than a stackgap detour via open().
2005-04-23 16:36:52 +00:00
Yoshihiro Takahashi 87b90f880e MFC: Rename from apm_bioscall.s to apm_bioscall.S. 2005-04-23 13:32:35 +00:00
Pawel Jakub Dawidek 281ceec453 MFC: ufs_vnops.c 1.268
- Plug memory leak.
- Fix two style nits.

Found by:	Coverity Prevent analysis tool
Reviewed by:	rwatson
2005-04-23 12:29:22 +00:00
Pawel Jakub Dawidek d324a05667 MFC: Makefile 1.257
Add missing links.
2005-04-23 12:22:45 +00:00
Pawel Jakub Dawidek 953aac98eb MFC: gmirror.8 1.16
Remove duplicated description of 'clear' subcommand.

Pointed out by:	marck
2005-04-23 12:18:04 +00:00
Robert Watson cf6e43fa85 Merge libugidfw.c:1.7 from HEAD to RELENG_5:
In practice, you need to include <sys/types.h> and
  <security/mac_bsdextended/mac_bsdextended.h> in order to include
  <ugidfw.h>, so document that.
2005-04-23 11:54:15 +00:00
SUZUKI Shinsuke 04e4385ef0 MFC Rev1.11
plugged memory leak
2005-04-23 08:25:52 +00:00
SUZUKI Shinsuke c938956432 MFC Rev 1.14
FAITH's base spec has already been an RFC
2005-04-23 08:20:32 +00:00
Nate Lawson 2990c125fc MFC: Add the debug.acpi.max_threads tunable. 2005-04-22 23:26:46 +00:00
Nate Lawson a1fdf9939d MFC: Document debug.acpi.max_threads 2005-04-22 23:23:04 +00:00
Simon L. B. Nielsen 5385c6206d MFC:
Correct multiple security related errors: a buffer overflow, NULL
pointer dereferences, possible use of uninitialized variables, and
memory leaks.

Security:	CAN-2005-0753
Security:	FreeBSD-SA-05:05.cvs
Approved by:	peter
2005-04-22 18:01:04 +00:00
Remko Lodder 9274a7f521 MFC:
date: 2005/04/10 19:03:48;  author: remko;  state: Exp;  lines: +1 -0
Add myself to the calendar.

MFC after:      1 week
Approved by:    simon (mentor)
2005-04-22 17:28:17 +00:00
Tim J. Robbins 703b10f386 MFC rev. 1.30: correctly handle inputs with missing newline at EOF
in -f mode.
2005-04-22 11:41:45 +00:00
Pawel Jakub Dawidek 8dead41fb0 MFC: gmirror.8 1.15
Document 'clear' and 'dump' subcommands.
2005-04-22 09:20:23 +00:00
Maxim Konovalov c3e3d461e8 MFC rev. 1.162: disable random port allocation when
ip.portrange.first == ip.portrange.last.
2005-04-22 08:08:54 +00:00
Paul Saab 83ccd73358 MFC:
- Move the function prototypes for kern_setrlimit() and kern_wait() to
  sys/syscallsubr.h where all the other kern_foo() prototypes live.
2005-04-21 22:19:22 +00:00
Paul Saab 2ce08b36ec MFC:
Split out kernel side of {get,set}itimer(2) into two parts: the first that
pops data from the userland and pushes results back and the second which does
actual processing. Use the latter to eliminate stackgap in the linux wrappers
of those syscalls.
2005-04-21 22:00:10 +00:00
Paul Saab fcfbbebf81 MFC:
kern_kevent prototype
2005-04-21 21:14:03 +00:00
Paul Saab 7497ba49d6 MFC:
regen after changing the freebsd32_kevent prototype.
2005-04-21 21:12:17 +00:00
Paul Saab 5ad1fecaf8 MFC:
Use kern_kevent instead of the stackgap for 32bit syscall wrapping
and correct the freebsd32_kevent prototype.
2005-04-21 21:11:24 +00:00
Paul Saab a6a52a2550 regen for kevent 2005-04-21 21:01:47 +00:00
Paul Saab dbf4b084e1 MFC: rev 1.186
Change the prototype of kevent to remove the const from the changelist.
2005-04-21 21:00:18 +00:00
Jesus R. Camou 44ee75e56a MFC: changes that have been applied over the years
to the devfs(8) man page.

Approved by:	trhodes (mentor)
2005-04-21 20:51:51 +00:00
Paul Saab b999e4002d MFC:
kern_ntptime.c, kern_time.c, sys_generic.c p1003_1b.c, syscallsubr.h:
- Implement kern_adjtime(), kern_readv(),
  kern_sched_rr_get_interval(), kern_settimeofday(), and
  kern_writev() to allow for further stackgap reduction in
  the compat ABIs.

osf1_misc.c:
- Use a custom version of copyinuio() to implement
  osf1_{read,write}v() via kern_{read,write}v().

linux32_machdep.c:
- Use a custom version of copyinuio() to implement readv/writev using
  kern_readv/writev.
- Use kern_sched_rr_get_interval() rather than the stackgap.

freebsd32_misc.c:
- Use a custom version of copyinuio() to implement readv/writev using
  kern_readv/writev.
- Use kern_settimeofday() and kern_adjtime() rather than
  stackgapping it.

ibcs2_misc.c:
- Use kern_settimeofday() to avoid stackgap use.
2005-04-21 20:33:05 +00:00
Warner Losh ab4f63c403 MFC 1.158: enable mii/phy on Xircom cards before probing for the mii/phy
rather than after.

This should be merge to RELENG_5_4 too.
2005-04-21 17:54:11 +00:00
Warner Losh 87e678347b MFC: Fix parsing of nomatch events. Also, sync usage to man page.
This should be merged to RELENG_5_4.
2005-04-21 17:51:26 +00:00
David E. O'Brien e7c9a3d9f6 MFC: rev 1.30: default boot0 to packet mode. 2005-04-21 15:51:44 +00:00
David E. O'Brien 9445266f88 MFC: rev 1.14: remove type 0x4 (FAT12 <32MB) to make room for type 0x7 (NTFS). 2005-04-21 15:42:28 +00:00
Marius Strobl 3ef4eb62cf MFC: 1.16
Release the IRQ resource on detach. This fixes repeatedly loading and
unloading the hme(4) module in case it attaches to sbus(4).
2005-04-20 23:37:01 +00:00
Marius Strobl 2112f03a3a MFC: 1.125 (partial)
- In sparc64_init() remove the call to tick_stop(). There's no need to
  call tick_stop() again after tick_init() as tick interrupts already
  have been disabled as part of tick_init().
- Use FBSDID.
2005-04-20 23:36:29 +00:00
Marius Strobl 359e25c162 MFC: cpufunc.h 1.19, 1.20; tick.c 1.16 (partial)
- Add a workaround for a bug in BlackBird CPUs (said to be part of the
  SpitFire erratum #54) which can cause writes to the TICK_CMPR register
  to fail. This seems to fix the dying clocks problem reported by jhb@
  and kris@.
- In tick_init() just use tick_stop() for stopping the tick interrupts
  until a proper handler is set up later. This also stops the system
  tick interrupt on USIII systems earlier.
- Some minor changes, e.g. use FBSDID, remove unused headers, etc.
2005-04-20 23:35:52 +00:00
Marius Strobl 242a5795da MFC: 1.22
Some changes to intr_execute_handlers():
- Fix NULL pointer dereferences caused when an ithread or a handler is
  NULL which happens when a stray interrupt triggers after the respective
  device interrupt was torn down.
- Remove the critical section around INTR_FAST handlers which actually
  was a nested critical section. Both tl0_intr() and tl1_intr() already
  enter a critical section for calling intr_execute_handlers().
2005-04-20 23:34:37 +00:00
2270 changed files with 249505 additions and 167303 deletions

No files matched your search

+1 -1
View File
@@ -4,7 +4,7 @@
The compilation of software known as FreeBSD is distributed under the
following terms:
Copyright (C) 1992-2005 The FreeBSD Project. All rights reserved.
Copyright (C) 1992-2007 The FreeBSD Project. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
+12
View File
@@ -0,0 +1,12 @@
$FreeBSD$
This file documents formal review/approval requirements that have been
approved by core.
subsystem login expires notes
--------------------------------------
Special cases:
src/* RELENG_4_* Requires Security Officer approval.
src/* RELENG_5_* Requires Security Officer approval.
src/* RELENG_6_* Requires Security Officer approval.
+51 -82
View File
@@ -1,37 +1,45 @@
$FreeBSD$
Please note that the content of this file is strictly advisory.
No locks listed here are valid. The only strict review requirements
are granted by core. These are documented in src/LOCKS and enforced
by CVSROOT/approvers.
The source tree is a community effort. However, some folks go to the
trouble of looking after particular areas of the tree. In return for
their active caretaking of the code it is polite to coordinate changes
with them. This is a list of people who have expressed an interest in
part of the code or listed their active caretaking role so that other
committers can easily find somebody who is familiar with it. The notes
should specify if there is a 3rd party source tree involved or other
things that should be kept in mind.
However, this is not a 'big stick', it is an offer to help and a source
of guidance. It does not override the communal nature of the tree.
It is not a registry of 'turf' or private property.
subsystem login notes
-----------------------------
kqueue jmg Pre-commit review requested.
mergemaster dougb Prefers to pre-approve commits
libc/posix1e rwatson Pre-commit review requested.
POSIX.1e ACLs rwatson Pre-commit review requested.
UFS EAs rwatson Pre-commit review requested.
MAC Framework rwatson Pre-commit review requested.
MAC Modules rwatson Pre-commit review requested.
contrib/openbsm rwatson Pre-commit review requested.
sys/security/audit rwatson Pre-commit review requested.
ATA/IDE sos Pre-commit review requested.
ahc(4) gibbs Pre-commit review requested.
ahd(4) gibbs Pre-commit review requested.
NEWCARD imp Pre-commit review requested.
OLDCARD imp Pre-commit review requested.
wi imp Pre-commit review requested.
telnet markm please ensure that a security-aware person
sanity-checks your work.
secure/* markm please ensure that a security-aware person
sanity-checks your work.
kerberos5 nectar Pre-commit review requested.
heimdal nectar Pre-commit review requested.
pci bus imp,jhb Pre-commit review requested.
cdboot jhb Pre-commit review requested.
pxeboot jhb Pre-commit review requested.
witness jhb Pre-commit review requested.
twe vkashyap Pre-commit review requested
twa vkashyap Pre-commit review requested
aac scottl Pre-commit review requested
udf scottl Pre-commit review requested.
ips scottl Pre-commit review requested.
iir scottl Pre-commit review requested.
mlx scottl Pre-commit review requested.
mly scottl Pre-commit review requested.
maestro3 scottl Pre-commit review requested.
twe [email protected] Pre-commit review requested
twa [email protected] Pre-commit review requested
CAM gibbs,
ken Pre-commit review requested. send to [email protected]
devstat(9) ken Pre-commit review requested.
@@ -51,10 +59,6 @@ etc/mail gshapiro Pre-commit review requested.
Keep in sync with -STABLE.
etc/sendmail gshapiro Pre-commit review requested.
Keep in sync with -STABLE.
dhcp mbr Needs to pre-approve commits to contrib/isc-dhcp, so
changes can be made to the isc.org CVS repository.
RELENG_4_* security-officer Requires Security Officer approval.
RELENG_5_* security-officer Requires Security Officer approval.
libfetch des Advance notification requested.
fetch des Advance notification requested.
libpam des Pre-commit review requested.
@@ -65,23 +69,21 @@ linprocfs des Advance notification requested.
lpr gad Pre-commit review requested, particularly for
lpd/recvjob.c and lpd/printjob.c.
newsyslog(8) gad Heads-up appreciated. I'm going thru the PR's for it.
patch gad I have a WIP which will change the src a lot.
vinum grog Recommends pre-commit review.
pkill gad Heads-up appreciated.
ps gad I am working on a number of changes to this. Would
like advance notice of major changes planned to it.
cvs peter Heads-up appreciated, try not to break it.
ncurses peter Heads-up appreciated, try not to break it.
nvi peter Try not to break it.
libz peter Try not to break it.
pppd/chat peter Try not to break it.
groff ru Recommends pre-commit review.
share/mk ru Recommends pre-commit review.
share/mk ru This is a vital component of the build system, so I
offer a pre-commit review for anything non-trivial.
ipfw ipfw Pre-commit review preferred. send to [email protected]
drm anholt Just keep me informed of changes, try not to break it.
regression jmallett Will help write new tests, etc.
libufs jmallett Willing to handle problems, help with work.
fdc(4) joerg Just keep me informed of changes, try not to break it.
sppp(4) joerg Just keep me informed of changes, try not to break it.
libc nectar Opportuntity for pre-commit review appreciated for
nsdispatch(3) and its consumers.
unifdef(1) fanf Pre-commit review requested.
ntp roberto Pre-commit review requested.
inetd dwmalone Recommends pre-commit review.
@@ -91,18 +93,37 @@ contrib/smbfs bp Open for in-tree committs. In case of functional
changes pre-commit review requested.
contrib/pf mlaier Pre-commit review requested.
binutils obrien Insists on BU blocked from unapproved commits
file obrien Insists to keep file blocked from other's unapproved
commits
contrib/bzip2 obrien Pre-commit review required.
lukemftpd obrien Pre-commit review required.
geom_concat pjd Pre-commit review preferred.
geom_eli pjd Pre-commit review preferred.
geom_gate pjd Pre-commit review preferred.
geom_label pjd Pre-commit review preferred.
geom_mirror pjd Pre-commit review preferred.
geom_nop pjd Pre-commit review preferred.
geom_raid3 pjd Pre-commit review preferred.
geom_shsec pjd Pre-commit review preferred.
geom_stripe pjd Pre-commit review preferred.
geom_zero pjd Pre-commit review preferred.
sbin/geom pjd Pre-commit review preferred.
nfs alfred Will be happy to review code, but not mandatory.
rpc.lockd alfred Will be happy to review code, but not mandatory.
truss alfred Will be happy to review code, but not mandatory.
rpc alfred Pre-commit review requested.
xfs [email protected],[email protected],[email protected]
Pre-commit review preferred.
pkg_install krion Pre-commit review or approval from portmgr@ requested.
linux emul emulation Please discuss changes here.
bs{diff,patch} cperciva Pre-commit review requested.
portsnap cperciva Pre-commit review requested.
sys/netgraph/bluetooth emax Pre-commit review preferred.
lib/libbluetooth emax Pre-commit review preferred.
lib/libsdp emax Pre-commit review preferred.
usr.bin/bluetooth emax Pre-commit review preferred.
usr.sbin/bluetooth emax Pre-commit review preferred.
gnu/usr.bin/send-pr bugmaster Pre-commit review requested.
Following are the entries from the Makefiles, and a few other sources.
Please remove stale entries from both their origin, and this file.
@@ -110,61 +131,9 @@ Please remove stale entries from both their origin, and this file.
Please also consider removing the lines from the files listed below and
stating your preferences here instead.
bin/dd/Makefile:MAINTAINER= [email protected]
contrib/cvs/FREEBSD-upgrade:MAINTAINER= [email protected]
games/fortune/datfiles/Makefile:MAINTAINER= [email protected]
gnu/usr.bin/cvs/Makefile:MAINTAINER= [email protected]
gnu/usr.bin/cvs/contrib/Makefile:MAINTAINER= [email protected]
gnu/usr.bin/cvs/cvs/Makefile:MAINTAINER= [email protected]
gnu/usr.bin/cvs/cvsbug/Makefile:MAINTAINER= [email protected]
gnu/usr.bin/cvs/doc/Makefile:MAINTAINER= [email protected]
gnu/usr.bin/cvs/lib/Makefile:MAINTAINER= [email protected]
gnu/usr.bin/cvs/libdiff/Makefile:MAINTAINER= [email protected]
gnu/usr.bin/man/apropos/Makefile:MAINTAINER= [email protected]
lib/libc/posix1e/Makefile.inc:MAINTAINER= [email protected]
lib/libusbhid/Makefile:MAINTAINER= [email protected]
lib/libz/Makefile:MAINTAINER= [email protected]
sbin/dhclient/Makefile.inc:MAINTAINER= [email protected]
sbin/ipf/Makefile:MAINTAINER= [email protected]
sbin/ipfs/Makefile:MAINTAINER= [email protected]
sbin/ipfstat/Makefile:MAINTAINER= [email protected]
sbin/ipmon/Makefile:MAINTAINER= [email protected]
sbin/ipnat/Makefile:MAINTAINER= [email protected]
sys/boot/i386/cdboot/Makefile:MAINTAINER= [email protected]
sys/boot/i386/pxeldr/Makefile:MAINTAINER= [email protected]
sys/compat/svr4/Makefile:MAINTAINER= [email protected]
sys/dev/asr/MAINTAINER:MAINTAINER= [email protected], [email protected], [email protected]
sys/dev/bktr/CHANGELOG.TXT:MAINTAINER= Roger Hardiman <[email protected]>
sys/dev/ep/if_ep.c:MAINTAINER= Matthew N. Dodd <[email protected]>
sys/dev/ex/if_ex.c:MAINTAINER= Matthew N. Dodd <[email protected]>
sys/dev/ie/if_ie.c:MAINTAINER= Matthew N. Dodd <[email protected]>
sys/dev/sound/pcm/feeder_rate.c:MAINTAINER= Orion Hodson <[email protected]>
List below generated with:
$ cd /usr/src; find */* -type f|xargs egrep 'MAINTAINER[ <tab>]*='
sys/modules/3dfx/Makefile:MAINTAINER= [email protected]
sys/modules/bktr/bktr_mem/Makefile:MAINTAINER= [email protected]
sys/modules/cam/Makefile:MAINTAINER= [email protected]
sys/modules/linux/Makefile:MAINTAINER= [email protected]
sys/modules/osf1/Makefile:MAINTAINER= [email protected]
sys/modules/pecoff/Makefile:MAINTAINER= [email protected]
sys/modules/streams/Makefile:MAINTAINER= [email protected]
sys/modules/svr4/Makefile:MAINTAINER= [email protected]
sys/modules/udbp/Makefile:MAINTAINER= [email protected]
sys/modules/ugen/Makefile:MAINTAINER= [email protected]
sys/modules/uhid/Makefile:MAINTAINER= [email protected]
sys/modules/ukbd/Makefile:MAINTAINER= [email protected]
sys/modules/ulpt/Makefile:MAINTAINER= [email protected]
sys/modules/umass/Makefile:MAINTAINER= [email protected]
sys/modules/umodem/Makefile:MAINTAINER= [email protected]
sys/modules/ums/Makefile:MAINTAINER= [email protected]
sys/modules/urio/Makefile:MAINTAINER= Iwasa Kazmi <[email protected]>
sys/modules/usb/Makefile:MAINTAINER= [email protected]
sys/modules/uscanner/Makefile:MAINTAINER= [email protected]
usr.bin/chat/Makefile:MAINTAINER= [email protected]
usr.bin/locate/Makefile:MAINTAINER= [email protected]
usr.sbin/ipftest/Makefile:MAINTAINER= [email protected]
usr.sbin/ipresend/Makefile:MAINTAINER= [email protected]
usr.sbin/ipsend/Makefile:MAINTAINER= [email protected]
usr.sbin/iptest/Makefile:MAINTAINER= [email protected]
usr.sbin/ntp/doc/Makefile:MAINTAINER= [email protected]
usr.sbin/pppd/Makefile:MAINTAINER= [email protected]
usr.sbin/pppstats/Makefile:MAINTAINER= [email protected]
usr.sbin/zic/Makefile:MAINTAINER= [email protected]
+2 -2
View File
@@ -87,11 +87,11 @@ TGTS+= ${BITGTS}
PATH= /sbin:/bin:/usr/sbin:/usr/bin
MAKEOBJDIRPREFIX?= /usr/obj
_MAKEOBJDIRPREFIX!= /usr/bin/env -i PATH=${PATH} ${MAKE} \
${.MAKEFLAGS:MMAKEOBJDIRPREFIX=*} \
${.MAKEFLAGS:MMAKEOBJDIRPREFIX=*} __MAKE_CONF=${__MAKE_CONF} \
-f /dev/null -V MAKEOBJDIRPREFIX dummy
.if !empty(_MAKEOBJDIRPREFIX)
.error MAKEOBJDIRPREFIX can only be set in environment, not as a global\
(in /etc/make.conf) or command-line variable.
(in make.conf(5)) or command-line variable.
.endif
MAKEPATH= ${MAKEOBJDIRPREFIX}${.CURDIR}/make.${MACHINE}
BINMAKE= \
+10 -8
View File
@@ -813,6 +813,14 @@ _groff= gnu/usr.bin/groff/tmac
_lex= usr.bin/lex
.endif
.if ${BOOTSTRAPPING} >= 600016
_mklocale= usr.bin/mklocale
.endif
.if ${BOOTSTRAPPING} >= 600017
_gencat= usr.bin/gencat
.endif
.if ${BOOTSTRAPPING} < 450005 || \
${BOOTSTRAPPING} >= 500000 && ${BOOTSTRAPPING} < 500034
_uudecode= usr.bin/uudecode
@@ -848,8 +856,10 @@ bootstrap-tools:
${_groff} \
gnu/usr.bin/texinfo \
usr.bin/colldef \
${_gencat} \
${_lex} \
usr.bin/makewhatis \
${_mklocale} \
usr.bin/rpcgen \
${_uudecode} \
${_xargs} \
@@ -1010,14 +1020,6 @@ _prebuild_libs+= lib/libcom_err lib/libcrypt lib/libexpat \
lib/libopie__L lib/libtacplus__L: lib/libmd__L
.if !defined(NO_BIND)
.if ${MACHINE_ARCH} == "alpha" || ${MACHINE_ARCH} == "sparc64"
_prebuild_libs+= lib/libc_r
.else
_prebuild_libs+= lib/libpthread
.endif
.endif
_generic_libs+= lib
.if !defined(NOCRYPT)
+95 -24
View File
@@ -8,6 +8,56 @@ Items affecting the ports and packages system can be found in
/usr/ports/UPDATING. Please read that file before running
portupgrade.
20070426:
The ABI breakage in sendmail(8)'s libmilter has been repaired
so it is no longer necessary to recompile mail filters (aka,
milters). If you recompiled mail filters after the 20070411
note, it is not necessary to recompile them again.
20070411:
sendmail(8) has been updated to version 8.14.1. Mail filters
(aka, milters) compiled against the libmilter included in the
base operating system should be recompiled.
20060525:
FreeBSD 5.5-RELEASE
20060127:
The i386 loader(8) now defaults to the serial speed set by the
previous boot stage, if the comconsole is already in use. If
you've changed BOOT_COMCONSOLE_SPEED in make.conf(5) and
installed a new loader, but have not rebuilt and reinstalled the
boot blocks, then your loader will leave the console at 9600
baud. Either install the new boot blocks, or set
comconsole_speed in loader.conf(5). Note that the new boot
blocks also support a -S<speed> flag described in boot(8).
20060111:
Bug fixes to the trimdomain(3) function in libutil may result in
slight changes to the host names appearing in log files under
relatively rare circumstances.
20051015:
The shared library version number of libarchive was accidentally
bumped up during an MFC of other changes on October 4, 2005. It
was reset to the correct value on October 14, 2005. If you
updated a system between those dates you should check to see if
/usr/lib/libarchive.so.2 exists and remove it AFTER doing your
next update.
20051004:
if_bridge has been merged which provides more advanced Ethernet
bridging and 802.1d spanning tree support. See if_bridge(4) for
configuration details.
20050513:
Intel Hyper-Threading is now disabled by default due to a
security issue, but can be re-enabled by setting the
machdep.hyperthreading_allowed tunable in /boot/loader.conf.
20050509:
FreeBSD 5.4-RELEASE
20050302:
The full packet destination manipulation for 'ipfw fwd' is
back with the kernel compile time option:
@@ -1833,10 +1883,10 @@ COMMON ITEMS:
<reboot>
To upgrade in-place from 4.x-stable to current
To upgrade in-place from 4.x-stable to 5.x
----------------------------------------------
# 5.x uses more space than 4.x. Also, the location of kernel
# modules has changed. If you are installing 5.0 onto a 4.x
# modules has changed. If you are installing 5.x onto a 4.x
# system, you'll need about 30MB of free disk space on your /
# partition. If you have less than this, you may encounter difficult
# to back out of problems with this procedure. If /tmp is on
@@ -1850,27 +1900,23 @@ COMMON ITEMS:
make buildkernel KERNCONF=YOUR_KERNEL_HERE [3]
cp sys/${MACHINE}/conf/GENERIC.hints /boot/device.hints [4]
make installkernel KERNCONF=YOUR_KERNEL_HERE
cd sys/boot ; make STRIP="" install [5]
cd sys/boot ; make STRIP= install [5]
[6]
<reboot in single user> [7]
/usr/src/etc/rc.d/preseedrandom [8]
mergemaster -p [9]
rm -rf /usr/include/g++
make installworld
mergemaster -i [10]
rm -f /sbin/mountd
make installworld [11]
mergemaster -i [12]
<reboot>
Make sure that you've read the UPDATING file to understand the
tweaks to various things you need. At this point in the life
cycle of current, things change often and you are on your own
to cope. The defaults can also change, so please read ALL of
the UPDATING entries.
Also, if you are tracking -current, you must be subscribed to
[email protected]. Make sure that before you update
your sources that you have read and understood all the recent
messages there. If in doubt, please track -stable which has
much fewer pitfalls.
cycle of stable, things change fairly rarely. However, many
changes from 4.x to 5.x are not reflected in this breif section.
The defaults can also change, so please read ALL of the UPDATING
entries.
If you have any ports or packages installed on the system, please
see /usr/ports/UPDATING. The following items are known to cause
@@ -1889,6 +1935,18 @@ COMMON ITEMS:
(except rc.conf) may cause problems.
(e) Device names have changed and MAKEDEV is gone.
(f) The boot loader defaults have changed, which may cause confusion.
(g) If the build dies for some reason and you reboot, you'll be booting
with new libraries, but old paths. You will need to tell ldconfig
about them with
ldconfig /lib /usr/lib /usr/local/lib
(h) If the system appears to hang, try toggling the scroll lock. Many
kvm switches use Scroll Lock to switch screens and on such systems
a hang can often just be scroll lock active.
(i) named now runs in a chroot unless you disable this. See
named_chrootdir in /etc/defaults/rc.conf for details on restoring
4.x behavior.
(j) Ports that use PAM on 4.x should be recompiled. This is especially
true for sudo. know thy root password before the upgrade!
[1] Before you upgrade, please make sure that you are not using
compatibility slices. These are device names of the form, on i386 and
@@ -1917,7 +1975,14 @@ COMMON ITEMS:
[4] If you have legacy ISA devices, you may need to create your own
device.hints to reflect your unique hardware configuration.
[5] 4.x boot loader can be used to boot a 5.x system, however it is
[5] Since make installkernel also does a make heirarchy, PAM will
stop working because /etc/pam.d's existance overrides /etc/pam.conf.
If you want to login to your system after the install kernel, or if
you have accidentally rebooted a remote system into multi-user, the
existance of /etc/pam.d will cause remote logins to fail. It is
safe to remove it at this step as it will be recreated later.
[6] 4.x boot loader can be used to boot a 5.x system, however it is
difficult to do that at best. If you wish to try, then you should
interrupt the boot and at the ok prompt type:
ok unload
@@ -1925,13 +1990,12 @@ COMMON ITEMS:
If this fails to work, you must install a new boot loader as described
here.
[6] If you have third party modules, such as vmware, you should
[7] If you have third party modules, such as vmware, you should
disable them at this point so they don't crash your system on reboot.
[7] From the bootblocks, boot -s, and then do
[8] From the bootblocks, boot -s, and then do
fsck -p
mount -u /
mount -a
mount -a -t ufs
cd /usr/src
adjkerntz -i # if CMOS is wall time
Also, when doing a major release upgrade, it is required that you boot
@@ -1940,23 +2004,30 @@ COMMON ITEMS:
your userland. These are harmless and can be ignored while you
proceed to the next step.
[8] In order to create temporary files, /dev/random must be
[9] In order to create temporary files, /dev/random must be
initialized by feeding data into it. /usr/src/etc/rc.d/preseedrandom
takes care of this.
[9] Usually this step is a noop. However, from time to time you may
[10] Usually this step is a noop. However, from time to time you may
need to do this if you get unknown user in the following step. It
never hurts to do it all the time. You may need to install a new
mergemaster (cd src/usr.sbin/mergemaster && make install) after the
buildworld before this step if you last updated from current before
20020224 or from -stable before 20020408.
20020224 or from -stable before 20020408. If you are installing not
from /usr/src, don't forget the -m option.
[10] Note: This step is non-optional. Failure to do this step can
[11] If you are using a non-standard /usr/obj, you need to set
an appropriate MAKEOBJDIRPREFIX before this step.
[12] Note: This step is non-optional. Failure to do this step can
result in a significant reduction in the functionality of the system.
Attempting to do it by hand is not recommended and those that pursue
this avenue should read this file carefully, as well as the archives
of freebsd-current and freebsd-hackers mailing lists for potential
gotchas.
gotchas. Also, if you are installing not from /usr/src, don't
forget the -m option. Also note: since many libraries moved into
/lib with 5.x, failure to run mergemaster will result in many
shared libraries that should be there not being found.
FORMAT:
-2
View File
@@ -1,8 +1,6 @@
# @(#)Makefile 8.1 (Berkeley) 5/31/93
# $FreeBSD$
MAINTAINER= [email protected]
PROG= dd
SRCS= args.c conv.c conv_tab.c dd.c misc.c position.c
+3 -2
View File
@@ -1,3 +1,4 @@
.\"-
.\" Copyright (c) 1983, 1988, 1990, 1993
.\" The Regents of the University of California. All rights reserved.
.\"
@@ -28,7 +29,7 @@
.\" @(#)hostname.1 8.2 (Berkeley) 4/28/95
.\" $FreeBSD$
.\"
.Dd April 28, 1995
.Dd May 12, 2005
.Dt HOSTNAME 1
.Os
.Sh NAME
@@ -45,7 +46,7 @@ utility prints the name of the current host.
The super-user can
set the hostname by supplying an argument; this is usually done in the
network initialization script
.Pa /etc/rc.network ,
.Pa /etc/rc.d/hostname ,
normally run at boot
time.
This script uses the
+8 -1
View File
@@ -31,10 +31,12 @@
.Nd dump or modify the kernel environment
.Sh SYNOPSIS
.Nm
.Op Fl h
.Op Fl hq
.Nm
.Op Fl q
.Ar variable Ns Op = Ns Ar value
.Nm
.Op Fl q
.Fl u
.Ar variable
.Sh DESCRIPTION
@@ -59,6 +61,11 @@ If the environment variable is followed by an optional
.Ar value ,
.Nm
will set the environment variable to this value.
.Pp
If the
.Fl q
option is set, warnings normally printed as a result of being unable to
perform the requested operation will be suppressed.
.Sh SEE ALSO
.Xr kenv 2 ,
.Xr loader 8
+12 -8
View File
@@ -42,15 +42,16 @@ static int ksetenv(char *, char *);
static int kunsetenv(char *);
static int hflag = 0;
static int qflag = 0;
static int uflag = 0;
static void
usage(void)
{
(void)fprintf(stderr, "%s\n%s\n%s\n",
"usage: kenv [-h]",
" kenv variable[=value]",
" kenv -u variable");
"usage: kenv [-hq]",
" kenv [-q] variable[=value]",
" kenv [-q] -u variable");
exit(1);
}
@@ -63,11 +64,14 @@ main(int argc, char **argv)
error = 0;
val = NULL;
env = NULL;
while ((ch = getopt(argc, argv, "hu")) != -1) {
while ((ch = getopt(argc, argv, "hqu")) != -1) {
switch (ch) {
case 'h':
hflag++;
break;
case 'q':
qflag++;
break;
case 'u':
uflag++;
break;
@@ -93,21 +97,21 @@ main(int argc, char **argv)
usage();
if (env == NULL) {
error = kdumpenv();
if (error)
if (error && !qflag)
warn("kdumpenv");
} else if (val == NULL) {
if (uflag) {
error = kunsetenv(env);
if (error)
if (error && !qflag)
warnx("unable to unset %s", env);
} else {
error = kgetenv(env);
if (error)
if (error && !qflag)
warnx("unable to get %s", env);
}
} else {
error = ksetenv(env, val);
if (error)
if (error && !qflag)
warnx("unable to set %s to %s", env, val);
}
return (error);
+48 -52
View File
@@ -176,29 +176,17 @@ using base 2 for sizes.
.It Fl i
For each file, print the file's file serial number (inode number).
.It Fl k
If the
.Fl s
option is specified, print the file size allocation in kilobytes,
not blocks.
This option overrides the environment variable
.Ev BLOCKSIZE .
Note that
.Fl k
is mutually exclusive to
.Fl h ,
and later
.Fl k
will nullify earlier
.Fl h .
This has the same effect as setting environment variable
.Ev BLOCKSIZE
to 1024, except that it also nullifies any
.Fl h
options to its left.
.It Fl l
(The lowercase letter
.Dq ell . )
List in long format.
(See below.)
A total sum (in blocks, see the
.Fl s
option for the block size unit) for all the file
sizes is output on a line before the long listing.
List files in the long format, as described in the
.Sx The Long Format
subsection below.
.It Fl m
Stream output format; list files across the page, separated by commas.
.It Fl n
@@ -223,13 +211,12 @@ this is the default when output is to a terminal.
Reverse the order of the sort to get reverse
lexicographical order or the oldest entries first.
.It Fl s
Display the number of file system blocks actually used by each file, in units
of 512 bytes, where partial units are rounded up to the next integer value.
A total sum for all the file
sizes is output on a line before the listing.
The environment variable
.Ev BLOCKSIZE
overrides the unit size of 512 bytes.
Display the number of blocks used in the file system by each file.
Block sizes and directory totals are handled as described in
.Sx The Long Format
subsection below, except (if the long format is not also requested)
the directory totals are not output when the output is in a
single column, even if multi-column output is requested.
.It Fl t
Sort by time modified (most recently modified
first) before sorting the operands by lexicographical
@@ -315,10 +302,6 @@ number of bytes in the file, abbreviated
month, day-of-month file was last modified,
hour file last modified, minute file last
modified, and the pathname.
In addition, for each directory whose contents are displayed, the total
number of 512-byte blocks used by the files in the directory is displayed
on a line by itself immediately before the information for the files in the
directory.
.Pp
If the modification time of the file is more than 6 months
in the past or future, then the year of the last modification
@@ -337,6 +320,24 @@ If the file is a symbolic link the pathname of the
linked-to file is preceded by
.Dq Li -> .
.Pp
The listing of a directory's contents is preceded
by a labeled total number of blocks used in the file system by the files
which are listed as the directory's contents
(which may or may not include
.Pa \&.
and
.Pa ..
and other files which start with a dot, depending on other options).
.Pp
The default block size is 512 bytes.
The block size may be set with option
.Fl k
or environment variable
.Ev BLOCKSIZE .
Numbers of blocks in the output will have been rounded up so the
numbers of bytes is at least as many as used by the corresponding
file system blocks (which might have a different size).
.Pp
The file mode printed under the
.Fl l
option consists of the
@@ -438,21 +439,6 @@ utility does not show the actual ACL;
use
.Xr getfacl 1
to do this.
.Sh EXAMPLES
The following is how to do an
.Nm
listing sorted by size (and shows why
.Nm
does not need a separate option for this):
.Pp
.Dl "ls -l | sort -n +4"
.Pp
Additionally, the
.Fl r
flag to
.Xr sort 1
may be used
to get the results sorted from largest to smallest (a reverse sort).
.Sh DIAGNOSTICS
.Ex -std
.Sh ENVIRONMENT
@@ -460,12 +446,15 @@ The following environment variables affect the execution of
.Nm :
.Bl -tag -width ".Ev CLICOLOR_FORCE"
.It Ev BLOCKSIZE
If the environment variable
.Ev BLOCKSIZE
is set, the block counts
(see
.Fl s )
will be displayed in units of that size block.
If this is set, its value, rounded up to 512 or down to a
multiple of 512, will be used as the block size in bytes by the
.Fl l
and
.Fl s
options.
See
.Sx The Long Format
subsection for more information.
.It Ev CLICOLOR
Use
.Tn ANSI
@@ -675,3 +664,10 @@ command appeared in
.Sh BUGS
To maintain backward compatibility, the relationships between the many
options are quite complex.
.Pp
The exception mentioned in the
.Fl s
option description might be a feature that was
based on the fact that single-column output
usually goes to something other than a terminal.
It is debatable whether this is a design bug.
+1 -1
View File
@@ -103,7 +103,7 @@ The options are as follows:
.Bl -tag -width indent
.It Fl a
Display information about other users' processes as well as your own.
This will skip any processes which do not have a controlling teminal,
This will skip any processes which do not have a controlling terminal,
unless the
.Fl x
option is also specified.
-1
View File
@@ -2,7 +2,6 @@
# $FreeBSD$
PROG= rm
SRCS= rm.c
LINKS= ${BINDIR}/rm ${BINDIR}/unlink
MLINKS= rm.1 unlink.1
+27 -20
View File
@@ -1,3 +1,4 @@
.\"-
.\" Copyright (c) 1990, 1993, 1994
.\" The Regents of the University of California. All rights reserved.
.\"
@@ -31,7 +32,7 @@
.\" @(#)rm.1 8.5 (Berkeley) 12/5/94
.\" $FreeBSD$
.\"
.Dd January 28, 1999
.Dd September 29, 2005
.Dt RM 1
.Os
.Sh NAME
@@ -40,7 +41,8 @@
.Nd remove directory entries
.Sh SYNOPSIS
.Nm
.Op Fl dfiIPRrvW
.Op Fl f | i
.Op Fl dIPRrvW
.Ar
.Nm unlink
.Ar file
@@ -86,6 +88,10 @@ yet provides almost the same level of protection against mistakes.
Overwrite regular files before deleting them.
Files are overwritten three times, first with the byte pattern 0xff,
then 0x00, and then 0xff again, before they are deleted.
Specifying this flag for a read only file will cause
.Nm
to generate an error message and exit.
The file will not be removed or overwritten.
.It Fl R
Attempt to remove the file hierarchy rooted in each file argument.
The
@@ -117,9 +123,10 @@ The
utility removes symbolic links, not the files referenced by the links.
.Pp
It is an error to attempt to remove the files
.Dq .\&
.Pa / ,
.Pa .\&
or
.Dq .. .
.Pa .. .
.Pp
When the utility is called as
.Nm unlink ,
@@ -161,22 +168,6 @@ path reference.
For example:
.Dl rm /home/user/-filename
.Dl rm ./-filename
.Sh SEE ALSO
.Xr chflags 1 ,
.Xr rmdir 1 ,
.Xr undelete 2 ,
.Xr unlink 2 ,
.Xr fts 3 ,
.Xr getopt 3 ,
.Xr symlink 7
.Sh BUGS
The
.Fl P
option assumes that the underlying file system is a fixed-block file
system.
UFS is a fixed-block file system, LFS is not.
In addition, only regular files are overwritten, other types of files
are not.
.Sh COMPATIBILITY
The
.Nm
@@ -192,6 +183,14 @@ Also, historical
.Bx
implementations prompted on the standard output,
not the standard error output.
.Sh SEE ALSO
.Xr chflags 1 ,
.Xr rmdir 1 ,
.Xr undelete 2 ,
.Xr unlink 2 ,
.Xr fts 3 ,
.Xr getopt 3 ,
.Xr symlink 7
.Sh STANDARDS
The
.Nm
@@ -207,3 +206,11 @@ A
.Nm
command appeared in
.At v1 .
.Sh BUGS
The
.Fl P
option assumes that the underlying file system is a fixed-block file
system.
UFS is a fixed-block file system, LFS is not.
In addition, only regular files are overwritten, other types of files
are not.
+38 -9
View File
@@ -64,6 +64,7 @@ uid_t uid;
int check(char *, char *, struct stat *);
int check2(char **);
void checkdot(char **);
void checkslash(char **);
void rm_file(char **);
int rm_overwrite(char *, struct stat *);
void rm_tree(char **);
@@ -72,9 +73,9 @@ void usage(void);
/*
* rm --
* This rm is different from historic rm's, but is expected to match
* POSIX 1003.2 behavior. The most visible difference is that -f
* POSIX 1003.2 behavior. The most visible difference is that -f
* has two specific effects now, ignore non-existent files and force
* file removal.
* file removal.
*/
int
main(int argc, char *argv[])
@@ -145,6 +146,8 @@ main(int argc, char *argv[])
}
checkdot(argv);
if (getenv("POSIXLY_CORRECT") == NULL)
checkslash(argv);
uid = geteuid();
if (*argv) {
@@ -189,8 +192,11 @@ rm_tree(char **argv)
flags |= FTS_NOSTAT;
if (Wflag)
flags |= FTS_WHITEOUT;
if (!(fts = fts_open(argv, flags, NULL)))
if (!(fts = fts_open(argv, flags, NULL))) {
if (fflag && errno == ENOENT)
return;
err(1, "fts_open");
}
while ((p = fts_read(fts)) != NULL) {
switch (p->fts_info) {
case FTS_DNR:
@@ -301,6 +307,7 @@ err:
}
if (errno)
err(1, "fts_read");
fts_close(fts);
}
void
@@ -443,14 +450,11 @@ check(char *path, char *name, struct stat *sp)
else {
/*
* If it's not a symbolic link and it's unwritable and we're
* talking to a terminal, ask. Symbolic links are excluded
* talking to a terminal, ask. Symbolic links are excluded
* because their permissions are meaningless. Check stdin_ok
* first because we may not have stat'ed the file.
* Also skip this check if the -P option was specified because
* we will not be able to overwrite file contents and will
* barf later.
*/
if (!stdin_ok || S_ISLNK(sp->st_mode) || Pflag ||
if (!stdin_ok || S_ISLNK(sp->st_mode) ||
(!access(name, W_OK) &&
!(sp->st_flags & (SF_APPEND|SF_IMMUTABLE)) &&
(!(sp->st_flags & (UF_APPEND|UF_IMMUTABLE)) || !uid)))
@@ -458,11 +462,15 @@ check(char *path, char *name, struct stat *sp)
strmode(sp->st_mode, modep);
if ((flagsp = fflagstostr(sp->st_flags)) == NULL)
err(1, "fflagstostr");
if (Pflag)
errx(1,
"%s: -P was specified, but file is not writable",
path);
(void)fprintf(stderr, "override %s%s%s/%s %s%sfor %s? ",
modep + 1, modep[9] == ' ' ? "" : " ",
user_from_uid(sp->st_uid, 0),
group_from_gid(sp->st_gid, 0),
*flagsp ? flagsp : "", *flagsp ? " " : "",
*flagsp ? flagsp : "", *flagsp ? " " : "",
path);
free(flagsp);
}
@@ -474,6 +482,27 @@ check(char *path, char *name, struct stat *sp)
return (first == 'y' || first == 'Y');
}
#define ISSLASH(a) ((a)[0] == '/' && (a)[1] == '\0')
void
checkslash(char **argv)
{
char **t, **u;
int complained;
complained = 0;
for (t = argv; *t;) {
if (ISSLASH(*t)) {
if (!complained++)
warnx("\"/\" may not be removed");
eval = 1;
for (u = t; u[0] != NULL; ++u)
u[0] = u[1];
} else {
++t;
}
}
}
int
check2(char **argv)
{
+1 -1
View File
@@ -242,7 +242,7 @@ unaliascmd(int argc __unused, char **argv __unused)
}
}
for (i = 0; *argptr; argptr++)
i = unalias(*argptr);
i |= unalias(*argptr);
return (i);
}
+1
View File
@@ -77,6 +77,7 @@ returncmd return
setcmd set
setvarcmd setvar
shiftcmd shift
timescmd times
trapcmd trap
truecmd : true
typecmd type
+55 -13
View File
@@ -42,6 +42,7 @@ __FBSDID("$FreeBSD$");
#include <signal.h>
#include <stdlib.h>
#include <unistd.h>
#include <sys/resource.h>
#include <sys/wait.h> /* For WIFSIGNALED(status) */
#include <errno.h>
@@ -90,8 +91,8 @@ int exitstatus; /* exit status of last command */
int oexitstatus; /* saved exit status */
STATIC void evalloop(union node *);
STATIC void evalfor(union node *);
STATIC void evalloop(union node *, int);
STATIC void evalfor(union node *, int);
STATIC void evalcase(union node *, int);
STATIC void evalsubshell(union node *, int);
STATIC void expredir(union node *);
@@ -182,6 +183,9 @@ evalstring(char *s)
void
evaltree(union node *n, int flags)
{
int do_etest;
do_etest = 0;
if (n == NULL) {
TRACE(("evaltree(NULL) called\n"));
exitstatus = 0;
@@ -193,7 +197,7 @@ evaltree(union node *n, int flags)
TRACE(("evaltree(0x%lx: %d) called\n", (long)n, n->type));
switch (n->type) {
case NSEMI:
evaltree(n->nbinary.ch1, 0);
evaltree(n->nbinary.ch1, flags & ~EV_EXIT);
if (evalskip)
goto out;
evaltree(n->nbinary.ch2, flags);
@@ -219,6 +223,7 @@ evaltree(union node *n, int flags)
break;
case NSUBSHELL:
evalsubshell(n, flags);
do_etest = !(flags & EV_TESTED);
break;
case NBACKGND:
evalsubshell(n, flags);
@@ -237,10 +242,10 @@ evaltree(union node *n, int flags)
}
case NWHILE:
case NUNTIL:
evalloop(n);
evalloop(n, flags & ~EV_EXIT);
break;
case NFOR:
evalfor(n);
evalfor(n, flags & ~EV_EXIT);
break;
case NCASE:
evalcase(n, flags);
@@ -256,9 +261,11 @@ evaltree(union node *n, int flags)
case NPIPE:
evalpipe(n);
do_etest = !(flags & EV_TESTED);
break;
case NCMD:
evalcommand(n, flags, (struct backcmd *)NULL);
do_etest = !(flags & EV_TESTED);
break;
default:
out1fmt("Node type = %d\n", n->type);
@@ -268,15 +275,13 @@ evaltree(union node *n, int flags)
out:
if (pendingsigs)
dotrap();
if ((flags & EV_EXIT) || (eflag && exitstatus
&& !(flags & EV_TESTED) && (n->type == NCMD ||
n->type == NSUBSHELL)))
if ((flags & EV_EXIT) || (eflag && exitstatus != 0 && do_etest))
exitshell(exitstatus);
}
STATIC void
evalloop(union node *n)
evalloop(union node *n, int flags)
{
int status;
@@ -300,7 +305,7 @@ skipping: if (evalskip == SKIPCONT && --skipcount <= 0) {
if (exitstatus == 0)
break;
}
evaltree(n->nbinary.ch2, 0);
evaltree(n->nbinary.ch2, flags);
status = exitstatus;
if (evalskip)
goto skipping;
@@ -312,7 +317,7 @@ skipping: if (evalskip == SKIPCONT && --skipcount <= 0) {
STATIC void
evalfor(union node *n)
evalfor(union node *n, int flags)
{
struct arglist arglist;
union node *argp;
@@ -333,7 +338,7 @@ evalfor(union node *n)
loopnest++;
for (sp = arglist.list ; sp ; sp = sp->next) {
setvar(n->nfor.var, sp->text, 0);
evaltree(n->nfor.body, 0);
evaltree(n->nfor.body, flags);
if (evalskip) {
if (evalskip == SKIPCONT && --skipcount <= 0) {
evalskip = 0;
@@ -972,6 +977,7 @@ commandcmd(int argc, char **argv)
struct strlist *sp;
char *path;
int ch;
int cmd = -1;
for (sp = cmdenviron; sp ; sp = sp->next)
setvareq(sp->text, VEXPORT|VSTACK);
@@ -979,11 +985,17 @@ commandcmd(int argc, char **argv)
optind = optreset = 1;
opterr = 0;
while ((ch = getopt(argc, argv, "p")) != -1) {
while ((ch = getopt(argc, argv, "pvV")) != -1) {
switch (ch) {
case 'p':
path = stdpath;
break;
case 'v':
cmd = TYPECMD_SMALLV;
break;
case 'V':
cmd = TYPECMD_BIGV;
break;
case '?':
default:
error("unknown option: -%c", optopt);
@@ -992,6 +1004,11 @@ commandcmd(int argc, char **argv)
argc -= optind;
argv += optind;
if (cmd != -1) {
if (argc != 1)
error("wrong number of arguments");
return typecmd_impl(2, argv - 1, cmd);
}
if (argc != 0) {
old = handler;
handler = &loc;
@@ -1062,3 +1079,28 @@ execcmd(int argc, char **argv)
}
return 0;
}
int
timescmd(int argc __unused, char **argv __unused)
{
struct rusage ru;
long shumins, shsmins, chumins, chsmins;
double shusecs, shssecs, chusecs, chssecs;
if (getrusage(RUSAGE_SELF, &ru) < 0)
return 1;
shumins = ru.ru_utime.tv_sec / 60;
shusecs = ru.ru_utime.tv_sec % 60 + ru.ru_utime.tv_usec / 1000000.;
shsmins = ru.ru_stime.tv_sec / 60;
shssecs = ru.ru_stime.tv_sec % 60 + ru.ru_stime.tv_usec / 1000000.;
if (getrusage(RUSAGE_CHILDREN, &ru) < 0)
return 1;
chumins = ru.ru_utime.tv_sec / 60;
chusecs = ru.ru_utime.tv_sec % 60 + ru.ru_utime.tv_usec / 1000000.;
chsmins = ru.ru_stime.tv_sec / 60;
chssecs = ru.ru_stime.tv_sec % 60 + ru.ru_stime.tv_usec / 1000000.;
out1fmt("%ldm%.3fs %ldm%.3fs\n%ldm%.3fs %ldm%.3fs\n", shumins,
shusecs, shsmins, shssecs, chumins, chusecs, chsmins, chssecs);
return 0;
}
+1
View File
@@ -56,6 +56,7 @@ int returncmd(int, char **);
int falsecmd(int, char **);
int truecmd(int, char **);
int execcmd(int, char **);
int timescmd(int, char **);
int commandcmd(int, char **);
/* in_function returns nonzero if we are currently evaluating a function */
+47 -12
View File
@@ -705,11 +705,12 @@ unsetfunc(char *name)
}
/*
* Locate and print what a word is...
* Shared code for the following builtin commands:
* type, command -v, command -V
*/
int
typecmd(int argc, char **argv)
typecmd_impl(int argc, char **argv, int cmd)
{
struct cmdentry entry;
struct tblentry *cmdp;
@@ -720,20 +721,28 @@ typecmd(int argc, char **argv)
extern char *const parsekwd[];
for (i = 1; i < argc; i++) {
out1str(argv[i]);
if (cmd != TYPECMD_SMALLV)
out1str(argv[i]);
/* First look at the keywords */
for (pp = (char **)parsekwd; *pp; pp++)
if (**pp == *argv[i] && equal(*pp, argv[i]))
break;
if (*pp) {
out1str(" is a shell keyword\n");
if (cmd == TYPECMD_SMALLV)
out1fmt("%s\n", argv[i]);
else
out1str(" is a shell keyword\n");
continue;
}
/* Then look at the aliases */
if ((ap = lookupalias(argv[i], 1)) != NULL) {
out1fmt(" is an alias for %s\n", ap->val);
if (cmd == TYPECMD_SMALLV)
out1fmt("alias %s='%s'\n", argv[i], ap->val);
else
out1fmt(" is an alias for %s\n", ap->val);
continue;
}
@@ -756,29 +765,55 @@ typecmd(int argc, char **argv)
name = padvance(&path, argv[i]);
stunalloc(name);
} while (--j >= 0);
out1fmt(" is%s %s\n",
cmdp ? " a tracked alias for" : "", name);
if (cmd == TYPECMD_SMALLV)
out1fmt("%s\n", name);
else
out1fmt(" is%s %s\n",
(cmdp && cmd == TYPECMD_TYPE) ?
" a tracked alias for" : "",
name);
} else {
if (access(argv[i], X_OK) == 0)
out1fmt(" is %s\n", argv[i]);
if (access(argv[i], X_OK) == 0) {
if (cmd == TYPECMD_SMALLV)
out1fmt("%s\n", argv[i]);
else
out1fmt(" is %s\n", argv[i]);
}
else
out1fmt(": %s\n", strerror(errno));
}
break;
}
case CMDFUNCTION:
out1str(" is a shell function\n");
if (cmd == TYPECMD_SMALLV)
out1fmt("%s\n", argv[i]);
else
out1str(" is a shell function\n");
break;
case CMDBUILTIN:
out1str(" is a shell builtin\n");
if (cmd == TYPECMD_SMALLV)
out1fmt("%s\n", argv[i]);
else
out1str(" is a shell builtin\n");
break;
default:
out1str(": not found\n");
if (cmd != TYPECMD_SMALLV)
out1str(": not found\n");
error |= 127;
break;
}
}
return error;
}
/*
* Locate and print what a word is...
*/
int
typecmd(int argc, char **argv)
{
return typecmd_impl(argc, argv, TYPECMD_TYPE);
}
+7
View File
@@ -39,6 +39,12 @@
#define CMDBUILTIN 1 /* command is a shell builtin */
#define CMDFUNCTION 2 /* command is a shell function */
/* values for typecmd_impl's third parameter */
enum {
TYPECMD_SMALLV, /* command -v */
TYPECMD_BIGV, /* command -V */
TYPECMD_TYPE /* type */
};
struct cmdentry {
int cmdtype;
@@ -63,5 +69,6 @@ void deletefuncs(void);
void addcmdentry(char *, struct cmdentry *);
void defun(char *, union node *);
int unsetfunc(char *);
int typecmd_impl(int, char **, int);
int typecmd(int, char **);
void clearcmdentry(int);
+1 -1
View File
@@ -1162,7 +1162,7 @@ expmeta(char *enddir, char *name)
if (*p == '\0')
break;
}
if (metaflag == 0 || stat(expdir, &statb) >= 0)
if (metaflag == 0 || lstat(expdir, &statb) >= 0)
addfname(expdir);
return;
}
+2 -1
View File
@@ -926,7 +926,8 @@ dowait(int block, struct job *job)
in_dowait--;
if (breakwaitcmd != 0) {
breakwaitcmd = 0;
return -1;
if (pid <= 0)
return -1;
}
if (pid <= 0)
return pid;
+16 -2
View File
@@ -57,7 +57,10 @@ ckmalloc(int nbytes)
{
pointer p;
if ((p = malloc(nbytes)) == NULL)
INTOFF;
p = malloc(nbytes);
INTON;
if (p == NULL)
error("Out of space");
return p;
}
@@ -70,11 +73,22 @@ ckmalloc(int nbytes)
pointer
ckrealloc(pointer p, int nbytes)
{
if ((p = realloc(p, nbytes)) == NULL)
INTOFF;
p = realloc(p, nbytes);
INTON;
if (p == NULL)
error("Out of space");
return p;
}
void
ckfree(pointer p)
{
INTOFF;
free(p);
INTON;
}
/*
* Make a copy of a string in safe storage.
+1 -2
View File
@@ -48,6 +48,7 @@ extern int herefd;
pointer ckmalloc(int);
pointer ckrealloc(pointer, int);
void ckfree(pointer);
char *savestr(char *);
pointer stalloc(int);
void stunalloc(pointer);
@@ -72,5 +73,3 @@ void ungrabstackstr(char *, char *);
#define STTOPC(p) p[-1]
#define STADJUST(amount, p) (p += (amount), sstrnleft -= (amount))
#define grabstackstr(p) stalloc(stackblocksize() - sstrnleft)
#define ckfree(p) free((pointer)(p))
+3 -1
View File
@@ -270,18 +270,20 @@ umaskcmd(int argc __unused, char **argv)
mask = 0;
do {
if (*ap >= '8' || *ap < '0')
error("Illegal number: %s", argv[1]);
error("Illegal number: %s", *argptr);
mask = (mask << 3) + (*ap - '0');
} while (*++ap != '\0');
umask(mask);
} else {
void *set;
INTOFF;
if ((set = setmode (ap)) == 0)
error("Illegal number: %s", ap);
mask = getmode (set, ~mask & 0777);
umask(~mask & 0777);
free(set);
INTON;
}
}
return 0;
+8 -11
View File
@@ -196,7 +196,7 @@ options(int cmdline)
STATIC void
minus_o(char *name, int val)
{
int doneset, i;
int i;
if (name == NULL) {
if (val) {
@@ -207,16 +207,13 @@ minus_o(char *name, int val)
optlist[i].val ? "on" : "off");
} else {
/* Output suitable for re-input to shell. */
for (doneset = i = 0; i < NOPTS; i++)
if (optlist[i].val) {
if (!doneset) {
out1str("set");
doneset = 1;
}
out1fmt(" -o %s", optlist[i].name);
}
if (doneset)
out1c('\n');
for (i = 0; i < NOPTS; i++) {
if (i % 6 == 0)
out1str(i == 0 ? "set" : "\nset");
out1fmt(" %co %s", optlist[i].val ? '-' : '+',
optlist[i].name);
}
out1c('\n');
}
} else {
for (i = 0; i < NOPTS; i++)
+4
View File
@@ -134,6 +134,10 @@ outqstr(const char *p, struct output *file)
{
char ch;
if (p[0] == '\0') {
outstr("''", file);
return;
}
if (p[strcspn(p, "|&;<>()$`\\\"'")] == '\0' && (!ifsset() ||
p[strcspn(p, ifsval())] == '\0')) {
outstr(p, file);
+3 -2
View File
@@ -958,6 +958,7 @@ readtoken1(int firstc, char const *syntax, char *eofmark, int striptabs)
USTPUTC('\\', out);
pungetc();
} else if (c == '\n') {
plinno++;
if (doprompt)
setprompt(2);
else
@@ -1599,7 +1600,7 @@ getprompt(void *unused __unused)
*/
case 'h':
case 'H':
ps[i] == '\0';
ps[i] = '\0';
gethostname(&ps[i], PROMPTLEN - i);
/* Skip to end of hostname. */
trim = (*fmt == 'h') ? '.' : '\0';
@@ -1615,7 +1616,7 @@ getprompt(void *unused __unused)
*/
case 'W':
case 'w':
ps[i] == '\0';
ps[i] = '\0';
getcwd(&ps[i], PROMPTLEN - i);
if (*fmt == 'W') {
/* Final path component only. */
+231 -57
View File
@@ -1,3 +1,4 @@
.\"-
.\" Copyright (c) 1991, 1993
.\" The Regents of the University of California. All rights reserved.
.\"
@@ -31,7 +32,7 @@
.\" from: @(#)sh.1 8.6 (Berkeley) 5/4/95
.\" $FreeBSD$
.\"
.Dd July 3, 2004
.Dd December 8, 2005
.Dt SH 1
.Os
.Sh NAME
@@ -97,7 +98,7 @@ generally prompts before each command and handles programming
and command errors differently (as described below).
When first starting, the shell inspects argument 0, and
if it begins with a dash
.Pq Li - ,
.Pq Ql - ,
the shell is also considered a login shell.
This is normally done automatically by the system
when the user first logs in.
@@ -171,15 +172,15 @@ built-in command
(described later in the section called
.Sx Built-in Commands ) .
Introducing an option with a dash
.Pq Li -
.Pq Ql -
enables the option,
while using a plus
.Pq Li +
.Pq Ql +
disables the option.
A
.Dq Li --
or plain
.Dq Li -
.Dq Ql -
will stop option processing and will force the remaining
words on the command line to be treated as arguments.
The
@@ -207,13 +208,22 @@ option if it has been set).
.It Fl e Li errexit
Exit immediately if any untested command fails in non-interactive mode.
The exit status of a command is considered to be
explicitly tested if the command is used to control
an if, elif, while, or until; or if the command is the left
explicitly tested if the command is part of the list used to control
an
.Ic if , elif , while ,
or
.Ic until ;
if the command is the left
hand operand of an
.Dq Li &&
or
.Dq Li ||
operator; or if the command is a pipeline preceded by the
.Ic !\&
operator.
If a shell function is executed and its exit status is explicitly
tested, all commands of the function are considered to be tested as
well.
.It Fl f Li noglob
Disable pathname expansion.
.It Fl I Li ignoreeof
@@ -303,8 +313,9 @@ Useful for debugging.
.Pp
The
.Fl c
option may be used to pass its string argument to the shell
to be interpreted as input.
option causes the commands to be read from the
.Ar string
operand instead of from the standard input.
Keep in mind that this option only accepts a single string as its
argument, hence multi-word strings must be quoted.
.Pp
@@ -353,8 +364,9 @@ The following is a list of valid operators:
.El
.Ss Quoting
Quoting is used to remove the special meaning of certain characters
or words to the shell, such as operators, whitespace, or
keywords.
or words to the shell, such as operators, whitespace, keywords,
or alias names.
.Pp
There are three types of quoting: matched single quotes,
matched double quotes, and backslash.
.Bl -tag -width indent
@@ -365,11 +377,11 @@ it impossible to put single-quotes in a single-quoted string).
.It Double Quotes
Enclosing characters within double quotes preserves the literal
meaning of all characters except dollarsign
.Pq Li $ ,
.Pq Ql $ ,
backquote
.Pq Li ` ,
.Pq Ql ` ,
and backslash
.Pq Li \e .
.Pq Ql \e .
The backslash inside double quotes is historically weird.
It remains literal unless it precedes the following characters,
which it serves to quote:
@@ -379,7 +391,7 @@ which it serves to quote:
.It Backslash
A backslash preserves the literal meaning of the following
character, with the exception of the newline character
.Pq Li \en .
.Pq Ql \en .
A backslash preceding a newline is treated as a line continuation.
.El
.Ss Reserved Words
@@ -420,6 +432,16 @@ to create functions with arguments.
They can also be
used to create lexically obscure code.
This use is discouraged.
.Pp
An alias name may be escaped in a command line, so that it is not
replaced by its alias value, by using quoting characters within or
adjacent to the alias name.
This is most often done by prefixing
an alias name with a backslash to execute a function, built-in, or
normal program with the same name.
See the
.Sx Quoting
subsection.
.Ss Commands
The shell interprets the words it reads according to a
language, the specification of which is outside the scope
@@ -702,7 +724,7 @@ They are executed in the current shell, although they do not affect its
environment when used in pipelines.
.Ss Background Commands (&)
If a command is terminated by the control operator ampersand
.Pq Li & ,
.Pq Ql & ,
the shell executes the command asynchronously;
the shell does not wait for the command to finish
before executing the next command.
@@ -774,10 +796,15 @@ repeat until the exit status of the first list is zero.
The syntax of the
.Ic for
command is:
.Dl Ic for Ar variable Ic in Ar word ...
.Dl Ic for Ar variable Op Ic in Ar word ...
.Dl Ic do Ar list
.Dl Ic done
.Pp
If
.Ic in
and the following words are omitted,
.Ic in Li $@
is used instead.
The words are expanded, and then the list is executed
repeatedly with the variable set to each word in turn.
The
@@ -870,7 +897,7 @@ and the syntax is:
.Bd -ragged -offset indent
.Ic local
.Op Ar variable ...
.Op Ar -
.Op Fl
.Ed
.Pp
The
@@ -947,12 +974,16 @@ The
.Ic set
built-in command can also be used to set or reset them.
.Ss Special Parameters
A special parameter is a parameter denoted by one of the following
special characters.
The value of the parameter is listed
next to its character.
A special parameter is a parameter denoted by a special one-character
name.
The special parameters recognized by the
.Nm
shell of
.Fx
are shown in the following list, exactly as they would appear in input
typed by the user or in the source of a shell script.
.Bl -hang
.It Li *
.It Li $*
Expands to the positional parameters, starting from one.
When
the expansion occurs within a double-quoted string
@@ -965,7 +996,7 @@ or by a
if
.Ev IFS
is unset.
.It Li @
.It Li $@
Expands to the positional parameters, starting from one.
When
the expansion occurs within double-quotes, each positional
@@ -988,26 +1019,26 @@ the two arguments:
.Bd -literal -offset indent
"abc" "def ghi"
.Ed
.It Li #
.It Li $#
Expands to the number of positional parameters.
.It Li \&?
.It Li $\&?
Expands to the exit status of the most recent pipeline.
.It Li -
.It Li $-
(hyphen) Expands to the current option flags (the single-letter
option names concatenated into a string) as specified on
invocation, by the set built-in command, or implicitly
by the shell.
.It Li $
.It Li $$
Expands to the process ID of the invoked shell.
A subshell
retains the same value of $ as its parent.
.It Li \&!
.It Li $\&!
Expands to the process ID of the most recent background
command executed from the current shell.
For a
pipeline, the process ID is that of the last command in the
pipeline.
.It Li 0
.It Li $0
(zero) Expands to the name of the shell or shell script.
.El
.Ss Word Expansions
@@ -1052,11 +1083,11 @@ character is used to introduce parameter expansion, command
substitution, or arithmetic evaluation.
.Ss Tilde Expansion (substituting a user's home directory)
A word beginning with an unquoted tilde character
.Pq Li ~
.Pq Ql ~
is
subjected to tilde expansion.
All the characters up to a slash
.Pq Li /
.Pq Ql /
or the end of the word are treated as a username
and are replaced with the user's home directory.
If the
@@ -1285,13 +1316,13 @@ variable or the output of the command is scanned for these
characters and they are turned into meta-characters.
.Pp
An asterisk
.Pq Li *
.Pq Ql *
matches any string of characters.
A question mark
.Pq Li \&?
.Pq Ql \&?
matches any single character.
A left bracket
.Pq Li [
.Pq Ql [
introduces a character class.
The end of the character class is indicated by a
.Dq Li \&] ;
@@ -1305,7 +1336,7 @@ rather than introducing a character class.
A character class matches any of the characters between the square brackets.
A range of characters may be specified using a minus sign.
The character class may be complemented by making an exclamation point
.Pq Li !\&
.Pq Ql !\&
the first character of the character class.
.Pp
To include a
@@ -1346,8 +1377,7 @@ for the file.
If it is not found in the
.Ev PATH ,
it is sought in the current working directory.
.It Ic alias Op Ar name ...
.It Ic alias Op Ar name Ns = Ns Ar string ...
.It Ic alias Oo Ar name Ns Oo = Ns Ar string Oc ... Oc
If
.Ar name Ns = Ns Ar string
is specified, the shell defines the alias
@@ -1366,6 +1396,9 @@ built-in command prints the names and values of all defined aliases
.Ic unalias ) .
Alias values are written with appropriate quoting so that they are
suitable for re-input to the shell.
Also see the
.Sx Aliases
subsection.
.It Ic bg Op Ar job ...
Continue the specified jobs
(or the current job if no jobs are given)
@@ -1433,7 +1466,8 @@ A synonym for the
.Ic cd
built-in command.
.It Ic command Oo Fl p Oc Op Ar utility Op Ar argument ...
Execute the specified
.It Ic command Oo Fl v | V Oc Op Ar utility
The first form of invocation executes the specified
.Ar utility
as a simple command (see the
.Sx Simple Commands
@@ -1445,10 +1479,39 @@ option is specified, the command search is performed using a
default value of
.Ev PATH
that is guaranteed to find all of the standard utilities.
.It Ic echo Oo Fl e | n Oc Op Ar string
Print
.Ar string
to the standard output with a newline appended.
.Pp
If the
.Fl v
option is specified,
.Ar utility
is not executed but a description of its interpretation by the shell is
printed.
For ordinary commands the output is the path name; for shell built-in
commands, shell functions and keywords only the name is written.
Aliases are printed as
.Dq Ic alias Ar name Ns = Ns Ar value .
.Pp
The
.Fl V
option is identical to
.Fl v
except for the output.
It prints
.Dq Ar utility Ic is Ar description
where
.Ar description
is either
the path name to
.Ar utility ,
a shell builtin,
a shell function,
a shell keyword
or
an alias for
. Ar value .
.It Ic echo Oo Fl e | n Oc Op Ar string ...
Print a space-separated list of the arguments to the standard output
and append a newline character.
.Bl -tag -width indent
.It Fl n
Suppress the output of the trailing newline.
@@ -1528,7 +1591,8 @@ If
is given
it is used as the exit status of the shell;
otherwise the exit status of the preceding command is used.
.It Ic export Oo Fl p Oc Op Ar name ...
.It Ic export Ar name ...
.It Ic export Op Fl p
The specified names are exported so that they will
appear in the environment of subsequent commands.
The only way to un-export a variable is to
@@ -1638,9 +1702,9 @@ the string form of the first operand cannot contain an embedded equal sign.
.Pp
The following environment variables affect the execution of
.Ic fc :
.Bl -tag -width indent
.Bl -tag -width ".Ev HISTSIZE"
.It Ev FCEDIT
Name of the editor to use.
Name of the editor to use for history editing.
.It Ev HISTSIZE
The number of previous commands that are accessible.
.El
@@ -1713,6 +1777,10 @@ option is specified, the PID of each job is also printed.
If the
.Fl s
option is specified, only the PIDs of the jobs are printed, one per line.
.It Ic local Oo Ar variable ... Oc Op Fl
See the
.Sx Functions
subsection.
.It Ic pwd Op Fl L | P
Print the path of the current directory.
The built-in command may
@@ -1778,7 +1846,7 @@ option is specified and the
elapses before any input is supplied,
the
.Ic read
command will return without assigning any values.
command will return an exit status of 1 without assigning any values.
The
.Ar timeout
value may optionally be followed by one of
@@ -1814,6 +1882,10 @@ If the
option is specified, the read-only variables are printed as
.Dq Ic readonly Ar name Ns = Ns Ar value
lines, suitable for re-input to the shell.
.It Ic return Op Ar exitstatus
See the
.Sx Functions
subsection.
.It Ic set Oo Fl /+abCEefIimnpTuVvx Oc Oo Fl /+o Ar longname Oc Oo
.Fl c Ar string Oc Op Fl - Ar arg ...
The
@@ -1848,9 +1920,9 @@ flag may be omitted when specifying arguments to be used
as positional replacement parameters.
This is not recommended,
because the first argument may begin with a dash
.Pq Li -
.Pq Ql -
or a plus
.Pq Li + ,
.Pq Ql + ,
which the
.Ic set
command will interpret as a request to enable or disable options.
@@ -1879,7 +1951,13 @@ A shift sets the value of $1 to the value of $2,
the value of $2 to the value of $3, and so on,
decreasing the value of $# by one.
If there are zero positional parameters, shifting does not do anything.
.It Ic times
Print the amount of time spent executing the shell and its children.
The first output line shows the user and system times for the shell
itself, the second one contains the user and system times for the
children.
.It Ic trap Oo Ar action Oc Ar signal ...
.It Ic trap Fl l
Cause the shell to parse and execute
.Ar action
when any specified
@@ -1891,14 +1969,25 @@ In addition, the pseudo-signal
may be used to specify an action that is performed when the shell terminates.
The
.Ar action
may be null or omitted;
may be an empty string or a dash
.Pq Ar - ;
the former causes the specified signal to be ignored
and the latter causes the default action to be taken.
Omitting the
.Ar action
is another way to request the default action, for compatibility reasons this
usage is not recommended though.
When the shell forks off a subshell,
it resets trapped (but not ignored) signals to the default action.
The
.Ic trap
command has no effect on signals that were ignored on entry to the shell.
.Pp
Option
.Fl l
causes the
.Ic trap
command to display a list of valid signal names.
.It Ic type Op Ar name ...
Interpret each
.Ar name
@@ -1972,16 +2061,19 @@ The maximal number of simultaneous processes for this user ID.
.It Fl v Ar virtualmem
The maximal virtual size of a process, in kilobytes.
.El
.It Ic umask Op Ar mask
.It Ic umask Oo Fl S Oc Op Ar mask
Set the file creation mask (see
.Xr umask 2 )
to the octal value specified by
to the octal or symbolic (see
.Xr chmod 1 )
value specified by
.Ar mask .
If the argument is omitted, the current mask value is printed.
.It Ic unalias Oo Fl a Oc Op Ar name
If
.Ar name
is specified, the shell removes that alias.
If the
.Fl S
option is specified, the output is symbolic, otherwise the output is octal.
.It Ic unalias Oo Fl a Oc Op Ar name ...
The specified alias names are removed.
If
.Fl a
is specified, all aliases are removed.
@@ -2038,12 +2130,94 @@ Similarly, the
.Dq Li set -E )
command can be used to enable a subset of
emacs-style command line editing features.
.Sh ENVIRONMENT
The following environment variables affect the execution of
.Nm :
.Bl -tag -width ".Ev HISTSIZE"
.It Ev CDPATH
The search path used with the
.Ic cd
built-in.
.It Ev EDITOR
The fallback editor used with the
.Ic fc
built-in.
If not set, the default editor is
.Xr ed 1 .
.It Ev FCEDIT
The default editor used with the
.Ic fc
built-in.
.It Ev HISTSIZE
The number of previous commands that are accessible.
.It Ev HOME
The starting directory of
.Nm .
.It Ev IFS
Input Field Separators.
This is normally set to
.Aq space ,
.Aq tab ,
and
.Aq newline .
See the
.Sx White Space Splitting
section for more details.
.It Ev MAIL
The name of a mail file, that will be checked for the arrival of new
mail.
Overridden by
.Ev MAILPATH .
.It Ev MAILPATH
A colon
.Pq Ql \&:
separated list of file names, for the shell to check for incoming
mail.
This environment setting overrides the
.Ev MAIL
setting.
There is a maximum of 10 mailboxes that can be monitored at once.
.It Ev PATH
The default search path for executables.
See the
.Sx Path Search
section for details.
.It Ev PS1
The primary prompt string, which defaults to
.Dq Li "$ " ,
unless you are the superuser, in which case it defaults to
.Dq Li "# " .
.It Ev PS2
The secondary prompt string, which defaults to
.Dq Li "> " .
.It Ev TERM
The default terminal setting for the shell.
This is inherited by children of the shell, and is used in the history
editing modes.
.El
.Sh EXIT STATUS
Errors that are detected by the shell, such as a syntax error, will
cause the shell to exit with a non-zero exit status.
If the shell is not an interactive shell, the execution of the shell
file will be aborted.
Otherwise the shell will return the exit status of the last command
executed, or if the exit builtin is used with a numeric argument, it
will return the argument.
.Sh SEE ALSO
.Xr builtin 1 ,
.Xr chsh 1 ,
.Xr echo 1 ,
.Xr ed 1 ,
.Xr emacs 1 ,
.Xr expr 1 ,
.Xr getopt 1 ,
.Xr pwd 1 ,
.Xr test 1
.Xr test 1 ,
.Xr vi 1 ,
.Xr execve 2 ,
.Xr getrlimit 2 ,
.Xr umask 2 ,
.Xr editrc 5
.Sh HISTORY
A
.Nm
+6 -7
View File
@@ -153,15 +153,14 @@ trapcmd(int argc, char **argv)
if (argc <= 1) {
for (signo = 0 ; signo < sys_nsig ; signo++) {
if (signo < NSIG && trap[signo] != NULL) {
out1str("trap -- ");
out1qstr(trap[signo]);
if (signo == 0) {
out1fmt("trap -- '%s' %s\n",
trap[signo], "exit");
out1str(" exit\n");
} else if (sys_signame[signo]) {
out1fmt("trap -- '%s' %s\n",
trap[signo], sys_signame[signo]);
out1fmt(" %s\n", sys_signame[signo]);
} else {
out1fmt("trap -- '%s' %d\n",
trap[signo], signo);
out1fmt(" %d\n", signo);
}
}
}
@@ -382,7 +381,7 @@ onsig(int signo)
*/
if (Tflag &&
trap[signo] != NULL &&
! trap[signo][0] == '\0' &&
! (trap[signo][0] == '\0') &&
! (trap[signo][0] == ':' && trap[signo][1] == '\0'))
breakwaitcmd = 1;
+3 -1
View File
@@ -541,9 +541,11 @@ exportcmd(int argc, char **argv)
argc -= optind;
argv += optind;
if (values && argc != 0)
error("-p requires no arguments");
listsetvar(cmdenviron);
if (argc != 0) {
while ((name = *argptr++) != NULL) {
while ((name = *argv++) != NULL) {
if ((p = strchr(name, '=')) != NULL) {
p++;
} else {
+2 -2
View File
@@ -142,8 +142,8 @@ print(struct termios *tp, struct winsize *wp, int ldisc, enum FMT fmt)
put("-onlcr", ONLCR, 1);
put("-ocrnl", OCRNL, 0);
put("-oxtabs", OXTABS, 1);
put("-onocr", OXTABS, 0);
put("-onlret", OXTABS, 0);
put("-onocr", ONOCR, 0);
put("-onlret", ONLRET, 0);
/* control flags (hardware state) */
tmp = tp->c_cflag;
+77 -52
View File
@@ -50,7 +50,7 @@
.Sh SYNOPSIS
.Nm amd
.Fl H
.Nm amd
.Nm amd
.Op Fl F Ar conf_file
.Nm amd
.Op Fl nprvHS
@@ -83,7 +83,8 @@
.Sh DESCRIPTION
.Nm Amd
is a daemon that automatically mounts file systems whenever a file or directory
within that file system is accessed. File systems are automatically unmounted
within that file system is accessed.
File systems are automatically unmounted
when they appear to be quiescent.
.Pp
.Nm Amd
@@ -96,17 +97,19 @@ are handled by
.Nm amd ,
which uses the map defined by
.Ar mapname
to determine how to resolve the lookup. Generally, this will be a host name,
to determine how to resolve the lookup.
Generally, this will be a host name,
some file system information and some mount options for the given file system.
.Pp
In the first form depicted above,
.Nm amd
will print a short help string. In the second form, if no options are
will print a short help string.
In the second form, if no options are
specified, or if the
.Fl F
is used,
.Nm amd
will read configuration parameters from the file
is used,
.Nm amd
will read configuration parameters from the file
.Ar conf_file
which defaults to
.Pa /etc/amd.conf .
@@ -121,12 +124,15 @@ The default is
Specify a
.Ar duration ,
in seconds, that a looked up name remains
cached when not in use. The default is 5 minutes.
cached when not in use.
The default is 5 minutes.
.It Fl d Ar domain
Specify the local domain name. If this option is not
Specify the local domain name.
If this option is not
given the domain name is determined from the hostname.
.It Fl k Ar kernel-arch
Specifies the kernel architecture. This is used solely
Specifies the kernel architecture.
This is used solely
to set the ${karch} selector.
.It Fl l Ar logfile
Specify a logfile in which to record mount and unmount events.
@@ -136,31 +142,32 @@ is the string
.Em syslog ,
the log messages will be sent to the system log daemon by
.Xr syslog 3 .
The default syslog facility used is LOG_DAEMON.
The default syslog facility used is LOG_DAEMON.
If you wish to change it, append its name to the log file name,
delimited by a single colon.
For example, if
For example, if
.Ar logfile
is the string
.Dq Li syslog:local7
then
.Nm amd
will log messages via
will log messages via
.Xr syslog 3
using the LOG_LOCAL7 facility (if it exists on the system).
.It Fl n
Normalize hostnames.
The name referred to by ${rhost} is normalized relative to the
host database before being used. The effect is to translate
host database before being used.
The effect is to translate
aliases into ``official'' names.
.It Fl o Ar op_sys_ver
Override the compiled-in version number of the operating system.
Useful when the built in version is not desired for backward
Useful when the built in version is not desired for backward
compatibility reasons.
For example, if the build in version is
.Dq 2.5.1 ,
For example, if the build in version is
.Dq 2.5.1 ,
you can override it to
.Dq 5.5.1 ,
.Dq 5.5.1 ,
and use older maps that were written with the latter in mind.
.It Fl p
Print
@@ -172,7 +179,8 @@ to standard output where it can be saved into a file.
Restart existing mounts.
.Nm Amd
will scan the mount file table to determine which file systems
are currently mounted. Whenever one of these would have
are currently mounted.
Whenever one of these would have
been auto-mounted,
.Nm amd
.Em inherits
@@ -182,25 +190,33 @@ Specify the NFS timeout
.Ar interval ,
in tenths of a second, between
.Tn NFS/RPC
retries (for UDP only). The default
is 0.8 seconds. The second value alters the retransmit counter, which
defaults to 11 retransmissions. Both of these values are used by the kernel
to communicate with amd. Useful defaults are supplied if either or both
retries (for UDP only).
The default
is 0.8 seconds.
The second value alters the retransmit counter, which
defaults to 11 retransmissions.
Both of these values are used by the kernel
to communicate with amd.
Useful defaults are supplied if either or both
values are missing.
.Pp
Amd relies on the kernel RPC retransmit mechanism to trigger mount retries.
The values of these parameters change the overall retry interval. Too long
The values of these parameters change the overall retry interval.
Too long
an interval gives poor interactive response; too short an interval causes
excessive retries.
.It Fl v
Version. Displays version and configuration information on standard error.
Version.
Displays version and configuration information on standard error.
.It Fl w Ar interval
Specify an
.Ar interval ,
in seconds, between attempts to dismount file systems that have exceeded their
cached times. The default is 2 minutes.
cached times.
The default is 2 minutes.
.It Fl x Ar options
Specify run-time logging options. The options are a comma separated list
Specify run-time logging options.
The options are a comma separated list
chosen from: fatal, error, user, warn, info, map, stats, all.
.It Fl y Ar domain
Specify an alternative
@@ -215,10 +231,12 @@ support is not available.
.It Fl C Ar cluster-name
Specify an alternative HP-UX cluster name to use.
.It Fl D Ar option
Select from a variety of debug options. Prefixing an
Select from a variety of debug options.
Prefixing an
option with the string
.Em no
reverses the effect of that option. Options are cumulative.
reverses the effect of that option.
Options are cumulative.
The most useful option is
.Ar all .
.Pp
@@ -232,40 +250,47 @@ and a fuller description is available in the program source.
.It Fl F Ar conf_file
Specify an
.Nm amd
configuration file to use. See
configuration file to use.
See
.Xr amd.conf 5
for description of this file's format. This configuration file is used to
specify any options in lieu of typing many of them on the command line. The
for description of this file's format.
This configuration file is used to
specify any options in lieu of typing many of them on the command line.
The
.Nm amd.conf
file includes directives for every command line option amd has,
and many more that are only available via the configuration file
facility. The configuration file specified by this option is
facility.
The configuration file specified by this option is
processed after all other options have been processed, regardless
of the actual location of this option on the command line.
.It Fl H
Print help and usage string.
.It Fl O Ar op_sys_name
Override the compiled-in name of the operating system.
Override the compiled-in name of the operating system.
Useful when the built in name is not desired for backward
compatibility reasons.
For example, if the build in name is
.Dq sunos5 ,
.Dq sunos5 ,
you can override it to
.Dq sos5
and use older maps which were written with the latter in mind.
.It Fl S
Do not lock the running executable pages of
.Nm amd
into memory. To improve
into memory.
To improve
.Nm amd's
performance, systems that support the
performance, systems that support the
.Xr plock 3
call, could lock the
.Nm amd
process into memory. This way there is less chance the operating system will
process into memory.
This way there is less chance the operating system will
schedule, page out, and swap the
.Nm amd
process as needed. This tends to improve
process as needed.
This tends to improve
.Nm amd's
performance, at the cost of reserving the memory used by the
.Nm amd
@@ -277,7 +302,7 @@ option.
.It Fl T Ar tag
Specify a tag to use with
.Xr amd.conf 5 .
All Map entries tagged with tag will be processed.
All Map entries tagged with tag will be processed.
Map entries that are not tagged are always processed.
Map entries that are tagged with a tag other than
.Ar tag
@@ -330,20 +355,20 @@ the features.
.%T Amd \- The 4.4 BSD Automounter
.Re
.Pp
.Pa http://www.cs.columbia.edu/~ezk/am-utils/
.Sh AUTHORS
.An Jan-Simon Pendry Aq [email protected] ,
Department of Computing, Imperial College, London, UK.
.Pp
.An Erez Zadok Aq [email protected] ,
Department of Computer Science, Columbia University,
New York, USA.
.Pp
Other authors and contributors to am-utils are listed in the
.Pa AUTHORS
file distributed with am-utils.
.Pa http://www.am-utils.org/
.Sh HISTORY
The
.Nm amd
utility first appeared in
.Bx 4.4 .
.Sh AUTHORS
.An Jan-Simon Pendry Aq [email protected] ,
Department of Computing, Imperial College, London, UK.
.Pp
.An Erez Zadok Aq [email protected] ,
Department of Computer Science, Columbia University,
New York, USA.
.Pp
Other authors and contributors to am-utils are listed in the
.Pa AUTHORS
file distributed with am-utils.
+1 -1
View File
@@ -65,7 +65,7 @@ usage (char *progname)
printf ("usage: %s [options] [file ...]\n%s%s%s%s%s%s%s", progname,
" -h --help print this usage and exit\n",
" -i --interactive force interactive mode\n",
" -l --mathlib use the predefine math routnes\n",
" -l --mathlib use the predefined math routines\n",
" -q --quiet don't print initial banner\n",
" -s --standard non-standard bc constructs are errors\n",
" -w --warn warn about non-standard bc constructs\n",
+629 -7
View File
@@ -1,4 +1,626 @@
--- 9.3.4-P1 released ---
2203. [security] Query id generation was cryptographically weak.
[RT # 16915]
2193. [port] win32: BINDInstall.exe is now linked statically.
[RT #16906]
2192. [port] win32: use vcredist_x86.exe to install Visual
Studio's redistributable dlls if building with
Visual Stdio 2005 or later.
--- 9.3.4 released ---
2126. [security] Serialise validation of type ANY responses. [RT #16555]
2124. [security] It was possible to dereference a freed fetch
context. [RT #16584]
--- 9.3.3 released ---
2107. [bug] dighost.c: more cleanup of buffers. [RT #16499]
2104. [port] Fix Solaris SMF error message.
2103. [port] Add /usr/sfw to list of locations for OpenSSL
under Solaris.
2102. [port] Silence solaris 10 warnings.
2101. [bug] OpenSSL version checks were not quite right.
[RT #16476]
2100. [port] win32: copy libeay32.dll to Build\Debug.
2099. [port] win32: more manifiest issues.
--- 9.3.3rc3 released ---
2096. [bug] libbind: handle applications that fail to detect
res_init() failures better.
2095. [port] libbind: alway prototype inet_cidr_ntop_ipv6() and
net_cidr_ntop_ipv6(). [RT #16388]
2094. [contrib] Update named-bootconf. [RT# 16404]
2092. [bug] win32: dig, host, nslookup. Use registry config
if resolv.conf does not exist or no nameservers
listed. [RT #15877]
2091. [port] dighost.c: race condition on cleanup. [RT #16417]
2090. [port] win32: Visual C++ 2005 command line manifest support.
[RT #16417]
2089. [security] Raise the minimum safe OpenSSL versions to
OpenSSL 0.9.7l and OpenSSL 0.9.8d. Versions
prior to these have known security flaws which
are (potentially) exploitable in named. [RT #16391]
2088. [security] Change the default RSA exponent from 3 to 65537.
[RT #16391]
2086. [port] libbind: FreeBSD now has get*by*_r() functions.
[RT #16403]
2085. [doc] win32: added index.html and README to zip. [RT #16201]
2084. [contrib] dbus update for 9.3.3rc2.
2083. [port] win32: Visual C++ 2005 support.
2082. [doc] Document 'cache-file' as a test only option.
--- 9.3.3rc2 released ---
2081. [port] libbind: minor 64-bit portability fix in memcluster.c.
[RT #16360]
2080. [port] libbind: res_init.c did not compile on older versions
of Solaris. [RT #16363]
2076. [bug] Several files were missing #include <config.h>
causing build failures on OSF. [RT #16341]
2074. [bug] dns_request_createvia2(), dns_request_createvia3(),
dns_request_createraw2() and dns_request_createraw3()
failed to send multiple UDP requests. [RT #16349]
2066. [security] Handle SIG queries gracefully. [RT #16300]
--- 9.3.3rc1 released ---
2071. [port] Test whether gcc accepts -fno-strict-aliasing.
[RT #16324]
2070. [bug] The remote address was not always displayed when
reporting dispatch failures. [RT #16315]
2069. [bug] Cross compiling was not working. [RT #16330]
2067. [bug] 'rndc' could close the socket too early triggering
a INSIST under Windows. [RT #16317]
2065. [bug] libbind: probe for HPUX prototypes for
endprotoent_r() and endservent_r(). [RT 16313]
2064. [bug] libbind: silence AIX compiler warnings. [RT #16218]
2063. [bug] Change #1955 introduced a bug which caused the first
'rndc flush' call to not free memory. [RT #16244]
2062. [bug] 'dig +nssearch' was reusing a buffer before it had
been returned by the socket code. [RT #16307]
2057. [bug] Make setting "ra" dependent on both allow-query and
allow-recursion. [RT #16290]
2056. [bug] dig: ixfr= was not being treated case insensitively
at all times. [RT #15955]
2055. [bug] Missing goto after dropping multicast query.
[RT #15944]
2054. [port] freebsd: do not explicitly link against -lpthread.
[RT #16170]
2053. [port] netbsd:libbind: silence compiler warnings. [RT #16220]
2052. [bug] 'rndc' improve connect failed message to report
the failing address. [RT #15978]
2051. [port] More strtol() fixes. [RT #16249]
2050. [bug] Parsing of NSAP records was not case insensitive.
[RT #16287]
2049. [bug] Restore SOA before AXFR when falling back from
a attempted IXFR when transfering in a zone.
Allow a initial SOA query before attempting
a AXFR to be requested. [RT #16156]
2048. [bug] It was possible to loop forever when using
avoid-v4-udp-ports / avoid-v6-udp-ports when
the OS always returned the same local port.
[RT #16182]
2047. [bug] Failed to initialise the interface flags to zero.
[RT #16245]
2043. [port] nsupdate/nslookup: Force the flushing of the prompt
for interactive sessions. [RT#16148]
2038. [bug] dig/nslookup/host was unlinking from wrong list
when handling errors. [RT #16122]
2037. [func] When unlinking the first or last element in a list
check that the list head points to the element to
be unlinked. [RT #15959]
2036. [bug] 'rndc recursing' could cause trigger a REQUIRE.
[RT #16075]
2034. [bug] gcc: set -fno-strict-aliasing. [RT #16124]
--- 9.3.3b1 released ---
2031. [bug] Emit a error message when "rndc refresh" is called on
a non slave/stub zone. [RT # 16073]
2030. [bug] We were being overly conservative when disabling
openssl engine support. [RT #16030]
2029. [bug] host printed out the server multiple times when
specified on the command line. [RT #15992]
2028. [port] linux: socket.c compatability for old systems.
[RT #16015]
2027. [port] libbind: Solaris x86 support. [RT #16020]
2026. [bug] Rate limit the two recursive client exceeded messages.
[RT #16044]
2024. [bug] named emited spurious "zone serial unchanged"
messages on reload. [RT #16027]
2023. [bug] "make install" should create ${localstatedir}/run and
${sysconfdir} if they do not exist. [RT #16033]
2016. [bug] Return a partial answer if recursion is not
allowed but requested and we had the answer
to the original qname. [RT #15945]
2013. [bug] Handle unexpected TSIGs on unsigned AXFR/IXFR
responses more gracefully. [RT #15941]
2009. [bug] libbind: coverity fixes. [RT #15808]
2005. [bug] libbind: Retransmission timeouts should be
based on which attempt it is to the nameserver
and not the nameserver itself. [RT #13548]
2004. [bug] dns_tsig_sign() could pass a NULL pointer to
dst_context_destroy() when cleaning up after a
error. [RT #15835]
2003. [bug] libbind: The DNS name/address lookup functions could
occasionally follow a random pointer due to
structures not being completely zeroed. [RT #15806]
2002. [bug] libbind: tighten the constraints on when
struct addrinfo._ai_pad exists. [RT #15783]
2000. [bug] memmove()/strtol() fix was incomplete. [RT #15812]
1998. [bug] Restrict handling of fifos as sockets to just SunOS.
This allows named to connect to entropy gathering
daemons that use fifos instead of sockets. [RT #15840]
1997. [bug] Named was failing to replace negative cache entries
when a positive one for the type was learnt.
[RT #15818]
1995. [bug] 'host' was reporting multiple "is an alias" messages.
[RT #15702]
1994. [port] OpenSSL 0.9.8 support. [RT #15694]
1993. [bug] Log messsage, via syslog, were missing the space
after the timestamp if "print-time yes" was specified.
[RT #15844]
1991. [cleanup] The configuration data, once read, should be treated
as readonly. Expand the use of const to enforce this
at compile time. [RT #15813]
1990. [bug] libbind: isc's override of broken gettimeofday()
implementions was not always effective.
[RT #15709]
1989. [bug] win32: don't check the service password when
re-installing. [RT #15882]
1985. [protocol] DLV has now been assigned a official type code of
32769. [RT #15807]
Note: care should be taken to ensure you upgrade
both named and dnssec-signzone at the same time for
zones with DLV records where named is the master
server for the zone. Also any zones that contain
DLV records should be removed when upgrading a slave
zone. You do not however have to upgrade all
servers for a zone with DLV records simultaniously.
1982. [bug] DNSKEY was being accepted on the parent side of
a delegation. KEY is still accepted there for
RFC 3007 validated updates. [RT #15620]
1981. [bug] win32: condition.c:wait() could fail to reattain
the mutex lock.
1979. [port] linux: allow named to drop core after changing
user ids. [RT #15753]
1978. [port] Handle systems which have a broken recvmsg().
[RT #15742]
1977. [bug] Silence noisy log message. [RT #15704]
1976. [bug] Handle systems with no IPv4 addresses. [RT #15695]
1975. [bug] libbind: isc_gethexstring() could misparse multi-line
hex strings with comments. [RT #15814]
1974. [doc] List each of the zone types and associated zone
options seperately in the ARM.
1972. [contrib] DBUS dynamic forwarders integation from
Jason Vas Dias <[email protected]>.
1971. [port] linux: make detection of missing IF_NAMESIZE more
robust. [RT #15443]
1970. [bug] nsupdate: adjust UDP timeout when falling back to
unsigned SOA query. [RT #15775]
1969. [bug] win32: the socket code was freeing the socket
structure too early. [RT #15776]
1968. [bug] Missing lock in resolver.c:validated(). [RT #15739]
1966. [bug] Don't set CD when we have fallen back to plain DNS.
[RT #15727]
1963. [port] Tru64 4.0E doesn't support send() and recv().
[RT #15586]
1962. [bug] Named failed to clear old update-policy when it
was removed. [RT #15491]
1961. [bug] Check the port and address of responses forwarded
to dispatch. [RT #15474]
1960. [bug] Update code should set NSEC ttls from SOA MINIMUM.
[RT #15465]
1958. [bug] Named failed to update the zone's secure state
until the zone was reloaded. [RT #15412]
1957. [bug] Dig mishandled responses to class ANY queries.
[RT #15402]
1956. [bug] Improve cross compile support, 'gen' is now built
by native compiler. See README for additional
cross compile support information. [RT #15148]
1955. [bug] Pre-allocate the cache cleaning interator. [RT #14998]
1952. [port] hpux: tell the linker to build a runtime link
path "-Wl,+b:". [RT #14816].
1951. [security] Drop queries from particular well known ports.
Don't return FORMERR to queries from particular
well known ports. [RT #15636]
1950. [port] Solaris 2.5.1 and earlier cannot bind() then connect()
a TCP socket. This prevents the source address being
set for TCP connections. [RT #15628]
1948. [bug] If was possible to trigger a REQUIRE failure in
xfrin.c:maybe_free() if named ran out of memory.
[RT #15568]
1946. [bug] resume_dslookup() could trigger a REQUIRE failure
when using forwarders. [RT #15549]
1944. [cleanup] isc_hash_create() does not need a read/write lock.
[RT #15522]
1943. [bug] Set the loadtime after rolling forward the journal.
[RT #15647]
1942. [bug] If the name of a DNSKEY match that of one in
trusted-keys do not attempt to validate the DNSKEY
using the parents DS RRset. [RT #15649]
1941. [bug] ncache_adderesult() should set eresult even if no
rdataset is passed to it. [RT #15642]
1940. [bug] Fixed a number of error conditions reported by
Coverity.
1939. [bug] The resolver could dereference a null pointer after
validation if all the queries have timed out.
[RT #15528]
1938. [bug] The validator was not correctly handling unsecure
negative responses at or below a SEP. [RT #15528]
1919. [contrib] queryperf: a set of new features: collecting/printing
response delays, printing intermediate results, and
adjusting query rate for the "target" qps.
--- 9.3.2 released ---
--- 9.3.2rc1 released ---
1936. [bug] The validator could leak memory. [RT #15544]
1932. [bug] hpux: LDFLAGS was getting corrupted. [RT #15530]
--- 9.3.2b2 released ---
1930. [port] HPUX: ia64 support. [RT #15473]
1929. [port] FreeBSD: extend use of PTHREAD_SCOPE_SYSTEM.
1926. [bug] The Windows installer did not check for empty
passwords. BINDinstall was being installed in
the wrong place. [RT #15483]
1925. [port] All outer level AC_TRY_RUNs need cross compiling
defaults. [RT #15469]
1924. [port] libbind: hpux ia64 support. [RT #15473]
1923. [bug] ns_client_detach() called too early. [RT #15499]
--- 9.3.2b1 released ---
1917. [doc] funcsynopsisinfo wasn't being treated as verbatim
when generating man pages. [RT #15385]
1915. [bug] dig +ndots was broken. [RT #15215]
1914. [protocol] DS is required to accept mnemonic algorithms
(RFC 4034). Still emit numeric algorithms for
compatability with RFC 3658. [RT #15354]
1911. [bug] Update windows socket code. [RT #14965]
1910. [bug] dig's +sigchase code overhauled. [RT #14933]
1909. [bug] The DLV code has been re-worked to make no longer
query order sensitive. [RT #14933]
1905. [bug] Strings returned from cfg_obj_asstring() should be
treated as read-only. [RT #15256]
1901. [cleanup] Don't add DNSKEY records to the additional section.
1900. [bug] ixfr-from-differences failed to ensure that the
serial number increased. [RT #15036]
1896. [bug] Extend ISC_SOCKADDR_FORMATSIZE and
ISC_NETADDR_FORMATSIZE to allow for scope details.
1894. [bug] Recursive clients soft quota support wasn't working
as expected. [RT #15103]
1893. [bug] A escaped character is, potentially, converted to
the output character set too early. [RT #14666]
1892. [port] Use uintptr_t if available. [RT #14606]
1889. [port] sunos: non blocking i/o support. [RT #14951]
1887. [bug] The cache could delete expired records too fast for
clients with a virtual time in the past. [RT #14991]
1886. [bug] fctx_create() could return success even though it
failed. [RT #14993]
1884. [cleanup] dighost.c: move external declarations into <dig/dig.h>.
1883. [bug] dnssec-signzone, dnssec-keygen: handle negative debug
levels. [RT #14962]
1881. [func] Add a system test for named-checkconf. [RT #14931]
1877. [bug] Fix unreasonably low quantum on call to
dns_rbt_destroy2(). Remove unnecessay unhash_node()
call. [RT #14919]
1875. [bug] process_dhtkey() was using the wrong memory context
to free some memory. [RT #14890]
1874. [port] sunos: portability fixes. [RT #14814]
1873. [port] win32: isc__errno2result() now reports its caller.
[RT #13753]
1872. [port] win32: Handle ERROR_NETNAME_DELETED. [RT #13753]
1867. [bug] It was possible to trigger a INSIST in
dlv_validatezonekey(). [RT #14846]
1866. [bug] resolv.conf parse errors were being ignored by
dig/host/nslookup. [RT #14841]
1865. [bug] Silently ignore nameservers in /etc/resolv.conf with
bad addresses. [RT #14841]
1864. [bug] Don't try the alternative transfer source if you
got a answer / transfer with the main source
address. [RT #14802]
1863. [bug] rrset-order "fixed" error messages not complete.
1861. [bug] dig could trigger a INSIST on certain malformed
responses. [RT #14801]
1860. [port] solaris 2.8: hack_shutup_pthreadmutexinit was
incorrectly set. [RT #14775]
1858. [bug] The flush-zones-on-shutdown option wasn't being
parsed. [RT #14686]
1857. [bug] named could trigger a INSIST() if reconfigured /
reloaded too fast. [RT #14673]
1856. [doc] Switch Docbook toolchain from DSSSL to XSL.
[RT #11398]
1855. [bug] ixfr-from-differences was failing to detect changes
of ttl due to dns_diff_subtract() was ignoring the ttl
of records. [RT #14616]
1854. [bug] lwres also needs to know the print format for
(long long). [RT #13754]
1853. [bug] Rework how DLV interacts with proveunsecure().
[RT #13605]
1852. [cleanup] Remove last vestiges of dnssec-signkey and
dnssec-makekeyset (removed from Makefile years ago).
1850. [bug] Memory leak in lwres_getipnodebyaddr(). [RT #14591]
1849. [doc] All forms of the man pages (docbook, man, html) should
have consistant copyright dates.
1848. [bug] Improve SMF integration. [RT #13238]
1847. [bug] isc_ondestroy_init() is called too late in
dns_rbtdb_create()/dns_rbtdb64_create().
[RT #13661]
1846. [contrib] query-loc-0.3.0 from Stephane Bortzmeyer
<[email protected]>.
1845. [bug] Improve error reporting to distingish between
accept()/fcntl() and socket()/fcntl() errors.
[RT #13745]
1844. [bug] inet_pton() accepted more that 4 hexadecimal digits
for each 16 bit piece of the IPv6 address. The text
representation of a IPv6 address has been tighted
to disallow this (draft-ietf-ipv6-addr-arch-v4-02.txt).
[RT #5662]
1843. [cleanup] CINCLUDES takes precedence over CFLAGS. This helps
when CFLAGS contains "-I /usr/local/include"
resulting in old header files being used.
1842. [port] cmsg_len() could produce incorrect results on
some platform. [RT #13744]
1841. [bug] "dig +nssearch" now makes a recursive query to
find the list of nameservers to query. [RT #13694]
1839. [bug] <isc/hash.h> was not being installed.
1838. [cleanup] Don't allow Linux capabilities to be inherited.
[RT #13707]
1837. [bug] Compile time option ISC_FACILITY was not effective
for 'named -u <user>'. [RT #13714]
1836. [cleanup] Silence compiler warnings in hash_test.c.
1835. [bug] Update dnssec-signzone's usage message. [RT #13657]
1834. [bug] Bad memset in rdata_test.c. [RT #13658]
1833. [bug] Race condition in isc_mutex_lock_profile(). [RT #13660]
1832. [bug] named fails to return BADKEY on unknown TSIG algorithm.
[RT #13620]
1831. [doc] Update named-checkzone documentation. [RT#13604]
1830. [bug] adb lame cache has sence of test reversed. [RT #13600]
1829. [bug] win32: "pid-file none;" broken. [RT #13563]
1828. [bug] isc_rwlock_init() failed to properly cleanup if it
encountered a error. [RT #13549]
1827. [bug] host: update usage message for '-a'. [RT #37116]
1826. [bug] Missing DESTROYLOCK() in isc_mem_createx() on out
of memory error. [RT #13537]
1825. [bug] Missing UNLOCK() on out of memory error from in
rbtdb.c:subtractrdataset(). [RT #13519]
1824. [bug] Memory leak on dns_zone_setdbtype() failure.
[RT #13510]
1823. [bug] Wrong macro used to check for point to point interface.
[RT#13418]
1822. [bug] check-names test for RT was reversed. [RT #13382]
1821. [doc] acls definitions are no longer required to be
in named.conf prior to reference. They can be
defined after being referenced.
1820. [bug] Gracefully handle acl loops. [RT #13659]
1819. [bug] The validator needed to check both the algorithm and
digest types of the DS to determine if it could be
used to introduce a secure zone. [RT #13593]
1816. [port] UnixWare: failed to compile lib/isc/unix/net.c.
[RT #13597]
1815. [bug] nsupdate triggered a REQUIRE if the server was set
without also setting the zone and it encountered
a CNAME and was using TSIG. [RT #13086]
1810. [bug] configure, lib/bind/configure make different default
decisions about whether to do a threaded build.
[RT #13212]
1809. [bug] "make distclean" failed for libbind if the platform
is not supported.
1807. [bug] When forwarding (forward only) set the active domain
from the forward zone name. [RT #13526]
1804. [bug] Ensure that if we are queried for glue that it fits
in the additional section or TC is set to tell the
client to retry using TCP. [RT #10114]
1803. [bug] dnssec-signzone sometimes failed to remove old
RRSIGs. [RT #13483]
1802. [bug] Handle connection resets better. [RT #11280]
1799. [bug] 'rndc flushname' failed to flush negative cache
entries. [RT #13438]
1795. [bug] "rndc dumpdb" was not fully documented. Minor
formating issues with "rndc dumpdb -all". [RT #13396]
1791. [bug] 'host -t a' still printed out AAAA and MX records.
[RT #13230]
--- 9.3.1 released ---
1818. [bug] 'named-checkconf -z' triggered an INSIST. [RT #13599]
@@ -59,14 +681,14 @@
1779. [port] OSF 5.1: libtool didn't handle -pthread correctly.
1778. [port] HUX 11.11: fix broken IN6ADDR_ANY_INIT and
1778. [port] HUX 11.11: fix broken IN6ADDR_ANY_INIT and
IN6ADDR_LOOPBACK_INIT macros.
1777. [port] OSF 5.1: fix broken IN6ADDR_ANY_INIT and
1777. [port] OSF 5.1: fix broken IN6ADDR_ANY_INIT and
IN6ADDR_LOOPBACK_INIT macros.
1776. [port] Solaris 2.9: fix broken IN6ADDR_ANY_INIT and
IN6ADDR_LOOPBACK_INIT macros.
1776. [port] Solaris 2.9: fix broken IN6ADDR_ANY_INIT and
IN6ADDR_LOOPBACK_INIT macros.
1775. [bug] Only compile getnetent_r.c when threaded. [RT #13205]
@@ -909,8 +1531,8 @@
1414. [func] Support for KSK flag.
1413. [func] Explictly request the (re-)generation of DS records from
keysets (dnssec-signzone -g).
1413. [func] Explicitly request the (re-)generation of DS records
from keysets (dnssec-signzone -g).
1412. [func] You can now specify servers to be tried if a nameserver
has IPv6 address and you only support IPv4 or the
@@ -5307,7 +5929,7 @@
<isc/bufferlist.h>, <isc/task.h>, <isc/mem.h> or
<isc/net.h>.
119. [cleanup] structure definitions for generic rdata stuctures do
119. [cleanup] structure definitions for generic rdata structures do
not have _generic_ in their names.
118. [cleanup] libdns.a is now namespace-clean, on NetBSD, excepting
+2 -2
View File
@@ -1,4 +1,4 @@
Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
Copyright (C) 1996-2003 Internet Software Consortium.
Permission to use, copy, modify, and distribute this software for any
@@ -13,7 +13,7 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.
$Id: COPYRIGHT,v 1.6.2.2.8.3 2005/01/10 23:51:37 marka Exp $
$Id: COPYRIGHT,v 1.6.2.2.8.4 2006/01/04 00:37:22 marka Exp $
Portions Copyright (C) 1996-2001 Nominum, Inc.
+545 -340
View File
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
-105
View File
@@ -1,105 +0,0 @@
FreeBSD maintainer's guide to updating BIND 9
=============================================
1) Obtain the latest source distribution from the ISC's FTP server
(ftp://ftp.isc.org/isc/bind9/)
2) Unpack the tarball in a suitable directory, and cd into the new
source directory.
3) Remove unwanted files and directories:
$ while read pattern ; do rm -rf $pattern ; done \
</usr/src/contrib/bind9/FREEBSD-Xlist
Make sure that took care of everything, and if it didn't, make sure
to update FREEBSD-Xlist so you won't miss it the next time. A good
way to do this is to run a test import and see if any new files
show up:
$ cvs -q -n import src/contrib/bind9 ISC x | grep \^N
4) Import the sources:
$ cvs import -m "Vendor import of BIND 9.X.Y" \
src/contrib/bind9 ISC BIND_9_X_Y
5) Resolve conflicts.
As of 17 March 2005, we have no local patches against BIND 9; thus
there are no conflicts to merge. This may change at a later date.
6) Remove any references to the {bin,lib}/tests and docutil
directories from the configure and Makefile templates:
$ sed -i.orig -e '/\/tests/d; /docutil/d;' \
configure.in Makefile.in */Makefile.in
Please do not commit this change, as it would unnecessarily take
files off the vendor branch. You only need this to generate
config.h.
7) Generate and run configure:
$ autoconf253
$ autoheader253
$ ./configure --prefix=/usr \
--infodir=/usr/share/info --mandir=/usr/share/man \
--enable-threads --enable-libbind --disable-ipv6 \
--enable-getifaddrs --disable-linux-caps \
--with-openssl=/usr --with-randomdev=/dev/random
Note that we intentionally disable IPv6 support on the configure
command line; src/lib/bind/config.mk will re-enable it at compile
time if NO_INET6 is not defined.
8) Copy the resulting config.h to src/lib/bind, add an RCS id tag and
commit it. Do not commit any other file that was modified or
created in steps 6) or 7).
9) cd src/lib/bind/dns && make -DMAINTAINER_MODE generate && rm gen
Commit the new versions of the files generated.
The following directories contain Makefiles for bits and pieces of
BIND 9:
FreeBSD directory ISC directory
========================================================
src/lib/bind bind9/lib
src/lib/bind/bind bind9/lib/bind
src/lib/bind/bind9 bind9/lib/bind9
src/lib/bind/dns bind9/lib/dns
src/lib/bind/isc bind9/lib/isc
src/lib/bind/isccc bind9/lib/isccc
src/lib/bind/isccfg bind9/lib/isccfg
src/lib/bind/lwres bind9/lib/lwres
src/share/doc/bind9 bind9/doc/{arm,misc}
src/usr.bin/dig bind9/bin/dig
src/usr.bin/host bind9/bin/dig
src/usr.bin/nslookup bind9/bin/dig
src/usr.bin/nsupdate bind9/bin/nsupdate
src/usr.sbin/dnssec-keygen bind9/bin/dnssec
src/usr.sbin/dnssec-signzone bind9/bin/dnssec
src/usr.sbin/named bind9/bin/named
src/usr.sbin/named-checkconf bind9/bin/check
src/usr.sbin/named-checkzone bind9/bin/check
src/usr.sbin/rndc bind9/bin/rndc
src/usr.sbin/rndc-confgen bind9/bin/rndc
Make sure that the lists of sources, headers and man pages in each
FreeBSD Makefile accurately reflects those in the corresponding ISC
Makefile. Please strive to keep those lists in the same order and
with line breaks in the same places to ease future comparisons.
A) Build and test.
B) Lather, rinse, repeat.
C) Commit when everything builds cleanly and works properly.
-- [email protected]
-- [email protected]
$FreeBSD$
-63
View File
@@ -1,63 +0,0 @@
# $FreeBSD$
# Misc. stuff
.cvsignore
aclocal.m4
config.h.in
configure
contrib
docutil
# Tests
bin/tests
lib/tests
# Windows directories
bin/check/win32
bin/dig/win32
bin/dnssec/win32
bin/named/win32
bin/nsupdate/win32
bin/rndc/win32
bin/win32
config.h.win32
lib/bind9/win32
lib/dns/gen-win32.h
lib/dns/win32
lib/isc/win32
lib/isccc/win32
lib/isccfg/win32
lib/lwres/win32
lib/win32
win32utils
# Various ports to other OSs
lib/bind/port/aix*
lib/bind/port/aux3
lib/bind/port/bsdos
lib/bind/port/bsdos2
lib/bind/port/cygwin
lib/bind/port/darwin
lib/bind/port/decunix
lib/bind/port/hpux
lib/bind/port/hpux10
lib/bind/port/hpux9
lib/bind/port/irix
lib/bind/port/linux
lib/bind/port/lynxos
lib/bind/port/mpe
lib/bind/port/netbsd
lib/bind/port/next
lib/bind/port/openbsd
lib/bind/port/prand_conf
lib/bind/port/qnx
lib/bind/port/rhapsody
lib/bind/port/sco42
lib/bind/port/sco50
lib/bind/port/solaris
lib/bind/port/sunos
lib/bind/port/ultrix
lib/bind/port/unixware20
lib/bind/port/unixware212
lib/bind/port/unixware7
lib/bind/port/unknown
+4 -3
View File
@@ -1,4 +1,4 @@
# Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
# Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
# Copyright (C) 1998-2002 Internet Software Consortium.
#
# Permission to use, copy, modify, and distribute this software for any
@@ -13,7 +13,7 @@
# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.41.2.2.2.2 2004/03/08 04:04:12 marka Exp $
# $Id: Makefile.in,v 1.41.2.2.2.4 2006/05/19 00:04:00 marka Exp $
srcdir = @srcdir@
VPATH = @srcdir@
@@ -44,7 +44,8 @@ maintainer-clean::
rm -f configure
installdirs:
$(SHELL) ${top_srcdir}/mkinstalldirs ${DESTDIR}${bindir}
$(SHELL) ${top_srcdir}/mkinstalldirs ${DESTDIR}${bindir} \
${DESTDIR}${localstatedir}/run ${DESTDIR}${sysconfdir}
install:: isc-config.sh installdirs
${INSTALL_SCRIPT} isc-config.sh ${DESTDIR}${bindir}
+52 -2
View File
@@ -42,6 +42,38 @@ BIND 9
Stichting NLnet - NLnet Foundation
Nominum, Inc.
BIND 9.3.4-P1
BIND 9.3.4-P1 is a security release.
BIND 9.3.4
BIND 9.3.4 is a security release.
BIND 9.3.3
BIND 9.3.3 is a maintenance release, containing fixes for
a number of bugs in 9.3.2.
BIND 9.3.2
BIND 9.3.2 is a maintenance release, containing fixes for
a number of bugs in 9.3.1.
libbind: corresponds to that from BIND 8.4.7-REL.
Known Issues:
The following INSIST can be triggered with DNSSEC enabled.
resolver.c:762: INSIST(result != 0 || dns_rdataset_isassociated(event->rdataset) || fctx->type == ((dns_rdatatype_t)dns_rdatatype_any) || fctx->type == ((dns_rdatatype_t)dns_rdatatype_rrsig)) failed
We are still trying to isolate the cause. If you have core
dump please send a bug report to [email protected] with
the location of the core, named executable and OS details.
Note: contrib/nanny contains a perl script to restart named
in the event of a INSIST/REQUIRE/ENSURE failure.
BIND 9.3.1
@@ -174,6 +206,9 @@ BIND 9.2.0
--with-libtool does not work on AIX.
--with-libtool does not work on SunOS 4. configure
requires "printf" which is not available.
A bug in the Windows 2000 DNS server can cause zone transfers
from a BIND 9 server to a W2K server to fail. For details,
see the "Zone Transfers" section in doc/misc/migration.
@@ -206,11 +241,11 @@ Building
Red Hat Linux 7.1
Debian GNU/Linux 2.2 and 3.0
Mandrake 8.1
OpenBSD 2.6, 2.8, 2.9
OpenBSD 2.6, 2.8, 2.9, 3.1, 3.6, 3.8
UnixWare 7.1.1
HP-UX 10.20
BSD/OS 4.2
Mac OS X 10.1
Mac OS X 10.1, 10.3.8
To build, just
@@ -245,10 +280,23 @@ Building
Enable DNSSEC signature chasing support in dig.
-DDIG_SIGCHASE=1 (sets -DDIG_SIGCHASE_TD=1 and
-DDIG_SIGCHASE_BU=1)
Disable dropping queries from particular well known ports.
-DNS_CLIENT_DROPPORT=0
LDFLAGS
Linker flags. Defaults to empty string.
The following need to be set when cross compiling.
BUILD_CC
The native C compiler.
BUILD_CFLAGS (optional)
BUILD_CPPFLAGS (optional)
Possible Settings:
-DNEED_OPTARG=1 (optarg is not declared in <unistd.h>)
BUILD_LDFLAGS (optional)
BUILD_LIBS (optional)
To build shared libraries, specify "--with-libtool" on the
configure command line.
@@ -300,9 +348,11 @@ Building
Building with gcc is not supported, unless gcc is the vendor's usual
compiler (e.g. the various BSD systems, Linux).
Known compiler issues:
* gcc-3.2.1 and gcc-3.1.1 is known to cause problems with solaris-x86.
* gcc prior to gcc-3.2.3 ultrasparc generates incorrect code at -02.
* gcc-3.3.5 powerpc generates incorrect code at -02.
* Irix, MipsPRO 7.4.1m is known to cause problems.
A limited test suite can be run with "make test". Many of
the tests require you to configure a set of virtual IP addresses
+49 -33
View File
@@ -1,59 +1,75 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2002 Internet Software Consortium.
.\"
.\" Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2002 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: named-checkconf.8,v 1.11.12.4 2004/06/03 05:35:41 marka Exp $
.\" $Id: named-checkconf.8,v 1.11.12.8 2006/06/29 13:02:30 marka Exp $
.\"
.TH "NAMED-CHECKCONF" "8" "June 14, 2000" "BIND9" ""
.SH NAME
named-checkconf \- named configuration file syntax checking tool
.SH SYNOPSIS
.sp
\fBnamed-checkconf\fR [ \fB-v\fR ] [ \fB-j\fR ] [ \fB-t \fIdirectory\fB\fR ] \fBfilename\fR [ \fB-z\fR ]
.hy 0
.ad l
.\" Title: named\-checkconf
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: June 14, 2000
.\" Manual: BIND9
.\" Source: BIND9
.\"
.TH "NAMED\-CHECKCONF" "8" "June 14, 2000" "BIND9" "BIND9"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
named\-checkconf \- named configuration file syntax checking tool
.SH "SYNOPSIS"
.HP 16
\fBnamed\-checkconf\fR [\fB\-v\fR] [\fB\-j\fR] [\fB\-t\ \fR\fB\fIdirectory\fR\fR] {filename} [\fB\-z\fR]
.SH "DESCRIPTION"
.PP
\fBnamed-checkconf\fR checks the syntax, but not
the semantics, of a named configuration file.
\fBnamed\-checkconf\fR
checks the syntax, but not the semantics, of a named configuration file.
.SH "OPTIONS"
.TP
\fB-t \fIdirectory\fB\fR
chroot to \fIdirectory\fR so that include
directives in the configuration file are processed as if
run by a similarly chrooted named.
.TP
\fB-v\fR
Print the version of the \fBnamed-checkconf\fR
.TP 3n
\-t \fIdirectory\fR
chroot to
\fIdirectory\fR
so that include directives in the configuration file are processed as if run by a similarly chrooted named.
.TP 3n
\-v
Print the version of the
\fBnamed\-checkconf\fR
program and exit.
.TP
\fB-z\fR
.TP 3n
\-z
Perform a check load the master zonefiles found in
\fInamed.conf\fR.
.TP
\fB-j\fR
.TP 3n
\-j
When loading a zonefile read the journal if it exists.
.TP
\fBfilename\fR
The name of the configuration file to be checked. If not
specified, it defaults to \fI/etc/named.conf\fR.
.TP 3n
filename
The name of the configuration file to be checked. If not specified, it defaults to
\fI/etc/named.conf\fR.
.SH "RETURN VALUES"
.PP
\fBnamed-checkconf\fR returns an exit status of 1 if
errors were detected and 0 otherwise.
\fBnamed\-checkconf\fR
returns an exit status of 1 if errors were detected and 0 otherwise.
.SH "SEE ALSO"
.PP
\fBnamed\fR(8),
\fIBIND 9 Administrator Reference Manual\fR.
BIND 9 Administrator Reference Manual.
.SH "AUTHOR"
.PP
Internet Systems Consortium
.SH "COPYRIGHT"
Copyright \(co 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
+22 -22
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: named-checkconf.c,v 1.12.12.9 2005/03/03 06:33:38 marka Exp $ */
/* $Id: named-checkconf.c,v 1.12.12.11 2006/03/02 00:37:20 marka Exp $ */
#include <config.h>
@@ -60,9 +60,9 @@ usage(void) {
}
static isc_result_t
directory_callback(const char *clausename, cfg_obj_t *obj, void *arg) {
directory_callback(const char *clausename, const cfg_obj_t *obj, void *arg) {
isc_result_t result;
char *directory;
const char *directory;
REQUIRE(strcasecmp("directory", clausename) == 0);
@@ -85,18 +85,18 @@ directory_callback(const char *clausename, cfg_obj_t *obj, void *arg) {
}
static isc_result_t
configure_zone(const char *vclass, const char *view, cfg_obj_t *zconfig,
isc_mem_t *mctx)
configure_zone(const char *vclass, const char *view,
const cfg_obj_t *zconfig, isc_mem_t *mctx)
{
isc_result_t result;
const char *zclass;
const char *zname;
const char *zfile;
cfg_obj_t *zoptions = NULL;
cfg_obj_t *classobj = NULL;
cfg_obj_t *typeobj = NULL;
cfg_obj_t *fileobj = NULL;
cfg_obj_t *dbobj = NULL;
const cfg_obj_t *zoptions = NULL;
const cfg_obj_t *classobj = NULL;
const cfg_obj_t *typeobj = NULL;
const cfg_obj_t *fileobj = NULL;
const cfg_obj_t *dbobj = NULL;
zname = cfg_obj_asstring(cfg_tuple_get(zconfig, "name"));
classobj = cfg_tuple_get(zconfig, "class");
@@ -125,12 +125,12 @@ configure_zone(const char *vclass, const char *view, cfg_obj_t *zconfig,
}
static isc_result_t
configure_view(const char *vclass, const char *view, cfg_obj_t *config,
cfg_obj_t *vconfig, isc_mem_t *mctx)
configure_view(const char *vclass, const char *view, const cfg_obj_t *config,
const cfg_obj_t *vconfig, isc_mem_t *mctx)
{
cfg_listelt_t *element;
cfg_obj_t *voptions;
cfg_obj_t *zonelist;
const cfg_listelt_t *element;
const cfg_obj_t *voptions;
const cfg_obj_t *zonelist;
isc_result_t result = ISC_R_SUCCESS;
isc_result_t tresult;
@@ -148,7 +148,7 @@ configure_view(const char *vclass, const char *view, cfg_obj_t *config,
element != NULL;
element = cfg_list_next(element))
{
cfg_obj_t *zconfig = cfg_listelt_value(element);
const cfg_obj_t *zconfig = cfg_listelt_value(element);
tresult = configure_zone(vclass, view, zconfig, mctx);
if (tresult != ISC_R_SUCCESS)
result = tresult;
@@ -158,11 +158,11 @@ configure_view(const char *vclass, const char *view, cfg_obj_t *config,
static isc_result_t
load_zones_fromconfig(cfg_obj_t *config, isc_mem_t *mctx) {
cfg_listelt_t *element;
cfg_obj_t *classobj;
cfg_obj_t *views;
cfg_obj_t *vconfig;
load_zones_fromconfig(const cfg_obj_t *config, isc_mem_t *mctx) {
const cfg_listelt_t *element;
const cfg_obj_t *classobj;
const cfg_obj_t *views;
const cfg_obj_t *vconfig;
const char *vclass;
isc_result_t result = ISC_R_SUCCESS;
isc_result_t tresult;
@@ -1,7 +1,9 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.0//EN"
"http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd"
[<!ENTITY mdash "&#8212;">]>
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001, 2002 Internet Software Consortium.
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2002 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
@@ -16,7 +18,7 @@
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: named-checkconf.docbook,v 1.3.2.1.8.5 2004/06/03 02:24:59 marka Exp $ -->
<!-- $Id: named-checkconf.docbook,v 1.3.2.1.8.7 2005/05/12 21:35:56 sra Exp $ -->
<refentry>
<refentryinfo>
@@ -29,6 +31,20 @@
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<docinfo>
<copyright>
<year>2004</year>
<year>2005</year>
<holder>Internet Systems Consortium, Inc. ("ISC")</holder>
</copyright>
<copyright>
<year>2000</year>
<year>2001</year>
<year>2002</year>
<holder>Internet Software Consortium.</holder>
</copyright>
</docinfo>
<refnamediv>
<refname><application>named-checkconf</application></refname>
<refpurpose>named configuration file syntax checking tool</refpurpose>
@@ -116,6 +132,7 @@
<para>
<command>named-checkconf</command> returns an exit status of 1 if
errors were detected and 0 otherwise.
</para>
</refsect1>
<refsect1>
+76 -200
View File
@@ -1,216 +1,92 @@
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001, 2002 Internet Software Consortium.
-
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2002 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: named-checkconf.html,v 1.5.2.1.4.5 2004/08/22 23:38:57 marka Exp $ -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML
><HEAD
><TITLE
>named-checkconf</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"></HEAD
><BODY
CLASS="REFENTRY"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><H1
><A
NAME="AEN1"
></A
><SPAN
CLASS="APPLICATION"
>named-checkconf</SPAN
></H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN9"
></A
><H2
>Name</H2
><SPAN
CLASS="APPLICATION"
>named-checkconf</SPAN
>&nbsp;--&nbsp;named configuration file syntax checking tool</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN13"
></A
><H2
>Synopsis</H2
><P
><B
CLASS="COMMAND"
>named-checkconf</B
> [<VAR
CLASS="OPTION"
>-v</VAR
>] [<VAR
CLASS="OPTION"
>-j</VAR
>] [<VAR
CLASS="OPTION"
>-t <VAR
CLASS="REPLACEABLE"
>directory</VAR
></VAR
>] {filename} [<VAR
CLASS="OPTION"
>-z</VAR
>]</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN26"
></A
><H2
>DESCRIPTION</H2
><P
> <B
CLASS="COMMAND"
>named-checkconf</B
> checks the syntax, but not
<!-- $Id: named-checkconf.html,v 1.5.2.1.4.15 2006/06/29 13:02:30 marka Exp $ -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>named-checkconf</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.70.1">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
<a name="id2482688"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2>Name</h2>
<p><span class="application">named-checkconf</span> &#8212; named configuration file syntax checking tool</p>
</div>
<div class="refsynopsisdiv">
<h2>Synopsis</h2>
<div class="cmdsynopsis"><p><code class="command">named-checkconf</code> [<code class="option">-v</code>] [<code class="option">-j</code>] [<code class="option">-t <em class="replaceable"><code>directory</code></em></code>] {filename} [<code class="option">-z</code>]</p></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549430"></a><h2>DESCRIPTION</h2>
<p>
<span><strong class="command">named-checkconf</strong></span> checks the syntax, but not
the semantics, of a named configuration file.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN30"
></A
><H2
>OPTIONS</H2
><P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
>-t <VAR
CLASS="REPLACEABLE"
>directory</VAR
></DT
><DD
><P
> chroot to <TT
CLASS="FILENAME"
>directory</TT
> so that include
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549443"></a><h2>OPTIONS</h2>
<div class="variablelist"><dl>
<dt><span class="term">-t <em class="replaceable"><code>directory</code></em></span></dt>
<dd><p>
chroot to <code class="filename">directory</code> so that include
directives in the configuration file are processed as if
run by a similarly chrooted named.
</P
></DD
><DT
>-v</DT
><DD
><P
> Print the version of the <B
CLASS="COMMAND"
>named-checkconf</B
>
</p></dd>
<dt><span class="term">-v</span></dt>
<dd><p>
Print the version of the <span><strong class="command">named-checkconf</strong></span>
program and exit.
</P
></DD
><DT
>-z</DT
><DD
><P
> Perform a check load the master zonefiles found in
<TT
CLASS="FILENAME"
>named.conf</TT
>.
</P
></DD
><DT
>-j</DT
><DD
><P
> When loading a zonefile read the journal if it exists.
</P
></DD
><DT
>filename</DT
><DD
><P
> The name of the configuration file to be checked. If not
specified, it defaults to <TT
CLASS="FILENAME"
>/etc/named.conf</TT
>.
</P
></DD
></DL
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN58"
></A
><H2
>RETURN VALUES</H2
><P
> <B
CLASS="COMMAND"
>named-checkconf</B
> returns an exit status of 1 if
</p></dd>
<dt><span class="term">-z</span></dt>
<dd><p>
Perform a check load the master zonefiles found in
<code class="filename">named.conf</code>.
</p></dd>
<dt><span class="term">-j</span></dt>
<dd><p>
When loading a zonefile read the journal if it exists.
</p></dd>
<dt><span class="term">filename</span></dt>
<dd><p>
The name of the configuration file to be checked. If not
specified, it defaults to <code class="filename">/etc/named.conf</code>.
</p></dd>
</dl></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549534"></a><h2>RETURN VALUES</h2>
<p>
<span><strong class="command">named-checkconf</strong></span> returns an exit status of 1 if
errors were detected and 0 otherwise.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN62"
></A
><H2
>SEE ALSO</H2
><P
> <SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>named</SPAN
>(8)</SPAN
>,
<I
CLASS="CITETITLE"
>BIND 9 Administrator Reference Manual</I
>.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN69"
></A
><H2
>AUTHOR</H2
><P
> Internet Systems Consortium
</P
></DIV
></BODY
></HTML
>
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549547"></a><h2>SEE ALSO</h2>
<p>
<span class="citerefentry"><span class="refentrytitle">named</span>(8)</span>,
<em class="citetitle">BIND 9 Administrator Reference Manual</em>.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549639"></a><h2>AUTHOR</h2>
<p>
<span class="corpauthor">Internet Systems Consortium</span>
</p>
</div>
</div></body>
</html>
+83 -61
View File
@@ -1,94 +1,116 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2002 Internet Software Consortium.
.\"
.\" Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2002 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: named-checkzone.8,v 1.11.2.1.8.4 2004/06/03 05:35:42 marka Exp $
.\" $Id: named-checkzone.8,v 1.11.2.1.8.11 2006/10/05 02:50:17 marka Exp $
.\"
.TH "NAMED-CHECKZONE" "8" "June 13, 2000" "BIND9" ""
.SH NAME
named-checkzone \- zone file validity checking tool
.SH SYNOPSIS
.sp
\fBnamed-checkzone\fR [ \fB-d\fR ] [ \fB-j\fR ] [ \fB-q\fR ] [ \fB-v\fR ] [ \fB-c \fIclass\fB\fR ] [ \fB-k \fImode\fB\fR ] [ \fB-n \fImode\fB\fR ] [ \fB-o \fIfilename\fB\fR ] [ \fB-t \fIdirectory\fB\fR ] [ \fB-w \fIdirectory\fB\fR ] [ \fB-D\fR ] \fBzonename\fR \fBfilename\fR
.hy 0
.ad l
.\" Title: named\-checkzone
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: June 13, 2000
.\" Manual: BIND9
.\" Source: BIND9
.\"
.TH "NAMED\-CHECKZONE" "8" "June 13, 2000" "BIND9" "BIND9"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
named\-checkzone \- zone file validity checking tool
.SH "SYNOPSIS"
.HP 16
\fBnamed\-checkzone\fR [\fB\-d\fR] [\fB\-j\fR] [\fB\-q\fR] [\fB\-v\fR] [\fB\-c\ \fR\fB\fIclass\fR\fR] [\fB\-k\ \fR\fB\fImode\fR\fR] [\fB\-n\ \fR\fB\fImode\fR\fR] [\fB\-o\ \fR\fB\fIfilename\fR\fR] [\fB\-t\ \fR\fB\fIdirectory\fR\fR] [\fB\-w\ \fR\fB\fIdirectory\fR\fR] [\fB\-D\fR] {zonename} {filename}
.SH "DESCRIPTION"
.PP
\fBnamed-checkzone\fR checks the syntax and integrity of
a zone file. It performs the same checks as \fBnamed\fR
\fBnamed\-checkzone\fR
checks the syntax and integrity of a zone file. It performs the same checks as
\fBnamed\fR
does when loading a zone. This makes
\fBnamed-checkzone\fR useful for checking zone
files before configuring them into a name server.
\fBnamed\-checkzone\fR
useful for checking zone files before configuring them into a name server.
.SH "OPTIONS"
.TP
\fB-d\fR
.TP 3n
\-d
Enable debugging.
.TP
\fB-q\fR
Quiet mode - exit code only.
.TP
\fB-v\fR
Print the version of the \fBnamed-checkzone\fR
.TP 3n
\-q
Quiet mode \- exit code only.
.TP 3n
\-v
Print the version of the
\fBnamed\-checkzone\fR
program and exit.
.TP
\fB-j\fR
.TP 3n
\-j
When loading the zone file read the journal if it exists.
.TP
\fB-c \fIclass\fB\fR
.TP 3n
\-c \fIclass\fR
Specify the class of the zone. If not specified "IN" is assumed.
.TP
\fB-k \fImode\fB\fR
Perform \fB"check-name"\fR checks with the specified failure mode.
Possible modes are \fB"fail"\fR,
\fB"warn"\fR (default) and
.TP 3n
\-k \fImode\fR
Perform
\fB"check\-names"\fR
checks with the specified failure mode. Possible modes are
\fB"fail"\fR,
\fB"warn"\fR
(default) and
\fB"ignore"\fR.
.TP
\fB-n \fImode\fB\fR
Specify whether NS records should be checked to see if they
are addresses. Possible modes are \fB"fail"\fR,
\fB"warn"\fR (default) and
.TP 3n
\-n \fImode\fR
Specify whether NS records should be checked to see if they are addresses. Possible modes are
\fB"fail"\fR,
\fB"warn"\fR
(default) and
\fB"ignore"\fR.
.TP
\fB-o \fIfilename\fB\fR
Write zone output to \fIdirectory\fR.
.TP
\fB-t \fIdirectory\fB\fR
chroot to \fIdirectory\fR so that include
directives in the configuration file are processed as if
run by a similarly chrooted named.
.TP
\fB-w \fIdirectory\fB\fR
chdir to \fIdirectory\fR so that relative
filenames in master file $INCLUDE directives work. This
is similar to the directory clause in
.TP 3n
\-o \fIfilename\fR
Write zone output to
\fIfilename\fR.
.TP 3n
\-t \fIdirectory\fR
chroot to
\fIdirectory\fR
so that include directives in the configuration file are processed as if run by a similarly chrooted named.
.TP 3n
\-w \fIdirectory\fR
chdir to
\fIdirectory\fR
so that relative filenames in master file $INCLUDE directives work. This is similar to the directory clause in
\fInamed.conf\fR.
.TP
\fB-D\fR
.TP 3n
\-D
Dump zone file in canonical format.
.TP
\fBzonename\fR
.TP 3n
zonename
The domain name of the zone being checked.
.TP
\fBfilename\fR
.TP 3n
filename
The name of the zone file.
.SH "RETURN VALUES"
.PP
\fBnamed-checkzone\fR returns an exit status of 1 if
errors were detected and 0 otherwise.
\fBnamed\-checkzone\fR
returns an exit status of 1 if errors were detected and 0 otherwise.
.SH "SEE ALSO"
.PP
\fBnamed\fR(8),
\fIRFC 1035\fR,
\fIBIND 9 Administrator Reference Manual\fR.
RFC 1035,
BIND 9 Administrator Reference Manual.
.SH "AUTHOR"
.PP
Internet Systems Consortium
.SH "COPYRIGHT"
Copyright \(co 2004\-2006 Internet Systems Consortium, Inc. ("ISC")
@@ -1,7 +1,9 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.0//EN"
"http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd"
[<!ENTITY mdash "&#8212;">]>
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001, 2002 Internet Software Consortium.
- Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2002 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
@@ -16,7 +18,7 @@
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: named-checkzone.docbook,v 1.3.2.2.8.7 2004/06/03 02:25:00 marka Exp $ -->
<!-- $Id: named-checkzone.docbook,v 1.3.2.2.8.13 2006/09/30 23:58:36 marka Exp $ -->
<refentry>
<refentryinfo>
@@ -29,6 +31,21 @@
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<docinfo>
<copyright>
<year>2004</year>
<year>2005</year>
<year>2006</year>
<holder>Internet Systems Consortium, Inc. ("ISC")</holder>
</copyright>
<copyright>
<year>2000</year>
<year>2001</year>
<year>2002</year>
<holder>Internet Software Consortium.</holder>
</copyright>
</docinfo>
<refnamediv>
<refname><application>named-checkzone</application></refname>
<refpurpose>zone file validity checking tool</refpurpose>
@@ -103,6 +120,7 @@
When loading the zone file read the journal if it exists.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-c <replaceable class="parameter">class</replaceable></term>
@@ -117,7 +135,7 @@
<term>-k <replaceable class="parameter">mode</replaceable></term>
<listitem>
<para>
Perform <command>"check-name"</command> checks with the specified failure mode.
Perform <command>"check-names"</command> checks with the specified failure mode.
Possible modes are <command>"fail"</command>,
<command>"warn"</command> (default) and
<command>"ignore"</command>.
@@ -141,7 +159,7 @@
<term>-o <replaceable class="parameter">filename</replaceable></term>
<listitem>
<para>
Write zone output to <filename>directory</filename>.
Write zone output to <filename>filename</filename>.
</para>
</listitem>
</varlistentry>
@@ -205,6 +223,7 @@
<para>
<command>named-checkzone</command> returns an exit status of 1 if
errors were detected and 0 otherwise.
</para>
</refsect1>
<refsect1>
+116 -348
View File
@@ -1,367 +1,135 @@
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001, 2002 Internet Software Consortium.
-
- Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2002 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: named-checkzone.html,v 1.5.2.2.4.5 2004/08/22 23:38:57 marka Exp $ -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML
><HEAD
><TITLE
>named-checkzone</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"></HEAD
><BODY
CLASS="REFENTRY"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><H1
><A
NAME="AEN1"
></A
><SPAN
CLASS="APPLICATION"
>named-checkzone</SPAN
></H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN9"
></A
><H2
>Name</H2
><SPAN
CLASS="APPLICATION"
>named-checkzone</SPAN
>&nbsp;--&nbsp;zone file validity checking tool</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN13"
></A
><H2
>Synopsis</H2
><P
><B
CLASS="COMMAND"
>named-checkzone</B
> [<VAR
CLASS="OPTION"
>-d</VAR
>] [<VAR
CLASS="OPTION"
>-j</VAR
>] [<VAR
CLASS="OPTION"
>-q</VAR
>] [<VAR
CLASS="OPTION"
>-v</VAR
>] [<VAR
CLASS="OPTION"
>-c <VAR
CLASS="REPLACEABLE"
>class</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-k <VAR
CLASS="REPLACEABLE"
>mode</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-n <VAR
CLASS="REPLACEABLE"
>mode</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-o <VAR
CLASS="REPLACEABLE"
>filename</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-t <VAR
CLASS="REPLACEABLE"
>directory</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-w <VAR
CLASS="REPLACEABLE"
>directory</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-D</VAR
>] {zonename} {filename}</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN46"
></A
><H2
>DESCRIPTION</H2
><P
> <B
CLASS="COMMAND"
>named-checkzone</B
> checks the syntax and integrity of
a zone file. It performs the same checks as <B
CLASS="COMMAND"
>named</B
>
<!-- $Id: named-checkzone.html,v 1.5.2.2.4.17 2006/10/05 02:50:17 marka Exp $ -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>named-checkzone</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.70.1">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
<a name="id2482688"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2>Name</h2>
<p><span class="application">named-checkzone</span> &#8212; zone file validity checking tool</p>
</div>
<div class="refsynopsisdiv">
<h2>Synopsis</h2>
<div class="cmdsynopsis"><p><code class="command">named-checkzone</code> [<code class="option">-d</code>] [<code class="option">-j</code>] [<code class="option">-q</code>] [<code class="option">-v</code>] [<code class="option">-c <em class="replaceable"><code>class</code></em></code>] [<code class="option">-k <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-n <em class="replaceable"><code>mode</code></em></code>] [<code class="option">-o <em class="replaceable"><code>filename</code></em></code>] [<code class="option">-t <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-w <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-D</code>] {zonename} {filename}</p></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549490"></a><h2>DESCRIPTION</h2>
<p>
<span><strong class="command">named-checkzone</strong></span> checks the syntax and integrity of
a zone file. It performs the same checks as <span><strong class="command">named</strong></span>
does when loading a zone. This makes
<B
CLASS="COMMAND"
>named-checkzone</B
> useful for checking zone
<span><strong class="command">named-checkzone</strong></span> useful for checking zone
files before configuring them into a name server.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN52"
></A
><H2
>OPTIONS</H2
><P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
>-d</DT
><DD
><P
> Enable debugging.
</P
></DD
><DT
>-q</DT
><DD
><P
> Quiet mode - exit code only.
</P
></DD
><DT
>-v</DT
><DD
><P
> Print the version of the <B
CLASS="COMMAND"
>named-checkzone</B
>
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549510"></a><h2>OPTIONS</h2>
<div class="variablelist"><dl>
<dt><span class="term">-d</span></dt>
<dd><p>
Enable debugging.
</p></dd>
<dt><span class="term">-q</span></dt>
<dd><p>
Quiet mode - exit code only.
</p></dd>
<dt><span class="term">-v</span></dt>
<dd><p>
Print the version of the <span><strong class="command">named-checkzone</strong></span>
program and exit.
</P
></DD
><DT
>-j</DT
><DD
><P
> When loading the zone file read the journal if it exists.
</P
></DD
><DT
>-c <VAR
CLASS="REPLACEABLE"
>class</VAR
></DT
><DD
><P
> Specify the class of the zone. If not specified "IN" is assumed.
</P
></DD
><DT
>-k <VAR
CLASS="REPLACEABLE"
>mode</VAR
></DT
><DD
><P
> Perform <B
CLASS="COMMAND"
>"check-name"</B
> checks with the specified failure mode.
Possible modes are <B
CLASS="COMMAND"
>"fail"</B
>,
<B
CLASS="COMMAND"
>"warn"</B
> (default) and
<B
CLASS="COMMAND"
>"ignore"</B
>.
</P
></DD
><DT
>-n <VAR
CLASS="REPLACEABLE"
>mode</VAR
></DT
><DD
><P
> Specify whether NS records should be checked to see if they
are addresses. Possible modes are <B
CLASS="COMMAND"
>"fail"</B
>,
<B
CLASS="COMMAND"
>"warn"</B
> (default) and
<B
CLASS="COMMAND"
>"ignore"</B
>.
</P
></DD
><DT
>-o <VAR
CLASS="REPLACEABLE"
>filename</VAR
></DT
><DD
><P
> Write zone output to <TT
CLASS="FILENAME"
>directory</TT
>.
</P
></DD
><DT
>-t <VAR
CLASS="REPLACEABLE"
>directory</VAR
></DT
><DD
><P
> chroot to <TT
CLASS="FILENAME"
>directory</TT
> so that include
</p></dd>
<dt><span class="term">-j</span></dt>
<dd><p>
When loading the zone file read the journal if it exists.
</p></dd>
<dt><span class="term">-c <em class="replaceable"><code>class</code></em></span></dt>
<dd><p>
Specify the class of the zone. If not specified "IN" is assumed.
</p></dd>
<dt><span class="term">-k <em class="replaceable"><code>mode</code></em></span></dt>
<dd><p>
Perform <span><strong class="command">"check-names"</strong></span> checks with the specified failure mode.
Possible modes are <span><strong class="command">"fail"</strong></span>,
<span><strong class="command">"warn"</strong></span> (default) and
<span><strong class="command">"ignore"</strong></span>.
</p></dd>
<dt><span class="term">-n <em class="replaceable"><code>mode</code></em></span></dt>
<dd><p>
Specify whether NS records should be checked to see if they
are addresses. Possible modes are <span><strong class="command">"fail"</strong></span>,
<span><strong class="command">"warn"</strong></span> (default) and
<span><strong class="command">"ignore"</strong></span>.
</p></dd>
<dt><span class="term">-o <em class="replaceable"><code>filename</code></em></span></dt>
<dd><p>
Write zone output to <code class="filename">filename</code>.
</p></dd>
<dt><span class="term">-t <em class="replaceable"><code>directory</code></em></span></dt>
<dd><p>
chroot to <code class="filename">directory</code> so that include
directives in the configuration file are processed as if
run by a similarly chrooted named.
</P
></DD
><DT
>-w <VAR
CLASS="REPLACEABLE"
>directory</VAR
></DT
><DD
><P
> chdir to <TT
CLASS="FILENAME"
>directory</TT
> so that relative
</p></dd>
<dt><span class="term">-w <em class="replaceable"><code>directory</code></em></span></dt>
<dd><p>
chdir to <code class="filename">directory</code> so that relative
filenames in master file $INCLUDE directives work. This
is similar to the directory clause in
<TT
CLASS="FILENAME"
>named.conf</TT
>.
</P
></DD
><DT
>-D</DT
><DD
><P
> Dump zone file in canonical format.
</P
></DD
><DT
>zonename</DT
><DD
><P
> The domain name of the zone being checked.
</P
></DD
><DT
>filename</DT
><DD
><P
> The name of the zone file.
</P
></DD
></DL
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN125"
></A
><H2
>RETURN VALUES</H2
><P
> <B
CLASS="COMMAND"
>named-checkzone</B
> returns an exit status of 1 if
<code class="filename">named.conf</code>.
</p></dd>
<dt><span class="term">-D</span></dt>
<dd><p>
Dump zone file in canonical format.
</p></dd>
<dt><span class="term">zonename</span></dt>
<dd><p>
The domain name of the zone being checked.
</p></dd>
<dt><span class="term">filename</span></dt>
<dd><p>
The name of the zone file.
</p></dd>
</dl></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549824"></a><h2>RETURN VALUES</h2>
<p>
<span><strong class="command">named-checkzone</strong></span> returns an exit status of 1 if
errors were detected and 0 otherwise.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN129"
></A
><H2
>SEE ALSO</H2
><P
> <SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>named</SPAN
>(8)</SPAN
>,
<I
CLASS="CITETITLE"
>RFC 1035</I
>,
<I
CLASS="CITETITLE"
>BIND 9 Administrator Reference Manual</I
>.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN137"
></A
><H2
>AUTHOR</H2
><P
> Internet Systems Consortium
</P
></DIV
></BODY
></HTML
>
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549836"></a><h2>SEE ALSO</h2>
<p>
<span class="citerefentry"><span class="refentrytitle">named</span>(8)</span>,
<em class="citetitle">RFC 1035</em>,
<em class="citetitle">BIND 9 Administrator Reference Manual</em>.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549863"></a><h2>AUTHOR</h2>
<p>
<span class="corpauthor">Internet Systems Consortium</span>
</p>
</div>
</div></body>
</html>
+317 -286
View File
@@ -1,388 +1,417 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2003 Internet Software Consortium.
.\"
.\" Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2003 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: dig.1,v 1.14.2.4.2.6 2004/06/23 09:11:01 marka Exp $
.\" $Id: dig.1,v 1.14.2.4.2.11 2006/06/29 13:02:30 marka Exp $
.\"
.TH "DIG" "1" "Jun 30, 2000" "BIND9" ""
.SH NAME
.hy 0
.ad l
.\" Title: dig
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: Jun 30, 2000
.\" Manual: BIND9
.\" Source: BIND9
.\"
.TH "DIG" "1" "Jun 30, 2000" "BIND9" "BIND9"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
dig \- DNS lookup utility
.SH SYNOPSIS
.sp
\fBdig\fR [ \fB@server\fR ] [ \fB-b \fIaddress\fB\fR ] [ \fB-c \fIclass\fB\fR ] [ \fB-f \fIfilename\fB\fR ] [ \fB-k \fIfilename\fB\fR ] [ \fB-p \fIport#\fB\fR ] [ \fB-t \fItype\fB\fR ] [ \fB-x \fIaddr\fB\fR ] [ \fB-y \fIname:key\fB\fR ] [ \fB-4\fR ] [ \fB-6\fR ] [ \fBname\fR ] [ \fBtype\fR ] [ \fBclass\fR ] [ \fBqueryopt\fR\fI...\fR ]
.sp
\fBdig\fR [ \fB-h\fR ]
.sp
\fBdig\fR [ \fBglobal-queryopt\fR\fI...\fR ] [ \fBquery\fR\fI...\fR ]
.SH "SYNOPSIS"
.HP 4
\fBdig\fR [@server] [\fB\-b\ \fR\fB\fIaddress\fR\fR] [\fB\-c\ \fR\fB\fIclass\fR\fR] [\fB\-f\ \fR\fB\fIfilename\fR\fR] [\fB\-k\ \fR\fB\fIfilename\fR\fR] [\fB\-p\ \fR\fB\fIport#\fR\fR] [\fB\-t\ \fR\fB\fItype\fR\fR] [\fB\-x\ \fR\fB\fIaddr\fR\fR] [\fB\-y\ \fR\fB\fIname:key\fR\fR] [\fB\-4\fR] [\fB\-6\fR] [name] [type] [class] [queryopt...]
.HP 4
\fBdig\fR [\fB\-h\fR]
.HP 4
\fBdig\fR [global\-queryopt...] [query...]
.SH "DESCRIPTION"
.PP
\fBdig\fR (domain information groper) is a flexible tool
for interrogating DNS name servers. It performs DNS lookups and
displays the answers that are returned from the name server(s) that
were queried. Most DNS administrators use \fBdig\fR to
troubleshoot DNS problems because of its flexibility, ease of use and
clarity of output. Other lookup tools tend to have less functionality
than \fBdig\fR.
\fBdig\fR
(domain information groper) is a flexible tool for interrogating DNS name servers. It performs DNS lookups and displays the answers that are returned from the name server(s) that were queried. Most DNS administrators use
\fBdig\fR
to troubleshoot DNS problems because of its flexibility, ease of use and clarity of output. Other lookup tools tend to have less functionality than
\fBdig\fR.
.PP
Although \fBdig\fR is normally used with command-line
arguments, it also has a batch mode of operation for reading lookup
requests from a file. A brief summary of its command-line arguments
and options is printed when the \fB-h\fR option is given.
Unlike earlier versions, the BIND9 implementation of
\fBdig\fR allows multiple lookups to be issued from the
command line.
Although
\fBdig\fR
is normally used with command\-line arguments, it also has a batch mode of operation for reading lookup requests from a file. A brief summary of its command\-line arguments and options is printed when the
\fB\-h\fR
option is given. Unlike earlier versions, the BIND9 implementation of
\fBdig\fR
allows multiple lookups to be issued from the command line.
.PP
Unless it is told to query a specific name server,
\fBdig\fR will try each of the servers listed in
\fBdig\fR
will try each of the servers listed in
\fI/etc/resolv.conf\fR.
.PP
When no command line arguments or options are given, will perform an
NS query for "." (the root).
When no command line arguments or options are given, will perform an NS query for "." (the root).
.PP
It is possible to set per-user defaults for \fBdig\fR via
\fI${HOME}/.digrc\fR. This file is read and any options in it
are applied before the command line arguments.
It is possible to set per\-user defaults for
\fBdig\fR
via
\fI${HOME}/.digrc\fR. This file is read and any options in it are applied before the command line arguments.
.SH "SIMPLE USAGE"
.PP
A typical invocation of \fBdig\fR looks like:
A typical invocation of
\fBdig\fR
looks like:
.sp
.RS 3n
.nf
dig @server name type
.sp
.fi
.RE
.sp
where:
.TP
.TP 3n
\fBserver\fR
is the name or IP address of the name server to query. This can be an IPv4
address in dotted-decimal notation or an IPv6
address in colon-delimited notation. When the supplied
\fIserver\fR argument is a hostname,
\fBdig\fR resolves that name before querying that name
server. If no \fIserver\fR argument is provided,
\fBdig\fR consults \fI/etc/resolv.conf\fR
and queries the name servers listed there. The reply from the name
server that responds is displayed.
.TP
is the name or IP address of the name server to query. This can be an IPv4 address in dotted\-decimal notation or an IPv6 address in colon\-delimited notation. When the supplied
\fIserver\fR
argument is a hostname,
\fBdig\fR
resolves that name before querying that name server. If no
\fIserver\fR
argument is provided,
\fBdig\fR
consults
\fI/etc/resolv.conf\fR
and queries the name servers listed there. The reply from the name server that responds is displayed.
.TP 3n
\fBname\fR
is the name of the resource record that is to be looked up.
.TP
.TP 3n
\fBtype\fR
indicates what type of query is required \(em
ANY, A, MX, SIG, etc.
\fItype\fR can be any valid query type. If no
\fItype\fR argument is supplied,
\fBdig\fR will perform a lookup for an A record.
indicates what type of query is required \(em ANY, A, MX, SIG, etc.
\fItype\fR
can be any valid query type. If no
\fItype\fR
argument is supplied,
\fBdig\fR
will perform a lookup for an A record.
.SH "OPTIONS"
.PP
The \fB-b\fR option sets the source IP address of the query
to \fIaddress\fR. This must be a valid address on
one of the host's network interfaces or "0.0.0.0" or "::". An optional port
may be specified by appending "#<port>"
The
\fB\-b\fR
option sets the source IP address of the query to
\fIaddress\fR. This must be a valid address on one of the host's network interfaces or "0.0.0.0" or "::". An optional port may be specified by appending "#<port>"
.PP
The default query class (IN for internet) is overridden by the
\fB-c\fR option. \fIclass\fR is any valid
class, such as HS for Hesiod records or CH for CHAOSNET records.
\fB\-c\fR
option.
\fIclass\fR
is any valid class, such as HS for Hesiod records or CH for CHAOSNET records.
.PP
The \fB-f\fR option makes \fBdig \fR operate
in batch mode by reading a list of lookup requests to process from the
file \fIfilename\fR. The file contains a number of
queries, one per line. Each entry in the file should be organised in
the same way they would be presented as queries to
\fBdig\fR using the command-line interface.
The
\fB\-f\fR
option makes
\fBdig \fR
operate in batch mode by reading a list of lookup requests to process from the file
\fIfilename\fR. The file contains a number of queries, one per line. Each entry in the file should be organised in the same way they would be presented as queries to
\fBdig\fR
using the command\-line interface.
.PP
If a non-standard port number is to be queried, the
\fB-p\fR option is used. \fIport#\fR is
the port number that \fBdig\fR will send its queries
instead of the standard DNS port number 53. This option would be used
to test a name server that has been configured to listen for queries
on a non-standard port number.
If a non\-standard port number is to be queried, the
\fB\-p\fR
option is used.
\fIport#\fR
is the port number that
\fBdig\fR
will send its queries instead of the standard DNS port number 53. This option would be used to test a name server that has been configured to listen for queries on a non\-standard port number.
.PP
The \fB-4\fR option forces \fBdig\fR to only
use IPv4 query transport. The \fB-6\fR option forces
\fBdig\fR to only use IPv6 query transport.
The
\fB\-4\fR
option forces
\fBdig\fR
to only use IPv4 query transport. The
\fB\-6\fR
option forces
\fBdig\fR
to only use IPv6 query transport.
.PP
The \fB-t\fR option sets the query type to
\fItype\fR. It can be any valid query type which is
supported in BIND9. The default query type "A", unless the
\fB-x\fR option is supplied to indicate a reverse lookup.
A zone transfer can be requested by specifying a type of AXFR. When
an incremental zone transfer (IXFR) is required,
\fItype\fR is set to ixfr=N.
The incremental zone transfer will contain the changes made to the zone
since the serial number in the zone's SOA record was
The
\fB\-t\fR
option sets the query type to
\fItype\fR. It can be any valid query type which is supported in BIND9. The default query type "A", unless the
\fB\-x\fR
option is supplied to indicate a reverse lookup. A zone transfer can be requested by specifying a type of AXFR. When an incremental zone transfer (IXFR) is required,
\fItype\fR
is set to
ixfr=N. The incremental zone transfer will contain the changes made to the zone since the serial number in the zone's SOA record was
\fIN\fR.
.PP
Reverse lookups - mapping addresses to names - are simplified by the
\fB-x\fR option. \fIaddr\fR is an IPv4
address in dotted-decimal notation, or a colon-delimited IPv6 address.
When this option is used, there is no need to provide the
\fIname\fR, \fIclass\fR and
\fItype\fR arguments. \fBdig\fR
Reverse lookups \- mapping addresses to names \- are simplified by the
\fB\-x\fR
option.
\fIaddr\fR
is an IPv4 address in dotted\-decimal notation, or a colon\-delimited IPv6 address. When this option is used, there is no need to provide the
\fIname\fR,
\fIclass\fR
and
\fItype\fR
arguments.
\fBdig\fR
automatically performs a lookup for a name like
11.12.13.10.in-addr.arpa and sets the query type and
class to PTR and IN respectively. By default, IPv6 addresses are
looked up using nibble format under the IP6.ARPA domain.
To use the older RFC1886 method using the IP6.INT domain
specify the \fB-i\fR option. Bit string labels (RFC2874)
are now experimental and are not attempted.
11.12.13.10.in\-addr.arpa
and sets the query type and class to PTR and IN respectively. By default, IPv6 addresses are looked up using nibble format under the IP6.ARPA domain. To use the older RFC1886 method using the IP6.INT domain specify the
\fB\-i\fR
option. Bit string labels (RFC2874) are now experimental and are not attempted.
.PP
To sign the DNS queries sent by \fBdig\fR and their
responses using transaction signatures (TSIG), specify a TSIG key file
using the \fB-k\fR option. You can also specify the TSIG
key itself on the command line using the \fB-y\fR option;
\fIname\fR is the name of the TSIG key and
\fIkey\fR is the actual key. The key is a base-64
encoded string, typically generated by \fBdnssec-keygen\fR(8).
Caution should be taken when using the \fB-y\fR option on
multi-user systems as the key can be visible in the output from
\fBps\fR(1) or in the shell's history file. When
using TSIG authentication with \fBdig\fR, the name
server that is queried needs to know the key and algorithm that is
being used. In BIND, this is done by providing appropriate
\fBkey\fR and \fBserver\fR statements in
To sign the DNS queries sent by
\fBdig\fR
and their responses using transaction signatures (TSIG), specify a TSIG key file using the
\fB\-k\fR
option. You can also specify the TSIG key itself on the command line using the
\fB\-y\fR
option;
\fIname\fR
is the name of the TSIG key and
\fIkey\fR
is the actual key. The key is a base\-64 encoded string, typically generated by
\fBdnssec\-keygen\fR(8). Caution should be taken when using the
\fB\-y\fR
option on multi\-user systems as the key can be visible in the output from
\fBps\fR(1 )
or in the shell's history file. When using TSIG authentication with
\fBdig\fR, the name server that is queried needs to know the key and algorithm that is being used. In BIND, this is done by providing appropriate
\fBkey\fR
and
\fBserver\fR
statements in
\fInamed.conf\fR.
.SH "QUERY OPTIONS"
.PP
\fBdig\fR provides a number of query options which affect
the way in which lookups are made and the results displayed. Some of
these set or reset flag bits in the query header, some determine which
sections of the answer get printed, and others determine the timeout
and retry strategies.
\fBdig\fR
provides a number of query options which affect the way in which lookups are made and the results displayed. Some of these set or reset flag bits in the query header, some determine which sections of the answer get printed, and others determine the timeout and retry strategies.
.PP
Each query option is identified by a keyword preceded by a plus sign
(+). Some keywords set or reset an option. These may be preceded
by the string no to negate the meaning of that keyword. Other
keywords assign values to options like the timeout interval. They
have the form \fB+keyword=value\fR.
The query options are:
.TP
Each query option is identified by a keyword preceded by a plus sign (+). Some keywords set or reset an option. These may be preceded by the string
no
to negate the meaning of that keyword. Other keywords assign values to options like the timeout interval. They have the form
\fB+keyword=value\fR. The query options are:
.TP 3n
\fB+[no]tcp\fR
Use [do not use] TCP when querying name servers. The default
behaviour is to use UDP unless an AXFR or IXFR query is requested, in
which case a TCP connection is used.
.TP
Use [do not use] TCP when querying name servers. The default behaviour is to use UDP unless an AXFR or IXFR query is requested, in which case a TCP connection is used.
.TP 3n
\fB+[no]vc\fR
Use [do not use] TCP when querying name servers. This alternate
syntax to \fI+[no]tcp\fR is provided for backwards
compatibility. The "vc" stands for "virtual circuit".
.TP
Use [do not use] TCP when querying name servers. This alternate syntax to
\fI+[no]tcp\fR
is provided for backwards compatibility. The "vc" stands for "virtual circuit".
.TP 3n
\fB+[no]ignore\fR
Ignore truncation in UDP responses instead of retrying with TCP. By
default, TCP retries are performed.
.TP
Ignore truncation in UDP responses instead of retrying with TCP. By default, TCP retries are performed.
.TP 3n
\fB+domain=somename\fR
Set the search list to contain the single domain
\fIsomename\fR, as if specified in a
\fBdomain\fR directive in
\fI/etc/resolv.conf\fR, and enable search list
processing as if the \fI+search\fR option were given.
.TP
\fBdomain\fR
directive in
\fI/etc/resolv.conf\fR, and enable search list processing as if the
\fI+search\fR
option were given.
.TP 3n
\fB+[no]search\fR
Use [do not use] the search list defined by the searchlist or domain
directive in \fIresolv.conf\fR (if any).
The search list is not used by default.
.TP
Use [do not use] the search list defined by the searchlist or domain directive in
\fIresolv.conf\fR
(if any). The search list is not used by default.
.TP 3n
\fB+[no]defname\fR
Deprecated, treated as a synonym for \fI+[no]search\fR
.TP
Deprecated, treated as a synonym for
\fI+[no]search\fR
.TP 3n
\fB+[no]aaonly\fR
Sets the "aa" flag in the query.
.TP
.TP 3n
\fB+[no]aaflag\fR
A synonym for \fI+[no]aaonly\fR.
.TP
A synonym for
\fI+[no]aaonly\fR.
.TP 3n
\fB+[no]adflag\fR
Set [do not set] the AD (authentic data) bit in the query. The AD bit
currently has a standard meaning only in responses, not in queries,
but the ability to set the bit in the query is provided for
completeness.
.TP
Set [do not set] the AD (authentic data) bit in the query. The AD bit currently has a standard meaning only in responses, not in queries, but the ability to set the bit in the query is provided for completeness.
.TP 3n
\fB+[no]cdflag\fR
Set [do not set] the CD (checking disabled) bit in the query. This
requests the server to not perform DNSSEC validation of responses.
.TP
Set [do not set] the CD (checking disabled) bit in the query. This requests the server to not perform DNSSEC validation of responses.
.TP 3n
\fB+[no]cl\fR
Display [do not display] the CLASS when printing the record.
.TP
.TP 3n
\fB+[no]ttlid\fR
Display [do not display] the TTL when printing the record.
.TP
.TP 3n
\fB+[no]recurse\fR
Toggle the setting of the RD (recursion desired) bit in the query.
This bit is set by default, which means \fBdig\fR
normally sends recursive queries. Recursion is automatically disabled
when the \fI+nssearch\fR or
\fI+trace\fR query options are used.
.TP
Toggle the setting of the RD (recursion desired) bit in the query. This bit is set by default, which means
\fBdig\fR
normally sends recursive queries. Recursion is automatically disabled when the
\fI+nssearch\fR
or
\fI+trace\fR
query options are used.
.TP 3n
\fB+[no]nssearch\fR
When this option is set, \fBdig\fR attempts to find the
authoritative name servers for the zone containing the name being
looked up and display the SOA record that each name server has for the
zone.
.TP
When this option is set,
\fBdig\fR
attempts to find the authoritative name servers for the zone containing the name being looked up and display the SOA record that each name server has for the zone.
.TP 3n
\fB+[no]trace\fR
Toggle tracing of the delegation path from the root name servers for
the name being looked up. Tracing is disabled by default. When
tracing is enabled, \fBdig\fR makes iterative queries to
resolve the name being looked up. It will follow referrals from the
root servers, showing the answer from each server that was used to
resolve the lookup.
.TP
Toggle tracing of the delegation path from the root name servers for the name being looked up. Tracing is disabled by default. When tracing is enabled,
\fBdig\fR
makes iterative queries to resolve the name being looked up. It will follow referrals from the root servers, showing the answer from each server that was used to resolve the lookup.
.TP 3n
\fB+[no]cmd\fR
toggles the printing of the initial comment in the output identifying
the version of \fBdig\fR and the query options that have
been applied. This comment is printed by default.
.TP
toggles the printing of the initial comment in the output identifying the version of
\fBdig\fR
and the query options that have been applied. This comment is printed by default.
.TP 3n
\fB+[no]short\fR
Provide a terse answer. The default is to print the answer in a
verbose form.
.TP
Provide a terse answer. The default is to print the answer in a verbose form.
.TP 3n
\fB+[no]identify\fR
Show [or do not show] the IP address and port number that supplied the
answer when the \fI+short\fR option is enabled. If
short form answers are requested, the default is not to show the
source address and port number of the server that provided the answer.
.TP
Show [or do not show] the IP address and port number that supplied the answer when the
\fI+short\fR
option is enabled. If short form answers are requested, the default is not to show the source address and port number of the server that provided the answer.
.TP 3n
\fB+[no]comments\fR
Toggle the display of comment lines in the output. The default is to
print comments.
.TP
Toggle the display of comment lines in the output. The default is to print comments.
.TP 3n
\fB+[no]stats\fR
This query option toggles the printing of statistics: when the query
was made, the size of the reply and so on. The default behaviour is
to print the query statistics.
.TP
This query option toggles the printing of statistics: when the query was made, the size of the reply and so on. The default behaviour is to print the query statistics.
.TP 3n
\fB+[no]qr\fR
Print [do not print] the query as it is sent.
By default, the query is not printed.
.TP
Print [do not print] the query as it is sent. By default, the query is not printed.
.TP 3n
\fB+[no]question\fR
Print [do not print] the question section of a query when an answer is
returned. The default is to print the question section as a comment.
.TP
Print [do not print] the question section of a query when an answer is returned. The default is to print the question section as a comment.
.TP 3n
\fB+[no]answer\fR
Display [do not display] the answer section of a reply. The default
is to display it.
.TP
Display [do not display] the answer section of a reply. The default is to display it.
.TP 3n
\fB+[no]authority\fR
Display [do not display] the authority section of a reply. The
default is to display it.
.TP
Display [do not display] the authority section of a reply. The default is to display it.
.TP 3n
\fB+[no]additional\fR
Display [do not display] the additional section of a reply.
The default is to display it.
.TP
Display [do not display] the additional section of a reply. The default is to display it.
.TP 3n
\fB+[no]all\fR
Set or clear all display flags.
.TP
.TP 3n
\fB+time=T\fR
Sets the timeout for a query to
\fIT\fR seconds. The default time out is 5 seconds.
An attempt to set \fIT\fR to less than 1 will result
in a query timeout of 1 second being applied.
.TP
\fIT\fR
seconds. The default time out is 5 seconds. An attempt to set
\fIT\fR
to less than 1 will result in a query timeout of 1 second being applied.
.TP 3n
\fB+tries=T\fR
Sets the number of times to try UDP queries to server to
\fIT\fR instead of the default, 3. If
\fIT\fR is less than or equal to zero, the number of
tries is silently rounded up to 1.
.TP
\fIT\fR
instead of the default, 3. If
\fIT\fR
is less than or equal to zero, the number of tries is silently rounded up to 1.
.TP 3n
\fB+retry=T\fR
Sets the number of times to retry UDP queries to server to
\fIT\fR instead of the default, 2. Unlike
\fI+tries\fR, this does not include the initial
query.
.TP
\fIT\fR
instead of the default, 2. Unlike
\fI+tries\fR, this does not include the initial query.
.TP 3n
\fB+ndots=D\fR
Set the number of dots that have to appear in
\fIname\fR to \fID\fR for it to be
considered absolute. The default value is that defined using the
ndots statement in \fI/etc/resolv.conf\fR, or 1 if no
ndots statement is present. Names with fewer dots are interpreted as
relative names and will be searched for in the domains listed in the
\fBsearch\fR or \fBdomain\fR directive in
\fIname\fR
to
\fID\fR
for it to be considered absolute. The default value is that defined using the ndots statement in
\fI/etc/resolv.conf\fR, or 1 if no ndots statement is present. Names with fewer dots are interpreted as relative names and will be searched for in the domains listed in the
\fBsearch\fR
or
\fBdomain\fR
directive in
\fI/etc/resolv.conf\fR.
.TP
.TP 3n
\fB+bufsize=B\fR
Set the UDP message buffer size advertised using EDNS0 to
\fIB\fR bytes. The maximum and minimum sizes of this
buffer are 65535 and 0 respectively. Values outside this range are
rounded up or down appropriately.
.TP
\fIB\fR
bytes. The maximum and minimum sizes of this buffer are 65535 and 0 respectively. Values outside this range are rounded up or down appropriately.
.TP 3n
\fB+[no]multiline\fR
Print records like the SOA records in a verbose multi-line
format with human-readable comments. The default is to print
each record on a single line, to facilitate machine parsing
of the \fBdig\fR output.
.TP
Print records like the SOA records in a verbose multi\-line format with human\-readable comments. The default is to print each record on a single line, to facilitate machine parsing of the
\fBdig\fR
output.
.TP 3n
\fB+[no]fail\fR
Do not try the next server if you receive a SERVFAIL. The default is
to not try the next server which is the reverse of normal stub resolver
behaviour.
.TP
Do not try the next server if you receive a SERVFAIL. The default is to not try the next server which is the reverse of normal stub resolver behaviour.
.TP 3n
\fB+[no]besteffort\fR
Attempt to display the contents of messages which are malformed.
The default is to not display malformed answers.
.TP
Attempt to display the contents of messages which are malformed. The default is to not display malformed answers.
.TP 3n
\fB+[no]dnssec\fR
Requests DNSSEC records be sent by setting the DNSSEC OK bit (DO)
in the OPT record in the additional section of the query.
.TP
Requests DNSSEC records be sent by setting the DNSSEC OK bit (DO) in the OPT record in the additional section of the query.
.TP 3n
\fB+[no]sigchase\fR
Chase DNSSEC signature chains. Requires dig be compiled with
-DDIG_SIGCHASE.
.TP
\fB+trusted-key=####\fR
Specify a trusted key to be used with \fB+sigchase\fR.
Requires dig be compiled with -DDIG_SIGCHASE.
.TP
Chase DNSSEC signature chains. Requires dig be compiled with \-DDIG_SIGCHASE.
.TP 3n
\fB+trusted\-key=####\fR
Specifies a file containing trusted keys to be used with
\fB+sigchase\fR. Each DNSKEY record must be on its own line.
.sp
If not specified
\fBdig\fR
will look for
\fI/etc/trusted\-key.key\fR
then
\fItrusted\-key.key\fR
in the current directory.
.sp
Requires dig be compiled with \-DDIG_SIGCHASE.
.TP 3n
\fB+[no]topdown\fR
When chasing DNSSEC signature chains perform a top down validation.
Requires dig be compiled with -DDIG_SIGCHASE.
When chasing DNSSEC signature chains perform a top down validation. Requires dig be compiled with \-DDIG_SIGCHASE.
.SH "MULTIPLE QUERIES"
.PP
The BIND 9 implementation of \fBdig \fR supports
specifying multiple queries on the command line (in addition to
supporting the \fB-f\fR batch file option). Each of those
queries can be supplied with its own set of flags, options and query
options.
The BIND 9 implementation of
\fBdig \fR
supports specifying multiple queries on the command line (in addition to supporting the
\fB\-f\fR
batch file option). Each of those queries can be supplied with its own set of flags, options and query options.
.PP
In this case, each \fIquery\fR argument represent an
individual query in the command-line syntax described above. Each
consists of any of the standard options and flags, the name to be
looked up, an optional query type and class and any query options that
should be applied to that query.
In this case, each
\fIquery\fR
argument represent an individual query in the command\-line syntax described above. Each consists of any of the standard options and flags, the name to be looked up, an optional query type and class and any query options that should be applied to that query.
.PP
A global set of query options, which should be applied to all queries,
can also be supplied. These global query options must precede the
first tuple of name, class, type, options, flags, and query options
supplied on the command line. Any global query options (except
the \fB+[no]cmd\fR option) can be
overridden by a query-specific set of query options. For example:
A global set of query options, which should be applied to all queries, can also be supplied. These global query options must precede the first tuple of name, class, type, options, flags, and query options supplied on the command line. Any global query options (except the
\fB+[no]cmd\fR
option) can be overridden by a query\-specific set of query options. For example:
.sp
.RS 3n
.nf
dig +qr www.isc.org any -x 127.0.0.1 isc.org ns +noqr
.sp
dig +qr www.isc.org any \-x 127.0.0.1 isc.org ns +noqr
.fi
shows how \fBdig\fR could be used from the command line
to make three lookups: an ANY query for www.isc.org, a
reverse lookup of 127.0.0.1 and a query for the NS records of
isc.org.
A global query option of \fI+qr\fR is applied, so
that \fBdig\fR shows the initial query it made for each
lookup. The final query has a local query option of
\fI+noqr\fR which means that \fBdig\fR
.RE
.sp
shows how
\fBdig\fR
could be used from the command line to make three lookups: an ANY query for
www.isc.org, a reverse lookup of 127.0.0.1 and a query for the NS records of
isc.org. A global query option of
\fI+qr\fR
is applied, so that
\fBdig\fR
shows the initial query it made for each lookup. The final query has a local query option of
\fI+noqr\fR
which means that
\fBdig\fR
will not print the initial query when it looks up the NS records for
isc.org.
.SH "FILES"
@@ -394,8 +423,10 @@ isc.org.
.PP
\fBhost\fR(1),
\fBnamed\fR(8),
\fBdnssec-keygen\fR(8),
\fIRFC1035\fR.
.SH "BUGS"
\fBdnssec\-keygen\fR(8),
RFC1035.
.SH "BUGS "
.PP
There are probably too many query options.
There are probably too many query options.
.SH "COPYRIGHT"
Copyright \(co 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
+7 -35
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2000-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dig.c,v 1.157.2.13.2.25 2004/09/16 02:14:14 marka Exp $ */
/* $Id: dig.c,v 1.157.2.13.2.31 2006/07/22 23:52:57 marka Exp $ */
#include <config.h>
#include <stdlib.h>
@@ -45,10 +45,6 @@
#include <dig/dig.h>
extern ISC_LIST(dig_lookup_t) lookup_list;
extern dig_serverlist_t server_list;
extern ISC_LIST(dig_searchlist_t) search_list;
#define ADD_STRING(b, s) { \
if (strlen(s) >= isc_buffer_availablelength(b)) \
return (ISC_R_NOSPACE); \
@@ -58,31 +54,8 @@ extern ISC_LIST(dig_searchlist_t) search_list;
#define DIG_MAX_ADDRESSES 20
extern isc_boolean_t have_ipv4, have_ipv6, specified_source,
usesearch, qr;
extern in_port_t port;
extern unsigned int timeout;
extern isc_mem_t *mctx;
extern dns_messageid_t id;
extern int sendcount;
extern int ndots;
extern int lookup_counter;
extern int exitcode;
extern isc_sockaddr_t bind_address;
extern char keynametext[MXNAME];
extern char keyfile[MXNAME];
extern char keysecret[MXNAME];
#ifdef DIG_SIGCHASE
extern char trustedkey[MXNAME];
#endif
extern dns_tsigkey_t *key;
extern isc_boolean_t validated;
extern isc_taskmgr_t *taskmgr;
extern isc_task_t *global_task;
extern isc_boolean_t free_now;
dig_lookup_t *default_lookup = NULL;
extern isc_boolean_t debugging, memdebugging;
static char *batchname = NULL;
static FILE *batchfp = NULL;
static char *argv0;
@@ -133,8 +106,6 @@ static const char *rcodetext[] = {
"BADVERS"
};
extern char *progname;
static void
print_usage(FILE *fp) {
fputs(
@@ -593,6 +564,7 @@ buftoosmall:
}
}
}
if (headers && query->lookup->comments && !short_form)
printf("\n");
@@ -818,7 +790,7 @@ plus_option(char *option, isc_boolean_t is_batchfile,
break;
case 'l': /* cl */
FULLCHECK("cl");
noclass = !state;
noclass = ISC_TF(!state);
break;
case 'm': /* cmd */
FULLCHECK("cmd");
@@ -892,7 +864,7 @@ plus_option(char *option, isc_boolean_t is_batchfile,
lookup->ns_search_only = state;
if (state) {
lookup->trace_root = ISC_TRUE;
lookup->recurse = ISC_FALSE;
lookup->recurse = ISC_TRUE;
lookup->identify = ISC_TRUE;
lookup->stats = ISC_FALSE;
lookup->comments = ISC_FALSE;
@@ -1054,7 +1026,7 @@ plus_option(char *option, isc_boolean_t is_batchfile,
break;
case 't': /* ttlid */
FULLCHECK("ttlid");
nottl = !state;
nottl = ISC_TF(!state);
break;
default:
goto invalid_option;
@@ -1465,7 +1437,7 @@ parse_args(isc_boolean_t is_batchfile, isc_boolean_t config_only,
* Anything which isn't an option
*/
if (open_type_class) {
if (strncmp(rv[0], "ixfr=", 5) == 0) {
if (strncasecmp(rv[0], "ixfr=", 5) == 0) {
rdtype = dns_rdatatype_ixfr;
result = ISC_R_SUCCESS;
} else {
+45 -15
View File
@@ -1,6 +1,8 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.0//EN"
"http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd"
[<!ENTITY mdash "&#8212;">]>
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
@@ -16,7 +18,7 @@
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dig.docbook,v 1.4.2.7.4.9 2004/06/23 04:19:41 marka Exp $ -->
<!-- $Id: dig.docbook,v 1.4.2.7.4.12 2005/08/30 00:50:29 marka Exp $ -->
<refentry>
@@ -30,6 +32,21 @@
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<docinfo>
<copyright>
<year>2004</year>
<year>2005</year>
<holder>Internet Systems Consortium, Inc. ("ISC")</holder>
</copyright>
<copyright>
<year>2000</year>
<year>2001</year>
<year>2002</year>
<year>2003</year>
<holder>Internet Software Consortium.</holder>
</copyright>
</docinfo>
<refnamediv>
<refname>dig</refname>
<refpurpose>DNS lookup utility</refpurpose>
@@ -38,7 +55,7 @@
<refsynopsisdiv>
<cmdsynopsis>
<command>dig</command>
<arg choice=opt>@server</arg>
<arg choice="opt">@server</arg>
<arg><option>-b <replaceable class="parameter">address</replaceable></option></arg>
<arg><option>-c <replaceable class="parameter">class</replaceable></option></arg>
<arg><option>-f <replaceable class="parameter">filename</replaceable></option></arg>
@@ -49,10 +66,10 @@
<arg><option>-y <replaceable class="parameter">name:key</replaceable></option></arg>
<arg><option>-4</option></arg>
<arg><option>-6</option></arg>
<arg choice=opt>name</arg>
<arg choice=opt>type</arg>
<arg choice=opt>class</arg>
<arg choice=opt rep=repeat>queryopt</arg>
<arg choice="opt">name</arg>
<arg choice="opt">type</arg>
<arg choice="opt">class</arg>
<arg choice="opt" rep="repeat">queryopt</arg>
</cmdsynopsis>
<cmdsynopsis>
@@ -62,8 +79,8 @@
<cmdsynopsis>
<command>dig</command>
<arg choice=opt rep=repeat>global-queryopt</arg>
<arg choice=opt rep=repeat>query</arg>
<arg choice="opt" rep="repeat">global-queryopt</arg>
<arg choice="opt" rep="repeat">query</arg>
</cmdsynopsis>
</refsynopsisdiv>
@@ -513,11 +530,24 @@ Chase DNSSEC signature chains. Requires dig be compiled with
-DDIG_SIGCHASE.
</para></listitem></varlistentry>
<varlistentry><term><option>+trusted-key=####</option></term>
<listitem><para>
Specify a trusted key to be used with <option>+sigchase</option>.
Requires dig be compiled with -DDIG_SIGCHASE.
</para></listitem></varlistentry>
<varlistentry>
<term><option>+trusted-key=####</option></term>
<listitem>
<para>
Specifies a file containing trusted keys to be used with
<option>+sigchase</option>. Each DNSKEY record must be
on its own line.
</para>
<para>
If not specified <command>dig</command> will look for
<filename>/etc/trusted-key.key</filename> then
<filename>trusted-key.key</filename> in the current directory.
</para>
<para>
Requires dig be compiled with -DDIG_SIGCHASE.
</para>
</listitem>
</varlistentry>
<varlistentry><term><option>+[no]topdown</option></term>
<listitem><para>
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
+145 -91
View File
@@ -1,132 +1,184 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2002 Internet Software Consortium.
.\"
.\" Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2002 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: host.1,v 1.11.2.1.4.4 2004/04/13 04:11:03 marka Exp $
.\" $Id: host.1,v 1.11.2.1.4.8 2006/06/29 13:02:30 marka Exp $
.\"
.TH "HOST" "1" "Jun 30, 2000" "BIND9" ""
.SH NAME
.hy 0
.ad l
.\" Title: host
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: Jun 30, 2000
.\" Manual: BIND9
.\" Source: BIND9
.\"
.TH "HOST" "1" "Jun 30, 2000" "BIND9" "BIND9"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
host \- DNS lookup utility
.SH SYNOPSIS
.sp
\fBhost\fR [ \fB-aCdlnrTwv\fR ] [ \fB-c \fIclass\fB\fR ] [ \fB-N \fIndots\fB\fR ] [ \fB-R \fInumber\fB\fR ] [ \fB-t \fItype\fB\fR ] [ \fB-W \fIwait\fB\fR ] [ \fB-4\fR ] [ \fB-6\fR ] \fBname\fR [ \fBserver\fR ]
.SH "SYNOPSIS"
.HP 5
\fBhost\fR [\fB\-aCdlnrTwv\fR] [\fB\-c\ \fR\fB\fIclass\fR\fR] [\fB\-N\ \fR\fB\fIndots\fR\fR] [\fB\-R\ \fR\fB\fInumber\fR\fR] [\fB\-t\ \fR\fB\fItype\fR\fR] [\fB\-W\ \fR\fB\fIwait\fR\fR] [\fB\-4\fR] [\fB\-6\fR] {name} [server]
.SH "DESCRIPTION"
.PP
\fBhost\fR
is a simple utility for performing DNS lookups.
It is normally used to convert names to IP addresses and vice versa.
When no arguments or options are given,
is a simple utility for performing DNS lookups. It is normally used to convert names to IP addresses and vice versa. When no arguments or options are given,
\fBhost\fR
prints a short summary of its command line arguments and options.
.PP
\fIname\fR is the domain name that is to be looked
up. It can also be a dotted-decimal IPv4 address or a colon-delimited
IPv6 address, in which case \fBhost\fR will by default
perform a reverse lookup for that address.
\fIserver\fR is an optional argument which is either
the name or IP address of the name server that \fBhost\fR
\fIname\fR
is the domain name that is to be looked up. It can also be a dotted\-decimal IPv4 address or a colon\-delimited IPv6 address, in which case
\fBhost\fR
will by default perform a reverse lookup for that address.
\fIserver\fR
is an optional argument which is either the name or IP address of the name server that
\fBhost\fR
should query instead of the server or servers listed in
\fI/etc/resolv.conf\fR.
.PP
The \fB-a\fR (all) option is equivalent to setting the
\fB-v\fR option and asking \fBhost\fR to make
a query of type ANY.
The
\fB\-a\fR
(all) option is equivalent to setting the
\fB\-v\fR
option and asking
\fBhost\fR
to make a query of type ANY.
.PP
When the \fB-C\fR option is used, \fBhost\fR
When the
\fB\-C\fR
option is used,
\fBhost\fR
will attempt to display the SOA records for zone
\fIname\fR from all the listed authoritative name
servers for that zone. The list of name servers is defined by the NS
records that are found for the zone.
\fIname\fR
from all the listed authoritative name servers for that zone. The list of name servers is defined by the NS records that are found for the zone.
.PP
The \fB-c\fR option instructs to make a DNS query of class
\fIclass\fR. This can be used to lookup Hesiod or
Chaosnet class resource records. The default class is IN (Internet).
The
\fB\-c\fR
option instructs to make a DNS query of class
\fIclass\fR. This can be used to lookup Hesiod or Chaosnet class resource records. The default class is IN (Internet).
.PP
Verbose output is generated by \fBhost\fR when the
\fB-d\fR or \fB-v\fR option is used. The two
options are equivalent. They have been provided for backwards
compatibility. In previous versions, the \fB-d\fR option
switched on debugging traces and \fB-v\fR enabled verbose
output.
Verbose output is generated by
\fBhost\fR
when the
\fB\-d\fR
or
\fB\-v\fR
option is used. The two options are equivalent. They have been provided for backwards compatibility. In previous versions, the
\fB\-d\fR
option switched on debugging traces and
\fB\-v\fR
enabled verbose output.
.PP
List mode is selected by the \fB-l\fR option. This makes
\fBhost\fR perform a zone transfer for zone
\fIname\fR. Transfer the zone printing out the NS, PTR
and address records (A/AAAA). If combined with \fB-a\fR
all records will be printed.
List mode is selected by the
\fB\-l\fR
option. This makes
\fBhost\fR
perform a zone transfer for zone
\fIname\fR. Transfer the zone printing out the NS, PTR and address records (A/AAAA). If combined with
\fB\-a\fR
all records will be printed.
.PP
The \fB-i\fR
option specifies that reverse lookups of IPv6 addresses should
use the IP6.INT domain as defined in RFC1886.
The default is to use IP6.ARPA.
The
\fB\-i\fR
option specifies that reverse lookups of IPv6 addresses should use the IP6.INT domain as defined in RFC1886. The default is to use IP6.ARPA.
.PP
The \fB-N\fR option sets the number of dots that have to be
in \fIname\fR for it to be considered absolute. The
default value is that defined using the ndots statement in
\fI/etc/resolv.conf\fR, or 1 if no ndots statement is
present. Names with fewer dots are interpreted as relative names and
will be searched for in the domains listed in the \fBsearch\fR
or \fBdomain\fR directive in
The
\fB\-N\fR
option sets the number of dots that have to be in
\fIname\fR
for it to be considered absolute. The default value is that defined using the ndots statement in
\fI/etc/resolv.conf\fR, or 1 if no ndots statement is present. Names with fewer dots are interpreted as relative names and will be searched for in the domains listed in the
\fBsearch\fR
or
\fBdomain\fR
directive in
\fI/etc/resolv.conf\fR.
.PP
The number of UDP retries for a lookup can be changed with the
\fB-R\fR option. \fInumber\fR indicates
how many times \fBhost\fR will repeat a query that does
not get answered. The default number of retries is 1. If
\fInumber\fR is negative or zero, the number of
retries will default to 1.
\fB\-R\fR
option.
\fInumber\fR
indicates how many times
\fBhost\fR
will repeat a query that does not get answered. The default number of retries is 1. If
\fInumber\fR
is negative or zero, the number of retries will default to 1.
.PP
Non-recursive queries can be made via the \fB-r\fR option.
Setting this option clears the \fBRD\fR \(em recursion
desired \(em bit in the query which \fBhost\fR makes.
This should mean that the name server receiving the query will not
attempt to resolve \fIname\fR. The
\fB-r\fR option enables \fBhost\fR to mimic
the behaviour of a name server by making non-recursive queries and
expecting to receive answers to those queries that are usually
referrals to other name servers.
Non\-recursive queries can be made via the
\fB\-r\fR
option. Setting this option clears the
\fBRD\fR
\(em recursion desired \(em bit in the query which
\fBhost\fR
makes. This should mean that the name server receiving the query will not attempt to resolve
\fIname\fR. The
\fB\-r\fR
option enables
\fBhost\fR
to mimic the behaviour of a name server by making non\-recursive queries and expecting to receive answers to those queries that are usually referrals to other name servers.
.PP
By default \fBhost\fR uses UDP when making queries. The
\fB-T\fR option makes it use a TCP connection when querying
the name server. TCP will be automatically selected for queries that
require it, such as zone transfer (AXFR) requests.
By default
\fBhost\fR
uses UDP when making queries. The
\fB\-T\fR
option makes it use a TCP connection when querying the name server. TCP will be automatically selected for queries that require it, such as zone transfer (AXFR) requests.
.PP
The \fB-4\fR option forces \fBhost\fR to only
use IPv4 query transport. The \fB-6\fR option forces
\fBhost\fR to only use IPv6 query transport.
The
\fB\-4\fR
option forces
\fBhost\fR
to only use IPv4 query transport. The
\fB\-6\fR
option forces
\fBhost\fR
to only use IPv6 query transport.
.PP
The \fB-t\fR option is used to select the query type.
\fItype\fR can be any recognised query type: CNAME,
NS, SOA, SIG, KEY, AXFR, etc. When no query type is specified,
\fBhost\fR automatically selects an appropriate query
type. By default it looks for A records, but if the
\fB-C\fR option was given, queries will be made for SOA
records, and if \fIname\fR is a dotted-decimal IPv4
address or colon-delimited IPv6 address, \fBhost\fR will
query for PTR records. If a query type of IXFR is chosen the starting
serial number can be specified by appending an equal followed by the
starting serial number (e.g. -t IXFR=12345678).
The
\fB\-t\fR
option is used to select the query type.
\fItype\fR
can be any recognised query type: CNAME, NS, SOA, SIG, KEY, AXFR, etc. When no query type is specified,
\fBhost\fR
automatically selects an appropriate query type. By default it looks for A records, but if the
\fB\-C\fR
option was given, queries will be made for SOA records, and if
\fIname\fR
is a dotted\-decimal IPv4 address or colon\-delimited IPv6 address,
\fBhost\fR
will query for PTR records. If a query type of IXFR is chosen the starting serial number can be specified by appending an equal followed by the starting serial number (e.g. \-t IXFR=12345678).
.PP
The time to wait for a reply can be controlled through the
\fB-W\fR and \fB-w\fR options. The
\fB-W\fR option makes \fBhost\fR wait for
\fIwait\fR seconds. If \fIwait\fR
\fB\-W\fR
and
\fB\-w\fR
options. The
\fB\-W\fR
option makes
\fBhost\fR
wait for
\fIwait\fR
seconds. If
\fIwait\fR
is less than one, the wait interval is set to one second. When the
\fB-w\fR option is used, \fBhost\fR will
effectively wait forever for a reply. The time to wait for a response
will be set to the number of seconds given by the hardware's maximum
value for an integer quantity.
\fB\-w\fR
option is used,
\fBhost\fR
will effectively wait forever for a reply. The time to wait for a response will be set to the number of seconds given by the hardware's maximum value for an integer quantity.
.SH "FILES"
.PP
\fI/etc/resolv.conf\fR
@@ -134,3 +186,5 @@ value for an integer quantity.
.PP
\fBdig\fR(1),
\fBnamed\fR(8).
.SH "COPYRIGHT"
Copyright \(co 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
+40 -20
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2000-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: host.c,v 1.76.2.5.2.10 2004/09/06 01:33:05 marka Exp $ */
/* $Id: host.c,v 1.76.2.5.2.16 2006/05/23 04:43:47 marka Exp $ */
#include <config.h>
#include <limits.h>
@@ -37,29 +37,16 @@
#include <dns/rdataclass.h>
#include <dns/rdataset.h>
#include <dns/rdatatype.h>
#include <dns/rdatastruct.h>
#include <dig/dig.h>
extern ISC_LIST(dig_lookup_t) lookup_list;
extern dig_serverlist_t server_list;
extern ISC_LIST(dig_searchlist_t) search_list;
extern isc_boolean_t have_ipv4, have_ipv6;
extern isc_boolean_t usesearch;
extern isc_boolean_t debugging;
extern unsigned int timeout;
extern isc_mem_t *mctx;
extern int ndots;
extern int tries;
extern char *progname;
extern isc_task_t *global_task;
extern int fatalexit;
static isc_boolean_t short_form = ISC_TRUE, listed_server = ISC_FALSE;
static isc_boolean_t default_lookups = ISC_TRUE;
static int seen_error = -1;
static isc_boolean_t list_addresses = ISC_TRUE;
static dns_rdatatype_t list_type = dns_rdatatype_a;
static isc_boolean_t printed_server = ISC_FALSE;
static const char *opcodetext[] = {
"QUERY",
@@ -366,6 +353,32 @@ printrdata(dns_message_t *msg, dns_rdataset_t *rdataset, dns_name_t *owner,
return (ISC_R_SUCCESS);
}
static void
chase_cnamechain(dns_message_t *msg, dns_name_t *qname) {
isc_result_t result;
dns_rdataset_t *rdataset;
dns_rdata_cname_t cname;
dns_rdata_t rdata = DNS_RDATA_INIT;
unsigned int i = msg->counts[DNS_SECTION_ANSWER];
while (i-- > 0) {
rdataset = NULL;
result = dns_message_findname(msg, DNS_SECTION_ANSWER, qname,
dns_rdatatype_cname, 0, NULL,
&rdataset);
if (result != ISC_R_SUCCESS)
return;
result = dns_rdataset_first(rdataset);
check_result(result, "dns_rdataset_first");
dns_rdata_reset(&rdata);
dns_rdataset_current(rdataset, &rdata);
result = dns_rdata_tostruct(&rdata, &cname, NULL);
check_result(result, "dns_rdata_tostruct");
dns_name_copy(&cname.cname, qname, NULL);
dns_rdata_freestruct(&cname);
}
}
isc_result_t
printmessage(dig_query_t *query, dns_message_t *msg, isc_boolean_t headers) {
isc_boolean_t did_flag = ISC_FALSE;
@@ -382,7 +395,7 @@ printmessage(dig_query_t *query, dns_message_t *msg, isc_boolean_t headers) {
*/
force_error = (seen_error == 1) ? 1 : 0;
seen_error = 1;
if (listed_server) {
if (listed_server && !printed_server) {
char sockstr[ISC_SOCKADDR_FORMATSIZE];
printf("Using domain server:\n");
@@ -391,6 +404,7 @@ printmessage(dig_query_t *query, dns_message_t *msg, isc_boolean_t headers) {
sizeof(sockstr));
printf("Address: %s\n", sockstr);
printf("Aliases: \n\n");
printed_server = ISC_TRUE;
}
if (msg->rcode != 0) {
@@ -404,10 +418,15 @@ printmessage(dig_query_t *query, dns_message_t *msg, isc_boolean_t headers) {
if (default_lookups && query->lookup->rdtype == dns_rdatatype_a) {
char namestr[DNS_NAME_FORMATSIZE];
dig_lookup_t *lookup;
dns_fixedname_t fixed;
dns_name_t *name;
/* Add AAAA and MX lookups. */
dns_name_format(query->lookup->name, namestr, sizeof(namestr));
dns_fixedname_init(&fixed);
name = dns_fixedname_name(&fixed);
dns_name_copy(query->lookup->name, name, NULL);
chase_cnamechain(msg, name);
dns_name_format(name, namestr, sizeof(namestr));
lookup = clone_lookup(query->lookup, ISC_FALSE);
if (lookup != NULL) {
strncpy(lookup->textname, namestr,
@@ -604,6 +623,7 @@ parse_args(isc_boolean_t is_batchfile, int argc, char **argv) {
} else
list_type = rdtype;
list_addresses = ISC_FALSE;
default_lookups = ISC_FALSE;
break;
case 'c':
tr.base = isc_commandline_argument;
+21 -5
View File
@@ -1,6 +1,8 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.0//EN"
"http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd"
[<!ENTITY mdash "&#8212;">]>
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2002 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
@@ -16,7 +18,7 @@
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: host.docbook,v 1.2.2.2.4.5 2004/04/13 01:26:26 marka Exp $ -->
<!-- $Id: host.docbook,v 1.2.2.2.4.7 2005/05/13 01:22:32 marka Exp $ -->
<refentry>
@@ -30,6 +32,20 @@
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<docinfo>
<copyright>
<year>2004</year>
<year>2005</year>
<holder>Internet Systems Consortium, Inc. ("ISC")</holder>
</copyright>
<copyright>
<year>2000</year>
<year>2001</year>
<year>2002</year>
<holder>Internet Software Consortium.</holder>
</copyright>
</docinfo>
<refnamediv>
<refname>host</refname>
<refpurpose>DNS lookup utility</refpurpose>
@@ -46,8 +62,8 @@
<arg><option>-W <replaceable class="parameter">wait</replaceable></option></arg>
<arg><option>-4</option></arg>
<arg><option>-6</option></arg>
<arg choice=req>name</arg>
<arg choice=opt>server</arg>
<arg choice="req">name</arg>
<arg choice="opt">server</arg>
</cmdsynopsis>
</refsynopsisdiv>
+135 -398
View File
@@ -1,434 +1,171 @@
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2002 Internet Software Consortium.
-
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2002 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: host.html,v 1.4.2.1.4.6 2004/08/22 23:38:58 marka Exp $ -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML
><HEAD
><TITLE
>host</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"></HEAD
><BODY
CLASS="REFENTRY"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><H1
><A
NAME="AEN1"
></A
>host</H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN8"
></A
><H2
>Name</H2
>host&nbsp;--&nbsp;DNS lookup utility</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN11"
></A
><H2
>Synopsis</H2
><P
><B
CLASS="COMMAND"
>host</B
> [<VAR
CLASS="OPTION"
>-aCdlnrTwv</VAR
>] [<VAR
CLASS="OPTION"
>-c <VAR
CLASS="REPLACEABLE"
>class</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-N <VAR
CLASS="REPLACEABLE"
>ndots</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-R <VAR
CLASS="REPLACEABLE"
>number</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-t <VAR
CLASS="REPLACEABLE"
>type</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-W <VAR
CLASS="REPLACEABLE"
>wait</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-4</VAR
>] [<VAR
CLASS="OPTION"
>-6</VAR
>] {name} [server]</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN37"
></A
><H2
>DESCRIPTION</H2
><P
><B
CLASS="COMMAND"
>host</B
>
<!-- $Id: host.html,v 1.4.2.1.4.14 2006/06/29 13:02:30 marka Exp $ -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>host</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.70.1">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
<a name="id2482688"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2>Name</h2>
<p>host &#8212; DNS lookup utility</p>
</div>
<div class="refsynopsisdiv">
<h2>Synopsis</h2>
<div class="cmdsynopsis"><p><code class="command">host</code> [<code class="option">-aCdlnrTwv</code>] [<code class="option">-c <em class="replaceable"><code>class</code></em></code>] [<code class="option">-N <em class="replaceable"><code>ndots</code></em></code>] [<code class="option">-R <em class="replaceable"><code>number</code></em></code>] [<code class="option">-t <em class="replaceable"><code>type</code></em></code>] [<code class="option">-W <em class="replaceable"><code>wait</code></em></code>] [<code class="option">-4</code>] [<code class="option">-6</code>] {name} [server]</p></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549466"></a><h2>DESCRIPTION</h2>
<p>
<span><strong class="command">host</strong></span>
is a simple utility for performing DNS lookups.
It is normally used to convert names to IP addresses and vice versa.
When no arguments or options are given,
<B
CLASS="COMMAND"
>host</B
>
prints a short summary of its command line arguments and options.</P
><P
><VAR
CLASS="PARAMETER"
>name</VAR
> is the domain name that is to be looked
<span><strong class="command">host</strong></span>
prints a short summary of its command line arguments and options.
</p>
<p>
<em class="parameter"><code>name</code></em> is the domain name that is to be looked
up. It can also be a dotted-decimal IPv4 address or a colon-delimited
IPv6 address, in which case <B
CLASS="COMMAND"
>host</B
> will by default
IPv6 address, in which case <span><strong class="command">host</strong></span> will by default
perform a reverse lookup for that address.
<VAR
CLASS="PARAMETER"
>server</VAR
> is an optional argument which is either
the name or IP address of the name server that <B
CLASS="COMMAND"
>host</B
>
<em class="parameter"><code>server</code></em> is an optional argument which is either
the name or IP address of the name server that <span><strong class="command">host</strong></span>
should query instead of the server or servers listed in
<TT
CLASS="FILENAME"
>/etc/resolv.conf</TT
>.</P
><P
>The <VAR
CLASS="OPTION"
>-a</VAR
> (all) option is equivalent to setting the
<VAR
CLASS="OPTION"
>-v</VAR
> option and asking <B
CLASS="COMMAND"
>host</B
> to make
a query of type ANY.</P
><P
>When the <VAR
CLASS="OPTION"
>-C</VAR
> option is used, <B
CLASS="COMMAND"
>host</B
>
<code class="filename">/etc/resolv.conf</code>.
</p>
<p>
The <code class="option">-a</code> (all) option is equivalent to setting the
<code class="option">-v</code> option and asking <span><strong class="command">host</strong></span> to make
a query of type ANY.
</p>
<p>
When the <code class="option">-C</code> option is used, <span><strong class="command">host</strong></span>
will attempt to display the SOA records for zone
<VAR
CLASS="PARAMETER"
>name</VAR
> from all the listed authoritative name
<em class="parameter"><code>name</code></em> from all the listed authoritative name
servers for that zone. The list of name servers is defined by the NS
records that are found for the zone.</P
><P
>The <VAR
CLASS="OPTION"
>-c</VAR
> option instructs to make a DNS query of class
<VAR
CLASS="PARAMETER"
>class</VAR
>. This can be used to lookup Hesiod or
Chaosnet class resource records. The default class is IN (Internet).</P
><P
>Verbose output is generated by <B
CLASS="COMMAND"
>host</B
> when the
<VAR
CLASS="OPTION"
>-d</VAR
> or <VAR
CLASS="OPTION"
>-v</VAR
> option is used. The two
records that are found for the zone.
</p>
<p>
The <code class="option">-c</code> option instructs to make a DNS query of class
<em class="parameter"><code>class</code></em>. This can be used to lookup Hesiod or
Chaosnet class resource records. The default class is IN (Internet).
</p>
<p>
Verbose output is generated by <span><strong class="command">host</strong></span> when the
<code class="option">-d</code> or <code class="option">-v</code> option is used. The two
options are equivalent. They have been provided for backwards
compatibility. In previous versions, the <VAR
CLASS="OPTION"
>-d</VAR
> option
switched on debugging traces and <VAR
CLASS="OPTION"
>-v</VAR
> enabled verbose
output.</P
><P
>List mode is selected by the <VAR
CLASS="OPTION"
>-l</VAR
> option. This makes
<B
CLASS="COMMAND"
>host</B
> perform a zone transfer for zone
<VAR
CLASS="PARAMETER"
>name</VAR
>. Transfer the zone printing out the NS, PTR
and address records (A/AAAA). If combined with <VAR
CLASS="OPTION"
>-a</VAR
>
all records will be printed. </P
><P
>The <VAR
CLASS="OPTION"
>-i</VAR
>
compatibility. In previous versions, the <code class="option">-d</code> option
switched on debugging traces and <code class="option">-v</code> enabled verbose
output.
</p>
<p>
List mode is selected by the <code class="option">-l</code> option. This makes
<span><strong class="command">host</strong></span> perform a zone transfer for zone
<em class="parameter"><code>name</code></em>. Transfer the zone printing out the NS, PTR
and address records (A/AAAA). If combined with <code class="option">-a</code>
all records will be printed.
</p>
<p>
The <code class="option">-i</code>
option specifies that reverse lookups of IPv6 addresses should
use the IP6.INT domain as defined in RFC1886.
The default is to use IP6.ARPA.</P
><P
>The <VAR
CLASS="OPTION"
>-N</VAR
> option sets the number of dots that have to be
in <VAR
CLASS="PARAMETER"
>name</VAR
> for it to be considered absolute. The
The default is to use IP6.ARPA.
</p>
<p>
The <code class="option">-N</code> option sets the number of dots that have to be
in <em class="parameter"><code>name</code></em> for it to be considered absolute. The
default value is that defined using the ndots statement in
<TT
CLASS="FILENAME"
>/etc/resolv.conf</TT
>, or 1 if no ndots statement is
<code class="filename">/etc/resolv.conf</code>, or 1 if no ndots statement is
present. Names with fewer dots are interpreted as relative names and
will be searched for in the domains listed in the <SPAN
CLASS="TYPE"
>search</SPAN
>
or <SPAN
CLASS="TYPE"
>domain</SPAN
> directive in
<TT
CLASS="FILENAME"
>/etc/resolv.conf</TT
>.</P
><P
>The number of UDP retries for a lookup can be changed with the
<VAR
CLASS="OPTION"
>-R</VAR
> option. <VAR
CLASS="PARAMETER"
>number</VAR
> indicates
how many times <B
CLASS="COMMAND"
>host</B
> will repeat a query that does
will be searched for in the domains listed in the <span class="type">search</span>
or <span class="type">domain</span> directive in
<code class="filename">/etc/resolv.conf</code>.
</p>
<p>
The number of UDP retries for a lookup can be changed with the
<code class="option">-R</code> option. <em class="parameter"><code>number</code></em> indicates
how many times <span><strong class="command">host</strong></span> will repeat a query that does
not get answered. The default number of retries is 1. If
<VAR
CLASS="PARAMETER"
>number</VAR
> is negative or zero, the number of
retries will default to 1.</P
><P
>Non-recursive queries can be made via the <VAR
CLASS="OPTION"
>-r</VAR
> option.
Setting this option clears the <SPAN
CLASS="TYPE"
>RD</SPAN
> &mdash; recursion
desired &mdash; bit in the query which <B
CLASS="COMMAND"
>host</B
> makes.
<em class="parameter"><code>number</code></em> is negative or zero, the number of
retries will default to 1.
</p>
<p>
Non-recursive queries can be made via the <code class="option">-r</code> option.
Setting this option clears the <span class="type">RD</span> &#8212; recursion
desired &#8212; bit in the query which <span><strong class="command">host</strong></span> makes.
This should mean that the name server receiving the query will not
attempt to resolve <VAR
CLASS="PARAMETER"
>name</VAR
>. The
<VAR
CLASS="OPTION"
>-r</VAR
> option enables <B
CLASS="COMMAND"
>host</B
> to mimic
attempt to resolve <em class="parameter"><code>name</code></em>. The
<code class="option">-r</code> option enables <span><strong class="command">host</strong></span> to mimic
the behaviour of a name server by making non-recursive queries and
expecting to receive answers to those queries that are usually
referrals to other name servers.</P
><P
>By default <B
CLASS="COMMAND"
>host</B
> uses UDP when making queries. The
<VAR
CLASS="OPTION"
>-T</VAR
> option makes it use a TCP connection when querying
referrals to other name servers.
</p>
<p>
By default <span><strong class="command">host</strong></span> uses UDP when making queries. The
<code class="option">-T</code> option makes it use a TCP connection when querying
the name server. TCP will be automatically selected for queries that
require it, such as zone transfer (AXFR) requests.</P
><P
>The <VAR
CLASS="OPTION"
>-4</VAR
> option forces <B
CLASS="COMMAND"
>host</B
> to only
use IPv4 query transport. The <VAR
CLASS="OPTION"
>-6</VAR
> option forces
<B
CLASS="COMMAND"
>host</B
> to only use IPv6 query transport.</P
><P
>The <VAR
CLASS="OPTION"
>-t</VAR
> option is used to select the query type.
<VAR
CLASS="PARAMETER"
>type</VAR
> can be any recognised query type: CNAME,
require it, such as zone transfer (AXFR) requests.
</p>
<p>
The <code class="option">-4</code> option forces <span><strong class="command">host</strong></span> to only
use IPv4 query transport. The <code class="option">-6</code> option forces
<span><strong class="command">host</strong></span> to only use IPv6 query transport.
</p>
<p>
The <code class="option">-t</code> option is used to select the query type.
<em class="parameter"><code>type</code></em> can be any recognised query type: CNAME,
NS, SOA, SIG, KEY, AXFR, etc. When no query type is specified,
<B
CLASS="COMMAND"
>host</B
> automatically selects an appropriate query
<span><strong class="command">host</strong></span> automatically selects an appropriate query
type. By default it looks for A records, but if the
<VAR
CLASS="OPTION"
>-C</VAR
> option was given, queries will be made for SOA
records, and if <VAR
CLASS="PARAMETER"
>name</VAR
> is a dotted-decimal IPv4
address or colon-delimited IPv6 address, <B
CLASS="COMMAND"
>host</B
> will
<code class="option">-C</code> option was given, queries will be made for SOA
records, and if <em class="parameter"><code>name</code></em> is a dotted-decimal IPv4
address or colon-delimited IPv6 address, <span><strong class="command">host</strong></span> will
query for PTR records. If a query type of IXFR is chosen the starting
serial number can be specified by appending an equal followed by the
starting serial number (e.g. -t IXFR=12345678).</P
><P
>The time to wait for a reply can be controlled through the
<VAR
CLASS="OPTION"
>-W</VAR
> and <VAR
CLASS="OPTION"
>-w</VAR
> options. The
<VAR
CLASS="OPTION"
>-W</VAR
> option makes <B
CLASS="COMMAND"
>host</B
> wait for
<VAR
CLASS="PARAMETER"
>wait</VAR
> seconds. If <VAR
CLASS="PARAMETER"
>wait</VAR
>
starting serial number (e.g. -t IXFR=12345678).
</p>
<p>
The time to wait for a reply can be controlled through the
<code class="option">-W</code> and <code class="option">-w</code> options. The
<code class="option">-W</code> option makes <span><strong class="command">host</strong></span> wait for
<em class="parameter"><code>wait</code></em> seconds. If <em class="parameter"><code>wait</code></em>
is less than one, the wait interval is set to one second. When the
<VAR
CLASS="OPTION"
>-w</VAR
> option is used, <B
CLASS="COMMAND"
>host</B
> will
<code class="option">-w</code> option is used, <span><strong class="command">host</strong></span> will
effectively wait forever for a reply. The time to wait for a response
will be set to the number of seconds given by the hardware's maximum
value for an integer quantity.</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN115"
></A
><H2
>FILES</H2
><P
><TT
CLASS="FILENAME"
>/etc/resolv.conf</TT
></P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN119"
></A
><H2
>SEE ALSO</H2
><P
><SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dig</SPAN
>(1)</SPAN
>,
<SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>named</SPAN
>(8)</SPAN
>.</P
></DIV
></BODY
></HTML
>
value for an integer quantity.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549874"></a><h2>FILES</h2>
<p>
<code class="filename">/etc/resolv.conf</code>
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549886"></a><h2>SEE ALSO</h2>
<p>
<span class="citerefentry"><span class="refentrytitle">dig</span>(1)</span>,
<span class="citerefentry"><span class="refentrytitle">named</span>(8)</span>.
</p>
</div>
</div></body>
</html>
+47 -12
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2000-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dig.h,v 1.71.2.6.2.7 2004/09/06 01:33:06 marka Exp $ */
/* $Id: dig.h,v 1.71.2.6.2.14 2006/12/07 01:26:33 marka Exp $ */
#ifndef DIG_H
#define DIG_H
@@ -35,7 +35,7 @@
#include <isc/sockaddr.h>
#include <isc/socket.h>
#define MXSERV 6
#define MXSERV 20
#define MXNAME (DNS_NAME_MAXTEXT+1)
#define MXRD 32
#define BUFSIZE 512
@@ -66,14 +66,6 @@
* in a tight loop of constant lookups. It's value is arbitrary.
*/
#define ROOTNS 1
/*
* Set the number of root servers to ask for information when running in
* trace mode.
* XXXMWS -- trace mode is currently semi-broken, and this number *MUST*
* be 1.
*/
/*
* Defaults for the sigchase suboptions. Consolidated here because
* these control the layout of dig_lookup_t (among other things).
@@ -154,7 +146,7 @@ isc_boolean_t sigchase;
char onamespace[BUFSIZE];
isc_buffer_t namebuf;
isc_buffer_t onamebuf;
isc_buffer_t sendbuf;
isc_buffer_t renderbuf;
char *sendspace;
dns_name_t *name;
isc_timer_t *timer;
@@ -181,6 +173,8 @@ isc_boolean_t sigchase;
struct dig_query {
dig_lookup_t *lookup;
isc_boolean_t waiting_connect,
pending_free,
waiting_senddone,
first_pass,
first_soa_rcvd,
second_rr_rcvd,
@@ -206,6 +200,7 @@ struct dig_query {
ISC_LINK(dig_query_t) link;
isc_sockaddr_t sockaddr;
isc_time_t time_sent;
isc_buffer_t sendbuf;
};
struct dig_server {
@@ -224,6 +219,46 @@ struct dig_message {
ISC_LINK(dig_message_t) link;
};
#endif
typedef ISC_LIST(dig_searchlist_t) dig_searchlistlist_t;
typedef ISC_LIST(dig_lookup_t) dig_lookuplist_t;
/*
* Externals from dighost.c
*/
extern dig_lookuplist_t lookup_list;
extern dig_serverlist_t server_list;
extern dig_searchlistlist_t search_list;
extern isc_boolean_t have_ipv4, have_ipv6, specified_source,
usesearch, qr;
extern in_port_t port;
extern unsigned int timeout;
extern isc_mem_t *mctx;
extern dns_messageid_t id;
extern int sendcount;
extern int ndots;
extern int lookup_counter;
extern int exitcode;
extern isc_sockaddr_t bind_address;
extern char keynametext[MXNAME];
extern char keyfile[MXNAME];
extern char keysecret[MXNAME];
#ifdef DIG_SIGCHASE
extern char trustedkey[MXNAME];
#endif
extern dns_tsigkey_t *key;
extern isc_boolean_t validated;
extern isc_taskmgr_t *taskmgr;
extern isc_task_t *global_task;
extern isc_boolean_t free_now;
extern isc_boolean_t debugging, memdebugging;
extern char *progname;
extern int tries;
extern int fatalexit;
/*
* Routines in dighost.c.
*/
+120 -124
View File
@@ -1,184 +1,178 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\"
.\" Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: nslookup.1,v 1.1.6.2 2004/08/20 02:29:39 marka Exp $
.\" $Id: nslookup.1,v 1.1.6.7 2006/06/29 13:02:30 marka Exp $
.\"
.TH "NSLOOKUP" "1" "Jun 30, 2000" "BIND9" ""
.SH NAME
.hy 0
.ad l
.\" Title: nslookup
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: Jun 30, 2000
.\" Manual: BIND9
.\" Source: BIND9
.\"
.TH "NSLOOKUP" "1" "Jun 30, 2000" "BIND9" "BIND9"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
nslookup \- query Internet name servers interactively
.SH SYNOPSIS
.sp
\fBnslookup\fR [ \fB-option\fR ] [ \fBname | -\fR ] [ \fBserver\fR ]
.SH "SYNOPSIS"
.HP 9
\fBnslookup\fR [\fB\-option\fR] [name\ |\ \-] [server]
.SH "DESCRIPTION"
.PP
\fBNslookup\fR
is a program to query Internet domain name servers. \fBNslookup\fR
has two modes: interactive and non-interactive. Interactive mode allows
the user to query name servers for information about various hosts and
domains or to print a list of hosts in a domain. Non-interactive mode is
used to print just the name and requested information for a host or
domain.
is a program to query Internet domain name servers.
\fBNslookup\fR
has two modes: interactive and non\-interactive. Interactive mode allows the user to query name servers for information about various hosts and domains or to print a list of hosts in a domain. Non\-interactive mode is used to print just the name and requested information for a host or domain.
.SH "ARGUMENTS"
.PP
Interactive mode is entered in the following cases:
.IP 1.
.TP 3n
1.
when no arguments are given (the default name server will be used)
.IP 2.
when the first argument is a hyphen (-) and the second argument is
the host name or Internet address of a name server.
.PP
Non-interactive mode is used when the name or Internet address of the
host to be looked up is given as the first argument. The optional second
argument specifies the host name or address of a name server.
.PP
Options can also be specified on the command line if they precede the
arguments and are prefixed with a hyphen. For example, to
change the default query type to host information, and the initial timeout to 10 seconds, type:
.PP
.TP 3n
2.
when the first argument is a hyphen (\-) and the second argument is the host name or Internet address of a name server.
.sp
.nf
nslookup -query=hinfo -timeout=10
.sp
.fi
.RE
.PP
Non\-interactive mode is used when the name or Internet address of the host to be looked up is given as the first argument. The optional second argument specifies the host name or address of a name server.
.PP
Options can also be specified on the command line if they precede the arguments and are prefixed with a hyphen. For example, to change the default query type to host information, and the initial timeout to 10 seconds, type:
.sp .RS 3n .nf nslookup \-query=hinfo \-timeout=10 .fi .RE
.SH "INTERACTIVE COMMANDS"
.TP
\fBhost [server]\fR
Look up information for host using the current default server or
using server, if specified. If host is an Internet address and
the query type is A or PTR, the name of the host is returned.
If host is a name and does not have a trailing period, the
search list is used to qualify the name.
To look up a host not in the current domain, append a period to
the name.
.TP
\fBserver \fIdomain\fB\fR
.TP
\fBlserver \fIdomain\fB\fR
Change the default server to \fIdomain\fR; lserver uses the initial
server to look up information about \fIdomain\fR, while server uses
the current default server. If an authoritative answer can't be
found, the names of servers that might have the answer are
returned.
.TP
.TP 3n
host [server]
Look up information for host using the current default server or using server, if specified. If host is an Internet address and the query type is A or PTR, the name of the host is returned. If host is a name and does not have a trailing period, the search list is used to qualify the name.
.sp
To look up a host not in the current domain, append a period to the name.
.TP 3n
\fBserver\fR \fIdomain\fR
.TP 3n
\fBlserver\fR \fIdomain\fR
Change the default server to
\fIdomain\fR;
\fBlserver\fR
uses the initial server to look up information about
\fIdomain\fR, while
\fBserver\fR
uses the current default server. If an authoritative answer can't be found, the names of servers that might have the answer are returned.
.TP 3n
\fBroot\fR
not implemented
.TP
.TP 3n
\fBfinger\fR
not implemented
.TP
.TP 3n
\fBls\fR
not implemented
.TP
.TP 3n
\fBview\fR
not implemented
.TP
.TP 3n
\fBhelp\fR
not implemented
.TP
.TP 3n
\fB?\fR
not implemented
.TP
.TP 3n
\fBexit\fR
Exits the program.
.TP
\fBset \fIkeyword[=value]\fB\fR
This command is used to change state information that affects
the lookups. Valid keywords are:
.RS
.TP
.TP 3n
\fBset\fR \fIkeyword\fR\fI[=value]\fR
This command is used to change state information that affects the lookups. Valid keywords are:
.RS 3n
.TP 3n
\fBall\fR
Prints the current values of the frequently used
options to \fBset\fR. Information about the current default
server and host is also printed.
.TP
\fBclass=\fIvalue\fB\fR
Prints the current values of the frequently used options to
\fBset\fR. Information about the current default server and host is also printed.
.TP 3n
\fBclass=\fR\fIvalue\fR
Change the query class to one of:
.RS
.TP
.RS 3n
.TP 3n
\fBIN\fR
the Internet class
.TP
.TP 3n
\fBCH\fR
the Chaos class
.TP
.TP 3n
\fBHS\fR
the Hesiod class
.TP
.TP 3n
\fBANY\fR
wildcard
.RE
.PP
.IP "" 3n
The class specifies the protocol group of the information.
.sp
(Default = IN; abbreviation = cl)
.TP
\fB\fI[no]\fBdebug\fR
Turn debugging mode on. A lot more information is
printed about the packet sent to the server and the
resulting answer.
(Default = nodebug; abbreviation = [no]deb)
.TP
\fB\fI[no]\fBd2\fR
Turn debugging mode on. A lot more information is
printed about the packet sent to the server and the
resulting answer.
.TP 3n
\fB\fI[no]\fR\fR\fBdebug\fR
Turn debugging mode on. A lot more information is printed about the packet sent to the server and the resulting answer.
.sp
(Default = nodebug; abbreviation =
[no]deb)
.TP 3n
\fB\fI[no]\fR\fR\fBd2\fR
Turn debugging mode on. A lot more information is printed about the packet sent to the server and the resulting answer.
.sp
(Default = nod2)
.TP
\fBdomain=\fIname\fB\fR
Sets the search list to \fIname\fR.
.TP
\fB\fI[no]\fBsearch\fR
If the lookup request contains at least one period but
doesn't end with a trailing period, append the domain
names in the domain search list to the request until an
answer is received.
.TP 3n
\fBdomain=\fR\fIname\fR
Sets the search list to
\fIname\fR.
.TP 3n
\fB\fI[no]\fR\fR\fBsearch\fR
If the lookup request contains at least one period but doesn't end with a trailing period, append the domain names in the domain search list to the request until an answer is received.
.sp
(Default = search)
.TP
\fBport=\fIvalue\fB\fR
Change the default TCP/UDP name server port to \fIvalue\fR.
.TP 3n
\fBport=\fR\fIvalue\fR
Change the default TCP/UDP name server port to
\fIvalue\fR.
.sp
(Default = 53; abbreviation = po)
.TP
\fBquerytype=\fIvalue\fB\fR
.TP
\fBtype=\fIvalue\fB\fR
Change the top of the information query.
.TP 3n
\fBquerytype=\fR\fIvalue\fR
.TP 3n
\fBtype=\fR\fIvalue\fR
Change the type of the information query.
.sp
(Default = A; abbreviations = q, ty)
.TP
\fB\fI[no]\fBrecurse\fR
Tell the name server to query other servers if it does not have the
information.
.TP 3n
\fB\fI[no]\fR\fR\fBrecurse\fR
Tell the name server to query other servers if it does not have the information.
.sp
(Default = recurse; abbreviation = [no]rec)
.TP
\fBretry=\fInumber\fB\fR
.TP 3n
\fBretry=\fR\fInumber\fR
Set the number of retries to number.
.TP
\fBtimeout=\fInumber\fB\fR
Change the initial timeout interval for waiting for a
reply to number seconds.
.TP
\fB\fI[no]\fBvc\fR
.TP 3n
\fBtimeout=\fR\fInumber\fR
Change the initial timeout interval for waiting for a reply to number seconds.
.TP 3n
\fB\fI[no]\fR\fR\fBvc\fR
Always use a virtual circuit when sending requests to the server.
.sp
(Default = novc)
.RE
.IP "" 3n
.SH "FILES"
.PP
\fI/etc/resolv.conf\fR
@@ -190,3 +184,5 @@ Always use a virtual circuit when sending requests to the server.
.SH "AUTHOR"
.PP
Andrew Cherenson
.SH "COPYRIGHT"
Copyright \(co 2004\-2006 Internet Systems Consortium, Inc. ("ISC")
+3 -15
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2000-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: nslookup.c,v 1.90.2.4.2.8 2004/09/06 01:33:05 marka Exp $ */
/* $Id: nslookup.c,v 1.90.2.4.2.12 2006/06/09 23:50:53 marka Exp $ */
#include <config.h>
@@ -44,19 +44,6 @@
#include <dig/dig.h>
extern ISC_LIST(dig_lookup_t) lookup_list;
extern dig_serverlist_t server_list;
extern ISC_LIST(dig_searchlist_t) search_list;
extern isc_boolean_t usesearch, debugging;
extern in_port_t port;
extern unsigned int timeout;
extern isc_mem_t *mctx;
extern int tries;
extern int lookup_counter;
extern isc_task_t *global_task;
extern char *progname;
static isc_boolean_t short_form = ISC_TRUE,
tcpmode = ISC_FALSE,
identify = ISC_FALSE, stats = ISC_TRUE,
@@ -721,6 +708,7 @@ get_next_command(void) {
if (buf == NULL)
fatal("memory allocation failure");
fputs("> ", stderr);
fflush(stderr);
isc_app_block();
ptr = fgets(buf, COMMSIZE, stdin);
isc_app_unblock();
+27 -16
View File
@@ -1,6 +1,8 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.0//EN"
"http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd"
[<!ENTITY mdash "&#8212;">]>
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
@@ -15,7 +17,7 @@
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: nslookup.docbook,v 1.3.6.3 2004/08/30 00:50:11 marka Exp $ -->
<!-- $Id: nslookup.docbook,v 1.3.6.7 2006/01/06 00:01:42 marka Exp $ -->
<!--
- Copyright (c) 1985, 1989
@@ -62,6 +64,15 @@
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<docinfo>
<copyright>
<year>2004</year>
<year>2005</year>
<year>2006</year>
<holder>Internet Systems Consortium, Inc. ("ISC")</holder>
</copyright>
</docinfo>
<refnamediv>
<refname>nslookup</refname>
<refpurpose>query Internet name servers interactively</refpurpose>
@@ -71,8 +82,8 @@
<cmdsynopsis>
<command>nslookup</command>
<arg><option>-option</option></arg>
<arg choice=opt>name | -</arg>
<arg choice=opt>server</arg>
<arg choice="opt">name | -</arg>
<arg choice="opt">server</arg>
</cmdsynopsis>
</refsynopsisdiv>
@@ -93,19 +104,19 @@ domain.
<title>ARGUMENTS</title>
<para>
Interactive mode is entered in the following cases:
<OrderedList Numeration=Loweralpha>
<Listitem>
<orderedlist numeration="loweralpha">
<listitem>
<para>
when no arguments are given (the default name server will be used)
</para>
</Listitem>
<Listitem>
</listitem>
<listitem>
<para>
when the first argument is a hyphen (-) and the second argument is
the host name or Internet address of a name server.
</para>
</Listitem>
</OrderedList>
</listitem>
</orderedlist>
</para>
<para>
@@ -118,11 +129,11 @@ argument specifies the host name or address of a name server.
Options can also be specified on the command line if they precede the
arguments and are prefixed with a hyphen. For example, to
change the default query type to host information, and the initial timeout to 10 seconds, type:
<InformalExample>
<PROGRAMLISTING>
<informalexample>
<programlisting>
nslookup -query=hinfo -timeout=10
</PROGRAMLISTING>
</InformalExample>
</programlisting>
</informalexample>
</para>
</refsect1>
@@ -253,7 +264,7 @@ the lookups. Valid keywords are:
<varlistentry><term><constant>type=</constant><replaceable>value</replaceable></term>
<listitem><para>
Change the top of the information query.
Change the type of the information query.
</para><para>
(Default = A; abbreviations = q, ty)
</para></listitem></varlistentry>
+229 -582
View File
@@ -1,617 +1,264 @@
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
-
- Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: nslookup.html,v 1.1.6.3 2004/08/22 23:38:58 marka Exp $ -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML
><HEAD
><TITLE
>nslookup</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"></HEAD
><BODY
CLASS="REFENTRY"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><H1
><A
NAME="AEN1"
></A
>nslookup</H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN8"
></A
><H2
>Name</H2
>nslookup&nbsp;--&nbsp;query Internet name servers interactively</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN11"
></A
><H2
>Synopsis</H2
><P
><B
CLASS="COMMAND"
>nslookup</B
> [<VAR
CLASS="OPTION"
>-option</VAR
>] [name | -] [server]</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN18"
></A
><H2
>DESCRIPTION</H2
><P
><B
CLASS="COMMAND"
>Nslookup</B
>
is a program to query Internet domain name servers. <B
CLASS="COMMAND"
>Nslookup</B
>
<!-- $Id: nslookup.html,v 1.1.6.12 2006/06/29 13:02:30 marka Exp $ -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>nslookup</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.70.1">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
<a name="id2482694"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2>Name</h2>
<p>nslookup &#8212; query Internet name servers interactively</p>
</div>
<div class="refsynopsisdiv">
<h2>Synopsis</h2>
<div class="cmdsynopsis"><p><code class="command">nslookup</code> [<code class="option">-option</code>] [name | -] [server]</p></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549404"></a><h2>DESCRIPTION</h2>
<p>
<span><strong class="command">Nslookup</strong></span>
is a program to query Internet domain name servers. <span><strong class="command">Nslookup</strong></span>
has two modes: interactive and non-interactive. Interactive mode allows
the user to query name servers for information about various hosts and
domains or to print a list of hosts in a domain. Non-interactive mode is
used to print just the name and requested information for a host or
domain.</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN23"
></A
><H2
>ARGUMENTS</H2
><P
>Interactive mode is entered in the following cases:
<P
></P
><OL
TYPE="a"
><LI
><P
>when no arguments are given (the default name server will be used)</P
></LI
><LI
><P
>when the first argument is a hyphen (-) and the second argument is
the host name or Internet address of a name server.</P
></LI
></OL
></P
><P
>Non-interactive mode is used when the name or Internet address of the
domain.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549421"></a><h2>ARGUMENTS</h2>
<p>
Interactive mode is entered in the following cases:
</p>
<div class="orderedlist"><ol type="a">
<li><p>
when no arguments are given (the default name server will be used)
</p></li>
<li><p>
when the first argument is a hyphen (-) and the second argument is
the host name or Internet address of a name server.
</p></li>
</ol></div>
<p>
</p>
<p>
Non-interactive mode is used when the name or Internet address of the
host to be looked up is given as the first argument. The optional second
argument specifies the host name or address of a name server.</P
><P
>Options can also be specified on the command line if they precede the
argument specifies the host name or address of a name server.
</p>
<p>
Options can also be specified on the command line if they precede the
arguments and are prefixed with a hyphen. For example, to
change the default query type to host information, and the initial timeout to 10 seconds, type:
<DIV
CLASS="INFORMALEXAMPLE"
><P
></P
><A
NAME="AEN33"
></A
><PRE
CLASS="PROGRAMLISTING"
>nslookup -query=hinfo -timeout=10</PRE
><P
></P
></DIV
></P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN35"
></A
><H2
>INTERACTIVE COMMANDS</H2
><P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
>host [<SPAN
CLASS="OPTIONAL"
>server</SPAN
>]</DT
><DD
><P
>Look up information for host using the current default server or
</p>
<div class="informalexample"><pre class="programlisting">
nslookup -query=hinfo -timeout=10
</pre></div>
<p>
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549464"></a><h2>INTERACTIVE COMMANDS</h2>
<div class="variablelist"><dl>
<dt><span class="term">host [<span class="optional">server</span>]</span></dt>
<dd>
<p>
Look up information for host using the current default server or
using server, if specified. If host is an Internet address and
the query type is A or PTR, the name of the host is returned.
If host is a name and does not have a trailing period, the
search list is used to qualify the name.</P
><P
>To look up a host not in the current domain, append a period to
the name.</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>server</CODE
> <VAR
CLASS="REPLACEABLE"
>domain</VAR
></DT
><DD
><P
></P
></DD
><DT
><CODE
CLASS="CONSTANT"
>lserver</CODE
> <VAR
CLASS="REPLACEABLE"
>domain</VAR
></DT
><DD
><P
>Change the default server to <VAR
CLASS="REPLACEABLE"
>domain</VAR
>; <CODE
CLASS="CONSTANT"
>lserver</CODE
> uses the initial
server to look up information about <VAR
CLASS="REPLACEABLE"
>domain</VAR
>, while <CODE
CLASS="CONSTANT"
>server</CODE
> uses
search list is used to qualify the name.
</p>
<p>
To look up a host not in the current domain, append a period to
the name.
</p>
</dd>
<dt><span class="term"><code class="constant">server</code> <em class="replaceable"><code>domain</code></em></span></dt>
<dd><p></p></dd>
<dt><span class="term"><code class="constant">lserver</code> <em class="replaceable"><code>domain</code></em></span></dt>
<dd><p>
Change the default server to <em class="replaceable"><code>domain</code></em>; <code class="constant">lserver</code> uses the initial
server to look up information about <em class="replaceable"><code>domain</code></em>, while <code class="constant">server</code> uses
the current default server. If an authoritative answer can't be
found, the names of servers that might have the answer are
returned.</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>root</CODE
></DT
><DD
><P
>not implemented</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>finger</CODE
></DT
><DD
><P
>not implemented</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>ls</CODE
></DT
><DD
><P
>not implemented</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>view</CODE
></DT
><DD
><P
>not implemented</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>help</CODE
></DT
><DD
><P
>not implemented</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>?</CODE
></DT
><DD
><P
>not implemented</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>exit</CODE
></DT
><DD
><P
>Exits the program.</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>set</CODE
> <VAR
CLASS="REPLACEABLE"
>keyword[<SPAN
CLASS="OPTIONAL"
>=value</SPAN
>]</VAR
></DT
><DD
><P
>This command is used to change state information that affects
returned.
</p></dd>
<dt><span class="term"><code class="constant">root</code></span></dt>
<dd><p>not implemented</p></dd>
<dt><span class="term"><code class="constant">finger</code></span></dt>
<dd><p>not implemented</p></dd>
<dt><span class="term"><code class="constant">ls</code></span></dt>
<dd><p>not implemented</p></dd>
<dt><span class="term"><code class="constant">view</code></span></dt>
<dd><p>not implemented</p></dd>
<dt><span class="term"><code class="constant">help</code></span></dt>
<dd><p>not implemented</p></dd>
<dt><span class="term"><code class="constant">?</code></span></dt>
<dd><p>not implemented</p></dd>
<dt><span class="term"><code class="constant">exit</code></span></dt>
<dd><p>Exits the program.</p></dd>
<dt><span class="term"><code class="constant">set</code> <em class="replaceable"><code>keyword[<span class="optional">=value</span>]</code></em></span></dt>
<dd>
<p>This command is used to change state information that affects
the lookups. Valid keywords are:
<P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
><CODE
CLASS="CONSTANT"
>all</CODE
></DT
><DD
><P
>Prints the current values of the frequently used
options to <B
CLASS="COMMAND"
>set</B
>. Information about the current default
</p>
<div class="variablelist"><dl>
<dt><span class="term"><code class="constant">all</code></span></dt>
<dd><p>Prints the current values of the frequently used
options to <span><strong class="command">set</strong></span>. Information about the current default
server and host is also printed.
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>class=</CODE
><VAR
CLASS="REPLACEABLE"
>value</VAR
></DT
><DD
><P
> Change the query class to one of:
<P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
><CODE
CLASS="CONSTANT"
>IN</CODE
></DT
><DD
><P
>the Internet class</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>CH</CODE
></DT
><DD
><P
>the Chaos class</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>HS</CODE
></DT
><DD
><P
>the Hesiod class</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>ANY</CODE
></DT
><DD
><P
>wildcard</P
></DD
></DL
></DIV
>
</p></dd>
<dt><span class="term"><code class="constant">class=</code><em class="replaceable"><code>value</code></em></span></dt>
<dd>
<p>
Change the query class to one of:
</p>
<div class="variablelist"><dl>
<dt><span class="term"><code class="constant">IN</code></span></dt>
<dd><p>the Internet class</p></dd>
<dt><span class="term"><code class="constant">CH</code></span></dt>
<dd><p>the Chaos class</p></dd>
<dt><span class="term"><code class="constant">HS</code></span></dt>
<dd><p>the Hesiod class</p></dd>
<dt><span class="term"><code class="constant">ANY</code></span></dt>
<dd><p>wildcard</p></dd>
</dl></div>
<p>
The class specifies the protocol group of the information.
</P
><P
> (Default = IN; abbreviation = cl)
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
><VAR
CLASS="REPLACEABLE"
>[<SPAN
CLASS="OPTIONAL"
>no</SPAN
>]</VAR
>debug</CODE
></DT
><DD
><P
> Turn debugging mode on. A lot more information is
</p>
<p>
(Default = IN; abbreviation = cl)
</p>
</dd>
<dt><span class="term"><code class="constant"><em class="replaceable"><code>[<span class="optional">no</span>]</code></em>debug</code></span></dt>
<dd>
<p>
Turn debugging mode on. A lot more information is
printed about the packet sent to the server and the
resulting answer.
</P
><P
> (Default = nodebug; abbreviation = [<SPAN
CLASS="OPTIONAL"
>no</SPAN
>]deb)
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
><VAR
CLASS="REPLACEABLE"
>[<SPAN
CLASS="OPTIONAL"
>no</SPAN
>]</VAR
>d2</CODE
></DT
><DD
><P
> Turn debugging mode on. A lot more information is
</p>
<p>
(Default = nodebug; abbreviation = [<span class="optional">no</span>]deb)
</p>
</dd>
<dt><span class="term"><code class="constant"><em class="replaceable"><code>[<span class="optional">no</span>]</code></em>d2</code></span></dt>
<dd>
<p>
Turn debugging mode on. A lot more information is
printed about the packet sent to the server and the
resulting answer.
</P
><P
> (Default = nod2)
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>domain=</CODE
><VAR
CLASS="REPLACEABLE"
>name</VAR
></DT
><DD
><P
> Sets the search list to <VAR
CLASS="REPLACEABLE"
>name</VAR
>.
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
><VAR
CLASS="REPLACEABLE"
>[<SPAN
CLASS="OPTIONAL"
>no</SPAN
>]</VAR
>search</CODE
></DT
><DD
><P
> If the lookup request contains at least one period but
</p>
<p>
(Default = nod2)
</p>
</dd>
<dt><span class="term"><code class="constant">domain=</code><em class="replaceable"><code>name</code></em></span></dt>
<dd><p>
Sets the search list to <em class="replaceable"><code>name</code></em>.
</p></dd>
<dt><span class="term"><code class="constant"><em class="replaceable"><code>[<span class="optional">no</span>]</code></em>search</code></span></dt>
<dd>
<p>
If the lookup request contains at least one period but
doesn't end with a trailing period, append the domain
names in the domain search list to the request until an
answer is received.
</P
><P
> (Default = search)
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>port=</CODE
><VAR
CLASS="REPLACEABLE"
>value</VAR
></DT
><DD
><P
> Change the default TCP/UDP name server port to <VAR
CLASS="REPLACEABLE"
>value</VAR
>.
</P
><P
> (Default = 53; abbreviation = po)
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>querytype=</CODE
><VAR
CLASS="REPLACEABLE"
>value</VAR
></DT
><DD
><P
></P
></DD
><DT
><CODE
CLASS="CONSTANT"
>type=</CODE
><VAR
CLASS="REPLACEABLE"
>value</VAR
></DT
><DD
><P
> Change the top of the information query.
</P
><P
> (Default = A; abbreviations = q, ty)
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
><VAR
CLASS="REPLACEABLE"
>[<SPAN
CLASS="OPTIONAL"
>no</SPAN
>]</VAR
>recurse</CODE
></DT
><DD
><P
> Tell the name server to query other servers if it does not have the
</p>
<p>
(Default = search)
</p>
</dd>
<dt><span class="term"><code class="constant">port=</code><em class="replaceable"><code>value</code></em></span></dt>
<dd>
<p>
Change the default TCP/UDP name server port to <em class="replaceable"><code>value</code></em>.
</p>
<p>
(Default = 53; abbreviation = po)
</p>
</dd>
<dt><span class="term"><code class="constant">querytype=</code><em class="replaceable"><code>value</code></em></span></dt>
<dd><p></p></dd>
<dt><span class="term"><code class="constant">type=</code><em class="replaceable"><code>value</code></em></span></dt>
<dd>
<p>
Change the type of the information query.
</p>
<p>
(Default = A; abbreviations = q, ty)
</p>
</dd>
<dt><span class="term"><code class="constant"><em class="replaceable"><code>[<span class="optional">no</span>]</code></em>recurse</code></span></dt>
<dd>
<p>
Tell the name server to query other servers if it does not have the
information.
</P
><P
> (Default = recurse; abbreviation = [no]rec)
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>retry=</CODE
><VAR
CLASS="REPLACEABLE"
>number</VAR
></DT
><DD
><P
> Set the number of retries to number.
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
>timeout=</CODE
><VAR
CLASS="REPLACEABLE"
>number</VAR
></DT
><DD
><P
> Change the initial timeout interval for waiting for a
</p>
<p>
(Default = recurse; abbreviation = [no]rec)
</p>
</dd>
<dt><span class="term"><code class="constant">retry=</code><em class="replaceable"><code>number</code></em></span></dt>
<dd><p>
Set the number of retries to number.
</p></dd>
<dt><span class="term"><code class="constant">timeout=</code><em class="replaceable"><code>number</code></em></span></dt>
<dd><p>
Change the initial timeout interval for waiting for a
reply to number seconds.
</P
></DD
><DT
><CODE
CLASS="CONSTANT"
><VAR
CLASS="REPLACEABLE"
>[<SPAN
CLASS="OPTIONAL"
>no</SPAN
>]</VAR
>vc</CODE
></DT
><DD
><P
> Always use a virtual circuit when sending requests to the server.
</P
><P
> (Default = novc)
</P
></DD
></DL
></DIV
></P
></DD
></DL
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN218"
></A
><H2
>FILES</H2
><P
><TT
CLASS="FILENAME"
>/etc/resolv.conf</TT
></P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN222"
></A
><H2
>SEE ALSO</H2
><P
><SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dig</SPAN
>(1)</SPAN
>,
<SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>host</SPAN
>(1)</SPAN
>,
<SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>named</SPAN
>(8)</SPAN
>.</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN234"
></A
><H2
>Author</H2
><P
>Andrew Cherenson</P
></DIV
></BODY
></HTML
>
</p></dd>
<dt><span class="term"><code class="constant"><em class="replaceable"><code>[<span class="optional">no</span>]</code></em>vc</code></span></dt>
<dd>
<p>
Always use a virtual circuit when sending requests to the server.
</p>
<p>
(Default = novc)
</p>
</dd>
</dl></div>
<p>
</p>
</dd>
</dl></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549990"></a><h2>FILES</h2>
<p>
<code class="filename">/etc/resolv.conf</code>
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2550003"></a><h2>SEE ALSO</h2>
<p>
<span class="citerefentry"><span class="refentrytitle">dig</span>(1)</span>,
<span class="citerefentry"><span class="refentrytitle">host</span>(1)</span>,
<span class="citerefentry"><span class="refentrytitle">named</span>(8)</span>.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2550038"></a><h2>Author</h2>
<p>
Andrew Cherenson
</p>
</div>
</div></body>
</html>
+4 -3
View File
@@ -1,4 +1,4 @@
# Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
# Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
# Copyright (C) 2000-2002 Internet Software Consortium.
#
# Permission to use, copy, modify, and distribute this software for any
@@ -13,7 +13,7 @@
# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
# PERFORMANCE OF THIS SOFTWARE.
# $Id: Makefile.in,v 1.19.12.9 2004/07/20 07:01:48 marka Exp $
# $Id: Makefile.in,v 1.19.12.12 2005/05/02 00:25:54 marka Exp $
srcdir = @srcdir@
VPATH = @srcdir@
@@ -58,7 +58,8 @@ dnssec-keygen@EXEEXT@: dnssec-keygen.@O@ ${OBJS} ${DEPLIBS}
dnssec-keygen.@O@ ${OBJS} ${LIBS}
dnssec-signzone.@O@: dnssec-signzone.c
${LIBTOOL_MODE_COMPILE} ${PURIFY} ${CC} ${ALL_CFLAGS} -c $<
${LIBTOOL_MODE_COMPILE} ${CC} ${ALL_CFLAGS} -DVERSION=\"${VERSION}\" \
-c ${srcdir}/dnssec-signzone.c
dnssec-signzone@EXEEXT@: dnssec-signzone.@O@ ${OBJS} ${DEPLIBS}
${LIBTOOL_MODE_LINK} ${PURIFY} ${CC} ${CFLAGS} ${LDFLAGS} -o $@ \
+127 -130
View File
@@ -1,174 +1,171 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2003 Internet Software Consortium.
.\"
.\" Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2003 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: dnssec-keygen.8,v 1.19.12.5 2004/06/11 02:32:45 marka Exp $
.\" $Id: dnssec-keygen.8,v 1.19.12.10 2006/06/29 13:02:30 marka Exp $
.\"
.TH "DNSSEC-KEYGEN" "8" "June 30, 2000" "BIND9" ""
.SH NAME
dnssec-keygen \- DNSSEC key generation tool
.SH SYNOPSIS
.sp
\fBdnssec-keygen\fR \fB-a \fIalgorithm\fB\fR \fB-b \fIkeysize\fB\fR \fB-n \fInametype\fB\fR [ \fB-c \fIclass\fB\fR ] [ \fB-e\fR ] [ \fB-f \fIflag\fB\fR ] [ \fB-g \fIgenerator\fB\fR ] [ \fB-h\fR ] [ \fB-k\fR ] [ \fB-p \fIprotocol\fB\fR ] [ \fB-r \fIrandomdev\fB\fR ] [ \fB-s \fIstrength\fB\fR ] [ \fB-t \fItype\fB\fR ] [ \fB-v \fIlevel\fB\fR ] \fBname\fR
.hy 0
.ad l
.\" Title: dnssec\-keygen
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: June 30, 2000
.\" Manual: BIND9
.\" Source: BIND9
.\"
.TH "DNSSEC\-KEYGEN" "8" "June 30, 2000" "BIND9" "BIND9"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
dnssec\-keygen \- DNSSEC key generation tool
.SH "SYNOPSIS"
.HP 14
\fBdnssec\-keygen\fR {\-a\ \fIalgorithm\fR} {\-b\ \fIkeysize\fR} {\-n\ \fInametype\fR} [\fB\-c\ \fR\fB\fIclass\fR\fR] [\fB\-e\fR] [\fB\-f\ \fR\fB\fIflag\fR\fR] [\fB\-g\ \fR\fB\fIgenerator\fR\fR] [\fB\-h\fR] [\fB\-k\fR] [\fB\-p\ \fR\fB\fIprotocol\fR\fR] [\fB\-r\ \fR\fB\fIrandomdev\fR\fR] [\fB\-s\ \fR\fB\fIstrength\fR\fR] [\fB\-t\ \fR\fB\fItype\fR\fR] [\fB\-v\ \fR\fB\fIlevel\fR\fR] {name}
.SH "DESCRIPTION"
.PP
\fBdnssec-keygen\fR generates keys for DNSSEC
(Secure DNS), as defined in RFC 2535 and RFC <TBA\\>. It can also generate
keys for use with TSIG (Transaction Signatures), as
defined in RFC 2845.
\fBdnssec\-keygen\fR
generates keys for DNSSEC (Secure DNS), as defined in RFC 2535 and RFC <TBA\\>. It can also generate keys for use with TSIG (Transaction Signatures), as defined in RFC 2845.
.SH "OPTIONS"
.TP
\fB-a \fIalgorithm\fB\fR
.TP 3n
\-a \fIalgorithm\fR
Selects the cryptographic algorithm. The value of
\fBalgorithm\fR must be one of RSAMD5 (RSA) or RSASHA1,
DSA, DH (Diffie Hellman), or HMAC-MD5. These values
are case insensitive.
Note 1: that for DNSSEC, RSASHA1 is a mandatory to implement algorithm,
and DSA is recommended. For TSIG, HMAC-MD5 is mandatory.
Note 2: HMAC-MD5 and DH automatically set the -k flag.
.TP
\fB-b \fIkeysize\fB\fR
Specifies the number of bits in the key. The choice of key
size depends on the algorithm used. RSAMD5 / RSASHA1 keys must be between
512 and 2048 bits. Diffie Hellman keys must be between
128 and 4096 bits. DSA keys must be between 512 and 1024
bits and an exact multiple of 64. HMAC-MD5 keys must be
between 1 and 512 bits.
.TP
\fB-n \fInametype\fB\fR
\fBalgorithm\fR
must be one of RSAMD5 (RSA) or RSASHA1, DSA, DH (Diffie Hellman), or HMAC\-MD5. These values are case insensitive.
.sp
Note 1: that for DNSSEC, RSASHA1 is a mandatory to implement algorithm, and DSA is recommended. For TSIG, HMAC\-MD5 is mandatory.
.sp
Note 2: HMAC\-MD5 and DH automatically set the \-k flag.
.TP 3n
\-b \fIkeysize\fR
Specifies the number of bits in the key. The choice of key size depends on the algorithm used. RSAMD5 / RSASHA1 keys must be between 512 and 2048 bits. Diffie Hellman keys must be between 128 and 4096 bits. DSA keys must be between 512 and 1024 bits and an exact multiple of 64. HMAC\-MD5 keys must be between 1 and 512 bits.
.TP 3n
\-n \fInametype\fR
Specifies the owner type of the key. The value of
\fBnametype\fR must either be ZONE (for a DNSSEC
zone key (KEY/DNSKEY)), HOST or ENTITY (for a key associated with a host (KEY)),
USER (for a key associated with a user(KEY)) or OTHER (DNSKEY). These values are
case insensitive.
.TP
\fB-c \fIclass\fB\fR
Indicates that the DNS record containing the key should have
the specified class. If not specified, class IN is used.
.TP
\fB-e\fR
\fBnametype\fR
must either be ZONE (for a DNSSEC zone key (KEY/DNSKEY)), HOST or ENTITY (for a key associated with a host (KEY)), USER (for a key associated with a user(KEY)) or OTHER (DNSKEY). These values are case insensitive.
.TP 3n
\-c \fIclass\fR
Indicates that the DNS record containing the key should have the specified class. If not specified, class IN is used.
.TP 3n
\-e
If generating an RSAMD5/RSASHA1 key, use a large exponent.
.TP
\fB-f \fIflag\fB\fR
Set the specified flag in the flag field of the KEY/DNSKEY record.
The only recognized flag is KSK (Key Signing Key) DNSKEY.
.TP
\fB-g \fIgenerator\fB\fR
If generating a Diffie Hellman key, use this generator.
Allowed values are 2 and 5. If no generator
is specified, a known prime from RFC 2539 will be used
if possible; otherwise the default is 2.
.TP
\fB-h\fR
.TP 3n
\-f \fIflag\fR
Set the specified flag in the flag field of the KEY/DNSKEY record. The only recognized flag is KSK (Key Signing Key) DNSKEY.
.TP 3n
\-g \fIgenerator\fR
If generating a Diffie Hellman key, use this generator. Allowed values are 2 and 5. If no generator is specified, a known prime from RFC 2539 will be used if possible; otherwise the default is 2.
.TP 3n
\-h
Prints a short summary of the options and arguments to
\fBdnssec-keygen\fR.
.TP
\fB-k\fR
\fBdnssec\-keygen\fR.
.TP 3n
\-k
Generate KEY records rather than DNSKEY records.
.TP
\fB-p \fIprotocol\fB\fR
Sets the protocol value for the generated key. The protocol
is a number between 0 and 255. The default is 3 (DNSSEC).
Other possible values for this argument are listed in
RFC 2535 and its successors.
.TP
\fB-r \fIrandomdev\fB\fR
Specifies the source of randomness. If the operating
system does not provide a \fI/dev/random\fR
or equivalent device, the default source of randomness
is keyboard input. \fIrandomdev\fR specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
\fIkeyboard\fR indicates that keyboard
input should be used.
.TP
\fB-s \fIstrength\fB\fR
Specifies the strength value of the key. The strength is
a number between 0 and 15, and currently has no defined
purpose in DNSSEC.
.TP
\fB-t \fItype\fB\fR
Indicates the use of the key. \fBtype\fR must be
one of AUTHCONF, NOAUTHCONF, NOAUTH, or NOCONF. The default
is AUTHCONF. AUTH refers to the ability to authenticate
data, and CONF the ability to encrypt data.
.TP
\fB-v \fIlevel\fB\fR
.TP 3n
\-p \fIprotocol\fR
Sets the protocol value for the generated key. The protocol is a number between 0 and 255. The default is 3 (DNSSEC). Other possible values for this argument are listed in RFC 2535 and its successors.
.TP 3n
\-r \fIrandomdev\fR
Specifies the source of randomness. If the operating system does not provide a
\fI/dev/random\fR
or equivalent device, the default source of randomness is keyboard input.
\fIrandomdev\fR
specifies the name of a character device or file containing random data to be used instead of the default. The special value
\fIkeyboard\fR
indicates that keyboard input should be used.
.TP 3n
\-s \fIstrength\fR
Specifies the strength value of the key. The strength is a number between 0 and 15, and currently has no defined purpose in DNSSEC.
.TP 3n
\-t \fItype\fR
Indicates the use of the key.
\fBtype\fR
must be one of AUTHCONF, NOAUTHCONF, NOAUTH, or NOCONF. The default is AUTHCONF. AUTH refers to the ability to authenticate data, and CONF the ability to encrypt data.
.TP 3n
\-v \fIlevel\fR
Sets the debugging level.
.SH "GENERATED KEYS"
.PP
When \fBdnssec-keygen\fR completes successfully,
it prints a string of the form \fIKnnnn.+aaa+iiiii\fR
to the standard output. This is an identification string for
the key it has generated. These strings can be used as arguments
to \fBdnssec-makekeyset\fR.
.TP 0.2i
When
\fBdnssec\-keygen\fR
completes successfully, it prints a string of the form
\fIKnnnn.+aaa+iiiii\fR
to the standard output. This is an identification string for the key it has generated.
.TP 3n
\(bu
\fInnnn\fR is the key name.
.TP 0.2i
\fInnnn\fR
is the key name.
.TP 3n
\(bu
\fIaaa\fR is the numeric representation of the
algorithm.
.TP 0.2i
\fIaaa\fR
is the numeric representation of the algorithm.
.TP 3n
\(bu
\fIiiiii\fR is the key identifier (or footprint).
\fIiiiii\fR
is the key identifier (or footprint).
.sp
.RE
.PP
\fBdnssec-keygen\fR creates two file, with names based
on the printed string. \fIKnnnn.+aaa+iiiii.key\fR
\fBdnssec\-keygen\fR
creates two file, with names based on the printed string.
\fIKnnnn.+aaa+iiiii.key\fR
contains the public key, and
\fIKnnnn.+aaa+iiiii.private\fR contains the private
key.
\fIKnnnn.+aaa+iiiii.private\fR
contains the private key.
.PP
The
\fI.key\fR
file contains a DNS KEY record that can be inserted into a zone file (directly or with a $INCLUDE statement).
.PP
The \fI.key\fR file contains a DNS KEY record that
can be inserted into a zone file (directly or with a $INCLUDE
statement).
.PP
.PP
The \fI.private\fR file contains algorithm specific
fields. For obvious security reasons, this file does not have
general read permission.
.PP
.PP
Both \fI.key\fR and \fI.private\fR
files are generated for symmetric encryption algorithm such as
HMAC-MD5, even though the public and private key are equivalent.
The
\fI.private\fR
file contains algorithm specific fields. For obvious security reasons, this file does not have general read permission.
.PP
Both
\fI.key\fR
and
\fI.private\fR
files are generated for symmetric encryption algorithm such as HMAC\-MD5, even though the public and private key are equivalent.
.SH "EXAMPLE"
.PP
To generate a 768-bit DSA key for the domain
\fBexample.com\fR, the following command would be
issued:
To generate a 768\-bit DSA key for the domain
\fBexample.com\fR, the following command would be issued:
.PP
\fBdnssec-keygen -a DSA -b 768 -n ZONE example.com\fR
\fBdnssec\-keygen \-a DSA \-b 768 \-n ZONE example.com\fR
.PP
The command would print a string of the form:
.PP
\fBKexample.com.+003+26160\fR
.PP
In this example, \fBdnssec-keygen\fR creates
the files \fIKexample.com.+003+26160.key\fR and
In this example,
\fBdnssec\-keygen\fR
creates the files
\fIKexample.com.+003+26160.key\fR
and
\fIKexample.com.+003+26160.private\fR
.SH "SEE ALSO"
.PP
\fBdnssec-signzone\fR(8),
\fIBIND 9 Administrator Reference Manual\fR,
\fIRFC 2535\fR,
\fIRFC 2845\fR,
\fIRFC 2539\fR.
\fBdnssec\-signzone\fR(8),
BIND 9 Administrator Reference Manual,
RFC 2535,
RFC 2845,
RFC 2539.
.SH "AUTHOR"
.PP
Internet Systems Consortium
.SH "COPYRIGHT"
Copyright \(co 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
+22 -6
View File
@@ -1,7 +1,9 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.0//EN"
"http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd"
[<!ENTITY mdash "&#8212;">]>
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001-2003 Internet Software Consortium.
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
@@ -16,7 +18,7 @@
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-keygen.docbook,v 1.3.12.6 2004/06/11 01:17:34 marka Exp $ -->
<!-- $Id: dnssec-keygen.docbook,v 1.3.12.9 2005/08/30 01:41:41 marka Exp $ -->
<refentry>
<refentryinfo>
@@ -29,6 +31,21 @@
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<docinfo>
<copyright>
<year>2004</year>
<year>2005</year>
<holder>Internet Systems Consortium, Inc. ("ISC")</holder>
</copyright>
<copyright>
<year>2000</year>
<year>2001</year>
<year>2002</year>
<year>2003</year>
<holder>Internet Software Consortium.</holder>
</copyright>
</docinfo>
<refnamediv>
<refname><application>dnssec-keygen</application></refname>
<refpurpose>DNSSEC key generation tool</refpurpose>
@@ -244,8 +261,7 @@
When <command>dnssec-keygen</command> completes successfully,
it prints a string of the form <filename>Knnnn.+aaa+iiiii</filename>
to the standard output. This is an identification string for
the key it has generated. These strings can be used as arguments
to <command>dnssec-makekeyset</command>.
the key it has generated.
</para>
<itemizedlist>
<listitem>
+175 -491
View File
@@ -1,544 +1,228 @@
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001-2003 Internet Software Consortium.
-
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-keygen.html,v 1.5.2.1.4.6 2004/08/22 23:38:58 marka Exp $ -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML
><HEAD
><TITLE
>dnssec-keygen</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"></HEAD
><BODY
CLASS="REFENTRY"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><H1
><A
NAME="AEN1"
></A
><SPAN
CLASS="APPLICATION"
>dnssec-keygen</SPAN
></H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN9"
></A
><H2
>Name</H2
><SPAN
CLASS="APPLICATION"
>dnssec-keygen</SPAN
>&nbsp;--&nbsp;DNSSEC key generation tool</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN13"
></A
><H2
>Synopsis</H2
><P
><B
CLASS="COMMAND"
>dnssec-keygen</B
> {-a <VAR
CLASS="REPLACEABLE"
>algorithm</VAR
>} {-b <VAR
CLASS="REPLACEABLE"
>keysize</VAR
>} {-n <VAR
CLASS="REPLACEABLE"
>nametype</VAR
>} [<VAR
CLASS="OPTION"
>-c <VAR
CLASS="REPLACEABLE"
>class</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-e</VAR
>] [<VAR
CLASS="OPTION"
>-f <VAR
CLASS="REPLACEABLE"
>flag</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-g <VAR
CLASS="REPLACEABLE"
>generator</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-h</VAR
>] [<VAR
CLASS="OPTION"
>-k</VAR
>] [<VAR
CLASS="OPTION"
>-p <VAR
CLASS="REPLACEABLE"
>protocol</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-r <VAR
CLASS="REPLACEABLE"
>randomdev</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-s <VAR
CLASS="REPLACEABLE"
>strength</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-t <VAR
CLASS="REPLACEABLE"
>type</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-v <VAR
CLASS="REPLACEABLE"
>level</VAR
></VAR
>] {name}</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN53"
></A
><H2
>DESCRIPTION</H2
><P
> <B
CLASS="COMMAND"
>dnssec-keygen</B
> generates keys for DNSSEC
<!-- $Id: dnssec-keygen.html,v 1.5.2.1.4.15 2006/06/29 13:02:30 marka Exp $ -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>dnssec-keygen</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.70.1">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
<a name="id2482688"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2>Name</h2>
<p><span class="application">dnssec-keygen</span> &#8212; DNSSEC key generation tool</p>
</div>
<div class="refsynopsisdiv">
<h2>Synopsis</h2>
<div class="cmdsynopsis"><p><code class="command">dnssec-keygen</code> {-a <em class="replaceable"><code>algorithm</code></em>} {-b <em class="replaceable"><code>keysize</code></em>} {-n <em class="replaceable"><code>nametype</code></em>} [<code class="option">-c <em class="replaceable"><code>class</code></em></code>] [<code class="option">-e</code>] [<code class="option">-f <em class="replaceable"><code>flag</code></em></code>] [<code class="option">-g <em class="replaceable"><code>generator</code></em></code>] [<code class="option">-h</code>] [<code class="option">-k</code>] [<code class="option">-p <em class="replaceable"><code>protocol</code></em></code>] [<code class="option">-r <em class="replaceable"><code>randomdev</code></em></code>] [<code class="option">-s <em class="replaceable"><code>strength</code></em></code>] [<code class="option">-t <em class="replaceable"><code>type</code></em></code>] [<code class="option">-v <em class="replaceable"><code>level</code></em></code>] {name}</p></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549521"></a><h2>DESCRIPTION</h2>
<p>
<span><strong class="command">dnssec-keygen</strong></span> generates keys for DNSSEC
(Secure DNS), as defined in RFC 2535 and RFC &lt;TBA\&gt;. It can also generate
keys for use with TSIG (Transaction Signatures), as
defined in RFC 2845.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN57"
></A
><H2
>OPTIONS</H2
><P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
>-a <VAR
CLASS="REPLACEABLE"
>algorithm</VAR
></DT
><DD
><P
> Selects the cryptographic algorithm. The value of
<VAR
CLASS="OPTION"
>algorithm</VAR
> must be one of RSAMD5 (RSA) or RSASHA1,
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549533"></a><h2>OPTIONS</h2>
<div class="variablelist"><dl>
<dt><span class="term">-a <em class="replaceable"><code>algorithm</code></em></span></dt>
<dd>
<p>
Selects the cryptographic algorithm. The value of
<code class="option">algorithm</code> must be one of RSAMD5 (RSA) or RSASHA1,
DSA, DH (Diffie Hellman), or HMAC-MD5. These values
are case insensitive.
</P
><P
> Note 1: that for DNSSEC, RSASHA1 is a mandatory to implement algorithm,
</p>
<p>
Note 1: that for DNSSEC, RSASHA1 is a mandatory to implement algorithm,
and DSA is recommended. For TSIG, HMAC-MD5 is mandatory.
</P
><P
> Note 2: HMAC-MD5 and DH automatically set the -k flag.
</P
></DD
><DT
>-b <VAR
CLASS="REPLACEABLE"
>keysize</VAR
></DT
><DD
><P
> Specifies the number of bits in the key. The choice of key
</p>
<p>
Note 2: HMAC-MD5 and DH automatically set the -k flag.
</p>
</dd>
<dt><span class="term">-b <em class="replaceable"><code>keysize</code></em></span></dt>
<dd><p>
Specifies the number of bits in the key. The choice of key
size depends on the algorithm used. RSAMD5 / RSASHA1 keys must be between
512 and 2048 bits. Diffie Hellman keys must be between
128 and 4096 bits. DSA keys must be between 512 and 1024
bits and an exact multiple of 64. HMAC-MD5 keys must be
between 1 and 512 bits.
</P
></DD
><DT
>-n <VAR
CLASS="REPLACEABLE"
>nametype</VAR
></DT
><DD
><P
> Specifies the owner type of the key. The value of
<VAR
CLASS="OPTION"
>nametype</VAR
> must either be ZONE (for a DNSSEC
</p></dd>
<dt><span class="term">-n <em class="replaceable"><code>nametype</code></em></span></dt>
<dd><p>
Specifies the owner type of the key. The value of
<code class="option">nametype</code> must either be ZONE (for a DNSSEC
zone key (KEY/DNSKEY)), HOST or ENTITY (for a key associated with a host (KEY)),
USER (for a key associated with a user(KEY)) or OTHER (DNSKEY). These values are
case insensitive.
</P
></DD
><DT
>-c <VAR
CLASS="REPLACEABLE"
>class</VAR
></DT
><DD
><P
> Indicates that the DNS record containing the key should have
</p></dd>
<dt><span class="term">-c <em class="replaceable"><code>class</code></em></span></dt>
<dd><p>
Indicates that the DNS record containing the key should have
the specified class. If not specified, class IN is used.
</P
></DD
><DT
>-e</DT
><DD
><P
> If generating an RSAMD5/RSASHA1 key, use a large exponent.
</P
></DD
><DT
>-f <VAR
CLASS="REPLACEABLE"
>flag</VAR
></DT
><DD
><P
> Set the specified flag in the flag field of the KEY/DNSKEY record.
</p></dd>
<dt><span class="term">-e</span></dt>
<dd><p>
If generating an RSAMD5/RSASHA1 key, use a large exponent.
</p></dd>
<dt><span class="term">-f <em class="replaceable"><code>flag</code></em></span></dt>
<dd><p>
Set the specified flag in the flag field of the KEY/DNSKEY record.
The only recognized flag is KSK (Key Signing Key) DNSKEY.
</P
></DD
><DT
>-g <VAR
CLASS="REPLACEABLE"
>generator</VAR
></DT
><DD
><P
> If generating a Diffie Hellman key, use this generator.
</p></dd>
<dt><span class="term">-g <em class="replaceable"><code>generator</code></em></span></dt>
<dd><p>
If generating a Diffie Hellman key, use this generator.
Allowed values are 2 and 5. If no generator
is specified, a known prime from RFC 2539 will be used
if possible; otherwise the default is 2.
</P
></DD
><DT
>-h</DT
><DD
><P
> Prints a short summary of the options and arguments to
<B
CLASS="COMMAND"
>dnssec-keygen</B
>.
</P
></DD
><DT
>-k</DT
><DD
><P
> Generate KEY records rather than DNSKEY records.
</P
></DD
><DT
>-p <VAR
CLASS="REPLACEABLE"
>protocol</VAR
></DT
><DD
><P
> Sets the protocol value for the generated key. The protocol
</p></dd>
<dt><span class="term">-h</span></dt>
<dd><p>
Prints a short summary of the options and arguments to
<span><strong class="command">dnssec-keygen</strong></span>.
</p></dd>
<dt><span class="term">-k</span></dt>
<dd><p>
Generate KEY records rather than DNSKEY records.
</p></dd>
<dt><span class="term">-p <em class="replaceable"><code>protocol</code></em></span></dt>
<dd><p>
Sets the protocol value for the generated key. The protocol
is a number between 0 and 255. The default is 3 (DNSSEC).
Other possible values for this argument are listed in
RFC 2535 and its successors.
</P
></DD
><DT
>-r <VAR
CLASS="REPLACEABLE"
>randomdev</VAR
></DT
><DD
><P
> Specifies the source of randomness. If the operating
system does not provide a <TT
CLASS="FILENAME"
>/dev/random</TT
>
</p></dd>
<dt><span class="term">-r <em class="replaceable"><code>randomdev</code></em></span></dt>
<dd><p>
Specifies the source of randomness. If the operating
system does not provide a <code class="filename">/dev/random</code>
or equivalent device, the default source of randomness
is keyboard input. <TT
CLASS="FILENAME"
>randomdev</TT
> specifies
is keyboard input. <code class="filename">randomdev</code> specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
<TT
CLASS="FILENAME"
>keyboard</TT
> indicates that keyboard
<code class="filename">keyboard</code> indicates that keyboard
input should be used.
</P
></DD
><DT
>-s <VAR
CLASS="REPLACEABLE"
>strength</VAR
></DT
><DD
><P
> Specifies the strength value of the key. The strength is
</p></dd>
<dt><span class="term">-s <em class="replaceable"><code>strength</code></em></span></dt>
<dd><p>
Specifies the strength value of the key. The strength is
a number between 0 and 15, and currently has no defined
purpose in DNSSEC.
</P
></DD
><DT
>-t <VAR
CLASS="REPLACEABLE"
>type</VAR
></DT
><DD
><P
> Indicates the use of the key. <VAR
CLASS="OPTION"
>type</VAR
> must be
</p></dd>
<dt><span class="term">-t <em class="replaceable"><code>type</code></em></span></dt>
<dd><p>
Indicates the use of the key. <code class="option">type</code> must be
one of AUTHCONF, NOAUTHCONF, NOAUTH, or NOCONF. The default
is AUTHCONF. AUTH refers to the ability to authenticate
data, and CONF the ability to encrypt data.
</P
></DD
><DT
>-v <VAR
CLASS="REPLACEABLE"
>level</VAR
></DT
><DD
><P
> Sets the debugging level.
</P
></DD
></DL
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN136"
></A
><H2
>GENERATED KEYS</H2
><P
> When <B
CLASS="COMMAND"
>dnssec-keygen</B
> completes successfully,
it prints a string of the form <TT
CLASS="FILENAME"
>Knnnn.+aaa+iiiii</TT
>
</p></dd>
<dt><span class="term">-v <em class="replaceable"><code>level</code></em></span></dt>
<dd><p>
Sets the debugging level.
</p></dd>
</dl></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549939"></a><h2>GENERATED KEYS</h2>
<p>
When <span><strong class="command">dnssec-keygen</strong></span> completes successfully,
it prints a string of the form <code class="filename">Knnnn.+aaa+iiiii</code>
to the standard output. This is an identification string for
the key it has generated. These strings can be used as arguments
to <B
CLASS="COMMAND"
>dnssec-makekeyset</B
>.
</P
><P
></P
><UL
><LI
><P
> <TT
CLASS="FILENAME"
>nnnn</TT
> is the key name.
</P
></LI
><LI
><P
> <TT
CLASS="FILENAME"
>aaa</TT
> is the numeric representation of the
the key it has generated.
</p>
<div class="itemizedlist"><ul type="disc">
<li><p>
<code class="filename">nnnn</code> is the key name.
</p></li>
<li><p>
<code class="filename">aaa</code> is the numeric representation of the
algorithm.
</P
></LI
><LI
><P
> <TT
CLASS="FILENAME"
>iiiii</TT
> is the key identifier (or footprint).
</P
></LI
></UL
><P
> <B
CLASS="COMMAND"
>dnssec-keygen</B
> creates two file, with names based
on the printed string. <TT
CLASS="FILENAME"
>Knnnn.+aaa+iiiii.key</TT
>
</p></li>
<li><p>
<code class="filename">iiiii</code> is the key identifier (or footprint).
</p></li>
</ul></div>
<p>
<span><strong class="command">dnssec-keygen</strong></span> creates two file, with names based
on the printed string. <code class="filename">Knnnn.+aaa+iiiii.key</code>
contains the public key, and
<TT
CLASS="FILENAME"
>Knnnn.+aaa+iiiii.private</TT
> contains the private
<code class="filename">Knnnn.+aaa+iiiii.private</code> contains the private
key.
</P
><P
> The <TT
CLASS="FILENAME"
>.key</TT
> file contains a DNS KEY record that
</p>
<p>
The <code class="filename">.key</code> file contains a DNS KEY record that
can be inserted into a zone file (directly or with a $INCLUDE
statement).
</P
><P
> The <TT
CLASS="FILENAME"
>.private</TT
> file contains algorithm specific
</p>
<p>
The <code class="filename">.private</code> file contains algorithm specific
fields. For obvious security reasons, this file does not have
general read permission.
</P
><P
> Both <TT
CLASS="FILENAME"
>.key</TT
> and <TT
CLASS="FILENAME"
>.private</TT
>
</p>
<p>
Both <code class="filename">.key</code> and <code class="filename">.private</code>
files are generated for symmetric encryption algorithm such as
HMAC-MD5, even though the public and private key are equivalent.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN163"
></A
><H2
>EXAMPLE</H2
><P
> To generate a 768-bit DSA key for the domain
<KBD
CLASS="USERINPUT"
>example.com</KBD
>, the following command would be
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2550027"></a><h2>EXAMPLE</h2>
<p>
To generate a 768-bit DSA key for the domain
<strong class="userinput"><code>example.com</code></strong>, the following command would be
issued:
</P
><P
> <KBD
CLASS="USERINPUT"
>dnssec-keygen -a DSA -b 768 -n ZONE example.com</KBD
>
</P
><P
> The command would print a string of the form:
</P
><P
> <KBD
CLASS="USERINPUT"
>Kexample.com.+003+26160</KBD
>
</P
><P
> In this example, <B
CLASS="COMMAND"
>dnssec-keygen</B
> creates
the files <TT
CLASS="FILENAME"
>Kexample.com.+003+26160.key</TT
> and
<TT
CLASS="FILENAME"
>Kexample.com.+003+26160.private</TT
>
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN176"
></A
><H2
>SEE ALSO</H2
><P
> <SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dnssec-signzone</SPAN
>(8)</SPAN
>,
<I
CLASS="CITETITLE"
>BIND 9 Administrator Reference Manual</I
>,
<I
CLASS="CITETITLE"
>RFC 2535</I
>,
<I
CLASS="CITETITLE"
>RFC 2845</I
>,
<I
CLASS="CITETITLE"
>RFC 2539</I
>.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN186"
></A
><H2
>AUTHOR</H2
><P
> Internet Systems Consortium
</P
></DIV
></BODY
></HTML
>
</p>
<p>
<strong class="userinput"><code>dnssec-keygen -a DSA -b 768 -n ZONE example.com</code></strong>
</p>
<p>
The command would print a string of the form:
</p>
<p>
<strong class="userinput"><code>Kexample.com.+003+26160</code></strong>
</p>
<p>
In this example, <span><strong class="command">dnssec-keygen</strong></span> creates
the files <code class="filename">Kexample.com.+003+26160.key</code> and
<code class="filename">Kexample.com.+003+26160.private</code>
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2550073"></a><h2>SEE ALSO</h2>
<p>
<span class="citerefentry"><span class="refentrytitle">dnssec-signzone</span>(8)</span>,
<em class="citetitle">BIND 9 Administrator Reference Manual</em>,
<em class="citetitle">RFC 2535</em>,
<em class="citetitle">RFC 2845</em>,
<em class="citetitle">RFC 2539</em>.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2550106"></a><h2>AUTHOR</h2>
<p>
<span class="corpauthor">Internet Systems Consortium</span>
</p>
</div>
</div></body>
</html>
@@ -1,113 +0,0 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000, 2001, 2003 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: dnssec-makekeyset.8,v 1.16.2.2.4.1 2004/03/06 07:41:39 marka Exp $
.\"
.TH "DNSSEC-MAKEKEYSET" "8" "June 30, 2000" "BIND9" ""
.SH NAME
dnssec-makekeyset \- DNSSEC zone signing tool
.SH SYNOPSIS
.sp
\fBdnssec-makekeyset\fR [ \fB-a\fR ] [ \fB-s \fIstart-time\fB\fR ] [ \fB-e \fIend-time\fB\fR ] [ \fB-h\fR ] [ \fB-p\fR ] [ \fB-r \fIrandomdev\fB\fR ] [ \fB-t\fIttl\fB\fR ] [ \fB-v \fIlevel\fB\fR ] \fBkey\fR\fI...\fR
.SH "DESCRIPTION"
.PP
\fBdnssec-makekeyset\fR generates a key set from one
or more keys created by \fBdnssec-keygen\fR. It creates
a file containing a KEY record for each key, and self-signs the key
set with each zone key. The output file is of the form
\fIkeyset-nnnn.\fR, where \fInnnn\fR
is the zone name.
.SH "OPTIONS"
.TP
\fB-a\fR
Verify all generated signatures.
.TP
\fB-s \fIstart-time\fB\fR
Specify the date and time when the generated SIG records
become valid. This can be either an absolute or relative
time. An absolute start time is indicated by a number
in YYYYMMDDHHMMSS notation; 20000530144500 denotes
14:45:00 UTC on May 30th, 2000. A relative start time is
indicated by +N, which is N seconds from the current time.
If no \fBstart-time\fR is specified, the current
time is used.
.TP
\fB-e \fIend-time\fB\fR
Specify the date and time when the generated SIG records
expire. As with \fBstart-time\fR, an absolute
time is indicated in YYYYMMDDHHMMSS notation. A time relative
to the start time is indicated with +N, which is N seconds from
the start time. A time relative to the current time is
indicated with now+N. If no \fBend-time\fR is
specified, 30 days from the start time is used as a default.
.TP
\fB-h\fR
Prints a short summary of the options and arguments to
\fBdnssec-makekeyset\fR.
.TP
\fB-p\fR
Use pseudo-random data when signing the zone. This is faster,
but less secure, than using real random data. This option
may be useful when signing large zones or when the entropy
source is limited.
.TP
\fB-r \fIrandomdev\fB\fR
Specifies the source of randomness. If the operating
system does not provide a \fI/dev/random\fR
or equivalent device, the default source of randomness
is keyboard input. \fIrandomdev\fR specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
\fIkeyboard\fR indicates that keyboard
input should be used.
.TP
\fB-t \fIttl\fB\fR
Specify the TTL (time to live) of the KEY and SIG records.
The default is 3600 seconds.
.TP
\fB-v \fIlevel\fB\fR
Sets the debugging level.
.TP
\fBkey\fR
The list of keys to be included in the keyset file. These keys
are expressed in the form \fIKnnnn.+aaa+iiiii\fR
as generated by \fBdnssec-keygen\fR.
.SH "EXAMPLE"
.PP
The following command generates a keyset containing the DSA key for
\fBexample.com\fR generated in the
\fBdnssec-keygen\fR man page.
.PP
\fBdnssec-makekeyset -t 86400 -s 20000701120000 -e +2592000 Kexample.com.+003+26160\fR
.PP
In this example, \fBdnssec-makekeyset\fR creates
the file \fIkeyset-example.com.\fR. This file
contains the specified key and a self-generated signature.
.PP
The DNS administrator for \fBexample.com\fR could
send \fIkeyset-example.com.\fR to the DNS
administrator for \fB.com\fR for signing, if the
\&.com zone is DNSSEC-aware and the administrators of the two zones
have some mechanism for authenticating each other and exchanging
the keys and signatures securely.
.SH "SEE ALSO"
.PP
\fBdnssec-keygen\fR(8),
\fBdnssec-signkey\fR(8),
\fIBIND 9 Administrator Reference Manual\fR,
\fIRFC 2535\fR.
.SH "AUTHOR"
.PP
Internet Software Consortium
@@ -1,401 +0,0 @@
/*
* Portions Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Portions Copyright (C) 2000-2003 Internet Software Consortium.
* Portions Copyright (C) 1995-2000 by Network Associates, Inc.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND ISC AND NETWORK ASSOCIATES DISCLAIMS
* ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE
* FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
* IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssec-makekeyset.c,v 1.52.2.1.10.7 2004/08/28 06:25:27 marka Exp $ */
#include <config.h>
#include <stdlib.h>
#include <isc/commandline.h>
#include <isc/entropy.h>
#include <isc/mem.h>
#include <isc/print.h>
#include <isc/string.h>
#include <isc/util.h>
#include <dns/db.h>
#include <dns/diff.h>
#include <dns/dnssec.h>
#include <dns/fixedname.h>
#include <dns/log.h>
#include <dns/rdata.h>
#include <dns/rdataset.h>
#include <dns/result.h>
#include <dns/secalg.h>
#include <dns/time.h>
#include <dst/dst.h>
#include "dnssectool.h"
const char *program = "dnssec-makekeyset";
int verbose;
typedef struct keynode keynode_t;
struct keynode {
dst_key_t *key;
ISC_LINK(keynode_t) link;
};
typedef ISC_LIST(keynode_t) keylist_t;
static isc_stdtime_t starttime = 0, endtime = 0, now;
static int ttl = -1;
static isc_mem_t *mctx = NULL;
static isc_entropy_t *ectx = NULL;
static keylist_t keylist;
static void
usage(void) {
fprintf(stderr, "Usage:\n");
fprintf(stderr, "\t%s [options] keys\n", program);
fprintf(stderr, "\n");
fprintf(stderr, "Version: %s\n", VERSION);
fprintf(stderr, "Options: (default value in parenthesis) \n");
fprintf(stderr, "\t-a\n");
fprintf(stderr, "\t\tverify generated signatures\n");
fprintf(stderr, "\t-s YYYYMMDDHHMMSS|+offset:\n");
fprintf(stderr, "\t\tSIG start time - absolute|offset (now)\n");
fprintf(stderr, "\t-e YYYYMMDDHHMMSS|+offset|\"now\"+offset]:\n");
fprintf(stderr, "\t\tSIG end time - "
"absolute|from start|from now (now + 30 days)\n");
fprintf(stderr, "\t-t ttl\n");
fprintf(stderr, "\t-p\n");
fprintf(stderr, "\t\tuse pseudorandom data (faster but less secure)\n");
fprintf(stderr, "\t-r randomdev:\n");
fprintf(stderr, "\t\ta file containing random data\n");
fprintf(stderr, "\t-v level:\n");
fprintf(stderr, "\t\tverbose level (0)\n");
fprintf(stderr, "\n");
fprintf(stderr, "keys:\n");
fprintf(stderr, "\tkeyfile (Kname+alg+tag)\n");
fprintf(stderr, "\n");
fprintf(stderr, "Output:\n");
fprintf(stderr, "\tkeyset (keyset-<name>)\n");
exit(0);
}
static isc_boolean_t
zonekey_on_list(dst_key_t *key) {
keynode_t *keynode;
for (keynode = ISC_LIST_HEAD(keylist);
keynode != NULL;
keynode = ISC_LIST_NEXT(keynode, link))
{
if (dst_key_compare(keynode->key, key))
return (ISC_TRUE);
}
return (ISC_FALSE);
}
int
main(int argc, char *argv[]) {
int i, ch;
char *startstr = NULL, *endstr = NULL;
dns_fixedname_t fdomain;
dns_name_t *domain = NULL;
char *output = NULL;
char *endp;
unsigned char data[65536];
dns_db_t *db;
dns_dbversion_t *version;
dns_diff_t diff;
dns_difftuple_t *tuple;
dns_fixedname_t tname;
dst_key_t *key = NULL;
dns_rdata_t rdata = DNS_RDATA_INIT;
dns_rdataset_t rdataset;
dns_rdataclass_t rdclass;
isc_result_t result;
isc_buffer_t b;
isc_region_t r;
isc_log_t *log = NULL;
keynode_t *keynode;
unsigned int eflags;
isc_boolean_t pseudorandom = ISC_FALSE;
isc_boolean_t tryverify = ISC_FALSE;
result = isc_mem_create(0, 0, &mctx);
if (result != ISC_R_SUCCESS)
fatal("failed to create memory context: %s",
isc_result_totext(result));
dns_result_register();
while ((ch = isc_commandline_parse(argc, argv, "as:e:t:r:v:ph")) != -1)
{
switch (ch) {
case 'a':
tryverify = ISC_TRUE;
break;
case 's':
startstr = isc_commandline_argument;
break;
case 'e':
endstr = isc_commandline_argument;
break;
case 't':
endp = NULL;
ttl = strtol(isc_commandline_argument, &endp, 0);
if (*endp != '\0')
fatal("TTL must be numeric");
break;
case 'r':
setup_entropy(mctx, isc_commandline_argument, &ectx);
break;
case 'v':
endp = NULL;
verbose = strtol(isc_commandline_argument, &endp, 0);
if (*endp != '\0')
fatal("verbose level must be numeric");
break;
case 'p':
pseudorandom = ISC_TRUE;
break;
case 'h':
default:
usage();
}
}
argc -= isc_commandline_index;
argv += isc_commandline_index;
if (argc < 1)
usage();
if (ectx == NULL)
setup_entropy(mctx, NULL, &ectx);
eflags = ISC_ENTROPY_BLOCKING;
if (!pseudorandom)
eflags |= ISC_ENTROPY_GOODONLY;
result = dst_lib_init(mctx, ectx, eflags);
if (result != ISC_R_SUCCESS)
fatal("could not initialize dst: %s",
isc_result_totext(result));
isc_stdtime_get(&now);
if (startstr != NULL)
starttime = strtotime(startstr, now, now);
else
starttime = now;
if (endstr != NULL)
endtime = strtotime(endstr, now, starttime);
else
endtime = starttime + (30 * 24 * 60 * 60);
if (ttl == -1) {
ttl = 3600;
fprintf(stderr, "%s: TTL not specified, assuming 3600\n",
program);
}
setup_logging(verbose, mctx, &log);
dns_diff_init(mctx, &diff);
rdclass = 0;
ISC_LIST_INIT(keylist);
for (i = 0; i < argc; i++) {
char namestr[DNS_NAME_FORMATSIZE];
isc_buffer_t namebuf;
key = NULL;
result = dst_key_fromnamedfile(argv[i], DST_TYPE_PUBLIC,
mctx, &key);
if (result != ISC_R_SUCCESS)
fatal("error loading key from %s: %s", argv[i],
isc_result_totext(result));
if (rdclass == 0)
rdclass = dst_key_class(key);
isc_buffer_init(&namebuf, namestr, sizeof(namestr));
result = dns_name_tofilenametext(dst_key_name(key),
ISC_FALSE,
&namebuf);
check_result(result, "dns_name_tofilenametext");
isc_buffer_putuint8(&namebuf, 0);
if (domain == NULL) {
dns_fixedname_init(&fdomain);
domain = dns_fixedname_name(&fdomain);
dns_name_copy(dst_key_name(key), domain, NULL);
} else if (!dns_name_equal(domain, dst_key_name(key))) {
char str[DNS_NAME_FORMATSIZE];
dns_name_format(domain, str, sizeof(str));
fatal("all keys must have the same owner - %s "
"and %s do not match", str, namestr);
}
if (output == NULL) {
output = isc_mem_allocate(mctx,
strlen("keyset-") +
strlen(namestr) + 1);
if (output == NULL)
fatal("out of memory");
sprintf(output, "keyset-%s", namestr);
}
if (dst_key_iszonekey(key)) {
dst_key_t *zonekey = NULL;
result = dst_key_fromnamedfile(argv[i],
DST_TYPE_PUBLIC |
DST_TYPE_PRIVATE,
mctx, &zonekey);
if (result != ISC_R_SUCCESS)
fatal("failed to read private key %s: %s",
argv[i], isc_result_totext(result));
if (!zonekey_on_list(zonekey)) {
keynode = isc_mem_get(mctx, sizeof(keynode_t));
if (keynode == NULL)
fatal("out of memory");
keynode->key = zonekey;
ISC_LIST_INITANDAPPEND(keylist, keynode, link);
} else
dst_key_free(&zonekey);
}
dns_rdata_reset(&rdata);
isc_buffer_init(&b, data, sizeof(data));
result = dst_key_todns(key, &b);
dst_key_free(&key);
if (result != ISC_R_SUCCESS)
fatal("failed to convert key %s to a DNS KEY: %s",
argv[i], isc_result_totext(result));
isc_buffer_usedregion(&b, &r);
dns_rdata_fromregion(&rdata, rdclass, dns_rdatatype_dnskey, &r);
tuple = NULL;
result = dns_difftuple_create(mctx, DNS_DIFFOP_ADD,
domain, ttl, &rdata, &tuple);
check_result(result, "dns_difftuple_create");
dns_diff_append(&diff, &tuple);
}
db = NULL;
result = dns_db_create(mctx, "rbt", dns_rootname, dns_dbtype_zone,
rdclass, 0, NULL, &db);
if (result != ISC_R_SUCCESS)
fatal("failed to create a database");
version = NULL;
dns_db_newversion(db, &version);
result = dns_diff_apply(&diff, db, version);
check_result(result, "dns_diff_apply");
dns_diff_clear(&diff);
dns_fixedname_init(&tname);
dns_rdataset_init(&rdataset);
result = dns_db_find(db, domain, version, dns_rdatatype_dnskey, 0, 0,
NULL, dns_fixedname_name(&tname), &rdataset,
NULL);
check_result(result, "dns_db_find");
if (ISC_LIST_EMPTY(keylist))
fprintf(stderr,
"%s: no private zone key found; not self-signing\n",
program);
for (keynode = ISC_LIST_HEAD(keylist);
keynode != NULL;
keynode = ISC_LIST_NEXT(keynode, link))
{
dns_rdata_reset(&rdata);
isc_buffer_init(&b, data, sizeof(data));
result = dns_dnssec_sign(domain, &rdataset, keynode->key,
&starttime, &endtime, mctx, &b,
&rdata);
isc_entropy_stopcallbacksources(ectx);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(keynode->key, keystr, sizeof(keystr));
fatal("failed to sign keyset with key %s: %s",
keystr, isc_result_totext(result));
}
if (tryverify) {
result = dns_dnssec_verify(domain, &rdataset,
keynode->key, ISC_TRUE,
mctx, &rdata);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(keynode->key, keystr, sizeof(keystr));
fatal("signature from key '%s' failed to "
"verify: %s",
keystr, isc_result_totext(result));
}
}
tuple = NULL;
result = dns_difftuple_create(mctx, DNS_DIFFOP_ADD,
domain, ttl, &rdata, &tuple);
check_result(result, "dns_difftuple_create");
dns_diff_append(&diff, &tuple);
}
result = dns_diff_apply(&diff, db, version);
check_result(result, "dns_diff_apply");
dns_diff_clear(&diff);
dns_rdataset_disassociate(&rdataset);
dns_db_closeversion(db, &version, ISC_TRUE);
result = dns_db_dump(db, version, output);
if (result != ISC_R_SUCCESS) {
char domainstr[DNS_NAME_FORMATSIZE];
dns_name_format(domain, domainstr, sizeof(domainstr));
fatal("failed to write database for %s to %s",
domainstr, output);
}
printf("%s\n", output);
dns_db_detach(&db);
while (!ISC_LIST_EMPTY(keylist)) {
keynode = ISC_LIST_HEAD(keylist);
ISC_LIST_UNLINK(keylist, keynode, link);
dst_key_free(&keynode->key);
isc_mem_put(mctx, keynode, sizeof(keynode_t));
}
cleanup_logging(&log);
cleanup_entropy(&ectx);
isc_mem_free(mctx, output);
dst_lib_destroy();
if (verbose > 10)
isc_mem_stats(mctx, stdout);
isc_mem_destroy(&mctx);
return (0);
}
@@ -1,233 +0,0 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001, 2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-makekeyset.docbook,v 1.2.2.3.4.2 2004/06/03 02:24:55 marka Exp $ -->
<refentry>
<refentryinfo>
<date>June 30, 2000</date>
</refentryinfo>
<refmeta>
<refentrytitle><application>dnssec-makekeyset</application></refentrytitle>
<manvolnum>8</manvolnum>
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<refnamediv>
<refname><application>dnssec-makekeyset</application></refname>
<refpurpose>DNSSEC zone signing tool</refpurpose>
</refnamediv>
<refsynopsisdiv>
<cmdsynopsis>
<command>dnssec-makekeyset</command>
<arg><option>-a</option></arg>
<arg><option>-s <replaceable class="parameter">start-time</replaceable></option></arg>
<arg><option>-e <replaceable class="parameter">end-time</replaceable></option></arg>
<arg><option>-h</option></arg>
<arg><option>-p</option></arg>
<arg><option>-r <replaceable class="parameter">randomdev</replaceable></option></arg>
<arg><option>-t</option><replaceable class="parameter">ttl</replaceable></arg>
<arg><option>-v <replaceable class="parameter">level</replaceable></option></arg>
<arg choice="req" rep="repeat">key</arg>
</cmdsynopsis>
</refsynopsisdiv>
<refsect1>
<title>DESCRIPTION</title>
<para>
<command>dnssec-makekeyset</command> generates a key set from one
or more keys created by <command>dnssec-keygen</command>. It creates
a file containing a KEY record for each key, and self-signs the key
set with each zone key. The output file is of the form
<filename>keyset-nnnn.</filename>, where <filename>nnnn</filename>
is the zone name.
</para>
</refsect1>
<refsect1>
<title>OPTIONS</title>
<variablelist>
<varlistentry>
<term>-a</term>
<listitem>
<para>
Verify all generated signatures.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-s <replaceable class="parameter">start-time</replaceable></term>
<listitem>
<para>
Specify the date and time when the generated SIG records
become valid. This can be either an absolute or relative
time. An absolute start time is indicated by a number
in YYYYMMDDHHMMSS notation; 20000530144500 denotes
14:45:00 UTC on May 30th, 2000. A relative start time is
indicated by +N, which is N seconds from the current time.
If no <option>start-time</option> is specified, the current
time is used.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-e <replaceable class="parameter">end-time</replaceable></term>
<listitem>
<para>
Specify the date and time when the generated SIG records
expire. As with <option>start-time</option>, an absolute
time is indicated in YYYYMMDDHHMMSS notation. A time relative
to the start time is indicated with +N, which is N seconds from
the start time. A time relative to the current time is
indicated with now+N. If no <option>end-time</option> is
specified, 30 days from the start time is used as a default.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-h</term>
<listitem>
<para>
Prints a short summary of the options and arguments to
<command>dnssec-makekeyset</command>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-p</term>
<listitem>
<para>
Use pseudo-random data when signing the zone. This is faster,
but less secure, than using real random data. This option
may be useful when signing large zones or when the entropy
source is limited.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-r <replaceable class="parameter">randomdev</replaceable></term>
<listitem>
<para>
Specifies the source of randomness. If the operating
system does not provide a <filename>/dev/random</filename>
or equivalent device, the default source of randomness
is keyboard input. <filename>randomdev</filename> specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
<filename>keyboard</filename> indicates that keyboard
input should be used.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-t <replaceable class="parameter">ttl</replaceable></term>
<listitem>
<para>
Specify the TTL (time to live) of the KEY and SIG records.
The default is 3600 seconds.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-v <replaceable class="parameter">level</replaceable></term>
<listitem>
<para>
Sets the debugging level.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>key</term>
<listitem>
<para>
The list of keys to be included in the keyset file. These keys
are expressed in the form <filename>Knnnn.+aaa+iiiii</filename>
as generated by <command>dnssec-keygen</command>.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1>
<title>EXAMPLE</title>
<para>
The following command generates a keyset containing the DSA key for
<userinput>example.com</userinput> generated in the
<command>dnssec-keygen</command> man page.
</para>
<para>
<userinput>dnssec-makekeyset -t 86400 -s 20000701120000 -e +2592000 Kexample.com.+003+26160</userinput>
</para>
<para>
In this example, <command>dnssec-makekeyset</command> creates
the file <filename>keyset-example.com.</filename>. This file
contains the specified key and a self-generated signature.
</para>
<para>
The DNS administrator for <userinput>example.com</userinput> could
send <filename>keyset-example.com.</filename> to the DNS
administrator for <userinput>.com</userinput> for signing, if the
.com zone is DNSSEC-aware and the administrators of the two zones
have some mechanism for authenticating each other and exchanging
the keys and signatures securely.
</para>
</refsect1>
<refsect1>
<title>SEE ALSO</title>
<para>
<citerefentry>
<refentrytitle>dnssec-keygen</refentrytitle>
<manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>dnssec-signkey</refentrytitle>
<manvolnum>8</manvolnum>
</citerefentry>,
<citetitle>BIND 9 Administrator Reference Manual</citetitle>,
<citetitle>RFC 2535</citetitle>.
</para>
</refsect1>
<refsect1>
<title>AUTHOR</title>
<para>
<corpauthor>Internet Systems Consortium</corpauthor>
</para>
</refsect1>
</refentry>
<!--
- Local variables:
- mode: sgml
- End:
-->
@@ -1,407 +0,0 @@
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001, 2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-makekeyset.html,v 1.4.2.2.4.1 2004/03/06 10:21:15 marka Exp $ -->
<HTML
><HEAD
><TITLE
>dnssec-makekeyset</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.73
"></HEAD
><BODY
CLASS="REFENTRY"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><H1
><A
NAME="AEN1"
><SPAN
CLASS="APPLICATION"
>dnssec-makekeyset</SPAN
></A
></H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN9"
></A
><H2
>Name</H2
><SPAN
CLASS="APPLICATION"
>dnssec-makekeyset</SPAN
>&nbsp;--&nbsp;DNSSEC zone signing tool</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN13"
></A
><H2
>Synopsis</H2
><P
><B
CLASS="COMMAND"
>dnssec-makekeyset</B
> [<TT
CLASS="OPTION"
>-a</TT
>] [<TT
CLASS="OPTION"
>-s <TT
CLASS="REPLACEABLE"
><I
>start-time</I
></TT
></TT
>] [<TT
CLASS="OPTION"
>-e <TT
CLASS="REPLACEABLE"
><I
>end-time</I
></TT
></TT
>] [<TT
CLASS="OPTION"
>-h</TT
>] [<TT
CLASS="OPTION"
>-p</TT
>] [<TT
CLASS="OPTION"
>-r <TT
CLASS="REPLACEABLE"
><I
>randomdev</I
></TT
></TT
>] [<TT
CLASS="OPTION"
>-t</TT
><TT
CLASS="REPLACEABLE"
><I
>ttl</I
></TT
>] [<TT
CLASS="OPTION"
>-v <TT
CLASS="REPLACEABLE"
><I
>level</I
></TT
></TT
>] {key...}</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN38"
></A
><H2
>DESCRIPTION</H2
><P
> <B
CLASS="COMMAND"
>dnssec-makekeyset</B
> generates a key set from one
or more keys created by <B
CLASS="COMMAND"
>dnssec-keygen</B
>. It creates
a file containing a KEY record for each key, and self-signs the key
set with each zone key. The output file is of the form
<TT
CLASS="FILENAME"
>keyset-nnnn.</TT
>, where <TT
CLASS="FILENAME"
>nnnn</TT
>
is the zone name.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN45"
></A
><H2
>OPTIONS</H2
><P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
>-a</DT
><DD
><P
> Verify all generated signatures.
</P
></DD
><DT
>-s <TT
CLASS="REPLACEABLE"
><I
>start-time</I
></TT
></DT
><DD
><P
> Specify the date and time when the generated SIG records
become valid. This can be either an absolute or relative
time. An absolute start time is indicated by a number
in YYYYMMDDHHMMSS notation; 20000530144500 denotes
14:45:00 UTC on May 30th, 2000. A relative start time is
indicated by +N, which is N seconds from the current time.
If no <TT
CLASS="OPTION"
>start-time</TT
> is specified, the current
time is used.
</P
></DD
><DT
>-e <TT
CLASS="REPLACEABLE"
><I
>end-time</I
></TT
></DT
><DD
><P
> Specify the date and time when the generated SIG records
expire. As with <TT
CLASS="OPTION"
>start-time</TT
>, an absolute
time is indicated in YYYYMMDDHHMMSS notation. A time relative
to the start time is indicated with +N, which is N seconds from
the start time. A time relative to the current time is
indicated with now+N. If no <TT
CLASS="OPTION"
>end-time</TT
> is
specified, 30 days from the start time is used as a default.
</P
></DD
><DT
>-h</DT
><DD
><P
> Prints a short summary of the options and arguments to
<B
CLASS="COMMAND"
>dnssec-makekeyset</B
>.
</P
></DD
><DT
>-p</DT
><DD
><P
> Use pseudo-random data when signing the zone. This is faster,
but less secure, than using real random data. This option
may be useful when signing large zones or when the entropy
source is limited.
</P
></DD
><DT
>-r <TT
CLASS="REPLACEABLE"
><I
>randomdev</I
></TT
></DT
><DD
><P
> Specifies the source of randomness. If the operating
system does not provide a <TT
CLASS="FILENAME"
>/dev/random</TT
>
or equivalent device, the default source of randomness
is keyboard input. <TT
CLASS="FILENAME"
>randomdev</TT
> specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
<TT
CLASS="FILENAME"
>keyboard</TT
> indicates that keyboard
input should be used.
</P
></DD
><DT
>-t <TT
CLASS="REPLACEABLE"
><I
>ttl</I
></TT
></DT
><DD
><P
> Specify the TTL (time to live) of the KEY and SIG records.
The default is 3600 seconds.
</P
></DD
><DT
>-v <TT
CLASS="REPLACEABLE"
><I
>level</I
></TT
></DT
><DD
><P
> Sets the debugging level.
</P
></DD
><DT
>key</DT
><DD
><P
> The list of keys to be included in the keyset file. These keys
are expressed in the form <TT
CLASS="FILENAME"
>Knnnn.+aaa+iiiii</TT
>
as generated by <B
CLASS="COMMAND"
>dnssec-keygen</B
>.
</P
></DD
></DL
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN98"
></A
><H2
>EXAMPLE</H2
><P
> The following command generates a keyset containing the DSA key for
<TT
CLASS="USERINPUT"
><B
>example.com</B
></TT
> generated in the
<B
CLASS="COMMAND"
>dnssec-keygen</B
> man page.
</P
><P
> <TT
CLASS="USERINPUT"
><B
>dnssec-makekeyset -t 86400 -s 20000701120000 -e +2592000 Kexample.com.+003+26160</B
></TT
>
</P
><P
> In this example, <B
CLASS="COMMAND"
>dnssec-makekeyset</B
> creates
the file <TT
CLASS="FILENAME"
>keyset-example.com.</TT
>. This file
contains the specified key and a self-generated signature.
</P
><P
> The DNS administrator for <TT
CLASS="USERINPUT"
><B
>example.com</B
></TT
> could
send <TT
CLASS="FILENAME"
>keyset-example.com.</TT
> to the DNS
administrator for <TT
CLASS="USERINPUT"
><B
>.com</B
></TT
> for signing, if the
.com zone is DNSSEC-aware and the administrators of the two zones
have some mechanism for authenticating each other and exchanging
the keys and signatures securely.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN112"
></A
><H2
>SEE ALSO</H2
><P
> <SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dnssec-keygen</SPAN
>(8)</SPAN
>,
<SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dnssec-signkey</SPAN
>(8)</SPAN
>,
<I
CLASS="CITETITLE"
>BIND 9 Administrator Reference Manual</I
>,
<I
CLASS="CITETITLE"
>RFC 2535</I
>.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN123"
></A
><H2
>AUTHOR</H2
><P
> Internet Software Consortium
</P
></DIV
></BODY
></HTML
>
-108
View File
@@ -1,108 +0,0 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000, 2001, 2003 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: dnssec-signkey.8,v 1.18.2.1.4.1 2004/03/06 07:41:39 marka Exp $
.\"
.TH "DNSSEC-SIGNKEY" "8" "June 30, 2000" "BIND9" ""
.SH NAME
dnssec-signkey \- DNSSEC key set signing tool
.SH SYNOPSIS
.sp
\fBdnssec-signkey\fR [ \fB-a\fR ] [ \fB-c \fIclass\fB\fR ] [ \fB-s \fIstart-time\fB\fR ] [ \fB-e \fIend-time\fB\fR ] [ \fB-h\fR ] [ \fB-p\fR ] [ \fB-r \fIrandomdev\fB\fR ] [ \fB-v \fIlevel\fB\fR ] \fBkeyset\fR \fBkey\fR\fI...\fR
.SH "DESCRIPTION"
.PP
\fBdnssec-signkey\fR signs a keyset. Typically
the keyset will be for a child zone, and will have been generated
by \fBdnssec-makekeyset\fR. The child zone's keyset
is signed with the zone keys for its parent zone. The output file
is of the form \fIsignedkey-nnnn.\fR, where
\fInnnn\fR is the zone name.
.SH "OPTIONS"
.TP
\fB-a\fR
Verify all generated signatures.
.TP
\fB-c \fIclass\fB\fR
Specifies the DNS class of the key sets.
.TP
\fB-s \fIstart-time\fB\fR
Specify the date and time when the generated SIG records
become valid. This can be either an absolute or relative
time. An absolute start time is indicated by a number
in YYYYMMDDHHMMSS notation; 20000530144500 denotes
14:45:00 UTC on May 30th, 2000. A relative start time is
indicated by +N, which is N seconds from the current time.
If no \fBstart-time\fR is specified, the current
time is used.
.TP
\fB-e \fIend-time\fB\fR
Specify the date and time when the generated SIG records
expire. As with \fBstart-time\fR, an absolute
time is indicated in YYYYMMDDHHMMSS notation. A time relative
to the start time is indicated with +N, which is N seconds from
the start time. A time relative to the current time is
indicated with now+N. If no \fBend-time\fR is
specified, 30 days from the start time is used as a default.
.TP
\fB-h\fR
Prints a short summary of the options and arguments to
\fBdnssec-signkey\fR.
.TP
\fB-p\fR
Use pseudo-random data when signing the zone. This is faster,
but less secure, than using real random data. This option
may be useful when signing large zones or when the entropy
source is limited.
.TP
\fB-r \fIrandomdev\fB\fR
Specifies the source of randomness. If the operating
system does not provide a \fI/dev/random\fR
or equivalent device, the default source of randomness
is keyboard input. \fIrandomdev\fR specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
\fIkeyboard\fR indicates that keyboard
input should be used.
.TP
\fB-v \fIlevel\fB\fR
Sets the debugging level.
.TP
\fBkeyset\fR
The file containing the child's keyset.
.TP
\fBkey\fR
The keys used to sign the child's keyset.
.SH "EXAMPLE"
.PP
The DNS administrator for a DNSSEC-aware \fB.com\fR
zone would use the following command to sign the
\fIkeyset\fR file for \fBexample.com\fR
created by \fBdnssec-makekeyset\fR with a key generated
by \fBdnssec-keygen\fR:
.PP
\fBdnssec-signkey keyset-example.com. Kcom.+003+51944\fR
.PP
In this example, \fBdnssec-signkey\fR creates
the file \fIsignedkey-example.com.\fR, which
contains the \fBexample.com\fR keys and the
signatures by the \fB.com\fR keys.
.SH "SEE ALSO"
.PP
\fBdnssec-keygen\fR(8),
\fBdnssec-makekeyset\fR(8),
\fBdnssec-signzone\fR(8).
.SH "AUTHOR"
.PP
Internet Software Consortium
-448
View File
@@ -1,448 +0,0 @@
/*
* Portions Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Portions Copyright (C) 2000-2003 Internet Software Consortium.
* Portions Copyright (C) 1995-2000 by Network Associates, Inc.
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND ISC AND NETWORK ASSOCIATES DISCLAIMS
* ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE
* FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
* IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssec-signkey.c,v 1.50.2.2.2.7 2004/08/28 06:25:28 marka Exp $ */
#include <config.h>
#include <stdlib.h>
#include <isc/string.h>
#include <isc/commandline.h>
#include <isc/entropy.h>
#include <isc/mem.h>
#include <isc/print.h>
#include <isc/util.h>
#include <dns/db.h>
#include <dns/dbiterator.h>
#include <dns/diff.h>
#include <dns/dnssec.h>
#include <dns/fixedname.h>
#include <dns/log.h>
#include <dns/rdata.h>
#include <dns/rdataclass.h>
#include <dns/rdataset.h>
#include <dns/rdatasetiter.h>
#include <dns/rdatastruct.h>
#include <dns/result.h>
#include <dns/secalg.h>
#include <dst/dst.h>
#include "dnssectool.h"
const char *program = "dnssec-signkey";
int verbose;
typedef struct keynode keynode_t;
struct keynode {
dst_key_t *key;
isc_boolean_t verified;
ISC_LINK(keynode_t) link;
};
typedef ISC_LIST(keynode_t) keylist_t;
static isc_stdtime_t starttime = 0, endtime = 0, now;
static isc_mem_t *mctx = NULL;
static isc_entropy_t *ectx = NULL;
static keylist_t keylist;
static void
usage(void) {
fprintf(stderr, "Usage:\n");
fprintf(stderr, "\t%s [options] keyset keys\n", program);
fprintf(stderr, "\n");
fprintf(stderr, "Version: %s\n", VERSION);
fprintf(stderr, "Options: (default value in parenthesis) \n");
fprintf(stderr, "\t-a\n");
fprintf(stderr, "\t\tverify generated signatures\n");
fprintf(stderr, "\t-c class (IN)\n");
fprintf(stderr, "\t-s YYYYMMDDHHMMSS|+offset:\n");
fprintf(stderr, "\t\tSIG start time - absolute|offset (from keyset)\n");
fprintf(stderr, "\t-e YYYYMMDDHHMMSS|+offset|\"now\"+offset]:\n");
fprintf(stderr, "\t\tSIG end time - absolute|from start|from now "
"(from keyset)\n");
fprintf(stderr, "\t-v level:\n");
fprintf(stderr, "\t\tverbose level (0)\n");
fprintf(stderr, "\t-p\n");
fprintf(stderr, "\t\tuse pseudorandom data (faster but less secure)\n");
fprintf(stderr, "\t-r randomdev:\n");
fprintf(stderr, "\t\ta file containing random data\n");
fprintf(stderr, "\n");
fprintf(stderr, "keyset:\n");
fprintf(stderr, "\tfile with keyset to be signed (keyset-<name>)\n");
fprintf(stderr, "keys:\n");
fprintf(stderr, "\tkeyfile (Kname+alg+tag)\n");
fprintf(stderr, "\n");
fprintf(stderr, "Output:\n");
fprintf(stderr, "\tsigned keyset (signedkey-<name>)\n");
exit(0);
}
static void
loadkeys(dns_name_t *name, dns_rdataset_t *rdataset) {
dst_key_t *key;
dns_rdata_t rdata = DNS_RDATA_INIT;
keynode_t *keynode;
isc_result_t result;
ISC_LIST_INIT(keylist);
result = dns_rdataset_first(rdataset);
check_result(result, "dns_rdataset_first");
for (; result == ISC_R_SUCCESS; result = dns_rdataset_next(rdataset)) {
dns_rdata_reset(&rdata);
dns_rdataset_current(rdataset, &rdata);
key = NULL;
result = dns_dnssec_keyfromrdata(name, &rdata, mctx, &key);
if (result != ISC_R_SUCCESS)
continue;
if (!dst_key_iszonekey(key)) {
dst_key_free(&key);
continue;
}
keynode = isc_mem_get(mctx, sizeof(keynode_t));
if (keynode == NULL)
fatal("out of memory");
keynode->key = key;
keynode->verified = ISC_FALSE;
ISC_LIST_INITANDAPPEND(keylist, keynode, link);
}
if (result != ISC_R_NOMORE)
fatal("failure traversing key list");
}
static dst_key_t *
findkey(dns_rdata_rrsig_t *sig) {
keynode_t *keynode;
for (keynode = ISC_LIST_HEAD(keylist);
keynode != NULL;
keynode = ISC_LIST_NEXT(keynode, link))
{
if (dst_key_id(keynode->key) == sig->keyid &&
dst_key_alg(keynode->key) == sig->algorithm) {
keynode->verified = ISC_TRUE;
return (keynode->key);
}
}
fatal("signature generated by non-zone or missing key");
return (NULL);
}
int
main(int argc, char *argv[]) {
int i, ch;
char *startstr = NULL, *endstr = NULL, *classname = NULL;
char tdomain[1025];
dns_fixedname_t fdomain;
dns_name_t *domain;
char *output = NULL;
char *endp;
unsigned char data[65536];
dns_db_t *db;
dns_dbnode_t *node;
dns_dbversion_t *version;
dns_diff_t diff;
dns_difftuple_t *tuple;
dns_dbiterator_t *dbiter;
dns_rdatasetiter_t *rdsiter;
dst_key_t *key = NULL;
dns_rdata_t rdata = DNS_RDATA_INIT;
dns_rdata_t sigrdata = DNS_RDATA_INIT;
dns_rdataset_t rdataset, sigrdataset;
dns_rdata_rrsig_t sig;
isc_result_t result;
isc_buffer_t b;
isc_log_t *log = NULL;
keynode_t *keynode;
isc_boolean_t pseudorandom = ISC_FALSE;
unsigned int eflags;
dns_rdataclass_t rdclass;
isc_boolean_t tryverify = ISC_FALSE;
isc_boolean_t settime = ISC_FALSE;
result = isc_mem_create(0, 0, &mctx);
check_result(result, "isc_mem_create()");
dns_result_register();
while ((ch = isc_commandline_parse(argc, argv, "ac:s:e:pr:v:h")) != -1)
{
switch (ch) {
case 'a':
tryverify = ISC_TRUE;
break;
case 'c':
classname = isc_commandline_argument;
break;
case 's':
startstr = isc_commandline_argument;
break;
case 'e':
endstr = isc_commandline_argument;
break;
case 'p':
pseudorandom = ISC_TRUE;
break;
case 'r':
setup_entropy(mctx, isc_commandline_argument, &ectx);
break;
case 'v':
endp = NULL;
verbose = strtol(isc_commandline_argument, &endp, 0);
if (*endp != '\0')
fatal("verbose level must be numeric");
break;
case 'h':
default:
usage();
}
}
argc -= isc_commandline_index;
argv += isc_commandline_index;
if (argc < 2)
usage();
rdclass = strtoclass(classname);
if (ectx == NULL)
setup_entropy(mctx, NULL, &ectx);
eflags = ISC_ENTROPY_BLOCKING;
if (!pseudorandom)
eflags |= ISC_ENTROPY_GOODONLY;
result = dst_lib_init(mctx, ectx, eflags);
if (result != ISC_R_SUCCESS)
fatal("could not initialize dst: %s",
isc_result_totext(result));
isc_stdtime_get(&now);
if ((startstr == NULL || endstr == NULL) &&
!(startstr == NULL && endstr == NULL))
fatal("if -s or -e is specified, both must be");
if (startstr != NULL) {
starttime = strtotime(startstr, now, now);
endtime = strtotime(endstr, now, starttime);
settime = ISC_TRUE;
}
setup_logging(verbose, mctx, &log);
if (strlen(argv[0]) < 8U || strncmp(argv[0], "keyset-", 7) != 0)
fatal("keyset file '%s' must start with keyset-", argv[0]);
db = NULL;
result = dns_db_create(mctx, "rbt", dns_rootname, dns_dbtype_zone,
rdclass, 0, NULL, &db);
check_result(result, "dns_db_create()");
result = dns_db_load(db, argv[0]);
if (result != ISC_R_SUCCESS && result != DNS_R_SEENINCLUDE)
fatal("failed to load database from '%s': %s", argv[0],
isc_result_totext(result));
dns_fixedname_init(&fdomain);
domain = dns_fixedname_name(&fdomain);
dbiter = NULL;
result = dns_db_createiterator(db, ISC_FALSE, &dbiter);
check_result(result, "dns_db_createiterator()");
result = dns_dbiterator_first(dbiter);
check_result(result, "dns_dbiterator_first()");
while (result == ISC_R_SUCCESS) {
node = NULL;
dns_dbiterator_current(dbiter, &node, domain);
rdsiter = NULL;
result = dns_db_allrdatasets(db, node, NULL, 0, &rdsiter);
check_result(result, "dns_db_allrdatasets()");
result = dns_rdatasetiter_first(rdsiter);
dns_rdatasetiter_destroy(&rdsiter);
if (result == ISC_R_SUCCESS)
break;
dns_db_detachnode(db, &node);
result = dns_dbiterator_next(dbiter);
}
dns_dbiterator_destroy(&dbiter);
if (result != ISC_R_SUCCESS)
fatal("failed to find data in keyset file");
isc_buffer_init(&b, tdomain, sizeof(tdomain) - 1);
result = dns_name_tofilenametext(domain, ISC_FALSE, &b);
check_result(result, "dns_name_tofilenametext()");
isc_buffer_putuint8(&b, 0);
output = isc_mem_allocate(mctx,
strlen("signedkey-") + strlen(tdomain) + 1);
if (output == NULL)
fatal("out of memory");
sprintf(output, "signedkey-%s", tdomain);
version = NULL;
dns_db_newversion(db, &version);
dns_rdataset_init(&rdataset);
dns_rdataset_init(&sigrdataset);
result = dns_db_findrdataset(db, node, version, dns_rdatatype_dnskey, 0,
0, &rdataset, &sigrdataset);
if (result != ISC_R_SUCCESS) {
char domainstr[DNS_NAME_FORMATSIZE];
dns_name_format(domain, domainstr, sizeof(domainstr));
fatal("failed to find rdataset '%s KEY': %s",
domainstr, isc_result_totext(result));
}
loadkeys(domain, &rdataset);
dns_diff_init(mctx, &diff);
if (!dns_rdataset_isassociated(&sigrdataset))
fatal("no SIG KEY set present");
result = dns_rdataset_first(&sigrdataset);
check_result(result, "dns_rdataset_first()");
do {
dns_rdataset_current(&sigrdataset, &sigrdata);
result = dns_rdata_tostruct(&sigrdata, &sig, mctx);
check_result(result, "dns_rdata_tostruct()");
key = findkey(&sig);
result = dns_dnssec_verify(domain, &rdataset, key,
ISC_TRUE, mctx, &sigrdata);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(key, keystr, sizeof(keystr));
fatal("signature by key '%s' did not verify: %s",
keystr, isc_result_totext(result));
}
if (!settime) {
starttime = sig.timesigned;
endtime = sig.timeexpire;
settime = ISC_TRUE;
}
dns_rdata_freestruct(&sig);
dns_rdata_reset(&sigrdata);
result = dns_rdataset_next(&sigrdataset);
} while (result == ISC_R_SUCCESS);
for (keynode = ISC_LIST_HEAD(keylist);
keynode != NULL;
keynode = ISC_LIST_NEXT(keynode, link))
if (!keynode->verified)
fatal("not all zone keys self signed the key set");
argc -= 1;
argv += 1;
for (i = 0; i < argc; i++) {
key = NULL;
result = dst_key_fromnamedfile(argv[i],
DST_TYPE_PUBLIC |
DST_TYPE_PRIVATE,
mctx, &key);
if (result != ISC_R_SUCCESS)
fatal("failed to read key %s from disk: %s",
argv[i], isc_result_totext(result));
dns_rdata_reset(&rdata);
isc_buffer_init(&b, data, sizeof(data));
result = dns_dnssec_sign(domain, &rdataset, key,
&starttime, &endtime,
mctx, &b, &rdata);
isc_entropy_stopcallbacksources(ectx);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(key, keystr, sizeof(keystr));
fatal("key '%s' failed to sign data: %s",
keystr, isc_result_totext(result));
}
if (tryverify) {
result = dns_dnssec_verify(domain, &rdataset, key,
ISC_TRUE, mctx, &rdata);
if (result != ISC_R_SUCCESS) {
char keystr[KEY_FORMATSIZE];
key_format(key, keystr, sizeof(keystr));
fatal("signature from key '%s' failed to "
"verify: %s",
keystr, isc_result_totext(result));
}
}
tuple = NULL;
result = dns_difftuple_create(mctx, DNS_DIFFOP_ADD,
domain, rdataset.ttl,
&rdata, &tuple);
check_result(result, "dns_difftuple_create");
dns_diff_append(&diff, &tuple);
dst_key_free(&key);
}
result = dns_db_deleterdataset(db, node, version, dns_rdatatype_rrsig,
dns_rdatatype_dnskey);
check_result(result, "dns_db_deleterdataset");
result = dns_diff_apply(&diff, db, version);
check_result(result, "dns_diff_apply");
dns_diff_clear(&diff);
dns_db_detachnode(db, &node);
dns_db_closeversion(db, &version, ISC_TRUE);
result = dns_db_dump(db, version, output);
if (result != ISC_R_SUCCESS)
fatal("failed to write database to '%s': %s",
output, isc_result_totext(result));
printf("%s\n", output);
dns_rdataset_disassociate(&rdataset);
dns_rdataset_disassociate(&sigrdataset);
dns_db_detach(&db);
while (!ISC_LIST_EMPTY(keylist)) {
keynode = ISC_LIST_HEAD(keylist);
ISC_LIST_UNLINK(keylist, keynode, link);
dst_key_free(&keynode->key);
isc_mem_put(mctx, keynode, sizeof(keynode_t));
}
cleanup_logging(&log);
isc_mem_free(mctx, output);
cleanup_entropy(&ectx);
dst_lib_destroy();
if (verbose > 10)
isc_mem_stats(mctx, stdout);
isc_mem_destroy(&mctx);
return (0);
}
@@ -1,237 +0,0 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001, 2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-signkey.docbook,v 1.2.2.2.4.2 2004/06/03 02:24:55 marka Exp $ -->
<refentry>
<refentryinfo>
<date>June 30, 2000</date>
</refentryinfo>
<refmeta>
<refentrytitle><application>dnssec-signkey</application></refentrytitle>
<manvolnum>8</manvolnum>
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<refnamediv>
<refname><application>dnssec-signkey</application></refname>
<refpurpose>DNSSEC key set signing tool</refpurpose>
</refnamediv>
<refsynopsisdiv>
<cmdsynopsis>
<command>dnssec-signkey</command>
<arg><option>-a</option></arg>
<arg><option>-c <replaceable class="parameter">class</replaceable></option></arg>
<arg><option>-s <replaceable class="parameter">start-time</replaceable></option></arg>
<arg><option>-e <replaceable class="parameter">end-time</replaceable></option></arg>
<arg><option>-h</option></arg>
<arg><option>-p</option></arg>
<arg><option>-r <replaceable class="parameter">randomdev</replaceable></option></arg>
<arg><option>-v <replaceable class="parameter">level</replaceable></option></arg>
<arg choice="req">keyset</arg>
<arg choice="req" rep="repeat">key</arg>
</cmdsynopsis>
</refsynopsisdiv>
<refsect1>
<title>DESCRIPTION</title>
<para>
<command>dnssec-signkey</command> signs a keyset. Typically
the keyset will be for a child zone, and will have been generated
by <command>dnssec-makekeyset</command>. The child zone's keyset
is signed with the zone keys for its parent zone. The output file
is of the form <filename>signedkey-nnnn.</filename>, where
<filename>nnnn</filename> is the zone name.
</para>
</refsect1>
<refsect1>
<title>OPTIONS</title>
<variablelist>
<varlistentry>
<term>-a</term>
<listitem>
<para>
Verify all generated signatures.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-c <replaceable class="parameter">class</replaceable></term>
<listitem>
<para>
Specifies the DNS class of the key sets.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-s <replaceable class="parameter">start-time</replaceable></term>
<listitem>
<para>
Specify the date and time when the generated SIG records
become valid. This can be either an absolute or relative
time. An absolute start time is indicated by a number
in YYYYMMDDHHMMSS notation; 20000530144500 denotes
14:45:00 UTC on May 30th, 2000. A relative start time is
indicated by +N, which is N seconds from the current time.
If no <option>start-time</option> is specified, the current
time is used.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-e <replaceable class="parameter">end-time</replaceable></term>
<listitem>
<para>
Specify the date and time when the generated SIG records
expire. As with <option>start-time</option>, an absolute
time is indicated in YYYYMMDDHHMMSS notation. A time relative
to the start time is indicated with +N, which is N seconds from
the start time. A time relative to the current time is
indicated with now+N. If no <option>end-time</option> is
specified, 30 days from the start time is used as a default.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-h</term>
<listitem>
<para>
Prints a short summary of the options and arguments to
<command>dnssec-signkey</command>.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-p</term>
<listitem>
<para>
Use pseudo-random data when signing the zone. This is faster,
but less secure, than using real random data. This option
may be useful when signing large zones or when the entropy
source is limited.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-r <replaceable class="parameter">randomdev</replaceable></term>
<listitem>
<para>
Specifies the source of randomness. If the operating
system does not provide a <filename>/dev/random</filename>
or equivalent device, the default source of randomness
is keyboard input. <filename>randomdev</filename> specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
<filename>keyboard</filename> indicates that keyboard
input should be used.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>-v <replaceable class="parameter">level</replaceable></term>
<listitem>
<para>
Sets the debugging level.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>keyset</term>
<listitem>
<para>
The file containing the child's keyset.
</para>
</listitem>
</varlistentry>
<varlistentry>
<term>key</term>
<listitem>
<para>
The keys used to sign the child's keyset.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1>
<title>EXAMPLE</title>
<para>
The DNS administrator for a DNSSEC-aware <userinput>.com</userinput>
zone would use the following command to sign the
<filename>keyset</filename> file for <userinput>example.com</userinput>
created by <command>dnssec-makekeyset</command> with a key generated
by <command>dnssec-keygen</command>:
</para>
<para>
<userinput>dnssec-signkey keyset-example.com. Kcom.+003+51944</userinput>
</para>
<para>
In this example, <command>dnssec-signkey</command> creates
the file <filename>signedkey-example.com.</filename>, which
contains the <userinput>example.com</userinput> keys and the
signatures by the <userinput>.com</userinput> keys.
</para>
</refsect1>
<refsect1>
<title>SEE ALSO</title>
<para>
<citerefentry>
<refentrytitle>dnssec-keygen</refentrytitle>
<manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>dnssec-makekeyset</refentrytitle>
<manvolnum>8</manvolnum>
</citerefentry>,
<citerefentry>
<refentrytitle>dnssec-signzone</refentrytitle>
<manvolnum>8</manvolnum>
</citerefentry>.
</para>
</refsect1>
<refsect1>
<title>AUTHOR</title>
<para>
<corpauthor>Internet Systems Consortium</corpauthor>
</para>
</refsect1>
</refentry>
<!--
- Local variables:
- mode: sgml
- End:
-->
@@ -1,407 +0,0 @@
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001, 2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-signkey.html,v 1.4.2.1.4.1 2004/03/06 10:21:15 marka Exp $ -->
<HTML
><HEAD
><TITLE
>dnssec-signkey</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.73
"></HEAD
><BODY
CLASS="REFENTRY"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><H1
><A
NAME="AEN1"
><SPAN
CLASS="APPLICATION"
>dnssec-signkey</SPAN
></A
></H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN9"
></A
><H2
>Name</H2
><SPAN
CLASS="APPLICATION"
>dnssec-signkey</SPAN
>&nbsp;--&nbsp;DNSSEC key set signing tool</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN13"
></A
><H2
>Synopsis</H2
><P
><B
CLASS="COMMAND"
>dnssec-signkey</B
> [<TT
CLASS="OPTION"
>-a</TT
>] [<TT
CLASS="OPTION"
>-c <TT
CLASS="REPLACEABLE"
><I
>class</I
></TT
></TT
>] [<TT
CLASS="OPTION"
>-s <TT
CLASS="REPLACEABLE"
><I
>start-time</I
></TT
></TT
>] [<TT
CLASS="OPTION"
>-e <TT
CLASS="REPLACEABLE"
><I
>end-time</I
></TT
></TT
>] [<TT
CLASS="OPTION"
>-h</TT
>] [<TT
CLASS="OPTION"
>-p</TT
>] [<TT
CLASS="OPTION"
>-r <TT
CLASS="REPLACEABLE"
><I
>randomdev</I
></TT
></TT
>] [<TT
CLASS="OPTION"
>-v <TT
CLASS="REPLACEABLE"
><I
>level</I
></TT
></TT
>] {keyset} {key...}</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN39"
></A
><H2
>DESCRIPTION</H2
><P
> <B
CLASS="COMMAND"
>dnssec-signkey</B
> signs a keyset. Typically
the keyset will be for a child zone, and will have been generated
by <B
CLASS="COMMAND"
>dnssec-makekeyset</B
>. The child zone's keyset
is signed with the zone keys for its parent zone. The output file
is of the form <TT
CLASS="FILENAME"
>signedkey-nnnn.</TT
>, where
<TT
CLASS="FILENAME"
>nnnn</TT
> is the zone name.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN46"
></A
><H2
>OPTIONS</H2
><P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
>-a</DT
><DD
><P
> Verify all generated signatures.
</P
></DD
><DT
>-c <TT
CLASS="REPLACEABLE"
><I
>class</I
></TT
></DT
><DD
><P
> Specifies the DNS class of the key sets.
</P
></DD
><DT
>-s <TT
CLASS="REPLACEABLE"
><I
>start-time</I
></TT
></DT
><DD
><P
> Specify the date and time when the generated SIG records
become valid. This can be either an absolute or relative
time. An absolute start time is indicated by a number
in YYYYMMDDHHMMSS notation; 20000530144500 denotes
14:45:00 UTC on May 30th, 2000. A relative start time is
indicated by +N, which is N seconds from the current time.
If no <TT
CLASS="OPTION"
>start-time</TT
> is specified, the current
time is used.
</P
></DD
><DT
>-e <TT
CLASS="REPLACEABLE"
><I
>end-time</I
></TT
></DT
><DD
><P
> Specify the date and time when the generated SIG records
expire. As with <TT
CLASS="OPTION"
>start-time</TT
>, an absolute
time is indicated in YYYYMMDDHHMMSS notation. A time relative
to the start time is indicated with +N, which is N seconds from
the start time. A time relative to the current time is
indicated with now+N. If no <TT
CLASS="OPTION"
>end-time</TT
> is
specified, 30 days from the start time is used as a default.
</P
></DD
><DT
>-h</DT
><DD
><P
> Prints a short summary of the options and arguments to
<B
CLASS="COMMAND"
>dnssec-signkey</B
>.
</P
></DD
><DT
>-p</DT
><DD
><P
> Use pseudo-random data when signing the zone. This is faster,
but less secure, than using real random data. This option
may be useful when signing large zones or when the entropy
source is limited.
</P
></DD
><DT
>-r <TT
CLASS="REPLACEABLE"
><I
>randomdev</I
></TT
></DT
><DD
><P
> Specifies the source of randomness. If the operating
system does not provide a <TT
CLASS="FILENAME"
>/dev/random</TT
>
or equivalent device, the default source of randomness
is keyboard input. <TT
CLASS="FILENAME"
>randomdev</TT
> specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
<TT
CLASS="FILENAME"
>keyboard</TT
> indicates that keyboard
input should be used.
</P
></DD
><DT
>-v <TT
CLASS="REPLACEABLE"
><I
>level</I
></TT
></DT
><DD
><P
> Sets the debugging level.
</P
></DD
><DT
>keyset</DT
><DD
><P
> The file containing the child's keyset.
</P
></DD
><DT
>key</DT
><DD
><P
> The keys used to sign the child's keyset.
</P
></DD
></DL
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN101"
></A
><H2
>EXAMPLE</H2
><P
> The DNS administrator for a DNSSEC-aware <TT
CLASS="USERINPUT"
><B
>.com</B
></TT
>
zone would use the following command to sign the
<TT
CLASS="FILENAME"
>keyset</TT
> file for <TT
CLASS="USERINPUT"
><B
>example.com</B
></TT
>
created by <B
CLASS="COMMAND"
>dnssec-makekeyset</B
> with a key generated
by <B
CLASS="COMMAND"
>dnssec-keygen</B
>:
</P
><P
> <TT
CLASS="USERINPUT"
><B
>dnssec-signkey keyset-example.com. Kcom.+003+51944</B
></TT
>
</P
><P
> In this example, <B
CLASS="COMMAND"
>dnssec-signkey</B
> creates
the file <TT
CLASS="FILENAME"
>signedkey-example.com.</TT
>, which
contains the <TT
CLASS="USERINPUT"
><B
>example.com</B
></TT
> keys and the
signatures by the <TT
CLASS="USERINPUT"
><B
>.com</B
></TT
> keys.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN116"
></A
><H2
>SEE ALSO</H2
><P
> <SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dnssec-keygen</SPAN
>(8)</SPAN
>,
<SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dnssec-makekeyset</SPAN
>(8)</SPAN
>,
<SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dnssec-signzone</SPAN
>(8)</SPAN
>.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN128"
></A
><H2
>AUTHOR</H2
><P
> Internet Software Consortium
</P
></DIV
></BODY
></HTML
>
+129 -134
View File
@@ -1,167 +1,162 @@
.\" Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2003 Internet Software Consortium.
.\"
.\" Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
.\" Copyright (C) 2000-2003 Internet Software Consortium.
.\"
.\" Permission to use, copy, modify, and distribute this software for any
.\" purpose with or without fee is hereby granted, provided that the above
.\" copyright notice and this permission notice appear in all copies.
.\"
.\"
.\" THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
.\" REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
.\" INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
.\" LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
.\" OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.\"
.\" $Id: dnssec-signzone.8,v 1.23.2.1.4.6 2004/06/11 02:32:46 marka Exp $
.\" $Id: dnssec-signzone.8,v 1.23.2.1.4.11 2006/06/29 13:02:30 marka Exp $
.\"
.TH "DNSSEC-SIGNZONE" "8" "June 30, 2000" "BIND9" ""
.SH NAME
dnssec-signzone \- DNSSEC zone signing tool
.SH SYNOPSIS
.sp
\fBdnssec-signzone\fR [ \fB-a\fR ] [ \fB-c \fIclass\fB\fR ] [ \fB-d \fIdirectory\fB\fR ] [ \fB-e \fIend-time\fB\fR ] [ \fB-f \fIoutput-file\fB\fR ] [ \fB-g\fR ] [ \fB-h\fR ] [ \fB-k \fIkey\fB\fR ] [ \fB-l \fIdomain\fB\fR ] [ \fB-i \fIinterval\fB\fR ] [ \fB-n \fInthreads\fB\fR ] [ \fB-o \fIorigin\fB\fR ] [ \fB-p\fR ] [ \fB-r \fIrandomdev\fB\fR ] [ \fB-s \fIstart-time\fB\fR ] [ \fB-t\fR ] [ \fB-v \fIlevel\fB\fR ] [ \fB-z\fR ] \fBzonefile\fR [ \fBkey\fR\fI...\fR ]
.hy 0
.ad l
.\" Title: dnssec\-signzone
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.70.1 <http://docbook.sf.net/>
.\" Date: June 30, 2000
.\" Manual: BIND9
.\" Source: BIND9
.\"
.TH "DNSSEC\-SIGNZONE" "8" "June 30, 2000" "BIND9" "BIND9"
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.SH "NAME"
dnssec\-signzone \- DNSSEC zone signing tool
.SH "SYNOPSIS"
.HP 16
\fBdnssec\-signzone\fR [\fB\-a\fR] [\fB\-c\ \fR\fB\fIclass\fR\fR] [\fB\-d\ \fR\fB\fIdirectory\fR\fR] [\fB\-e\ \fR\fB\fIend\-time\fR\fR] [\fB\-f\ \fR\fB\fIoutput\-file\fR\fR] [\fB\-g\fR] [\fB\-h\fR] [\fB\-k\ \fR\fB\fIkey\fR\fR] [\fB\-l\ \fR\fB\fIdomain\fR\fR] [\fB\-i\ \fR\fB\fIinterval\fR\fR] [\fB\-n\ \fR\fB\fInthreads\fR\fR] [\fB\-o\ \fR\fB\fIorigin\fR\fR] [\fB\-p\fR] [\fB\-r\ \fR\fB\fIrandomdev\fR\fR] [\fB\-s\ \fR\fB\fIstart\-time\fR\fR] [\fB\-t\fR] [\fB\-v\ \fR\fB\fIlevel\fR\fR] [\fB\-z\fR] {zonefile} [key...]
.SH "DESCRIPTION"
.PP
\fBdnssec-signzone\fR signs a zone. It generates
NSEC and RRSIG records and produces a signed version of the
zone. The security status of delegations from the signed zone
(that is, whether the child zones are secure or not) is
determined by the presence or absence of a
\fIkeyset\fR file for each child zone.
\fBdnssec\-signzone\fR
signs a zone. It generates NSEC and RRSIG records and produces a signed version of the zone. The security status of delegations from the signed zone (that is, whether the child zones are secure or not) is determined by the presence or absence of a
\fIkeyset\fR
file for each child zone.
.SH "OPTIONS"
.TP
\fB-a\fR
.TP 3n
\-a
Verify all generated signatures.
.TP
\fB-c \fIclass\fB\fR
.TP 3n
\-c \fIclass\fR
Specifies the DNS class of the zone.
.TP
\fB-k \fIkey\fB\fR
Treat specified key as a key signing key ignoring any
key flags. This option may be specified multiple times.
.TP
\fB-l \fIdomain\fB\fR
Generate a DLV set in addition to the key (DNSKEY) and DS sets.
The domain is appended to the name of the records.
.TP
\fB-d \fIdirectory\fB\fR
Look for \fIkeyset\fR files in
\fBdirectory\fR as the directory
.TP
\fB-g\fR
Generate DS records for child zones from keyset files.
Existing DS records will be removed.
.TP
\fB-s \fIstart-time\fB\fR
Specify the date and time when the generated RRSIG records
become valid. This can be either an absolute or relative
time. An absolute start time is indicated by a number
in YYYYMMDDHHMMSS notation; 20000530144500 denotes
14:45:00 UTC on May 30th, 2000. A relative start time is
indicated by +N, which is N seconds from the current time.
If no \fBstart-time\fR is specified, the current
time minus 1 hour (to allow for clock skew) is used.
.TP
\fB-e \fIend-time\fB\fR
Specify the date and time when the generated RRSIG records
expire. As with \fBstart-time\fR, an absolute
time is indicated in YYYYMMDDHHMMSS notation. A time relative
to the start time is indicated with +N, which is N seconds from
the start time. A time relative to the current time is
indicated with now+N. If no \fBend-time\fR is
specified, 30 days from the start time is used as a default.
.TP
\fB-f \fIoutput-file\fB\fR
The name of the output file containing the signed zone. The
default is to append \fI.signed\fR to the
input file.
.TP
\fB-h\fR
.TP 3n
\-k \fIkey\fR
Treat specified key as a key signing key ignoring any key flags. This option may be specified multiple times.
.TP 3n
\-l \fIdomain\fR
Generate a DLV set in addition to the key (DNSKEY) and DS sets. The domain is appended to the name of the records.
.TP 3n
\-d \fIdirectory\fR
Look for
\fIkeyset\fR
files in
\fBdirectory\fR
as the directory
.TP 3n
\-g
Generate DS records for child zones from keyset files. Existing DS records will be removed.
.TP 3n
\-s \fIstart\-time\fR
Specify the date and time when the generated RRSIG records become valid. This can be either an absolute or relative time. An absolute start time is indicated by a number in YYYYMMDDHHMMSS notation; 20000530144500 denotes 14:45:00 UTC on May 30th, 2000. A relative start time is indicated by +N, which is N seconds from the current time. If no
\fBstart\-time\fR
is specified, the current time minus 1 hour (to allow for clock skew) is used.
.TP 3n
\-e \fIend\-time\fR
Specify the date and time when the generated RRSIG records expire. As with
\fBstart\-time\fR, an absolute time is indicated in YYYYMMDDHHMMSS notation. A time relative to the start time is indicated with +N, which is N seconds from the start time. A time relative to the current time is indicated with now+N. If no
\fBend\-time\fR
is specified, 30 days from the start time is used as a default.
.TP 3n
\-f \fIoutput\-file\fR
The name of the output file containing the signed zone. The default is to append
\fI.signed\fR
to the input file.
.TP 3n
\-h
Prints a short summary of the options and arguments to
\fBdnssec-signzone\fR.
.TP
\fB-i \fIinterval\fB\fR
When a previously signed zone is passed as input, records
may be resigned. The \fBinterval\fR option
specifies the cycle interval as an offset from the current
time (in seconds). If a RRSIG record expires after the
cycle interval, it is retained. Otherwise, it is considered
to be expiring soon, and it will be replaced.
The default cycle interval is one quarter of the difference
between the signature end and start times. So if neither
\fBend-time\fR or \fBstart-time\fR
are specified, \fBdnssec-signzone\fR generates
signatures that are valid for 30 days, with a cycle
interval of 7.5 days. Therefore, if any existing RRSIG records
are due to expire in less than 7.5 days, they would be
replaced.
.TP
\fB-n \fIncpus\fB\fR
Specifies the number of threads to use. By default, one
thread is started for each detected CPU.
.TP
\fB-o \fIorigin\fB\fR
The zone origin. If not specified, the name of the zone file
is assumed to be the origin.
.TP
\fB-p\fR
Use pseudo-random data when signing the zone. This is faster,
but less secure, than using real random data. This option
may be useful when signing large zones or when the entropy
source is limited.
.TP
\fB-r \fIrandomdev\fB\fR
Specifies the source of randomness. If the operating
system does not provide a \fI/dev/random\fR
or equivalent device, the default source of randomness
is keyboard input. \fIrandomdev\fR specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
\fIkeyboard\fR indicates that keyboard
input should be used.
.TP
\fB-t\fR
\fBdnssec\-signzone\fR.
.TP 3n
\-i \fIinterval\fR
When a previously signed zone is passed as input, records may be resigned. The
\fBinterval\fR
option specifies the cycle interval as an offset from the current time (in seconds). If a RRSIG record expires after the cycle interval, it is retained. Otherwise, it is considered to be expiring soon, and it will be replaced.
.sp
The default cycle interval is one quarter of the difference between the signature end and start times. So if neither
\fBend\-time\fR
or
\fBstart\-time\fR
are specified,
\fBdnssec\-signzone\fR
generates signatures that are valid for 30 days, with a cycle interval of 7.5 days. Therefore, if any existing RRSIG records are due to expire in less than 7.5 days, they would be replaced.
.TP 3n
\-n \fIncpus\fR
Specifies the number of threads to use. By default, one thread is started for each detected CPU.
.TP 3n
\-o \fIorigin\fR
The zone origin. If not specified, the name of the zone file is assumed to be the origin.
.TP 3n
\-p
Use pseudo\-random data when signing the zone. This is faster, but less secure, than using real random data. This option may be useful when signing large zones or when the entropy source is limited.
.TP 3n
\-r \fIrandomdev\fR
Specifies the source of randomness. If the operating system does not provide a
\fI/dev/random\fR
or equivalent device, the default source of randomness is keyboard input.
\fIrandomdev\fR
specifies the name of a character device or file containing random data to be used instead of the default. The special value
\fIkeyboard\fR
indicates that keyboard input should be used.
.TP 3n
\-t
Print statistics at completion.
.TP
\fB-v \fIlevel\fB\fR
.TP 3n
\-v \fIlevel\fR
Sets the debugging level.
.TP
\fB-z\fR
.TP 3n
\-z
Ignore KSK flag on key when determining what to sign.
.TP
\fBzonefile\fR
.TP 3n
zonefile
The file containing the zone to be signed.
Sets the debugging level.
.TP
\fBkey\fR
The keys used to sign the zone. If no keys are specified, the
default all zone keys that have private key files in the
current directory.
.TP 3n
key
The keys used to sign the zone. If no keys are specified, the default all zone keys that have private key files in the current directory.
.SH "EXAMPLE"
.PP
The following command signs the \fBexample.com\fR
zone with the DSA key generated in the \fBdnssec-keygen\fR
The following command signs the
\fBexample.com\fR
zone with the DSA key generated in the
\fBdnssec\-keygen\fR
man page. The zone's keys must be in the zone. If there are
\fIkeyset\fR files associated with child zones,
they must be in the current directory.
\fBexample.com\fR, the following command would be
issued:
\fIkeyset\fR
files associated with child zones, they must be in the current directory.
\fBexample.com\fR, the following command would be issued:
.PP
\fBdnssec-signzone -o example.com db.example.com Kexample.com.+003+26160\fR
\fBdnssec\-signzone \-o example.com db.example.com Kexample.com.+003+26160\fR
.PP
The command would print a string of the form:
.PP
In this example, \fBdnssec-signzone\fR creates
the file \fIdb.example.com.signed\fR. This file
should be referenced in a zone statement in a
\fInamed.conf\fR file.
In this example,
\fBdnssec\-signzone\fR
creates the file
\fIdb.example.com.signed\fR. This file should be referenced in a zone statement in a
\fInamed.conf\fR
file.
.SH "SEE ALSO"
.PP
\fBdnssec-keygen\fR(8),
\fIBIND 9 Administrator Reference Manual\fR,
\fIRFC 2535\fR.
\fBdnssec\-keygen\fR(8),
BIND 9 Administrator Reference Manual,
RFC 2535.
.SH "AUTHOR"
.PP
Internet Systems Consortium
.SH "COPYRIGHT"
Copyright \(co 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
+56 -35
View File
@@ -1,5 +1,5 @@
/*
* Portions Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Portions Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Portions Copyright (C) 1999-2003 Internet Software Consortium.
* Portions Copyright (C) 1995-2000 by Network Associates, Inc.
*
@@ -16,7 +16,7 @@
* IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssec-signzone.c,v 1.139.2.2.4.17 2004/10/25 01:36:06 marka Exp $ */
/* $Id: dnssec-signzone.c,v 1.139.2.2.4.23 2006/01/04 23:50:19 marka Exp $ */
#include <config.h>
@@ -787,7 +787,6 @@ signname(dns_dbnode_t *node, dns_name_t *name) {
dns_rdatasetiter_t *rdsiter;
isc_boolean_t isdelegation = ISC_FALSE;
isc_boolean_t hasds = ISC_FALSE;
isc_boolean_t atorigin;
isc_boolean_t changed = ISC_FALSE;
dns_diff_t del, add;
char namestr[DNS_NAME_FORMATSIZE];
@@ -795,8 +794,6 @@ signname(dns_dbnode_t *node, dns_name_t *name) {
dns_name_format(name, namestr, sizeof(namestr));
atorigin = dns_name_equal(name, gorigin);
/*
* Determine if this is a delegation point.
*/
@@ -931,13 +928,16 @@ signname(dns_dbnode_t *node, dns_name_t *name) {
static inline isc_boolean_t
active_node(dns_dbnode_t *node) {
dns_rdatasetiter_t *rdsiter;
dns_rdatasetiter_t *rdsiter = NULL;
dns_rdatasetiter_t *rdsiter2 = NULL;
isc_boolean_t active = ISC_FALSE;
isc_result_t result;
dns_rdataset_t rdataset;
dns_rdatatype_t type;
dns_rdatatype_t covers;
isc_boolean_t found;
dns_rdataset_init(&rdataset);
rdsiter = NULL;
result = dns_db_allrdatasets(gdb, node, gversion, 0, &rdsiter);
check_result(result, "dns_db_allrdatasets()");
result = dns_rdatasetiter_first(rdsiter);
@@ -958,36 +958,63 @@ active_node(dns_dbnode_t *node) {
if (!active) {
/*
* Make sure there is no NSEC / RRSIG records for
* this node.
* The node is empty of everything but NSEC / RRSIG records.
*/
result = dns_db_deleterdataset(gdb, node, gversion,
dns_rdatatype_nsec, 0);
if (result == DNS_R_UNCHANGED)
result = ISC_R_SUCCESS;
check_result(result, "dns_db_deleterdataset(nsec)");
result = dns_rdatasetiter_first(rdsiter);
for (result = dns_rdatasetiter_first(rdsiter);
result == ISC_R_SUCCESS;
result = dns_rdatasetiter_next(rdsiter)) {
dns_rdatasetiter_current(rdsiter, &rdataset);
if (rdataset.type == dns_rdatatype_rrsig) {
dns_rdatatype_t type = rdataset.type;
dns_rdatatype_t covers = rdataset.covers;
result = dns_db_deleterdataset(gdb, node,
gversion, type,
covers);
if (result == DNS_R_UNCHANGED)
result = ISC_R_SUCCESS;
check_result(result,
"dns_db_deleterdataset(rrsig)");
}
result = dns_db_deleterdataset(gdb, node, gversion,
rdataset.type,
rdataset.covers);
check_result(result, "dns_db_deleterdataset()");
dns_rdataset_disassociate(&rdataset);
}
if (result != ISC_R_NOMORE)
fatal("rdataset iteration failed: %s",
isc_result_totext(result));
} else {
/*
* Delete RRSIGs for types that no longer exist.
*/
result = dns_db_allrdatasets(gdb, node, gversion, 0, &rdsiter2);
check_result(result, "dns_db_allrdatasets()");
for (result = dns_rdatasetiter_first(rdsiter);
result == ISC_R_SUCCESS;
result = dns_rdatasetiter_next(rdsiter)) {
dns_rdatasetiter_current(rdsiter, &rdataset);
type = rdataset.type;
covers = rdataset.covers;
dns_rdataset_disassociate(&rdataset);
if (type != dns_rdatatype_rrsig)
continue;
found = ISC_FALSE;
for (result = dns_rdatasetiter_first(rdsiter2);
!found && result == ISC_R_SUCCESS;
result = dns_rdatasetiter_next(rdsiter2)) {
dns_rdatasetiter_current(rdsiter2, &rdataset);
if (rdataset.type == covers)
found = ISC_TRUE;
dns_rdataset_disassociate(&rdataset);
}
if (!found) {
if (result != ISC_R_NOMORE)
fatal("rdataset iteration failed: %s",
isc_result_totext(result));
result = dns_db_deleterdataset(gdb, node,
gversion, type,
covers);
check_result(result,
"dns_db_deleterdataset(rrsig)");
} else if (result != ISC_R_NOMORE &&
result != ISC_R_SUCCESS)
fatal("rdataset iteration failed: %s",
isc_result_totext(result));
}
if (result != ISC_R_NOMORE)
fatal("rdataset iteration failed: %s",
isc_result_totext(result));
dns_rdatasetiter_destroy(&rdsiter2);
}
dns_rdatasetiter_destroy(&rdsiter);
@@ -1265,10 +1292,6 @@ nsecify(void) {
result = dns_dbiterator_next(dbiter);
continue;
}
if (result != ISC_R_SUCCESS) {
dns_db_detachnode(gdb, &nextnode);
break;
}
if (!dns_name_issubdomain(nextname, gorigin) ||
(zonecut != NULL &&
dns_name_issubdomain(nextname, zonecut)))
@@ -1423,7 +1446,6 @@ warnifallksk(dns_db_t *db) {
dns_dbnode_t *node = NULL;
dns_rdataset_t rdataset;
dns_rdata_t rdata = DNS_RDATA_INIT;
dst_key_t *pubkey;
isc_result_t result;
dns_rdata_key_t key;
isc_boolean_t have_non_ksk = ISC_FALSE;
@@ -1444,7 +1466,6 @@ warnifallksk(dns_db_t *db) {
result = dns_rdataset_first(&rdataset);
check_result(result, "dns_rdataset_first");
while (result == ISC_R_SUCCESS) {
pubkey = NULL;
dns_rdata_reset(&rdata);
dns_rdataset_current(&rdataset, &rdata);
result = dns_rdata_tostruct(&rdata, &key, NULL);
@@ -1615,9 +1636,9 @@ usage(void) {
fprintf(stderr, "\t\tdirectory to find keyset files (.)\n");
fprintf(stderr, "\t-g:\t");
fprintf(stderr, "generate DS records from keyset files\n");
fprintf(stderr, "\t-s YYYYMMDDHHMMSS|+offset:\n");
fprintf(stderr, "\t-s [YYYYMMDDHHMMSS|+offset]:\n");
fprintf(stderr, "\t\tRRSIG start time - absolute|offset (now - 1 hour)\n");
fprintf(stderr, "\t-e YYYYMMDDHHMMSS|+offset|\"now\"+offset]:\n");
fprintf(stderr, "\t-e [YYYYMMDDHHMMSS|+offset|\"now\"+offset]:\n");
fprintf(stderr, "\t\tRRSIG end time - absolute|from start|from now "
"(now + 30 days)\n");
fprintf(stderr, "\t-i interval:\n");
@@ -1,7 +1,9 @@
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook V4.1//EN">
<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.0//EN"
"http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd"
[<!ENTITY mdash "&#8212;">]>
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001-2003 Internet Software Consortium.
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
@@ -16,7 +18,7 @@
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-signzone.docbook,v 1.2.2.2.4.8 2004/06/11 01:17:35 marka Exp $ -->
<!-- $Id: dnssec-signzone.docbook,v 1.2.2.2.4.11 2005/06/24 00:18:15 marka Exp $ -->
<refentry>
<refentryinfo>
@@ -29,6 +31,21 @@
<refmiscinfo>BIND9</refmiscinfo>
</refmeta>
<docinfo>
<copyright>
<year>2004</year>
<year>2005</year>
<holder>Internet Systems Consortium, Inc. ("ISC")</holder>
</copyright>
<copyright>
<year>2000</year>
<year>2001</year>
<year>2002</year>
<year>2003</year>
<holder>Internet Software Consortium.</holder>
</copyright>
</docinfo>
<refnamediv>
<refname><application>dnssec-signzone</application></refname>
<refpurpose>DNSSEC zone signing tool</refpurpose>
@@ -290,7 +307,6 @@
<listitem>
<para>
The file containing the zone to be signed.
Sets the debugging level.
</para>
</listitem>
</varlistentry>
+166 -499
View File
@@ -1,553 +1,220 @@
<!--
- Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2001-2003 Internet Software Consortium.
-
- Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
- Copyright (C) 2000-2003 Internet Software Consortium.
-
- Permission to use, copy, modify, and distribute this software for any
- purpose with or without fee is hereby granted, provided that the above
- copyright notice and this permission notice appear in all copies.
-
-
- THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
- REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
- INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
- LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
- OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
- PERFORMANCE OF THIS SOFTWARE.
-->
<!-- $Id: dnssec-signzone.html,v 1.4.2.1.4.7 2004/08/22 23:38:58 marka Exp $ -->
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML
><HEAD
><TITLE
>dnssec-signzone</TITLE
><META
NAME="GENERATOR"
CONTENT="Modular DocBook HTML Stylesheet Version 1.7"></HEAD
><BODY
CLASS="REFENTRY"
BGCOLOR="#FFFFFF"
TEXT="#000000"
LINK="#0000FF"
VLINK="#840084"
ALINK="#0000FF"
><H1
><A
NAME="AEN1"
></A
><SPAN
CLASS="APPLICATION"
>dnssec-signzone</SPAN
></H1
><DIV
CLASS="REFNAMEDIV"
><A
NAME="AEN9"
></A
><H2
>Name</H2
><SPAN
CLASS="APPLICATION"
>dnssec-signzone</SPAN
>&nbsp;--&nbsp;DNSSEC zone signing tool</DIV
><DIV
CLASS="REFSYNOPSISDIV"
><A
NAME="AEN13"
></A
><H2
>Synopsis</H2
><P
><B
CLASS="COMMAND"
>dnssec-signzone</B
> [<VAR
CLASS="OPTION"
>-a</VAR
>] [<VAR
CLASS="OPTION"
>-c <VAR
CLASS="REPLACEABLE"
>class</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-d <VAR
CLASS="REPLACEABLE"
>directory</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-e <VAR
CLASS="REPLACEABLE"
>end-time</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-f <VAR
CLASS="REPLACEABLE"
>output-file</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-g</VAR
>] [<VAR
CLASS="OPTION"
>-h</VAR
>] [<VAR
CLASS="OPTION"
>-k <VAR
CLASS="REPLACEABLE"
>key</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-l <VAR
CLASS="REPLACEABLE"
>domain</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-i <VAR
CLASS="REPLACEABLE"
>interval</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-n <VAR
CLASS="REPLACEABLE"
>nthreads</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-o <VAR
CLASS="REPLACEABLE"
>origin</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-p</VAR
>] [<VAR
CLASS="OPTION"
>-r <VAR
CLASS="REPLACEABLE"
>randomdev</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-s <VAR
CLASS="REPLACEABLE"
>start-time</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-t</VAR
>] [<VAR
CLASS="OPTION"
>-v <VAR
CLASS="REPLACEABLE"
>level</VAR
></VAR
>] [<VAR
CLASS="OPTION"
>-z</VAR
>] {zonefile} [key...]</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN66"
></A
><H2
>DESCRIPTION</H2
><P
> <B
CLASS="COMMAND"
>dnssec-signzone</B
> signs a zone. It generates
<!-- $Id: dnssec-signzone.html,v 1.4.2.1.4.16 2006/06/29 13:02:30 marka Exp $ -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>dnssec-signzone</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.70.1">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="refentry" lang="en">
<a name="id2482688"></a><div class="titlepage"></div>
<div class="refnamediv">
<h2>Name</h2>
<p><span class="application">dnssec-signzone</span> &#8212; DNSSEC zone signing tool</p>
</div>
<div class="refsynopsisdiv">
<h2>Synopsis</h2>
<div class="cmdsynopsis"><p><code class="command">dnssec-signzone</code> [<code class="option">-a</code>] [<code class="option">-c <em class="replaceable"><code>class</code></em></code>] [<code class="option">-d <em class="replaceable"><code>directory</code></em></code>] [<code class="option">-e <em class="replaceable"><code>end-time</code></em></code>] [<code class="option">-f <em class="replaceable"><code>output-file</code></em></code>] [<code class="option">-g</code>] [<code class="option">-h</code>] [<code class="option">-k <em class="replaceable"><code>key</code></em></code>] [<code class="option">-l <em class="replaceable"><code>domain</code></em></code>] [<code class="option">-i <em class="replaceable"><code>interval</code></em></code>] [<code class="option">-n <em class="replaceable"><code>nthreads</code></em></code>] [<code class="option">-o <em class="replaceable"><code>origin</code></em></code>] [<code class="option">-p</code>] [<code class="option">-r <em class="replaceable"><code>randomdev</code></em></code>] [<code class="option">-s <em class="replaceable"><code>start-time</code></em></code>] [<code class="option">-t</code>] [<code class="option">-v <em class="replaceable"><code>level</code></em></code>] [<code class="option">-z</code>] {zonefile} [key...]</p></div>
</div>
<div class="refsect1" lang="en">
<a name="id2549544"></a><h2>DESCRIPTION</h2>
<p>
<span><strong class="command">dnssec-signzone</strong></span> signs a zone. It generates
NSEC and RRSIG records and produces a signed version of the
zone. The security status of delegations from the signed zone
(that is, whether the child zones are secure or not) is
determined by the presence or absence of a
<TT
CLASS="FILENAME"
>keyset</TT
> file for each child zone.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN71"
></A
><H2
>OPTIONS</H2
><P
></P
><DIV
CLASS="VARIABLELIST"
><DL
><DT
>-a</DT
><DD
><P
> Verify all generated signatures.
</P
></DD
><DT
>-c <VAR
CLASS="REPLACEABLE"
>class</VAR
></DT
><DD
><P
> Specifies the DNS class of the zone.
</P
></DD
><DT
>-k <VAR
CLASS="REPLACEABLE"
>key</VAR
></DT
><DD
><P
> Treat specified key as a key signing key ignoring any
<code class="filename">keyset</code> file for each child zone.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2549560"></a><h2>OPTIONS</h2>
<div class="variablelist"><dl>
<dt><span class="term">-a</span></dt>
<dd><p>
Verify all generated signatures.
</p></dd>
<dt><span class="term">-c <em class="replaceable"><code>class</code></em></span></dt>
<dd><p>
Specifies the DNS class of the zone.
</p></dd>
<dt><span class="term">-k <em class="replaceable"><code>key</code></em></span></dt>
<dd><p>
Treat specified key as a key signing key ignoring any
key flags. This option may be specified multiple times.
</P
></DD
><DT
>-l <VAR
CLASS="REPLACEABLE"
>domain</VAR
></DT
><DD
><P
> Generate a DLV set in addition to the key (DNSKEY) and DS sets.
</p></dd>
<dt><span class="term">-l <em class="replaceable"><code>domain</code></em></span></dt>
<dd><p>
Generate a DLV set in addition to the key (DNSKEY) and DS sets.
The domain is appended to the name of the records.
</P
></DD
><DT
>-d <VAR
CLASS="REPLACEABLE"
>directory</VAR
></DT
><DD
><P
> Look for <TT
CLASS="FILENAME"
>keyset</TT
> files in
<VAR
CLASS="OPTION"
>directory</VAR
> as the directory
</P
></DD
><DT
>-g</DT
><DD
><P
> Generate DS records for child zones from keyset files.
</p></dd>
<dt><span class="term">-d <em class="replaceable"><code>directory</code></em></span></dt>
<dd><p>
Look for <code class="filename">keyset</code> files in
<code class="option">directory</code> as the directory
</p></dd>
<dt><span class="term">-g</span></dt>
<dd><p>
Generate DS records for child zones from keyset files.
Existing DS records will be removed.
</P
></DD
><DT
>-s <VAR
CLASS="REPLACEABLE"
>start-time</VAR
></DT
><DD
><P
> Specify the date and time when the generated RRSIG records
</p></dd>
<dt><span class="term">-s <em class="replaceable"><code>start-time</code></em></span></dt>
<dd><p>
Specify the date and time when the generated RRSIG records
become valid. This can be either an absolute or relative
time. An absolute start time is indicated by a number
in YYYYMMDDHHMMSS notation; 20000530144500 denotes
14:45:00 UTC on May 30th, 2000. A relative start time is
indicated by +N, which is N seconds from the current time.
If no <VAR
CLASS="OPTION"
>start-time</VAR
> is specified, the current
If no <code class="option">start-time</code> is specified, the current
time minus 1 hour (to allow for clock skew) is used.
</P
></DD
><DT
>-e <VAR
CLASS="REPLACEABLE"
>end-time</VAR
></DT
><DD
><P
> Specify the date and time when the generated RRSIG records
expire. As with <VAR
CLASS="OPTION"
>start-time</VAR
>, an absolute
</p></dd>
<dt><span class="term">-e <em class="replaceable"><code>end-time</code></em></span></dt>
<dd><p>
Specify the date and time when the generated RRSIG records
expire. As with <code class="option">start-time</code>, an absolute
time is indicated in YYYYMMDDHHMMSS notation. A time relative
to the start time is indicated with +N, which is N seconds from
the start time. A time relative to the current time is
indicated with now+N. If no <VAR
CLASS="OPTION"
>end-time</VAR
> is
indicated with now+N. If no <code class="option">end-time</code> is
specified, 30 days from the start time is used as a default.
</P
></DD
><DT
>-f <VAR
CLASS="REPLACEABLE"
>output-file</VAR
></DT
><DD
><P
> The name of the output file containing the signed zone. The
default is to append <TT
CLASS="FILENAME"
>.signed</TT
> to the
</p></dd>
<dt><span class="term">-f <em class="replaceable"><code>output-file</code></em></span></dt>
<dd><p>
The name of the output file containing the signed zone. The
default is to append <code class="filename">.signed</code> to the
input file.
</P
></DD
><DT
>-h</DT
><DD
><P
> Prints a short summary of the options and arguments to
<B
CLASS="COMMAND"
>dnssec-signzone</B
>.
</P
></DD
><DT
>-i <VAR
CLASS="REPLACEABLE"
>interval</VAR
></DT
><DD
><P
> When a previously signed zone is passed as input, records
may be resigned. The <VAR
CLASS="OPTION"
>interval</VAR
> option
</p></dd>
<dt><span class="term">-h</span></dt>
<dd><p>
Prints a short summary of the options and arguments to
<span><strong class="command">dnssec-signzone</strong></span>.
</p></dd>
<dt><span class="term">-i <em class="replaceable"><code>interval</code></em></span></dt>
<dd>
<p>
When a previously signed zone is passed as input, records
may be resigned. The <code class="option">interval</code> option
specifies the cycle interval as an offset from the current
time (in seconds). If a RRSIG record expires after the
cycle interval, it is retained. Otherwise, it is considered
to be expiring soon, and it will be replaced.
</P
><P
> The default cycle interval is one quarter of the difference
</p>
<p>
The default cycle interval is one quarter of the difference
between the signature end and start times. So if neither
<VAR
CLASS="OPTION"
>end-time</VAR
> or <VAR
CLASS="OPTION"
>start-time</VAR
>
are specified, <B
CLASS="COMMAND"
>dnssec-signzone</B
> generates
<code class="option">end-time</code> or <code class="option">start-time</code>
are specified, <span><strong class="command">dnssec-signzone</strong></span> generates
signatures that are valid for 30 days, with a cycle
interval of 7.5 days. Therefore, if any existing RRSIG records
are due to expire in less than 7.5 days, they would be
replaced.
</P
></DD
><DT
>-n <VAR
CLASS="REPLACEABLE"
>ncpus</VAR
></DT
><DD
><P
> Specifies the number of threads to use. By default, one
</p>
</dd>
<dt><span class="term">-n <em class="replaceable"><code>ncpus</code></em></span></dt>
<dd><p>
Specifies the number of threads to use. By default, one
thread is started for each detected CPU.
</P
></DD
><DT
>-o <VAR
CLASS="REPLACEABLE"
>origin</VAR
></DT
><DD
><P
> The zone origin. If not specified, the name of the zone file
</p></dd>
<dt><span class="term">-o <em class="replaceable"><code>origin</code></em></span></dt>
<dd><p>
The zone origin. If not specified, the name of the zone file
is assumed to be the origin.
</P
></DD
><DT
>-p</DT
><DD
><P
> Use pseudo-random data when signing the zone. This is faster,
</p></dd>
<dt><span class="term">-p</span></dt>
<dd><p>
Use pseudo-random data when signing the zone. This is faster,
but less secure, than using real random data. This option
may be useful when signing large zones or when the entropy
source is limited.
</P
></DD
><DT
>-r <VAR
CLASS="REPLACEABLE"
>randomdev</VAR
></DT
><DD
><P
> Specifies the source of randomness. If the operating
system does not provide a <TT
CLASS="FILENAME"
>/dev/random</TT
>
</p></dd>
<dt><span class="term">-r <em class="replaceable"><code>randomdev</code></em></span></dt>
<dd><p>
Specifies the source of randomness. If the operating
system does not provide a <code class="filename">/dev/random</code>
or equivalent device, the default source of randomness
is keyboard input. <TT
CLASS="FILENAME"
>randomdev</TT
> specifies
is keyboard input. <code class="filename">randomdev</code> specifies
the name of a character device or file containing random
data to be used instead of the default. The special value
<TT
CLASS="FILENAME"
>keyboard</TT
> indicates that keyboard
<code class="filename">keyboard</code> indicates that keyboard
input should be used.
</P
></DD
><DT
>-t</DT
><DD
><P
> Print statistics at completion.
</P
></DD
><DT
>-v <VAR
CLASS="REPLACEABLE"
>level</VAR
></DT
><DD
><P
> Sets the debugging level.
</P
></DD
><DT
>-z</DT
><DD
><P
> Ignore KSK flag on key when determining what to sign.
</P
></DD
><DT
>zonefile</DT
><DD
><P
> The file containing the zone to be signed.
</p></dd>
<dt><span class="term">-t</span></dt>
<dd><p>
Print statistics at completion.
</p></dd>
<dt><span class="term">-v <em class="replaceable"><code>level</code></em></span></dt>
<dd><p>
Sets the debugging level.
</P
></DD
><DT
>key</DT
><DD
><P
> The keys used to sign the zone. If no keys are specified, the
</p></dd>
<dt><span class="term">-z</span></dt>
<dd><p>
Ignore KSK flag on key when determining what to sign.
</p></dd>
<dt><span class="term">zonefile</span></dt>
<dd><p>
The file containing the zone to be signed.
</p></dd>
<dt><span class="term">key</span></dt>
<dd><p>
The keys used to sign the zone. If no keys are specified, the
default all zone keys that have private key files in the
current directory.
</P
></DD
></DL
></DIV
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN181"
></A
><H2
>EXAMPLE</H2
><P
> The following command signs the <KBD
CLASS="USERINPUT"
>example.com</KBD
>
zone with the DSA key generated in the <B
CLASS="COMMAND"
>dnssec-keygen</B
>
</p></dd>
</dl></div>
</div>
<div class="refsect1" lang="en">
<a name="id2550068"></a><h2>EXAMPLE</h2>
<p>
The following command signs the <strong class="userinput"><code>example.com</code></strong>
zone with the DSA key generated in the <span><strong class="command">dnssec-keygen</strong></span>
man page. The zone's keys must be in the zone. If there are
<TT
CLASS="FILENAME"
>keyset</TT
> files associated with child zones,
<code class="filename">keyset</code> files associated with child zones,
they must be in the current directory.
<KBD
CLASS="USERINPUT"
>example.com</KBD
>, the following command would be
<strong class="userinput"><code>example.com</code></strong>, the following command would be
issued:
</P
><P
> <KBD
CLASS="USERINPUT"
>dnssec-signzone -o example.com db.example.com Kexample.com.+003+26160</KBD
>
</P
><P
> The command would print a string of the form:
</P
><P
> In this example, <B
CLASS="COMMAND"
>dnssec-signzone</B
> creates
the file <TT
CLASS="FILENAME"
>db.example.com.signed</TT
>. This file
</p>
<p>
<strong class="userinput"><code>dnssec-signzone -o example.com db.example.com Kexample.com.+003+26160</code></strong>
</p>
<p>
The command would print a string of the form:
</p>
<p>
In this example, <span><strong class="command">dnssec-signzone</strong></span> creates
the file <code class="filename">db.example.com.signed</code>. This file
should be referenced in a zone statement in a
<TT
CLASS="FILENAME"
>named.conf</TT
> file.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN195"
></A
><H2
>SEE ALSO</H2
><P
> <SPAN
CLASS="CITEREFENTRY"
><SPAN
CLASS="REFENTRYTITLE"
>dnssec-keygen</SPAN
>(8)</SPAN
>,
<I
CLASS="CITETITLE"
>BIND 9 Administrator Reference Manual</I
>,
<I
CLASS="CITETITLE"
>RFC 2535</I
>.
</P
></DIV
><DIV
CLASS="REFSECT1"
><A
NAME="AEN203"
></A
><H2
>AUTHOR</H2
><P
> Internet Systems Consortium
</P
></DIV
></BODY
></HTML
>
<code class="filename">named.conf</code> file.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2550118"></a><h2>SEE ALSO</h2>
<p>
<span class="citerefentry"><span class="refentrytitle">dnssec-keygen</span>(8)</span>,
<em class="citetitle">BIND 9 Administrator Reference Manual</em>,
<em class="citetitle">RFC 2535</em>.
</p>
</div>
<div class="refsect1" lang="en">
<a name="id2550145"></a><h2>AUTHOR</h2>
<p>
<span class="corpauthor">Internet Systems Consortium</span>
</p>
</div>
</div></body>
</html>
+4 -2
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2000, 2001, 2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: dnssectool.c,v 1.31.2.3.2.4 2004/03/08 02:07:38 marka Exp $ */
/* $Id: dnssectool.c,v 1.31.2.3.2.6 2005/07/02 02:42:43 marka Exp $ */
#include <config.h>
@@ -145,6 +145,8 @@ setup_logging(int verbose, isc_mem_t *mctx, isc_log_t **logp) {
isc_log_t *log = NULL;
int level;
if (verbose < 0)
verbose = 0;
switch (verbose) {
case 0:
/*
+34 -15
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: aclconf.c,v 1.27.12.3 2004/03/08 04:04:18 marka Exp $ */
/* $Id: aclconf.c,v 1.27.12.7 2006/03/02 00:37:20 marka Exp $ */
#include <config.h>
@@ -31,6 +31,8 @@
#include <named/aclconf.h>
#define LOOP_MAGIC ISC_MAGIC('L','O','O','P')
void
ns_aclconfctx_init(ns_aclconfctx_t *ctx) {
ISC_LIST_INIT(ctx->named_acl_cache);
@@ -52,10 +54,10 @@ ns_aclconfctx_destroy(ns_aclconfctx_t *ctx) {
* Find the definition of the named acl whose name is "name".
*/
static isc_result_t
get_acl_def(cfg_obj_t *cctx, char *name, cfg_obj_t **ret) {
get_acl_def(const cfg_obj_t *cctx, const char *name, const cfg_obj_t **ret) {
isc_result_t result;
cfg_obj_t *acls = NULL;
cfg_listelt_t *elt;
const cfg_obj_t *acls = NULL;
const cfg_listelt_t *elt;
result = cfg_map_get(cctx, "acl", &acls);
if (result != ISC_R_SUCCESS)
@@ -63,7 +65,7 @@ get_acl_def(cfg_obj_t *cctx, char *name, cfg_obj_t **ret) {
for (elt = cfg_list_first(acls);
elt != NULL;
elt = cfg_list_next(elt)) {
cfg_obj_t *acl = cfg_listelt_value(elt);
const cfg_obj_t *acl = cfg_listelt_value(elt);
const char *aclname = cfg_obj_asstring(cfg_tuple_get(acl, "name"));
if (strcasecmp(aclname, name) == 0) {
*ret = cfg_tuple_get(acl, "value");
@@ -74,14 +76,15 @@ get_acl_def(cfg_obj_t *cctx, char *name, cfg_obj_t **ret) {
}
static isc_result_t
convert_named_acl(cfg_obj_t *nameobj, cfg_obj_t *cctx,
convert_named_acl(const cfg_obj_t *nameobj, const cfg_obj_t *cctx,
ns_aclconfctx_t *ctx, isc_mem_t *mctx,
dns_acl_t **target)
{
isc_result_t result;
cfg_obj_t *cacl = NULL;
const cfg_obj_t *cacl = NULL;
dns_acl_t *dacl;
char *aclname = cfg_obj_asstring(nameobj);
dns_acl_t loop;
const char *aclname = cfg_obj_asstring(nameobj);
/* Look for an already-converted version. */
for (dacl = ISC_LIST_HEAD(ctx->named_acl_cache);
@@ -89,6 +92,11 @@ convert_named_acl(cfg_obj_t *nameobj, cfg_obj_t *cctx,
dacl = ISC_LIST_NEXT(dacl, nextincache))
{
if (strcasecmp(aclname, dacl->name) == 0) {
if (ISC_MAGIC_VALID(dacl, LOOP_MAGIC)) {
cfg_obj_log(nameobj, dns_lctx, ISC_LOG_ERROR,
"acl loop detected: %s", aclname);
return (ISC_R_FAILURE);
}
dns_acl_attach(dacl, target);
return (ISC_R_SUCCESS);
}
@@ -100,7 +108,18 @@ convert_named_acl(cfg_obj_t *nameobj, cfg_obj_t *cctx,
"undefined ACL '%s'", aclname);
return (result);
}
/*
* Add a loop detection element.
*/
memset(&loop, 0, sizeof(loop));
ISC_LINK_INIT(&loop, nextincache);
DE_CONST(aclname, loop.name);
loop.magic = LOOP_MAGIC;
ISC_LIST_APPEND(ctx->named_acl_cache, &loop, nextincache);
result = ns_acl_fromconfig(cacl, cctx, ctx, mctx, &dacl);
ISC_LIST_UNLINK(ctx->named_acl_cache, &loop, nextincache);
loop.magic = 0;
loop.name = NULL;
if (result != ISC_R_SUCCESS)
return (result);
dacl->name = isc_mem_strdup(dacl->mctx, aclname);
@@ -112,7 +131,7 @@ convert_named_acl(cfg_obj_t *nameobj, cfg_obj_t *cctx,
}
static isc_result_t
convert_keyname(cfg_obj_t *keyobj, isc_mem_t *mctx, dns_name_t *dnsname) {
convert_keyname(const cfg_obj_t *keyobj, isc_mem_t *mctx, dns_name_t *dnsname) {
isc_result_t result;
isc_buffer_t buf;
dns_fixedname_t fixname;
@@ -135,8 +154,8 @@ convert_keyname(cfg_obj_t *keyobj, isc_mem_t *mctx, dns_name_t *dnsname) {
}
isc_result_t
ns_acl_fromconfig(cfg_obj_t *caml,
cfg_obj_t *cctx,
ns_acl_fromconfig(const cfg_obj_t *caml,
const cfg_obj_t *cctx,
ns_aclconfctx_t *ctx,
isc_mem_t *mctx,
dns_acl_t **target)
@@ -145,7 +164,7 @@ ns_acl_fromconfig(cfg_obj_t *caml,
unsigned int count;
dns_acl_t *dacl = NULL;
dns_aclelement_t *de;
cfg_listelt_t *elt;
const cfg_listelt_t *elt;
REQUIRE(target != NULL && *target == NULL);
@@ -164,7 +183,7 @@ ns_acl_fromconfig(cfg_obj_t *caml,
elt != NULL;
elt = cfg_list_next(elt))
{
cfg_obj_t *ce = cfg_listelt_value(elt);
const cfg_obj_t *ce = cfg_listelt_value(elt);
if (cfg_obj_istuple(ce)) {
/* This must be a negated element. */
ce = cfg_tuple_get(ce, "value");
@@ -196,7 +215,7 @@ ns_acl_fromconfig(cfg_obj_t *caml,
goto cleanup;
} else if (cfg_obj_isstring(ce)) {
/* ACL name */
char *name = cfg_obj_asstring(ce);
const char *name = cfg_obj_asstring(ce);
if (strcasecmp(name, "localhost") == 0) {
de->type = dns_aclelementtype_localhost;
} else if (strcasecmp(name, "localnets") == 0) {
+128 -18
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: client.c,v 1.176.2.13.4.23 2004/09/26 22:37:43 marka Exp $ */
/* $Id: client.c,v 1.176.2.13.4.31.6.1 2007/06/26 04:14:55 marka Exp $ */
#include <config.h>
@@ -164,6 +164,12 @@ struct ns_clientmgr {
* Must be greater than any valid state.
*/
/*
* Enable ns_client_dropport() by default.
*/
#ifndef NS_CLIENT_DROPPORT
#define NS_CLIENT_DROPPORT 1
#endif
static void client_read(ns_client_t *client);
static void client_accept(ns_client_t *client);
@@ -177,23 +183,29 @@ static void client_request(isc_task_t *task, isc_event_t *event);
static void ns_client_dumpmessage(ns_client_t *client, const char *reason);
void
ns_client_recursing(ns_client_t *client, isc_boolean_t killoldest) {
ns_client_recursing(ns_client_t *client) {
REQUIRE(NS_CLIENT_VALID(client));
LOCK(&client->manager->lock);
ISC_LIST_UNLINK(*client->list, client, link);
ISC_LIST_APPEND(client->manager->recursing, client, link);
client->list = &client->manager->recursing;
UNLOCK(&client->manager->lock);
}
void
ns_client_killoldestquery(ns_client_t *client) {
ns_client_t *oldest;
REQUIRE(NS_CLIENT_VALID(client));
LOCK(&client->manager->lock);
if (killoldest) {
oldest = ISC_LIST_HEAD(client->manager->recursing);
if (oldest != NULL) {
ns_query_cancel(oldest);
ISC_LIST_UNLINK(*oldest->list, oldest, link);
ISC_LIST_APPEND(client->manager->active, oldest, link);
oldest->list = &client->manager->active;
}
oldest = ISC_LIST_HEAD(client->manager->recursing);
if (oldest != NULL) {
ns_query_cancel(oldest);
ISC_LIST_UNLINK(*oldest->list, oldest, link);
ISC_LIST_APPEND(client->manager->active, oldest, link);
oldest->list = &client->manager->active;
}
ISC_LIST_UNLINK(*client->list, client, link);
ISC_LIST_APPEND(client->manager->recursing, client, link);
client->list = &client->manager->recursing;
UNLOCK(&client->manager->lock);
}
@@ -279,8 +291,17 @@ exit_check(ns_client_t *client) {
}
/*
* I/O cancel is complete. Burn down all state
* related to the current request.
* related to the current request. Ensure that
* the client is on the active list and not the
* recursing list.
*/
LOCK(&client->manager->lock);
if (client->list == &client->manager->recursing) {
ISC_LIST_UNLINK(*client->list, client, link);
ISC_LIST_APPEND(client->manager->active, client, link);
client->list = &client->manager->active;
}
UNLOCK(&client->manager->lock);
ns_client_endrequest(client);
client->state = NS_CLIENTSTATE_READING;
@@ -966,6 +987,34 @@ ns_client_send(ns_client_t *client) {
ns_client_next(client, result);
}
#if NS_CLIENT_DROPPORT
#define DROPPORT_NO 0
#define DROPPORT_REQUEST 1
#define DROPPORT_RESPONSE 2
/*%
* ns_client_dropport determines if certain requests / responses
* should be dropped based on the port number.
*
* Returns:
* \li 0: Don't drop.
* \li 1: Drop request.
* \li 2: Drop (error) response.
*/
static int
ns_client_dropport(in_port_t port) {
switch (port) {
case 7: /* echo */
case 13: /* daytime */
case 19: /* chargen */
case 37: /* time */
return (DROPPORT_REQUEST);
case 464: /* kpasswd */
return (DROPPORT_RESPONSE);
}
return (DROPPORT_NO);
}
#endif
void
ns_client_error(ns_client_t *client, isc_result_t result) {
dns_rcode_t rcode;
@@ -978,6 +1027,28 @@ ns_client_error(ns_client_t *client, isc_result_t result) {
message = client->message;
rcode = dns_result_torcode(result);
#if NS_CLIENT_DROPPORT
/*
* Don't send FORMERR to ports on the drop port list.
*/
if (rcode == dns_rcode_formerr &&
ns_client_dropport(isc_sockaddr_getport(&client->peeraddr)) !=
DROPPORT_NO) {
char buf[64];
isc_buffer_t b;
isc_buffer_init(&b, buf, sizeof(buf) - 1);
if (dns_rcode_totext(rcode, &b) != ISC_R_SUCCESS)
isc_buffer_putstr(&b, "UNKNOWN RCODE");
ns_client_log(client, DNS_LOGCATEGORY_SECURITY,
NS_LOGMODULE_CLIENT, ISC_LOG_DEBUG(10),
"dropped error (%.*s) response: suspicious port",
(int)isc_buffer_usedlength(&b), buf);
ns_client_next(client, ISC_R_SUCCESS);
return;
}
#endif
/*
* Message may be an in-progress reply that we had trouble
* with, in which case QR will be set. We need to clear QR before
@@ -1202,6 +1273,17 @@ client_request(isc_task_t *task, isc_event_t *event) {
isc_netaddr_fromsockaddr(&netaddr, &client->peeraddr);
#if NS_CLIENT_DROPPORT
if (ns_client_dropport(isc_sockaddr_getport(&client->peeraddr)) ==
DROPPORT_REQUEST) {
ns_client_log(client, DNS_LOGCATEGORY_SECURITY,
NS_LOGMODULE_CLIENT, ISC_LOG_DEBUG(10),
"dropped request: suspicious port");
ns_client_next(client, ISC_R_SUCCESS);
goto cleanup;
}
#endif
ns_client_log(client, NS_LOGCATEGORY_CLIENT,
NS_LOGMODULE_CLIENT, ISC_LOG_DEBUG(3),
"%s request",
@@ -1236,6 +1318,7 @@ client_request(isc_task_t *task, isc_event_t *event) {
NS_LOGMODULE_CLIENT, ISC_LOG_DEBUG(2),
"dropping multicast request");
ns_client_next(client, DNS_R_REFUSED);
goto cleanup;
}
result = dns_message_peekheader(buffer, &id, &flags);
@@ -1265,6 +1348,14 @@ client_request(isc_task_t *task, isc_event_t *event) {
}
}
/*
* Hash the incoming request here as it is after
* dns_dispatch_importrecv().
*/
dns_dispatch_hash(&client->now, sizeof(client->now));
dns_dispatch_hash(isc_buffer_base(buffer),
isc_buffer_usedlength(buffer));
/*
* It's a request. Parse it.
*/
@@ -1526,12 +1617,15 @@ client_request(isc_task_t *task, isc_event_t *event) {
* Decide whether recursive service is available to this client.
* We do this here rather than in the query code so that we can
* set the RA bit correctly on all kinds of responses, not just
* responses to ordinary queries.
* responses to ordinary queries. Note if you can't query the
* cache there is no point in setting RA.
*/
ra = ISC_FALSE;
if (client->view->resolver != NULL &&
client->view->recursion == ISC_TRUE &&
ns_client_checkaclsilent(client, client->view->recursionacl,
ISC_TRUE) == ISC_R_SUCCESS &&
ns_client_checkaclsilent(client, client->view->queryacl,
ISC_TRUE) == ISC_R_SUCCESS)
ra = ISC_TRUE;
@@ -1603,8 +1697,7 @@ client_timeout(isc_task_t *task, isc_event_t *event) {
}
static isc_result_t
client_create(ns_clientmgr_t *manager, ns_client_t **clientp)
{
client_create(ns_clientmgr_t *manager, ns_client_t **clientp) {
ns_client_t *client;
isc_result_t result;
@@ -2359,3 +2452,20 @@ ns_client_dumprecursing(FILE *f, ns_clientmgr_t *manager) {
}
UNLOCK(&manager->lock);
}
void
ns_client_qnamereplace(ns_client_t *client, dns_name_t *name) {
if (client->manager != NULL)
LOCK(&client->manager->lock);
if (client->query.restarts > 0) {
/*
* client->query.qname was dynamically allocated.
*/
dns_message_puttempname(client->message,
&client->query.qname);
}
client->query.qname = name;
if (client->manager != NULL)
UNLOCK(&client->manager->lock);
}
+51 -46
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2001-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: config.c,v 1.11.2.4.8.29 2004/10/05 02:52:26 marka Exp $ */
/* $Id: config.c,v 1.11.2.4.8.32 2006/02/28 06:32:53 marka Exp $ */
#include <config.h>
@@ -196,7 +196,7 @@ ns_config_parsedefaults(cfg_parser_t *parser, cfg_obj_t **conf) {
}
isc_result_t
ns_config_get(cfg_obj_t **maps, const char *name, cfg_obj_t **obj) {
ns_config_get(const cfg_obj_t **maps, const char *name, const cfg_obj_t **obj) {
int i;
for (i = 0;; i++) {
@@ -208,11 +208,13 @@ ns_config_get(cfg_obj_t **maps, const char *name, cfg_obj_t **obj) {
}
isc_result_t
ns_checknames_get(cfg_obj_t **maps, const char *which, cfg_obj_t **obj) {
cfg_listelt_t *element;
cfg_obj_t *checknames;
cfg_obj_t *type;
cfg_obj_t *value;
ns_checknames_get(const cfg_obj_t **maps, const char *which,
const cfg_obj_t **obj)
{
const cfg_listelt_t *element;
const cfg_obj_t *checknames;
const cfg_obj_t *type;
const cfg_obj_t *value;
int i;
for (i = 0;; i++) {
@@ -243,8 +245,8 @@ ns_checknames_get(cfg_obj_t **maps, const char *which, cfg_obj_t **obj) {
}
int
ns_config_listcount(cfg_obj_t *list) {
cfg_listelt_t *e;
ns_config_listcount(const cfg_obj_t *list) {
const cfg_listelt_t *e;
int i = 0;
for (e = cfg_list_first(list); e != NULL; e = cfg_list_next(e))
@@ -254,9 +256,9 @@ ns_config_listcount(cfg_obj_t *list) {
}
isc_result_t
ns_config_getclass(cfg_obj_t *classobj, dns_rdataclass_t defclass,
ns_config_getclass(const cfg_obj_t *classobj, dns_rdataclass_t defclass,
dns_rdataclass_t *classp) {
char *str;
const char *str;
isc_textregion_t r;
isc_result_t result;
@@ -265,7 +267,7 @@ ns_config_getclass(cfg_obj_t *classobj, dns_rdataclass_t defclass,
return (ISC_R_SUCCESS);
}
str = cfg_obj_asstring(classobj);
r.base = str;
DE_CONST(str, r.base);
r.length = strlen(str);
result = dns_rdataclass_fromtext(classp, &r);
if (result != ISC_R_SUCCESS)
@@ -275,9 +277,9 @@ ns_config_getclass(cfg_obj_t *classobj, dns_rdataclass_t defclass,
}
isc_result_t
ns_config_gettype(cfg_obj_t *typeobj, dns_rdatatype_t deftype,
ns_config_gettype(const cfg_obj_t *typeobj, dns_rdatatype_t deftype,
dns_rdatatype_t *typep) {
char *str;
const char *str;
isc_textregion_t r;
isc_result_t result;
@@ -286,7 +288,7 @@ ns_config_gettype(cfg_obj_t *typeobj, dns_rdatatype_t deftype,
return (ISC_R_SUCCESS);
}
str = cfg_obj_asstring(typeobj);
r.base = str;
DE_CONST(str, r.base);
r.length = strlen(str);
result = dns_rdatatype_fromtext(typep, &r);
if (result != ISC_R_SUCCESS)
@@ -296,9 +298,9 @@ ns_config_gettype(cfg_obj_t *typeobj, dns_rdatatype_t deftype,
}
dns_zonetype_t
ns_config_getzonetype(cfg_obj_t *zonetypeobj) {
ns_config_getzonetype(const cfg_obj_t *zonetypeobj) {
dns_zonetype_t ztype = dns_zone_none;
char *str;
const char *str;
str = cfg_obj_asstring(zonetypeobj);
if (strcasecmp(str, "master") == 0)
@@ -313,14 +315,14 @@ ns_config_getzonetype(cfg_obj_t *zonetypeobj) {
}
isc_result_t
ns_config_getiplist(cfg_obj_t *config, cfg_obj_t *list,
ns_config_getiplist(const cfg_obj_t *config, const cfg_obj_t *list,
in_port_t defport, isc_mem_t *mctx,
isc_sockaddr_t **addrsp, isc_uint32_t *countp)
{
int count, i = 0;
cfg_obj_t *addrlist;
cfg_obj_t *portobj;
cfg_listelt_t *element;
const cfg_obj_t *addrlist;
const cfg_obj_t *portobj;
const cfg_listelt_t *element;
isc_sockaddr_t *addrs;
in_port_t port;
isc_result_t result;
@@ -380,10 +382,12 @@ ns_config_putiplist(isc_mem_t *mctx, isc_sockaddr_t **addrsp,
}
static isc_result_t
get_masters_def(cfg_obj_t *cctx, char *name, cfg_obj_t **ret) {
get_masters_def(const cfg_obj_t *cctx, const char *name,
const cfg_obj_t **ret)
{
isc_result_t result;
cfg_obj_t *masters = NULL;
cfg_listelt_t *elt;
const cfg_obj_t *masters = NULL;
const cfg_listelt_t *elt;
result = cfg_map_get(cctx, "masters", &masters);
if (result != ISC_R_SUCCESS)
@@ -391,7 +395,7 @@ get_masters_def(cfg_obj_t *cctx, char *name, cfg_obj_t **ret) {
for (elt = cfg_list_first(masters);
elt != NULL;
elt = cfg_list_next(elt)) {
cfg_obj_t *list;
const cfg_obj_t *list;
const char *listname;
list = cfg_listelt_value(elt);
@@ -406,24 +410,24 @@ get_masters_def(cfg_obj_t *cctx, char *name, cfg_obj_t **ret) {
}
isc_result_t
ns_config_getipandkeylist(cfg_obj_t *config, cfg_obj_t *list, isc_mem_t *mctx,
isc_sockaddr_t **addrsp, dns_name_t ***keysp,
isc_uint32_t *countp)
ns_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
isc_mem_t *mctx, isc_sockaddr_t **addrsp,
dns_name_t ***keysp, isc_uint32_t *countp)
{
isc_uint32_t addrcount = 0, keycount = 0, i = 0;
isc_uint32_t listcount = 0, l = 0, j;
isc_uint32_t stackcount = 0, pushed = 0;
isc_result_t result;
cfg_listelt_t *element;
cfg_obj_t *addrlist;
cfg_obj_t *portobj;
const cfg_listelt_t *element;
const cfg_obj_t *addrlist;
const cfg_obj_t *portobj;
in_port_t port;
dns_fixedname_t fname;
isc_sockaddr_t *addrs = NULL;
dns_name_t **keys = NULL;
char **lists = NULL;
const char **lists = NULL;
struct {
cfg_listelt_t *element;
const cfg_listelt_t *element;
in_port_t port;
} *stack = NULL;
@@ -439,13 +443,14 @@ ns_config_getipandkeylist(cfg_obj_t *config, cfg_obj_t *list, isc_mem_t *mctx,
if (val > ISC_UINT16_MAX) {
cfg_obj_log(portobj, ns_g_lctx, ISC_LOG_ERROR,
"port '%u' out of range", val);
return (ISC_R_RANGE);
result = ISC_R_RANGE;
goto cleanup;
}
port = (in_port_t) val;
} else {
result = ns_config_getport(config, &port);
if (result != ISC_R_SUCCESS)
return (result);
goto cleanup;
}
result = ISC_R_NOMEMORY;
@@ -456,9 +461,9 @@ ns_config_getipandkeylist(cfg_obj_t *config, cfg_obj_t *list, isc_mem_t *mctx,
element != NULL;
element = cfg_list_next(element))
{
cfg_obj_t *addr;
cfg_obj_t *key;
char *keystr;
const cfg_obj_t *addr;
const cfg_obj_t *key;
const char *keystr;
isc_buffer_t b;
addr = cfg_tuple_get(cfg_listelt_value(element),
@@ -466,7 +471,7 @@ ns_config_getipandkeylist(cfg_obj_t *config, cfg_obj_t *list, isc_mem_t *mctx,
key = cfg_tuple_get(cfg_listelt_value(element), "key");
if (!cfg_obj_issockaddr(addr)) {
char *listname = cfg_obj_asstring(addr);
const char *listname = cfg_obj_asstring(addr);
isc_result_t tresult;
/* Grow lists? */
@@ -606,9 +611,9 @@ ns_config_getipandkeylist(cfg_obj_t *config, cfg_obj_t *list, isc_mem_t *mctx,
if (new == NULL)
goto cleanup;
memcpy(new, addrs, newsize);
isc_mem_put(mctx, addrs, oldsize);
} else
new = NULL;
isc_mem_put(mctx, addrs, oldsize);
addrs = new;
addrcount = i;
@@ -619,9 +624,9 @@ ns_config_getipandkeylist(cfg_obj_t *config, cfg_obj_t *list, isc_mem_t *mctx,
if (new == NULL)
goto cleanup;
memcpy(new, keys, newsize);
isc_mem_put(mctx, keys, oldsize);
} else
new = NULL;
isc_mem_put(mctx, keys, oldsize);
keys = new;
keycount = i;
}
@@ -682,10 +687,10 @@ ns_config_putipandkeylist(isc_mem_t *mctx, isc_sockaddr_t **addrsp,
}
isc_result_t
ns_config_getport(cfg_obj_t *config, in_port_t *portp) {
cfg_obj_t *maps[3];
cfg_obj_t *options = NULL;
cfg_obj_t *portobj = NULL;
ns_config_getport(const cfg_obj_t *config, in_port_t *portp) {
const cfg_obj_t *maps[3];
const cfg_obj_t *options = NULL;
const cfg_obj_t *portobj = NULL;
isc_result_t result;
int i;
+38 -2
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2005 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2001-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: control.c,v 1.7.2.2.2.11 2004/09/03 03:43:31 marka Exp $ */
/* $Id: control.c,v 1.7.2.2.2.14 2005/04/29 01:04:47 marka Exp $ */
#include <config.h>
@@ -37,6 +37,9 @@
#include <named/log.h>
#include <named/os.h>
#include <named/server.h>
#ifdef HAVE_LIBSCF
#include <named/ns_smf_globals.h>
#endif
static isc_boolean_t
command_compare(const char *text, const char *command) {
@@ -58,6 +61,9 @@ ns_control_docommand(isccc_sexpr_t *message, isc_buffer_t *text) {
isccc_sexpr_t *data;
char *command;
isc_result_t result;
#ifdef HAVE_LIBSCF
ns_smf_want_disable = 0;
#endif
data = isccc_alist_lookup(message, "_data");
if (data == NULL) {
@@ -92,11 +98,41 @@ ns_control_docommand(isccc_sexpr_t *message, isc_buffer_t *text) {
} else if (command_compare(command, NS_COMMAND_RETRANSFER)) {
result = ns_server_retransfercommand(ns_g_server, command);
} else if (command_compare(command, NS_COMMAND_HALT)) {
#ifdef HAVE_LIBSCF
/*
* If we are managed by smf(5), AND in chroot, then
* we cannot connect to the smf repository, so just
* return with an appropriate message back to rndc.
*/
if (ns_smf_got_instance == 1 && ns_smf_chroot == 1) {
result = ns_smf_add_message(text);
return (result);
}
/*
* If we are managed by smf(5) but not in chroot,
* try to disable ourselves the smf way.
*/
if (ns_smf_got_instance == 1 && ns_smf_chroot == 0)
ns_smf_want_disable = 1;
/*
* If ns_smf_got_instance = 0, ns_smf_chroot
* is not relevant and we fall through to
* isc_app_shutdown below.
*/
#endif
ns_server_flushonshutdown(ns_g_server, ISC_FALSE);
ns_os_shutdownmsg(command, text);
isc_app_shutdown();
result = ISC_R_SUCCESS;
} else if (command_compare(command, NS_COMMAND_STOP)) {
#ifdef HAVE_LIBSCF
if (ns_smf_got_instance == 1 && ns_smf_chroot == 1) {
result = ns_smf_add_message(text);
return (result);
}
if (ns_smf_got_instance == 1 && ns_smf_chroot == 0)
ns_smf_want_disable = 1;
#endif
ns_server_flushonshutdown(ns_g_server, ISC_TRUE);
ns_os_shutdownmsg(command, text);
isc_app_shutdown();
+76 -58
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2001-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: controlconf.c,v 1.28.2.9.2.6 2004/03/08 09:04:14 marka Exp $ */
/* $Id: controlconf.c,v 1.28.2.9.2.10 2006/02/28 06:32:53 marka Exp $ */
#include <config.h>
@@ -356,6 +356,9 @@ control_recvmessage(isc_task_t *task, isc_event_t *event) {
{
ccregion.rstart = isc_buffer_base(&conn->ccmsg.buffer);
ccregion.rend = isc_buffer_used(&conn->ccmsg.buffer);
if (secret.rstart != NULL)
isc_mem_put(listener->mctx, secret.rstart,
REGION_SIZE(secret));
secret.rstart = isc_mem_get(listener->mctx, key->secret.length);
if (secret.rstart == NULL)
goto cleanup;
@@ -371,8 +374,6 @@ control_recvmessage(isc_task_t *task, isc_event_t *event) {
*/
if (request != NULL)
isccc_sexpr_free(&request);
isc_mem_put(listener->mctx, secret.rstart,
REGION_SIZE(secret));
} else {
log_invalid(&conn->ccmsg, result);
goto cleanup;
@@ -649,10 +650,12 @@ ns_controls_shutdown(ns_controls_t *controls) {
}
static isc_result_t
cfgkeylist_find(cfg_obj_t *keylist, const char *keyname, cfg_obj_t **objp) {
cfg_listelt_t *element;
cfgkeylist_find(const cfg_obj_t *keylist, const char *keyname,
const cfg_obj_t **objp)
{
const cfg_listelt_t *element;
const char *str;
cfg_obj_t *obj;
const cfg_obj_t *obj;
for (element = cfg_list_first(keylist);
element != NULL;
@@ -671,13 +674,13 @@ cfgkeylist_find(cfg_obj_t *keylist, const char *keyname, cfg_obj_t **objp) {
}
static isc_result_t
controlkeylist_fromcfg(cfg_obj_t *keylist, isc_mem_t *mctx,
controlkeylist_fromcfg(const cfg_obj_t *keylist, isc_mem_t *mctx,
controlkeylist_t *keyids)
{
cfg_listelt_t *element;
const cfg_listelt_t *element;
char *newstr = NULL;
const char *str;
cfg_obj_t *obj;
const cfg_obj_t *obj;
controlkey_t *key = NULL;
for (element = cfg_list_first(keylist);
@@ -712,11 +715,11 @@ controlkeylist_fromcfg(cfg_obj_t *keylist, isc_mem_t *mctx,
}
static void
register_keys(cfg_obj_t *control, cfg_obj_t *keylist,
register_keys(const cfg_obj_t *control, const cfg_obj_t *keylist,
controlkeylist_t *keyids, isc_mem_t *mctx, const char *socktext)
{
controlkey_t *keyid, *next;
cfg_obj_t *keydef;
const cfg_obj_t *keydef;
char secret[1024];
isc_buffer_t b;
isc_result_t result;
@@ -736,10 +739,10 @@ register_keys(cfg_obj_t *control, cfg_obj_t *keylist,
ISC_LIST_UNLINK(*keyids, keyid, link);
free_controlkey(keyid, mctx);
} else {
cfg_obj_t *algobj = NULL;
cfg_obj_t *secretobj = NULL;
char *algstr = NULL;
char *secretstr = NULL;
const cfg_obj_t *algobj = NULL;
const cfg_obj_t *secretobj = NULL;
const char *algstr = NULL;
const char *secretstr = NULL;
(void)cfg_map_get(keydef, "algorithm", &algobj);
(void)cfg_map_get(keydef, "secret", &secretobj);
@@ -805,11 +808,11 @@ get_rndckey(isc_mem_t *mctx, controlkeylist_t *keyids) {
isc_result_t result;
cfg_parser_t *pctx = NULL;
cfg_obj_t *config = NULL;
cfg_obj_t *key = NULL;
cfg_obj_t *algobj = NULL;
cfg_obj_t *secretobj = NULL;
char *algstr = NULL;
char *secretstr = NULL;
const cfg_obj_t *key = NULL;
const cfg_obj_t *algobj = NULL;
const cfg_obj_t *secretobj = NULL;
const char *algstr = NULL;
const char *secretstr = NULL;
controlkey_t *keyid = NULL;
char secret[1024];
isc_buffer_t b;
@@ -888,12 +891,13 @@ get_rndckey(isc_mem_t *mctx, controlkeylist_t *keyids) {
* valid or both are NULL.
*/
static void
get_key_info(cfg_obj_t *config, cfg_obj_t *control,
cfg_obj_t **global_keylistp, cfg_obj_t **control_keylistp)
get_key_info(const cfg_obj_t *config, const cfg_obj_t *control,
const cfg_obj_t **global_keylistp,
const cfg_obj_t **control_keylistp)
{
isc_result_t result;
cfg_obj_t *control_keylist = NULL;
cfg_obj_t *global_keylist = NULL;
const cfg_obj_t *control_keylist = NULL;
const cfg_obj_t *global_keylist = NULL;
REQUIRE(global_keylistp != NULL && *global_keylistp == NULL);
REQUIRE(control_keylistp != NULL && *control_keylistp == NULL);
@@ -912,15 +916,15 @@ get_key_info(cfg_obj_t *config, cfg_obj_t *control,
}
static void
update_listener(ns_controls_t *cp,
controllistener_t **listenerp, cfg_obj_t *control,
cfg_obj_t *config, isc_sockaddr_t *addr,
ns_aclconfctx_t *aclconfctx, const char *socktext)
update_listener(ns_controls_t *cp, controllistener_t **listenerp,
const cfg_obj_t *control, const cfg_obj_t *config,
isc_sockaddr_t *addr, ns_aclconfctx_t *aclconfctx,
const char *socktext)
{
controllistener_t *listener;
cfg_obj_t *allow;
cfg_obj_t *global_keylist = NULL;
cfg_obj_t *control_keylist = NULL;
const cfg_obj_t *allow;
const cfg_obj_t *global_keylist = NULL;
const cfg_obj_t *control_keylist = NULL;
dns_acl_t *new_acl = NULL;
controlkeylist_t keys;
isc_result_t result = ISC_R_SUCCESS;
@@ -977,18 +981,25 @@ update_listener(ns_controls_t *cp,
result = get_rndckey(listener->mctx, &listener->keys);
}
if (result != ISC_R_SUCCESS && global_keylist != NULL)
if (result != ISC_R_SUCCESS && global_keylist != NULL) {
/*
* This message might be a little misleading since the
* "new keys" might in fact be identical to the old ones,
* but tracking whether they are identical just for the
* sake of avoiding this message would be too much trouble.
*/
cfg_obj_log(control, ns_g_lctx, ISC_LOG_WARNING,
"couldn't install new keys for "
"command channel %s: %s",
socktext, isc_result_totext(result));
if (control != NULL)
cfg_obj_log(control, ns_g_lctx, ISC_LOG_WARNING,
"couldn't install new keys for "
"command channel %s: %s",
socktext, isc_result_totext(result));
else
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_CONTROL, ISC_LOG_WARNING,
"couldn't install new keys for "
"command channel %s: %s",
socktext, isc_result_totext(result));
}
/*
* Now, keep the old access list unless a new one can be made.
@@ -1005,26 +1016,33 @@ update_listener(ns_controls_t *cp,
dns_acl_detach(&listener->acl);
dns_acl_attach(new_acl, &listener->acl);
dns_acl_detach(&new_acl);
} else
/* XXXDCL say the old acl is still used? */
} else if (control != NULL)
cfg_obj_log(control, ns_g_lctx, ISC_LOG_WARNING,
"couldn't install new acl for "
"command channel %s: %s",
socktext, isc_result_totext(result));
else
isc_log_write(ns_g_lctx, NS_LOGCATEGORY_GENERAL,
NS_LOGMODULE_CONTROL, ISC_LOG_WARNING,
"couldn't install new acl for "
"command channel %s: %s",
socktext, isc_result_totext(result));
*listenerp = listener;
}
static void
add_listener(ns_controls_t *cp, controllistener_t **listenerp,
cfg_obj_t *control, cfg_obj_t *config, isc_sockaddr_t *addr,
ns_aclconfctx_t *aclconfctx, const char *socktext)
const cfg_obj_t *control, const cfg_obj_t *config,
isc_sockaddr_t *addr, ns_aclconfctx_t *aclconfctx,
const char *socktext)
{
isc_mem_t *mctx = cp->server->mctx;
controllistener_t *listener;
cfg_obj_t *allow;
cfg_obj_t *global_keylist = NULL;
cfg_obj_t *control_keylist = NULL;
const cfg_obj_t *allow;
const cfg_obj_t *global_keylist = NULL;
const cfg_obj_t *control_keylist = NULL;
dns_acl_t *new_acl = NULL;
isc_result_t result = ISC_R_SUCCESS;
@@ -1135,13 +1153,13 @@ add_listener(ns_controls_t *cp, controllistener_t **listenerp,
}
isc_result_t
ns_controls_configure(ns_controls_t *cp, cfg_obj_t *config,
ns_controls_configure(ns_controls_t *cp, const cfg_obj_t *config,
ns_aclconfctx_t *aclconfctx)
{
controllistener_t *listener;
controllistenerlist_t new_listeners;
cfg_obj_t *controlslist = NULL;
cfg_listelt_t *element, *element2;
const cfg_obj_t *controlslist = NULL;
const cfg_listelt_t *element, *element2;
char socktext[ISC_SOCKADDR_FORMATSIZE];
ISC_LIST_INIT(new_listeners);
@@ -1163,8 +1181,8 @@ ns_controls_configure(ns_controls_t *cp, cfg_obj_t *config,
for (element = cfg_list_first(controlslist);
element != NULL;
element = cfg_list_next(element)) {
cfg_obj_t *controls;
cfg_obj_t *inetcontrols = NULL;
const cfg_obj_t *controls;
const cfg_obj_t *inetcontrols = NULL;
controls = cfg_listelt_value(element);
(void)cfg_map_get(controls, "inet", &inetcontrols);
@@ -1174,9 +1192,9 @@ ns_controls_configure(ns_controls_t *cp, cfg_obj_t *config,
for (element2 = cfg_list_first(inetcontrols);
element2 != NULL;
element2 = cfg_list_next(element2)) {
cfg_obj_t *control;
cfg_obj_t *obj;
isc_sockaddr_t *addr;
const cfg_obj_t *control;
const cfg_obj_t *obj;
isc_sockaddr_t addr;
/*
* The parser handles BIND 8 configuration file
@@ -1189,12 +1207,12 @@ ns_controls_configure(ns_controls_t *cp, cfg_obj_t *config,
control = cfg_listelt_value(element2);
obj = cfg_tuple_get(control, "address");
addr = cfg_obj_assockaddr(obj);
if (isc_sockaddr_getport(addr) == 0)
isc_sockaddr_setport(addr,
addr = *cfg_obj_assockaddr(obj);
if (isc_sockaddr_getport(&addr) == 0)
isc_sockaddr_setport(&addr,
NS_CONTROL_PORT);
isc_sockaddr_format(addr, socktext,
isc_sockaddr_format(&addr, socktext,
sizeof(socktext));
isc_log_write(ns_g_lctx,
@@ -1205,7 +1223,7 @@ ns_controls_configure(ns_controls_t *cp, cfg_obj_t *config,
socktext);
update_listener(cp, &listener, control, config,
addr, aclconfctx, socktext);
&addr, aclconfctx, socktext);
if (listener != NULL)
/*
@@ -1219,7 +1237,7 @@ ns_controls_configure(ns_controls_t *cp, cfg_obj_t *config,
* This is a new listener.
*/
add_listener(cp, &listener, control,
config, addr, aclconfctx,
config, &addr, aclconfctx,
socktext);
if (listener != NULL)
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: aclconf.h,v 1.12.208.1 2004/03/06 10:21:23 marka Exp $ */
/* $Id: aclconf.h,v 1.12.208.3 2006/03/02 00:37:20 marka Exp $ */
#ifndef NS_ACLCONF_H
#define NS_ACLCONF_H 1
@@ -49,8 +49,8 @@ ns_aclconfctx_destroy(ns_aclconfctx_t *ctx);
*/
isc_result_t
ns_acl_fromconfig(cfg_obj_t *caml,
cfg_obj_t *cctx,
ns_acl_fromconfig(const cfg_obj_t *caml,
const cfg_obj_t *cctx,
ns_aclconfctx_t *ctx,
isc_mem_t *mctx,
dns_acl_t **target);
+16 -4
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004-2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: client.h,v 1.60.2.2.10.8 2004/07/23 02:56:52 marka Exp $ */
/* $Id: client.h,v 1.60.2.2.10.12 2006/06/06 00:11:40 marka Exp $ */
#ifndef NAMED_CLIENT_H
#define NAMED_CLIENT_H 1
@@ -198,6 +198,12 @@ ns_client_next(ns_client_t *client, isc_result_t result);
* return no response to the client.
*/
void
ns_client_qnamereplace(ns_client_t *client, dns_name_t *name);
/*%
* Replace the qname.
*/
isc_boolean_t
ns_client_shuttingdown(ns_client_t *client);
/*
@@ -322,12 +328,18 @@ ns_client_aclmsg(const char *msg, dns_name_t *name, dns_rdatatype_t type,
DNS_RDATACLASS_FORMATSIZE + sizeof(x) + sizeof("'/'"))
void
ns_client_recursing(ns_client_t *client, isc_boolean_t killoldest);
/*
ns_client_recursing(ns_client_t *client);
/*%
* Add client to end of recursing list. If 'killoldest' is true
* kill the oldest recursive client (list head).
*/
void
ns_client_killoldestquery(ns_client_t *client);
/*%
* Kill the oldest recursive query (recursing list head).
*/
void
ns_client_dumprecursing(FILE *f, ns_clientmgr_t *manager);
/*
+14 -13
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2001, 2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: config.h,v 1.4.12.4 2004/04/20 14:12:10 marka Exp $ */
/* $Id: config.h,v 1.4.12.6 2006/03/02 00:37:20 marka Exp $ */
#ifndef NAMED_CONFIG_H
#define NAMED_CONFIG_H 1
@@ -29,27 +29,28 @@ isc_result_t
ns_config_parsedefaults(cfg_parser_t *parser, cfg_obj_t **conf);
isc_result_t
ns_config_get(cfg_obj_t **maps, const char* name, cfg_obj_t **obj);
ns_config_get(const cfg_obj_t **maps, const char* name, const cfg_obj_t **obj);
isc_result_t
ns_checknames_get(cfg_obj_t **maps, const char* name, cfg_obj_t **obj);
ns_checknames_get(const cfg_obj_t **maps, const char* name,
const cfg_obj_t **obj);
int
ns_config_listcount(cfg_obj_t *list);
ns_config_listcount(const cfg_obj_t *list);
isc_result_t
ns_config_getclass(cfg_obj_t *classobj, dns_rdataclass_t defclass,
ns_config_getclass(const cfg_obj_t *classobj, dns_rdataclass_t defclass,
dns_rdataclass_t *classp);
isc_result_t
ns_config_gettype(cfg_obj_t *typeobj, dns_rdatatype_t deftype,
ns_config_gettype(const cfg_obj_t *typeobj, dns_rdatatype_t deftype,
dns_rdatatype_t *typep);
dns_zonetype_t
ns_config_getzonetype(cfg_obj_t *zonetypeobj);
ns_config_getzonetype(const cfg_obj_t *zonetypeobj);
isc_result_t
ns_config_getiplist(cfg_obj_t *config, cfg_obj_t *list,
ns_config_getiplist(const cfg_obj_t *config, const cfg_obj_t *list,
in_port_t defport, isc_mem_t *mctx,
isc_sockaddr_t **addrsp, isc_uint32_t *countp);
@@ -58,16 +59,16 @@ ns_config_putiplist(isc_mem_t *mctx, isc_sockaddr_t **addrsp,
isc_uint32_t count);
isc_result_t
ns_config_getipandkeylist(cfg_obj_t *config, cfg_obj_t *list, isc_mem_t *mctx,
isc_sockaddr_t **addrsp, dns_name_t ***keys,
isc_uint32_t *countp);
ns_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list,
isc_mem_t *mctx, isc_sockaddr_t **addrsp,
dns_name_t ***keys, isc_uint32_t *countp);
void
ns_config_putipandkeylist(isc_mem_t *mctx, isc_sockaddr_t **addrsp,
dns_name_t ***keys, isc_uint32_t count);
isc_result_t
ns_config_getport(cfg_obj_t *config, in_port_t *portp);
ns_config_getport(const cfg_obj_t *config, in_port_t *portp);
isc_result_t
ns_config_getkeyalgorithm(const char *str, dns_name_t **name);
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2001-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: control.h,v 1.6.2.2.2.7 2004/09/03 03:43:32 marka Exp $ */
/* $Id: control.h,v 1.6.2.2.2.9 2006/03/02 00:37:20 marka Exp $ */
#ifndef NAMED_CONTROL_H
#define NAMED_CONTROL_H 1
@@ -67,7 +67,7 @@ ns_controls_destroy(ns_controls_t **ctrlsp);
*/
isc_result_t
ns_controls_configure(ns_controls_t *controls, cfg_obj_t *config,
ns_controls_configure(ns_controls_t *controls, const cfg_obj_t *config,
ns_aclconfctx_t *aclconfctx);
/*
* Configure zero or more command channels into 'controls'
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: globals.h,v 1.59.68.5 2004/03/08 04:04:20 marka Exp $ */
/* $Id: globals.h,v 1.59.68.7 2006/03/02 00:37:20 marka Exp $ */
#ifndef NAMED_GLOBALS_H
#define NAMED_GLOBALS_H 1
@@ -75,7 +75,7 @@ EXTERN unsigned int ns_g_debuglevel INIT(0);
* Current configuration information.
*/
EXTERN cfg_obj_t * ns_g_config INIT(NULL);
EXTERN cfg_obj_t * ns_g_defaults INIT(NULL);
EXTERN const cfg_obj_t * ns_g_defaults INIT(NULL);
EXTERN const char * ns_g_conffile INIT(NS_SYSCONFDIR
"/named.conf");
EXTERN const char * ns_g_keyfile INIT(NS_SYSCONFDIR
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: logconf.h,v 1.10.208.1 2004/03/06 10:21:24 marka Exp $ */
/* $Id: logconf.h,v 1.10.208.3 2006/03/02 00:37:20 marka Exp $ */
#ifndef NAMED_LOGCONF_H
#define NAMED_LOGCONF_H 1
@@ -23,7 +23,7 @@
#include <isc/log.h>
isc_result_t
ns_log_configure(isc_logconfig_t *logconf, cfg_obj_t *logstmt);
ns_log_configure(isc_logconfig_t *logconf, const cfg_obj_t *logstmt);
/*
* Set up the logging configuration in '*logconf' according to
* the named.conf data in 'logstmt'.
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2000, 2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: lwresd.h,v 1.12.208.1 2004/03/06 10:21:25 marka Exp $ */
/* $Id: lwresd.h,v 1.12.208.3 2006/03/02 00:37:20 marka Exp $ */
#ifndef NAMED_LWRESD_H
#define NAMED_LWRESD_H 1
@@ -56,7 +56,7 @@ struct ns_lwreslistener {
* Configure lwresd.
*/
isc_result_t
ns_lwresd_configure(isc_mem_t *mctx, cfg_obj_t *config);
ns_lwresd_configure(isc_mem_t *mctx, const cfg_obj_t *config);
isc_result_t
ns_lwresd_parseeresolvconf(isc_mem_t *mctx, cfg_parser_t *pctx,
@@ -72,7 +72,8 @@ ns_lwresd_shutdown(void);
* Manager functions
*/
isc_result_t
ns_lwdmanager_create(isc_mem_t *mctx, cfg_obj_t *lwres, ns_lwresd_t **lwresdp);
ns_lwdmanager_create(isc_mem_t *mctx, const cfg_obj_t *lwres,
ns_lwresd_t **lwresdp);
void
ns_lwdmanager_attach(ns_lwresd_t *source, ns_lwresd_t **targetp);
@@ -0,0 +1,44 @@
/*
* Copyright (C) 2005 Internet Systems Consortium, Inc. ("ISC")
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH
* REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
* AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT,
* INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
* LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
* OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: ns_smf_globals.h,v 1.2.4.4 2005/05/13 01:22:33 marka Exp $ */
#ifndef NS_SMF_GLOBALS_H
#define NS_SMF_GLOBALS_H 1
#include <libscf.h>
#undef EXTERN
#undef INIT
#ifdef NS_MAIN
#define EXTERN
#define INIT(v) = (v)
#else
#define EXTERN extern
#define INIT(v)
#endif
EXTERN unsigned int ns_smf_got_instance INIT(0);
EXTERN unsigned int ns_smf_chroot INIT(0);
EXTERN unsigned int ns_smf_want_disable INIT(0);
isc_result_t ns_smf_add_message(isc_buffer_t *text);
isc_result_t ns_smf_get_instance(char **name, int debug, isc_mem_t *mctx);
#undef EXTERN
#undef INIT
#endif /* NS_SMF_GLOBALS_H */
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2003 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: server.h,v 1.58.2.1.10.11 2004/03/08 04:04:21 marka Exp $ */
/* $Id: server.h,v 1.58.2.1.10.13 2006/03/02 00:37:20 marka Exp $ */
#ifndef NAMED_SERVER_H
#define NAMED_SERVER_H 1
@@ -208,6 +208,6 @@ ns_server_dumprecursing(ns_server_t *server);
* Maintain a list of dispatches that require reserved ports.
*/
void
ns_add_reserved_dispatch(ns_server_t *server, isc_sockaddr_t *addr);
ns_add_reserved_dispatch(ns_server_t *server, const isc_sockaddr_t *addr);
#endif /* NAMED_SERVER_H */
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2000, 2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: sortlist.h,v 1.4.208.1 2004/03/06 10:21:26 marka Exp $ */
/* $Id: sortlist.h,v 1.4.208.3 2006/03/02 00:37:20 marka Exp $ */
#ifndef NAMED_SORTLIST_H
#define NAMED_SORTLIST_H 1
@@ -28,7 +28,7 @@
* Type for callback functions that rank addresses.
*/
typedef int
(*dns_addressorderfunc_t)(isc_netaddr_t *address, void *arg);
(*dns_addressorderfunc_t)(const isc_netaddr_t *address, const void *arg);
/*
* Return value type for setup_sortlist.
@@ -40,7 +40,8 @@ typedef enum {
} ns_sortlisttype_t;
ns_sortlisttype_t
ns_sortlist_setup(dns_acl_t *acl, isc_netaddr_t *clientaddr, void **argp);
ns_sortlist_setup(dns_acl_t *acl, isc_netaddr_t *clientaddr,
const void **argp);
/*
* Find the sortlist statement in 'acl' that applies to 'clientaddr', if any.
*
@@ -55,14 +56,14 @@ ns_sortlist_setup(dns_acl_t *acl, isc_netaddr_t *clientaddr, void **argp);
*/
int
ns_sortlist_addrorder1(isc_netaddr_t *addr, void *arg);
ns_sortlist_addrorder1(const isc_netaddr_t *addr, const void *arg);
/*
* Find the sort order of 'addr' in 'arg', the matching element
* of a 1-element top-level sortlist statement.
*/
int
ns_sortlist_addrorder2(isc_netaddr_t *addr, void *arg);
ns_sortlist_addrorder2(const isc_netaddr_t *addr, const void *arg);
/*
* Find the sort order of 'addr' in 'arg', a topology-like
* ACL forming the second element in a 2-element top-level
@@ -72,7 +73,7 @@ ns_sortlist_addrorder2(isc_netaddr_t *addr, void *arg);
void
ns_sortlist_byaddrsetup(dns_acl_t *sortlist_acl, isc_netaddr_t *client_addr,
dns_addressorderfunc_t *orderp,
void **argp);
const void **argp);
/*
* Find the sortlist statement in 'acl' that applies to 'clientaddr', if any.
* If a sortlist statement applies, return in '*orderp' a pointer to a function
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: tkeyconf.h,v 1.9.208.1 2004/03/06 10:21:26 marka Exp $ */
/* $Id: tkeyconf.h,v 1.9.208.3 2006/03/02 00:37:20 marka Exp $ */
#ifndef NS_TKEYCONF_H
#define NS_TKEYCONF_H 1
@@ -28,8 +28,8 @@
ISC_LANG_BEGINDECLS
isc_result_t
ns_tkeyctx_fromconfig(cfg_obj_t *options, isc_mem_t *mctx, isc_entropy_t *ectx,
dns_tkeyctx_t **tctxp);
ns_tkeyctx_fromconfig(const cfg_obj_t *options, isc_mem_t *mctx,
isc_entropy_t *ectx, dns_tkeyctx_t **tctxp);
/*
* Create a TKEY context and configure it, including the default DH key
* and default domain, according to 'options'.
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2001 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: tsigconf.h,v 1.9.208.1 2004/03/06 10:21:26 marka Exp $ */
/* $Id: tsigconf.h,v 1.9.208.3 2006/03/02 00:37:20 marka Exp $ */
#ifndef NS_TSIGCONF_H
#define NS_TSIGCONF_H 1
@@ -26,7 +26,7 @@
ISC_LANG_BEGINDECLS
isc_result_t
ns_tsigkeyring_fromconfig(cfg_obj_t *config, cfg_obj_t *vconfig,
ns_tsigkeyring_fromconfig(const cfg_obj_t *config, const cfg_obj_t *vconfig,
isc_mem_t *mctx, dns_tsig_keyring_t **ringp);
/*
* Create a TSIG key ring and configure it according to the 'key'
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: zoneconf.h,v 1.16.2.2.8.1 2004/03/06 10:21:27 marka Exp $ */
/* $Id: zoneconf.h,v 1.16.2.2.8.3 2006/03/02 00:37:20 marka Exp $ */
#ifndef NS_ZONECONF_H
#define NS_ZONECONF_H 1
@@ -30,8 +30,9 @@
ISC_LANG_BEGINDECLS
isc_result_t
ns_zone_configure(cfg_obj_t *config, cfg_obj_t *vconfig, cfg_obj_t *zconfig,
ns_aclconfctx_t *ac, dns_zone_t *zone);
ns_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig,
const cfg_obj_t *zconfig, ns_aclconfctx_t *ac,
dns_zone_t *zone);
/*
* Configure or reconfigure a zone according to the named.conf
* data in 'cctx' and 'czone'.
@@ -48,7 +49,7 @@ ns_zone_configure(cfg_obj_t *config, cfg_obj_t *vconfig, cfg_obj_t *zconfig,
*/
isc_boolean_t
ns_zone_reusable(dns_zone_t *zone, cfg_obj_t *zconfig);
ns_zone_reusable(dns_zone_t *zone, const cfg_obj_t *zconfig);
/*
* If 'zone' can be safely reconfigured according to the configuration
* data in 'zconfig', return ISC_TRUE. If the configuration data is so
+8 -8
View File
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2004 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 2004, 2006 Internet Systems Consortium, Inc. ("ISC")
* Copyright (C) 1999-2002 Internet Software Consortium.
*
* Permission to use, copy, modify, and distribute this software for any
@@ -15,7 +15,7 @@
* PERFORMANCE OF THIS SOFTWARE.
*/
/* $Id: interfacemgr.c,v 1.59.2.5.8.15 2004/08/10 04:56:23 jinmei Exp $ */
/* $Id: interfacemgr.c,v 1.59.2.5.8.18 2006/07/19 00:16:28 marka Exp $ */
#include <config.h>
@@ -182,6 +182,7 @@ ns_interface_create(ns_interfacemgr_t *mgr, isc_sockaddr_t *addr,
ifp->mgr = NULL;
ifp->generation = mgr->generation;
ifp->addr = *addr;
ifp->flags = 0;
strncpy(ifp->name, name, sizeof(ifp->name));
ifp->name[sizeof(ifp->name)-1] = '\0';
ifp->clientmgr = NULL;
@@ -717,9 +718,8 @@ do_scan(ns_interfacemgr_t *mgr, ns_listenlist_t *ext_listen,
* See if the address matches the listen-on statement;
* if not, ignore the interface.
*/
result = dns_acl_match(&listen_netaddr, NULL,
le->acl, &mgr->aclenv,
&match, NULL);
(void)dns_acl_match(&listen_netaddr, NULL, le->acl,
&mgr->aclenv, &match, NULL);
if (match <= 0)
continue;
@@ -745,9 +745,9 @@ do_scan(ns_interfacemgr_t *mgr, ns_listenlist_t *ext_listen,
for (ele = ISC_LIST_HEAD(ext_listen->elts);
ele != NULL;
ele = ISC_LIST_NEXT(ele, link)) {
dns_acl_match(&listen_netaddr, NULL,
ele->acl, NULL,
&match, NULL);
(void)dns_acl_match(&listen_netaddr,
NULL, ele->acl,
NULL, &match, NULL);
if (match > 0 && ele->port == le->port)
break;
else
Loaded 100 of 2270 files, more files were not shown because too many files have changed in this diff. Show more