]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
18 years agoAdd `reload' which invalidates the cache for every user.
Hajimu UMEMOTO [Tue, 6 Jun 2006 12:55:58 +0000 (12:55 +0000)]
Add `reload' which invalidates the cache for every user.

18 years ago- Note that the synchronisation interface needs to be up and have
Gleb Smirnoff [Tue, 6 Jun 2006 12:35:53 +0000 (12:35 +0000)]
- Note that the synchronisation interface needs to be up and have
  an IP address assigned.
- Add "quick" keyword to pf.conf example.

PR: docs/85209

18 years agoMake ke_rqindex unsigned.
David Xu [Tue, 6 Jun 2006 12:26:17 +0000 (12:26 +0000)]
Make ke_rqindex unsigned.

18 years agoPrint pfsync interface status if either syncpeer or syncdev is configured.
Gleb Smirnoff [Tue, 6 Jun 2006 11:21:08 +0000 (11:21 +0000)]
Print pfsync interface status if either syncpeer or syncdev is configured.

18 years agoExtract pointer value for mnt_stat from vp after the NULL check, not
Robert Watson [Tue, 6 Jun 2006 08:43:27 +0000 (08:43 +0000)]
Extract pointer value for mnt_stat from vp after the NULL check, not
before.

Coverity ID: 134394
Found with: Coverity Prevent (tm)

18 years agoUse NET_CALLOUT_MPSAFE for netgraph callout initializer.
Gleb Smirnoff [Tue, 6 Jun 2006 08:05:27 +0000 (08:05 +0000)]
Use NET_CALLOUT_MPSAFE for netgraph callout initializer.

18 years agoThe procedure of raceless switching between polling mode and
Gleb Smirnoff [Tue, 6 Jun 2006 08:03:49 +0000 (08:03 +0000)]
The procedure of raceless switching between polling mode and
taskqueued interrupt mode is going to be quite complex. Since
the polling mode is considered legacy feature for em(4) driver,
the decision is made to make polling and new interrupt handler
mutually exclusive, selected at compile time.

If kernel is compiled with DEVICE_POLLING, the fast taskqueued
interrupt handler code is disabled and the em_poll() and legacy
em_intr() functions are enabled. Otherwise, legacy functions
are disabled and only em_intr_fast() code is compiled.

Discussed with: scottl

18 years agoRemove section committed by mistake. It is not yet ready.
Pawel Jakub Dawidek [Tue, 6 Jun 2006 07:10:42 +0000 (07:10 +0000)]
Remove section committed by mistake. It is not yet ready.

18 years agoAdd regression tests for geli(8) authentication feature.
Pawel Jakub Dawidek [Tue, 6 Jun 2006 06:46:51 +0000 (06:46 +0000)]
Add regression tests for geli(8) authentication feature.

