<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/sys/netkey, branch releng/5.3</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=releng%2F5.3</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=releng%2F5.3'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2004-10-01T19:18:55Z</updated>
<entry>
<title>MFC rev 1.68:</title>
<updated>2004-10-01T19:18:55Z</updated>
<author>
<name>Scott Long</name>
<email>scottl@FreeBSD.org</email>
</author>
<published>2004-10-01T19:18:55Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=c8f8fba370c5ec696dc0f704b5f533ecd6964f2c'/>
<id>urn:sha1:c8f8fba370c5ec696dc0f704b5f533ecd6964f2c</id>
<content type='text'>
  Merge netipsec/key.c:1.17 into KAME pfkey implementation:

    date: 2004/09/26 02:01:27;  author: sam;  state: Exp;  lines: +0 -5
    Correct handling of SADB_UPDATE and SADB_ADD requests.  key_align may
    split the mbuf due to use of m_pulldown.  Discarding the result because
    of this does not make sense as no subsequent code depends on the entire
    msg being linearized (only the individual pieces).  It's likely
    something else is wrong here but for now this appears to get things back
    to a working state.

    Submitted by:   Roselyn Lee

  This change was also made in the KAME CVS repository as key.c:1.337 by
  itojun.

Approved by: re
</content>
</entry>
<entry>
<title>Merge key.c:1.67 to RELENG_5:</title>
<updated>2004-09-06T19:36:40Z</updated>
<author>
<name>Robert Watson</name>
<email>rwatson@FreeBSD.org</email>
</author>
<published>2004-09-06T19:36:40Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=e80df11f01f0c9bcfe7e702e2f955ae5185bb2ea'/>
<id>urn:sha1:e80df11f01f0c9bcfe7e702e2f955ae5185bb2ea</id>
<content type='text'>
  date: 2004/09/02 20:14:03;  author: rwatson;  state: Exp;  lines: +0 -22
  The KAME IPSEC implementation at one point used its own pseudo-random
  number generator, which was re-seeded via a timeout.  Now centralized
  randomness/entropy is used, we can garbage collect the timeout and
  re-seeding code (which was largely a no-op).

  Discussed with: itojun, suz, JINMEI Tatuya &lt; jinmei at isl dot rdc dot
  toshiba dot co dot jp &gt;

Approved by:	re (scottl)
</content>
</entry>
<entry>
<title>Merge next step in socket buffer locking:</title>
<updated>2004-06-21T00:20:43Z</updated>
<author>
<name>Robert Watson</name>
<email>rwatson@FreeBSD.org</email>
</author>
<published>2004-06-21T00:20:43Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=a34b7046665fb5808990297bbf8a3b0147d12e47'/>
<id>urn:sha1:a34b7046665fb5808990297bbf8a3b0147d12e47</id>
<content type='text'>
- sowakeup() now asserts the socket buffer lock on entry.  Move
  the call to KNOTE higher in sowakeup() so that it is made with
  the socket buffer lock held for consistency with other calls.
  Release the socket buffer lock prior to calling into pgsigio(),
  so_upcall(), or aio_swake().  Locking for this event management
  will need revisiting in the future, but this model avoids lock
  order reversals when upcalls into other subsystems result in
  socket/socket buffer operations.  Assert that the socket buffer
  lock is not held at the end of the function.

- Wrapper macros for sowakeup(), sorwakeup() and sowwakeup(), now
  have _locked versions which assert the socket buffer lock on
  entry.  If a wakeup is required by sb_notify(), invoke
  sowakeup(); otherwise, unconditionally release the socket buffer
  lock.  This results in the socket buffer lock being released
  whether a wakeup is required or not.

- Break out socantsendmore() into socantsendmore_locked() that
  asserts the socket buffer lock.  socantsendmore()
  unconditionally locks the socket buffer before calling
  socantsendmore_locked().  Note that both functions return with
  the socket buffer unlocked as socantsendmore_locked() calls
  sowwakeup_locked() which has the same properties.  Assert that
  the socket buffer is unlocked on return.

