Skip to content
Snippets Groups Projects
  1. Apr 11, 2014
    • David S. Miller's avatar
      net: Fix use after free by removing length arg from sk_data_ready callbacks. · 676d2369
      David S. Miller authored
      
      Several spots in the kernel perform a sequence like:
      
      	skb_queue_tail(&sk->s_receive_queue, skb);
      	sk->sk_data_ready(sk, skb->len);
      
      But at the moment we place the SKB onto the socket receive queue it
      can be consumed and freed up.  So this skb->len access is potentially
      to freed up memory.
      
      Furthermore, the skb->len can be modified by the consumer so it is
      possible that the value isn't accurate.
      
      And finally, no actual implementation of this callback actually uses
      the length argument.  And since nobody actually cared about it's
      value, lots of call sites pass arbitrary values in such as '0' and
      even '1'.
      
      So just remove the length argument from the callback, that way there
      is no confusion whatsoever and all of these use-after-free cases get
      fixed as a side effect.
      
      Based upon a patch by Eric Dumazet and his suggestion to audit this
      issue tree-wide.
      
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      676d2369
  2. Apr 04, 2014
  3. Sep 12, 2013
  4. Jul 04, 2013
  5. Feb 28, 2013
  6. Feb 22, 2013
  7. Jan 09, 2013
  8. Apr 21, 2012
  9. Nov 01, 2011
  10. Jul 24, 2011
  11. Mar 31, 2011
  12. Mar 28, 2011
  13. Jan 08, 2011
  14. Dec 23, 2010
  15. Dec 16, 2010
  16. Oct 08, 2010
    • Sunil Mushran's avatar
      · 0e105d37
      Sunil Mushran authored
      ocfs2/cluster: Check slots for unconfigured live nodes
      
      o2hb currently checks slots for configured nodes only. This patch makes
      it check the slots for the live nodes too to take care of a race in which
      a node is removed from the configuration but not from the live map.
      
      Signed-off-by: default avatarSunil Mushran <sunil.mushran@oracle.com>
      0e105d37
  17. Sep 18, 2010
  18. Aug 07, 2010
  19. May 06, 2010
  20. Mar 13, 2010
  21. Feb 08, 2010
  22. Jan 26, 2010
  23. Jun 15, 2009
  24. Oct 31, 2008
  25. Aug 22, 2008
  26. May 31, 2008
  27. Apr 18, 2008
    • Sunil Mushran's avatar
      ocfs2/net: Add debug interface to o2net · 2309e9e0
      Sunil Mushran authored
      
      This patch exposes o2net information via debugfs. The information includes
      the list of sockets (sock_containers) as well as the list of outstanding
      messages (send_tracking). Useful for o2dlm debugging.
      
      (This patch is derived from an earlier one written by Zach Brown that
      exposed the same information via /proc.)
      
      [Mark: checkpatch fixes]
      
      Signed-off-by: default avatarSunil Mushran <sunil.mushran@oracle.com>
      Reviewed-by: default avatarJoel Becker <joel.becker@oracle.com>
      Signed-off-by: default avatarMark Fasheh <mfasheh@suse.com>
      2309e9e0
    • Jeff Mahoney's avatar
      ocfs2/cluster: Get rid of arguments to the timeout routines · 409753bf
      Jeff Mahoney authored
      
      We keep seeing bug reports related to NULL pointer derefs in
      o2net_set_nn_state(). When I originally wrote up the configurable timeout
      patch, I had tried to plan for multiple clusters. This was silly.
      
      The timeout routines all use o2nm_single_cluster so there's no point in
      passing an argument at all. This patch removes the arguments and kills those
      bugs dead.
      
      Signed-off-by: default avatarJeff Mahoney <jeffm@suse.com>
      Signed-off-by: default avatarMark Fasheh <mfasheh@suse.com>
      409753bf
    • Tao Ma's avatar
      ocfs2: Reconnect after idle time out. · 5cc3bf27
      Tao Ma authored
      
      Currently, o2net connects to a node on hb_up and disconnects on
      hb_down and net timeout.
      
      It disconnects on net timeout is ok, but it should attempt to
      reconnect back. This is because sometimes nodes get overloaded
      enough that the network connection breaks but the disk hb does not.
      And if we get into that situation, we either fence (unnecessarily)
      or wait for its disk hb to die (and sometimes hang in the process).
      
      So in this updated scheme, when the network disconnects, we keep
      attempting to reconnect till we succeed or we get a disk hb down
      event.
      
      If the other node is really dead, then we will eventually get a
      node down event. If not, we should be able to connect again and
      continue.
      
      Signed-off-by: default avatarTao Ma <tao.ma@oracle.com>
      Signed-off-by: default avatarMark Fasheh <mfasheh@suse.com>
      5cc3bf27
  28. Mar 10, 2008
  29. Dec 05, 2007
  30. Nov 13, 2007
Loading