Supported by: Wheel Sp. z o.o. (http://www.wheel.pl)

18 years ago- Update regression tests after recent changes.
Pawel Jakub Dawidek [Tue, 6 Jun 2006 06:44:19 +0000 (06:44 +0000)]
- Update regression tests after recent changes.
- Verify various sector sizes.

18 years agoCleanups for mailwrapper(8):
Xin LI [Tue, 6 Jun 2006 05:01:12 +0000 (05:01 +0000)]
Cleanups for mailwrapper(8):
 - K&R -> ANSI prototype [O]
 - Do not bother to do free right before exit() or execve() [O]
 - Remove some dead code in addarg()
 - Make additional parameters specified in mailer.conf(5)
   actually work and document the fact. [N]
 - Avoid using __progname but instead use getprogname()
   and setprogname() to provide more sensible messages. [O, N]
 - Update $OpenBSD$ and $NetBSD$ to reflect the fact that we
   have sync'ed with their code.
 - WARNS=6

Obtained from/Inspired by: OpenBSD [O], NetBSD [N] (partially)

18 years agoAdd partial pmap locking.
Alan Cox [Tue, 6 Jun 2006 04:32:20 +0000 (04:32 +0000)]
Add partial pmap locking.

Eliminate the unused allpmaps list.

Tested by: cognet@

18 years agoCorrect a typo in the previous revision.
Alan Cox [Tue, 6 Jun 2006 02:02:10 +0000 (02:02 +0000)]
Correct a typo in the previous revision.

18 years agoAdd a stub for pmap_enter_object().
Alan Cox [Tue, 6 Jun 2006 02:00:08 +0000 (02:00 +0000)]
Add a stub for pmap_enter_object().

18 years agoMake VERBOSE_INIT_ARM compile by fixing various printf formats, and add it
Olivier Houchard [Tue, 6 Jun 2006 01:14:12 +0000 (01:14 +0000)]
Make VERBOSE_INIT_ARM compile by fixing various printf formats, and add it
as an option.

Submitted by:   Max N. Boyarov <m.boyarov at bsd dot by>

18 years agovm_page_alloc_contig() can sleep, so don't even think about using it
Olivier Houchard [Mon, 5 Jun 2006 23:42:47 +0000 (23:42 +0000)]
vm_page_alloc_contig() can sleep, so don't even think about using it
in the M_NOWAIT case.

18 years agoReally fix the typo this time: it should be sc->sc_drvbpf to be verified,
Tai-hwa Liang [Mon, 5 Jun 2006 23:06:03 +0000 (23:06 +0000)]
Really fix the typo this time: it should be sc->sc_drvbpf to be verified,
not ic->ic_drvbpf.

18 years agoFixing a typo in rev1.196.
Tai-hwa Liang [Mon, 5 Jun 2006 22:59:14 +0000 (22:59 +0000)]
Fixing a typo in rev1.196.

18 years agoRemove use of Giant around vn_open() in audit trail setup.
Robert Watson [Mon, 5 Jun 2006 22:36:12 +0000 (22:36 +0000)]
Remove use of Giant around vn_open() in audit trail setup.

Submitted by: jhb, wsalamon
Obtained from: TrustedBSD Project

18 years agoDo some source && comment cleanup.
Matt Jacob [Mon, 5 Jun 2006 22:25:49 +0000 (22:25 +0000)]
Do some source && comment cleanup.

Clean out the abortive start to homegrown, per-mpt,
Domain Validation. This should really be done at a
higher level.

Use the PIM_SEQSCAN flag for U320- this seems to correct
cases of being unable to consistently negotiate U320 in
the cases where I'd seen this before.

Between this and other recent checkins, this driver is
pretty close to being ready for MFC.

Reviewed by: scottl, ken, scsi@
MFC after: 1 week

18 years agoAdd PIM_SEQSCAN for HBA misc flags and code that understands
Matt Jacob [Mon, 5 Jun 2006 22:22:14 +0000 (22:22 +0000)]
Add PIM_SEQSCAN for HBA misc flags and code that understands
what to do with it.

This forces us to scan targets sequentially, not in parallel.
The reason we might want to do this is that SPI negotiation
might not work right at the SIM level if we try to do it
in parallel. We *could* fix this for each SIM where this is
broken, but it's a lot harder to do that when we can simply
ask CAM to probe sequentially.

If PIM_SEQSCAN is not set (default), the original behaviour for
probing is unchanged.

LUN probing is still done in parallel for each target in either
case.

While we're at it, clean up some resource leakage for error
cases.

Reviewed by: ken, scott, scsi@
MFC after: 1 week

18 years agoDocument geli(8) data authentication.
Pawel Jakub Dawidek [Mon, 5 Jun 2006 21:43:51 +0000 (21:43 +0000)]
Document geli(8) data authentication.

Supported by: Wheel Sp. z o.o. (http://www.wheel.pl)

18 years agoConnect new GELI files to the build.
Pawel Jakub Dawidek [Mon, 5 Jun 2006 21:42:26 +0000 (21:42 +0000)]
Connect new GELI files to the build.

Supported by: Wheel Sp. z o.o. (http://www.wheel.pl)

18 years agoUserland bits of geli(8) data authentication.
Pawel Jakub Dawidek [Mon, 5 Jun 2006 21:40:54 +0000 (21:40 +0000)]
Userland bits of geli(8) data authentication.
Now, encryption algorithm is given using '-e' option, not '-a'.
The '-a' option is now used to specify authentication algorithm.

Supported by: Wheel Sp. z o.o. (http://www.wheel.pl)

18 years agoImplement data integrity verification (data authentication) for geli(8).
Pawel Jakub Dawidek [Mon, 5 Jun 2006 21:38:54 +0000 (21:38 +0000)]
Implement data integrity verification (data authentication) for geli(8).

Supported by: Wheel Sp. z o.o. (http://www.wheel.pl)

18 years agoMake kern.geom.eli.overwrites sysctl a tunable as well.
Pawel Jakub Dawidek [Mon, 5 Jun 2006 21:25:19 +0000 (21:25 +0000)]
Make kern.geom.eli.overwrites sysctl a tunable as well.

18 years agoAssuming the interface has an address of x.x.x.195, a mask of
Qing Li [Mon, 5 Jun 2006 21:20:21 +0000 (21:20 +0000)]
Assuming the interface has an address of x.x.x.195, a mask of
255.255.255.0, and a default route with gateway x.x.x.1. Now if
the address mask is changed to something more specific, e.g.,
255.255.255.128, then after the mask change the default gateway
is no longer reachable.

Since the default route is still present in the routing table,
when the output code tries to resolve the address of the default
gateway in function rt_check(), again, the default route will be
returned by rtalloc1(). Because the lock is currently held on the
rtentry structure, one more attempt to hold the lock will trigger
a crash due to "lock recursed on non-recursive mutex ..."

This is a general problem. The fix checks for the above condition
so that an existing route entry is not mistaken for a new cloned
route. Approriately, an ENETUNREACH error is returned back to the
caller

Approved by: andre

18 years agoAdd g_duplicate_bio() function which does the same thing what g_clone_bio()
Pawel Jakub Dawidek [Mon, 5 Jun 2006 21:13:22 +0000 (21:13 +0000)]
Add g_duplicate_bio() function which does the same thing what g_clone_bio()
is doing, but g_duplicate_bio() allocates new bio with M_WAITOK flag.

18 years agoIntroduce the function pmap_enter_object(). It maps a sequence of resident
Alan Cox [Mon, 5 Jun 2006 20:35:27 +0000 (20:35 +0000)]
Introduce the function pmap_enter_object().  It maps a sequence of resident
pages from the same object.  Use it in vm_map_pmap_enter() to reduce the
locking overhead of premapping objects.

Reviewed by: tegge@

18 years agoSome mdoc and wording improvements.
Christian Brueffer [Mon, 5 Jun 2006 20:29:31 +0000 (20:29 +0000)]
Some mdoc and wording improvements.

18 years agoFix kernel panic in rt2661_tx_intr() if no frames has been sent.
Max Khon [Mon, 5 Jun 2006 20:06:29 +0000 (20:06 +0000)]
Fix kernel panic in rt2661_tx_intr() if no frames has been sent.

Obtained from: OpenBSD (sys/dev/ic/rt2661.c rev. 1.15)

18 years agoo Add missed comma.
Maxim Konovalov [Mon, 5 Jun 2006 19:55:44 +0000 (19:55 +0000)]
o Add missed comma.

18 years agoJust a very quick update to get *close* to reality.
Matt Jacob [Mon, 5 Jun 2006 19:46:55 +0000 (19:46 +0000)]
Just a very quick update to get *close* to reality.

18 years ago - ANSIfy.
Xin LI [Mon, 5 Jun 2006 18:22:13 +0000 (18:22 +0000)]
 - ANSIfy.
 - Remove two unnecessary casts.

These changes would help gcc4 compile.

18 years agoFix cut-n-pasteo: use the i386 version #define for i386 dumps, not the amd64 one.
Ed Maste [Mon, 5 Jun 2006 18:21:29 +0000 (18:21 +0000)]
Fix cut-n-pasteo: use the i386 version #define for i386 dumps, not the amd64 one.

18 years agomy(4) provides support now as well.
Christian Brueffer [Mon, 5 Jun 2006 18:02:36 +0000 (18:02 +0000)]
my(4) provides support now as well.

18 years agoAdd altq(4) support.
Christian Brueffer [Mon, 5 Jun 2006 17:59:46 +0000 (17:59 +0000)]
Add altq(4) support.

Reviewed by: mlaier
Approved by: rwatson (mentor)
MFC after: 2 weeks

18 years agomove hal bus+tag externalization to the bus glue code where it belongs;
Sam Leffler [Mon, 5 Jun 2006 17:51:20 +0000 (17:51 +0000)]
move hal bus+tag externalization to the bus glue code where it belongs;
this is a noop on all current freebsd architectures

MFC after: 1 month

18 years ago- Declare the PnP map const.
Marius Strobl [Mon, 5 Jun 2006 17:48:54 +0000 (17:48 +0000)]
- Declare the PnP map const.
- Add devices found in V210 to the PnP map.
- Don't leak memory if we didn't find a match for a node in the PnP map.

MFC after: 2 weeks

18 years agoresolve merge conflicts
Sam Leffler [Mon, 5 Jun 2006 17:46:41 +0000 (17:46 +0000)]
resolve merge conflicts

MFC after: 1 month

18 years agoThis commit was generated by cvs2svn to compensate for changes in r159285,
Sam Leffler [Mon, 5 Jun 2006 17:43:51 +0000 (17:43 +0000)]
This commit was generated by cvs2svn to compensate for changes in r159285,
which included commits to RCS files with non-trunk default branches.

18 years agoVersion 0.9.17.2:
Sam Leffler [Mon, 5 Jun 2006 17:43:51 +0000 (17:43 +0000)]
Version 0.9.17.2:

o define HAL_SOFTC, HAL_BUS_TAG, and HAL_BUS_HANDLE to be machine
  independent; this fixes portability issues with bsd systems
o add ah_disable api for turning off operation of both MAC and PHY
o add ah_getAntennaSwitch and ah_setAntennaSwitch api's for better control
  of antenna usage and diversity
o add ah_setAckCTSRate and ah_setAckCTSRate for controlling tx rate of
  h/w generated frames
o add ah_setBeaconTimers api for simpler setting of the beacon timer registers
o remove ah_waitForBeaconDone api
o add HAL_TXDESC_DURENA flag to enable h/w duration setting in tx descriptor
o correct documentation of min/max tx power units (.5 dBm)
o switch arm, mips, and powerpc builds to use functions for register
  read/write operations
o fix sparc builds to not reference %g2 and %g3 registers
o add public builds for SoC's

MFC after: 1 month

18 years agoUpon further review, DES prefers this change over that in revision 1.13
Guy Helmer [Mon, 5 Jun 2006 16:41:27 +0000 (16:41 +0000)]
Upon further review, DES prefers this change over that in revision 1.13
to resolve the directory access problem for processes with P_SUGID flag
set.

Suggested by: des

18 years agoFix minor typos.
Joel Dahl [Mon, 5 Jun 2006 16:31:57 +0000 (16:31 +0000)]
Fix minor typos.

18 years ago- Document that padlock(4) pretends to accelerate HMAC algorithms.
Pawel Jakub Dawidek [Mon, 5 Jun 2006 16:24:31 +0000 (16:24 +0000)]
- Document that padlock(4) pretends to accelerate HMAC algorithms.
- Remove "device cryptodev" as it is not needed for compiling padlock(4)
  into the kernel. Actually it is not advisable, because padlock
  instructions can be used directly from userland, so passing the work
  through the kernel is a bad idea.

18 years ago- Pretend to accelerate various HMAC algorithms, so padlock(4) can be used
Pawel Jakub Dawidek [Mon, 5 Jun 2006 16:22:04 +0000 (16:22 +0000)]
- Pretend to accelerate various HMAC algorithms, so padlock(4) can be used
  with fast_ipsec(4) and geli(8) authentication (comming soon).
  If consumer requests only for HMAC algorithm (without encryption), return
  EINVAL.
- Add support for the CRD_F_KEY_EXPLICIT flag, for both encryption and
  authentication.

18 years agoWhen generating BSM tokens for mkfifo(), include mode argument.
Robert Watson [Mon, 5 Jun 2006 16:14:49 +0000 (16:14 +0000)]
When generating BSM tokens for mkfifo(), include mode argument.

Submitted by: wsalamon
Obtained from: TrustedBSD Project

18 years agoWhen generating the process token, need to check whether the
Robert Watson [Mon, 5 Jun 2006 16:12:00 +0000 (16:12 +0000)]
When generating the process token, need to check whether the
process was sucessfully audited.  Otherwise, generate the PID
token. This change covers the pid < 0 cases, and pid lookup
failure cases.

Submitted by: wsalamon
Obtained from: TrustedBSD Project

18 years agoFix compilation of ftpcmd.y without -DINET6.
Yaroslav Tykhiy [Mon, 5 Jun 2006 15:50:34 +0000 (15:50 +0000)]
Fix compilation of ftpcmd.y without -DINET6.
Respect MK_INET6_SUPPORT in Makefile.

Requested by: Attila Nagy <bra at fsn dot hu>
MFC after: 1 week

18 years agoConsistently use audit_free() to free records, rather than
Robert Watson [Mon, 5 Jun 2006 15:38:12 +0000 (15:38 +0000)]
Consistently use audit_free() to free records, rather than
directly invoking uma_zfree().

Perforce change: 96652
Obtained from: TrustedBSD Project

18 years agoAudit some arguments to nmount(), mount(), umount().
Robert Watson [Mon, 5 Jun 2006 15:32:07 +0000 (15:32 +0000)]
Audit some arguments to nmount(), mount(), umount().

Submitted by: wsalamon
Obtained from: TrustedBSD Project

18 years agoBreak out description of the audit pipe facility from audit.4 into a new
Robert Watson [Mon, 5 Jun 2006 15:26:09 +0000 (15:26 +0000)]
Break out description of the audit pipe facility from audit.4 into a new
man page, auditpipe.4, which describes the behavior of audit pipes, the
ioctls, preselection, etc.

Obtained from: TrustedBSD Project

18 years agoRevert the part of rev. 1.3 which changed the software style to be
Marius Strobl [Mon, 5 Jun 2006 15:14:14 +0000 (15:14 +0000)]
Revert the part of rev. 1.3 which changed the software style to be
set to ILACC rather than PCnet-PCI as VMware doesn't implement ILACC
compatibility, resulting in the VMware virtual machine to crash if
enabled. Add a comment regarding usage of ILACC vs. PCnet-PCI mode.

Reported and tested by: gnn, wsalamon

18 years agoReplace absolute addressing in the call instructions with position-independend
Konstantin Belousov [Mon, 5 Jun 2006 14:59:33 +0000 (14:59 +0000)]
Replace absolute addressing in the call instructions with position-independend
calls. This eliminates TEXTREL from libc, making its text segment relocatable.

PR: i386/85242
Approved by: kan (mentor)
MFC after: 1 month

18 years agoIntroduce support for per-audit pipe preselection independent from the
Robert Watson [Mon, 5 Jun 2006 14:48:17 +0000 (14:48 +0000)]
Introduce support for per-audit pipe preselection independent from the
global audit trail configuration.  This allows applications consuming
audit trails to specify parameters for which audit records are of
interest, including selecting records not required by the global trail.
Allowing application interest specification without changing the global
configuration allows intrusion detection systems to run without
interfering with global auditing or each other (if multiple are
present).  To implement this:

- Kernel audit records now carry a flag to indicate whether they have
  been selected by the global trail or by the audit pipe subsystem,
  set during record commit, so that this information is available
  after BSM conversion when delivering the BSM to the trail and audit
  pipes in the audit worker thread asynchronously.  Preselection by
  either record target will cause the record to be kept.

- Similar changes to preselection when the audit record is created
  when the system call is entering: consult both the global trail and
  pipes.

- au_preselect() now accepts the class in order to avoid repeatedly
  looking up the mask for each preselection test.

- Define a series of ioctls that allow applications to specify whether
  they want to track the global trail, or program their own
  preselection parameters: they may specify their own flags and naflags
  masks, similar to the global masks of the same name, as well as a set
  of per-auid masks.  They also set a per-pipe mode specifying whether
  they track the global trail, or user their own -- the door is left
  open for future additional modes.  A new ioctl is defined to allow a
  user process to flush the current audit pipe queue, which can be used
  after reprogramming pre-selection to make sure that only records of
  interest are received in future reads.

- Audit pipe data structures are extended to hold the additional fields
  necessary to support preselection.  By default, audit pipes track the
  global trail, so "praudit /dev/auditpipe" will track the global audit
  trail even though praudit doesn't program the audit pipe selection
  model.

- Comment about the complexities of potentially adding partial read
  support to audit pipes.

By using a set of ioctls, applications can select which records are of
interest, and toggle the preselection mode.

Obtained from: TrustedBSD Project

18 years agoTemporary workaround to prevent leak of Giant from nfsd when calling
Konstantin Belousov [Mon, 5 Jun 2006 14:48:02 +0000 (14:48 +0000)]
Temporary workaround to prevent leak of Giant from nfsd when calling
lookup().

Reviewed by: tegge
Tested by: "Arno J. Klaassen" <arno at heho snv jussieu fr>, "Rong-en Fan" <grafan at gmail com>, Dmitriy Kirhlarov <dimma at higis ru>, Dmitry Pryanishnikov <dmitry at atlantis dp ua>
MFC after: 1 week
Approved by: kan, pjd (mentors)

18 years agoFix a number of cases where ugen would panic, especially when the
Ian Dowse [Mon, 5 Jun 2006 14:44:39 +0000 (14:44 +0000)]
Fix a number of cases where ugen would panic, especially when the
device went away while open or if you tried to change the config
number while devices were open. Based on the patch from the PR with
a number of changes as discussed with the submitter.

PR: usb/97271
Submitted by: Anish Mistry

18 years agoShorten audit record zone name.
Robert Watson [Mon, 5 Jun 2006 14:11:28 +0000 (14:11 +0000)]
Shorten audit record zone name.

Perforce change: 93598
Obtained from: TrustedBSD Project

18 years agoNo longer unconditionally drain the audit record queue if there is
Robert Watson [Mon, 5 Jun 2006 14:09:59 +0000 (14:09 +0000)]
No longer unconditionally drain the audit record queue if there is
not an active audit trail: instead, continue to iterate through
each record in case an audit pipe is interested.

Obtained from: TrustedBSD Project

18 years agoPull BSM conversion logic out of audit_record_write(), as well as
Robert Watson [Mon, 5 Jun 2006 13:50:02 +0000 (13:50 +0000)]
Pull BSM conversion logic out of audit_record_write(), as well as
knowledge of user vs. kernel audit records into
audit_worker_process_record().  This largely confines vnode
knowledge to audit_record_write(), but avoids that logic knowing
about BSM as opposed to byte streams.  This will allow us to
improve our ability to support real-time audit stream processing
by audit pipe consumers while auditing is disabled, but this
support is not yet complete.

Obtained from: TrustedBSD Project

18 years agoAssert audit mtx in audit_worker_drain().
Robert Watson [Mon, 5 Jun 2006 13:46:55 +0000 (13:46 +0000)]
Assert audit mtx in audit_worker_drain().

Break out logic to call audit_record_write() and handle error
conditions into audit_worker_process_record().  This will be the
future home of some logic now present in audit_record_write()
also.

Obtained from: TrustedBSD Project

18 years agoUse struct kaudit_queue instead of a hand-crafted queue type for
Robert Watson [Mon, 5 Jun 2006 13:45:05 +0000 (13:45 +0000)]
Use struct kaudit_queue instead of a hand-crafted queue type for
audit records in the audit_worker thread.

Obtained from: TrustedBSD Project

18 years agoRename audit_cv to audit_worker_cv, as it wakes up the audit
Robert Watson [Mon, 5 Jun 2006 13:43:57 +0000 (13:43 +0000)]
Rename audit_cv to audit_worker_cv, as it wakes up the audit
worker.

Rename audit_commit_cv to audit_watermark_cv, since it is there to
wake up threads waiting on hitting the low watermark.  Describe
properly in comment.

Obtained from: TrustedBSD Project

18 years agoAudit command, uid arguments for quotactl().
Robert Watson [Mon, 5 Jun 2006 13:34:23 +0000 (13:34 +0000)]
Audit command, uid arguments for quotactl().
Audit the mode argument to mkfifo().
Audit the target path passed to symlink().

Submitted by: wsalamon
Obtained from: TrustedBSD Project

18 years agoMerge OpenBSM 1.0 alpha 6 changes for BSM token creation to
Robert Watson [Mon, 5 Jun 2006 13:13:02 +0000 (13:13 +0000)]
Merge OpenBSM 1.0 alpha 6 changes for BSM token creation to
src/sys/security/audit:

- Clarify and clean up AUR_ types to match Solaris.
- Clean up use of host vs. network byte order for IP addresses.
- Remove combined user/kernel implementations of some token creation
  calls, such as au_to_file(), header calls, etc.

Obtained from: TrustedBSD Project

18 years agoAudit path passed to the acct() system call.
Robert Watson [Mon, 5 Jun 2006 13:02:34 +0000 (13:02 +0000)]
Audit path passed to the acct() system call.

Obtained from: TrustedBSD Project

18 years agoMerge OpenBSM 1.0 alpha 6 version of audit_record.h to src/sys:
Robert Watson [Mon, 5 Jun 2006 13:00:52 +0000 (13:00 +0000)]
Merge OpenBSM 1.0 alpha 6 version of audit_record.h to src/sys:

- Cleanup of AUR_ data types.
- Comment fixes.
- au_close_token() definition.
- Break out of kernel vs. user space token interfaces for headers.

Note: this may briefly break the kernel build until other kernel files are
updated to match.

Obtained from: TrustedBSD Project

18 years agoMerge OpenBSM 1.0 alpha 6 changes to bsm/audit.h into src/sys: respell
Robert Watson [Mon, 5 Jun 2006 12:55:45 +0000 (12:55 +0000)]
Merge OpenBSM 1.0 alpha 6 changes to bsm/audit.h into src/sys: respell
statistics variables.

Submitted by: Martin Fong <martin dot fong at sri dot com>
Obtained from: TrustedBSD Project

18 years agoAdd audit_submit.3 to the set of man pages built and installed with
Robert Watson [Mon, 5 Jun 2006 12:53:44 +0000 (12:53 +0000)]
Add audit_submit.3 to the set of man pages built and installed with
libbsm.  This interface is new as of OpenBSM 1.0 alpha 6.

Submitted by: csjp
Obtained from: TrustedBSD Project

18 years agoAdd Fn+F7 hotkey (suspend) support.
Yoshihiro Takahashi [Mon, 5 Jun 2006 11:55:20 +0000 (11:55 +0000)]
Add Fn+F7 hotkey (suspend) support.

Tested by: nork

18 years agoMFi386: revisions 1.627, 1.628 and 1.629.
Yoshihiro Takahashi [Mon, 5 Jun 2006 11:53:36 +0000 (11:53 +0000)]
MFi386: revisions 1.627, 1.628 and 1.629.

18 years agoRegenerate config.h from OpenBSM 1.0 alpha 6 import.
Robert Watson [Mon, 5 Jun 2006 11:06:32 +0000 (11:06 +0000)]
Regenerate config.h from OpenBSM 1.0 alpha 6 import.

Obtained from: TrustedBSD Project

18 years agoThis commit was generated by cvs2svn to compensate for changes in r159248,
Robert Watson [Mon, 5 Jun 2006 10:52:12 +0000 (10:52 +0000)]
This commit was generated by cvs2svn to compensate for changes in r159248,
which included commits to RCS files with non-trunk default branches.

18 years agoVendor branch import of TrustedBSD OpenBSM 1.0 alpha 6:
Robert Watson [Mon, 5 Jun 2006 10:52:12 +0000 (10:52 +0000)]
Vendor branch import of TrustedBSD OpenBSM 1.0 alpha 6:

- Use AU_TO_WRITE and AU_NO_TO_WRITE for the 'keep' argument to au_close();
  previously we used hard-coded 0 and 1 values.
- Add man page for au_open(), au_write(), au_close(), and
  au_close_buffer().
- Support a more complete range of data types for the arbitrary data token:
  add AUR_CHAR (alias to AUR_BYTE), remove AUR_LONG, add AUR_INT32 (alias
  to AUR_INT), add AUR_INT64.
- Add au_close_token(), which allows writing a single token_t to a memory
  buffer.  Not likely to be used much by applications, but useful for
  writing test tools.
- Modify au_to_file() so that it accepts a timeval in user space, not just
  kernel -- this is not a Solaris BSM API so can be modified without
  causing compatibility issues.
- Define a new API, au_to_header32_tm(), which adds a struct timeval
  argument to the ordinary au_to_header32(), which is now implemented by
  wrapping au_to_header32_tm() and calling gettimeofday().  #ifndef KERNEL
  the APIs that invoke gettimeofday(), rather than having a variable
  definition.  Don't try to retrieve time zone information using
  gettimeofday(), as it's not needed, and introduces possible failure
  modes.
- Don't perform byte order transformations on the addr/machine fields of
  the terminal ID that appears in the process32/subject32 tokens.  These
  are assumed to be IP addresses, and as such, to be in network byte
  order.
- Universally, APIs now assume that IP addresses and ports are provided
  in network byte order.  APIs now generally provide these types in
  network byte order when decoding.
- Beginnings of an OpenBSM test framework can now be found in openbsm/test.
  This code is not built or installed by default.
- auditd now assigns more appropriate syslog levels to its debugging and
  error information.
- Support for audit filters introduced: audit filters are dynamically
  loaded shared objects that run in the context of a new daemon,
  auditfilterd.  The daemon reads from an audit pipe and feeds both BSM and
  parsed versions of records to shared objects using a module API.  This
  will provide a framework for the writing of intrusion detection services.
- New utility API, audit_submit(), added to capture common elements of audit
  record submission for many applications.

Obtained from: TrustedBSD Project

18 years agoAdd audit.h to mkioctls inclusion list: audit pipe ioctls need access
Robert Watson [Mon, 5 Jun 2006 10:06:51 +0000 (10:06 +0000)]
Add audit.h to mkioctls inclusion list: audit pipe ioctls need access
to the audit types.

Submitted by: wsalamon
Obtained from: TrustedBSD Project

18 years agoInclude strings.h for bzero()
Xin LI [Mon, 5 Jun 2006 08:51:14 +0000 (08:51 +0000)]
Include strings.h for bzero()

18 years agoMFamd64
Alan Cox [Mon, 5 Jun 2006 06:08:21 +0000 (06:08 +0000)]
MFamd64
 Eliminate unnecessary, recursive acquisitions and releases of the page
 queues lock by free_pv_entry() and pmap_remove_pages().

 Reduce the scope of the page queues lock in pmap_remove_pages().

18 years agoUse an option form better matching the manual.
David E. O'Brien [Mon, 5 Jun 2006 03:47:14 +0000 (03:47 +0000)]
Use an option form better matching the manual.

18 years agoUse newly added functions to simplify the code.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 22:17:25 +0000 (22:17 +0000)]
Use newly added functions to simplify the code.

18 years ago- Replace COPYDATA() and COPYBACK() macros with crypto_copydata() and
Pawel Jakub Dawidek [Sun, 4 Jun 2006 22:15:13 +0000 (22:15 +0000)]
- Replace COPYDATA() and COPYBACK() macros with crypto_copydata() and
  crypto_copyback() functions.
- Add crypto_apply() function.

This will allow for more code simplification.

18 years agoPrefer hardware crypto over software crypto.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 22:12:08 +0000 (22:12 +0000)]
Prefer hardware crypto over software crypto.

Before the change if a hardware crypto driver was loaded after
the software crypto driver, calling crypto_newsession() with
hard=0, will always choose software crypto.

18 years agoAdd regression tests for IPsec.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 22:06:17 +0000 (22:06 +0000)]
Add regression tests for IPsec.

18 years agoFix unaligned memory accesses on Alpha and possible other platforms.
Marcel Moolenaar [Sun, 4 Jun 2006 20:26:13 +0000 (20:26 +0000)]
Fix unaligned memory accesses on Alpha and possible other platforms.
By using a pointer to struct dos_partition, we implicitly tell the
compiler that the pointer is 4-bytes aligned, even though we know
that's not the case. The fact that we only dereference the pointer
to access a byte-wide field (field dp_ptyp) is not a guarantee that
the compiler will in fact use a byte-wide load. On some platforms
it's more efficient to use long word or quad word loads and use
bit-shifting and bit-masking to get the intended byte. On those
platforms an misaligned load will be the result.
The fix is to use byte-wide pointer arithmetic based on sizeof() and
offsetof() to avoid invalid casts which avoids that the compiler
makes invalid assumptions.

Backtrace provided by: wilko@
MFC after: 1 week

18 years agoChange '#if INET' and '#if INET6' to '#ifdef INET' and '#ifdef INET6'.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 19:32:32 +0000 (19:32 +0000)]
Change '#if INET' and '#if INET6' to '#ifdef INET' and '#ifdef INET6'.
This unbreaks compiling a kernel with FAST_IPSEC and no INET6.

18 years ago- Fix markup
Pav Lucistnik [Sun, 4 Jun 2006 15:39:19 +0000 (15:39 +0000)]
- Fix markup

PR: docs/98471
Submitted by: Tsurutani Naoki <turutani@scphys.kyoto-u.ac.jp>
MFC after: 1 day

18 years agoUse newly added defines instead of magic values.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 15:11:59 +0000 (15:11 +0000)]
Use newly added defines instead of magic values.