- Break out socantrcvmore() into socantrcvmore_locked() that
  asserts the socket buffer lock.  socantrcvmore() unconditionally
  locks the socket buffer before calling socantrcvmore_locked().
  Note that both functions return with the socket buffer unlocked
  as socantrcvmore_locked() calls sorwakeup_locked() which has
  similar properties.  Assert that the socket buffer is unlocked
  on return.

- Break out sbrelease() into a sbrelease_locked() that asserts the
  socket buffer lock.  sbrelease() unconditionally locks the
  socket buffer before calling sbrelease_locked().
  sbrelease_locked() now invokes sbflush_locked() instead of
  sbflush().

- Assert the socket buffer lock in socket buffer sanity check
  functions sblastrecordchk(), sblastmbufchk().

- Assert the socket buffer lock in SBLINKRECORD().

- Break out various sbappend() functions into sbappend_locked()
  (and variations on that name) that assert the socket buffer
  lock.  The !_locked() variations unconditionally lock the socket
  buffer before calling their _locked counterparts.  Internally,
  make sure to call _locked() support routines, etc, if already
  holding the socket buffer lock.

- Break out sbinsertoob() into sbinsertoob_locked() that asserts
  the socket buffer lock.  sbinsertoob() unconditionally locks the
  socket buffer before calling sbinsertoob_locked().

- Break out sbflush() into sbflush_locked() that asserts the
  socket buffer lock.  sbflush() unconditionally locks the socket
  buffer before calling sbflush_locked().  Update panic strings
  for new function names.

- Break out sbdrop() into sbdrop_locked() that asserts the socket
  buffer lock.  sbdrop() unconditionally locks the socket buffer
  before calling sbdrop_locked().

- Break out sbdroprecord() into sbdroprecord_locked() that asserts
  the socket buffer lock.  sbdroprecord() unconditionally locks
  the socket buffer before calling sbdroprecord_locked().

- sofree() now calls socantsendmore_locked() and re-acquires the
  socket buffer lock on return.  It also now calls
  sbrelease_locked().

- sorflush() now calls socantrcvmore_locked() and re-acquires the
  socket buffer lock on return.  Clean up/mess up other behavior
  in sorflush() relating to the temporary stack copy of the socket
  buffer used with dom_dispose by more properly initializing the
  temporary copy, and selectively bzeroing/copying more carefully
  to prevent WITNESS from getting confused by improperly
  initialized mutexes.  Annotate why that's necessary, or at
  least, needed.

- soisconnected() now calls sbdrop_locked() before unlocking the
  socket buffer to avoid locking overhead.

Some parts of this change were:

Submitted by:	sam
Sponsored by:	FreeBSD Foundation
Obtained from:	BSD/OS
</content>
</entry>
<entry>
<title>avoid duplicate free.</title>
<updated>2004-01-25T17:18:12Z</updated>
<author>
<name>Hajimu UMEMOTO</name>
<email>ume@FreeBSD.org</email>
</author>
<published>2004-01-25T17:18:12Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=a8938746a3b4c995f5f3a51d2ca051c7ad6ddf53'/>
<id>urn:sha1:a8938746a3b4c995f5f3a51d2ca051c7ad6ddf53</id>
<content type='text'>
(though KAME doesn't decide how to fix it yet, I once commit it
to be in time for 5.2.1-RELEASE.)

Submitted by:	itojun
</content>
</entry>
<entry>
<title>invalidate secpolicy pcb cache on key_timehandler.  part of</title>
<updated>2004-01-14T04:39:40Z</updated>
<author>
<name>Hajimu UMEMOTO</name>
<email>ume@FreeBSD.org</email>
</author>
<published>2004-01-14T04:39:40Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=3b0105ca3062649c1bb498a5372937cea564b82d'/>
<id>urn:sha1:3b0105ca3062649c1bb498a5372937cea564b82d</id>
<content type='text'>
http://sources.zabbadoz.net/freebsd/patchset/110-ipsec-netkey-key.diff

