Skip to content
  1. May 05, 2005
  2. May 03, 2005
    • Herbert Xu's avatar
      [NETLINK]: Synchronous message processing. · 2a0a6ebe
      Herbert Xu authored
      
      
      Let's recap the problem.  The current asynchronous netlink kernel
      message processing is vulnerable to these attacks:
      
      1) Hit and run: Attacker sends one or more messages and then exits
      before they're processed.  This may confuse/disable the next netlink
      user that gets the netlink address of the attacker since it may
      receive the responses to the attacker's messages.
      
      Proposed solutions:
      
      a) Synchronous processing.
      b) Stream mode socket.
      c) Restrict/prohibit binding.
      
      2) Starvation: Because various netlink rcv functions were written
      to not return until all messages have been processed on a socket,
      it is possible for these functions to execute for an arbitrarily
      long period of time.  If this is successfully exploited it could
      also be used to hold rtnl forever.
      
      Proposed solutions:
      
      a) Synchronous processing.
      b) Stream mode socket.
      
      Firstly let's cross off solution c).  It only solves the first
      problem and it has user-visible impacts.  In particular, it'll
      break user space applications that expect to bind or communicate
      with specific netlink addresses (pid's).
      
      So we're left with a choice of synchronous processing versus
      SOCK_STREAM for netlink.
      
      For the moment I'm sticking with the synchronous approach as
      suggested by Alexey since it's simpler and I'd rather spend
      my time working on other things.
      
      However, it does have a number of deficiencies compared to the
      stream mode solution:
      
      1) User-space to user-space netlink communication is still vulnerable.
      
      2) Inefficient use of resources.  This is especially true for rtnetlink
      since the lock is shared with other users such as networking drivers.
      The latter could hold the rtnl while communicating with hardware which
      causes the rtnetlink user to wait when it could be doing other things.
      
      3) It is still possible to DoS all netlink users by flooding the kernel
      netlink receive queue.  The attacker simply fills the receive socket
      with a single netlink message that fills up the entire queue.  The
      attacker then continues to call sendmsg with the same message in a loop.
      
      Point 3) can be countered by retransmissions in user-space code, however
      it is pretty messy.
      
      In light of these problems (in particular, point 3), we should implement
      stream mode netlink at some point.  In the mean time, here is a patch
      that implements synchronous processing.  
      
      Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      2a0a6ebe
    • Russ Anderson's avatar
      [patch] MCA recovery module undefined symbol fix · 012914da
      Russ Anderson authored
      
      
      The patch "MCA recovery improvements" added do_exit to mca_drv.c.
      That's fine when the mca recovery code is built in the kernel
      (CONFIG_IA64_MCA_RECOVERY=y) but breaks building the mca recovery
      code as a module (CONFIG_IA64_MCA_RECOVERY=m).
      
      Most users are currently building this as a module, as loading
      and unloading the module provides a very convenient way to turn
      on/off error recovery.
      
      This patch exports do_exit, so mca_drv.c can build as a module.
      
      Signed-off-by: default avatarRuss Anderson <(rja@sgi.com)>
      Signed-off-by: default avatarTony Luck <tony.luck@intel.com>
      012914da
    • Chris Wright's avatar
      [PATCH] add new audit data to last skb · 0dd8e06b
      Chris Wright authored
      
      
      When adding more formatted audit data to an skb for delivery to userspace,
      the kernel will attempt to reuse an skb that has spare room.  However, if
      the audit message has already been fragmented to multiple skb's, the search
      for spare room in the skb uses the head of the list.  This will corrupt the
      audit message with trailing bytes being placed midway through the stream.
      Fix is to look at the end of the list.
      
      Signed-off-by: default avatarChris Wright <chrisw@osdl.org>
      Signed-off-by: default avatarDavid Woodhouse <dwmw2@infradead.org>
      0dd8e06b
  3. May 01, 2005
  4. Apr 29, 2005
  5. Apr 28, 2005
    • Christoph Lameter's avatar
      [PATCH] time interpolator: Fix settimeofday inaccuracy · 9acf6597
      Christoph Lameter authored
      
      
      settimeofday will set the time a little bit too early on systems using
      time interpolation since it subtracts the current interpolator offset
      from the time. This used to be necessary with the code in 2.6.9 and earlier
      but the new code resets the time interpolator after setting the time.
      Thus the time is set too early and gettimeofday will return a time slightly
      before the time specified with settimeofday if invoked immeditely after
      settimeofday.
      
      This removes the obsolete subtraction of the time interpolator offset
      and makes settimeofday set the time accurately. 
      
      Signed-off-by: default avatarChristoph Lameter <clameter@sgi.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      9acf6597
  6. Apr 25, 2005
  7. Apr 18, 2005
  8. Apr 16, 2005
Loading