18 years agoMove COPYDATA() and COPYBACK() macros to cryptodev.h, they will be used
Pawel Jakub Dawidek [Sun, 4 Jun 2006 15:10:12 +0000 (15:10 +0000)]
Move COPYDATA() and COPYBACK() macros to cryptodev.h, they will be used
in padlock(4) as well.

18 years agoUse defines from cryptodev.h.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 15:00:52 +0000 (15:00 +0000)]
Use defines from cryptodev.h.

18 years ago- Remove HMAC_BLOCK_LEN, it serves no purpose.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 14:49:34 +0000 (14:49 +0000)]
- Remove HMAC_BLOCK_LEN, it serves no purpose.
- Use defines of used algorithm instead of HMAC_BLOCK_LEN.

18 years agoAdd a sleep lock that protects access to sequences of blocking
Ian Dowse [Sun, 4 Jun 2006 14:42:38 +0000 (14:42 +0000)]
Add a sleep lock that protects access to sequences of blocking
axe_cmd() calls. Without this the device can get confused if multiple
threads attempt these operations concurrently. The problem was
easily reproducible by running "ifconfig axe0" in a loop because
eventually it would conflict with axe_tick_task().

A similar approach is probably required in all USB ethernet drivers.

18 years ago- Use define of an algorithm with the biggest block length to describe
Pawel Jakub Dawidek [Sun, 4 Jun 2006 14:36:42 +0000 (14:36 +0000)]
- Use define of an algorithm with the biggest block length to describe
  EALG_MAX_BLOCK_LEN instead of hardcoded value.