Submitted by:	"Bjoern A. Zeeb" &lt;bzeeb+freebsd@zabbadoz.net&gt;
Reviewed by:	itojun
</content>
</entry>
<entry>
<title>add missing key_freesp()s.  part of</title>
<updated>2004-01-14T04:10:28Z</updated>
<author>
<name>Hajimu UMEMOTO</name>
<email>ume@FreeBSD.org</email>
</author>
<published>2004-01-14T04:10:28Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=e9c8752e567d4d4047b6cb5417eeb1b163abf0d5'/>
<id>urn:sha1:e9c8752e567d4d4047b6cb5417eeb1b163abf0d5</id>
<content type='text'>
http://sources.zabbadoz.net/freebsd/patchset/110-ipsec-netkey-key.diff
with some modification.

Submitted by:	"Bjoern A. Zeeb" &lt;bzeeb+freebsd@zabbadoz.net&gt;
Reviewed by:	itojun
Obtained from:	KAME
</content>
</entry>
<entry>
<title>don't touch after free.</title>
<updated>2003-12-10T05:01:41Z</updated>
<author>
<name>Hajimu UMEMOTO</name>
<email>ume@FreeBSD.org</email>
</author>
<published>2003-12-10T05:01:41Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=869a467690c0a1d4336a5e235d07d0a1b6c935f0'/>
<id>urn:sha1:869a467690c0a1d4336a5e235d07d0a1b6c935f0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>use callout_*() rather than timeout().</title>
<updated>2003-12-07T11:23:59Z</updated>
<author>
<name>Hajimu UMEMOTO</name>
<email>ume@FreeBSD.org</email>
</author>
<published>2003-12-07T11:23:59Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=7c1da7529a16d23f386a95851e0daa3cd59314ef'/>
<id>urn:sha1:7c1da7529a16d23f386a95851e0daa3cd59314ef</id>
<content type='text'>
</content>
</entry>
<entry>
<title>missing splx.</title>
<updated>2003-11-28T14:34:42Z</updated>
<author>
<name>Hajimu UMEMOTO</name>
<email>ume@FreeBSD.org</email>
</author>
<published>2003-11-28T14:34:42Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=dd8b0111cb37d1d383194ea4b113500d93376545'/>
<id>urn:sha1:dd8b0111cb37d1d383194ea4b113500d93376545</id>
<content type='text'>
this is a NOOP change, and primarily merged for consistency with
-STABLE.

Approved by:	re (rwatson)
</content>
</entry>
<entry>
<title>Introduce a MAC label reference in 'struct inpcb', which caches</title>
<updated>2003-11-18T00:39:07Z</updated>
<author>
<name>Robert Watson</name>
<email>rwatson@FreeBSD.org</email>
</author>
<published>2003-11-18T00:39:07Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=a557af222b70694470f63e2a0f1bf58c9dcc73fd'/>
<id>urn:sha1:a557af222b70694470f63e2a0f1bf58c9dcc73fd</id>
<content type='text'>
the   MAC label referenced from 'struct socket' in the IPv4 and
IPv6-based protocols.  This permits MAC labels to be checked during
network delivery operations without dereferencing inp-&gt;inp_socket
to get to so-&gt;so_label, which will eventually avoid our having to
grab the socket lock during delivery at the network layer.

This change introduces 'struct inpcb' as a labeled object to the
MAC Framework, along with the normal circus of entry points:
initialization, creation from socket, destruction, as well as a
delivery access control check.

For most policies, the inpcb label will simply be a cache of the
socket label, so a new protocol switch method is introduced,
pr_sosetlabel() to notify protocols that the socket layer label
has been updated so that the cache can be updated while holding
appropriate locks.  Most protocols implement this using
pru_sosetlabel_null(), but IPv4/IPv6 protocols using inpcbs use
the the worker function in_pcbsosetlabel(), which calls into the
MAC Framework to perform a cache update.

Biba, LOMAC, and MLS implement these entry points, as do the stub
policy, and test policy.

Reviewed by:	sam, bms
Obtained from:	TrustedBSD Project
Sponsored by:	DARPA, Network Associates Laboratories
</content>
</entry>
</feed>