- Kill an unused define.

18 years agoRename HMAC_BLOCK_MAXLEN to HMAC_MAX_BLOCK_LEN to be consistent with
Pawel Jakub Dawidek [Sun, 4 Jun 2006 14:29:42 +0000 (14:29 +0000)]
Rename HMAC_BLOCK_MAXLEN to HMAC_MAX_BLOCK_LEN to be consistent with
EALG_MAX_BLOCK_LEN.

18 years agoRename AALG_MAX_RESULT_LEN to HASH_MAX_LEN to look more constent with
Pawel Jakub Dawidek [Sun, 4 Jun 2006 14:25:16 +0000 (14:25 +0000)]
Rename AALG_MAX_RESULT_LEN to HASH_MAX_LEN to look more constent with
other defines.

18 years ago- Add defines with hash length for each hash algorithm.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 14:20:47 +0000 (14:20 +0000)]
- Add defines with hash length for each hash algorithm.
- Add defines with block length for each HMAC algorithm.
- Add AES_BLOCK_LEN define which is an alias for RIJNDAEL128_BLOCK_LEN.
- Add NULL_BLOCK_LEN define.

18 years agoAdd support for the CRD_F_KEY_EXPLICIT flag for both encryption and
Pawel Jakub Dawidek [Sun, 4 Jun 2006 14:14:35 +0000 (14:14 +0000)]
Add support for the CRD_F_KEY_EXPLICIT flag for both encryption and
authentication operations.

Unfortunately I've no hardware, so I only compiled-tested it.

18 years agoAdd support for the CRD_F_KEY_EXPLICIT flag for both encryption and
Pawel Jakub Dawidek [Sun, 4 Jun 2006 14:13:17 +0000 (14:13 +0000)]
Add support for the CRD_F_KEY_EXPLICIT flag for both encryption and
authentication operations.

18 years agoDon't forget to destroy the sc_freeqlock mutex on detach.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 13:45:04 +0000 (13:45 +0000)]
Don't forget to destroy the sc_freeqlock mutex on detach.

18 years agoKill an unused argument.
Pawel Jakub Dawidek [Sun, 4 Jun 2006 12:15:59 +0000 (12:15 +0000)]
Kill an unused argument.

18 years agoPush acquisition of pcbinfo lock out of tcp_usr_attach() into
Robert Watson [Sun, 4 Jun 2006 09:31:34 +0000 (09:31 +0000)]
Push acquisition of pcbinfo lock out of tcp_usr_attach() into
tcp_attach() after the call to soreserve(), as it doesn't require
the global lock.  Rearrange inpcb locking here also.

MFC after: 1 month

18 years agoClean up many of the debugging messages and move them under bootverbose.
Nate Lawson [Sun, 4 Jun 2006 08:04:19 +0000 (08:04 +0000)]
Clean up many of the debugging messages and move them under bootverbose.
Move the code for printing timer statistics into a test function instead of
an ifdef (accessible via the debug.acpi.hpet_test tunable).  Also use defines
for register offsets instead of magic values.

Courtesy of: slow flight to HK