1. 01 2月, 2008 2 次提交
  2. 29 1月, 2008 5 次提交
  3. 16 10月, 2007 1 次提交
  4. 11 7月, 2007 4 次提交
  5. 11 5月, 2007 1 次提交
  6. 16 11月, 2006 1 次提交
  7. 25 9月, 2006 1 次提交
  8. 23 9月, 2006 6 次提交
  9. 02 5月, 2006 1 次提交
    • P
      [NETFILTER] x_tables: fix compat related crash on non-x86 · 46c5ea3c
      Patrick McHardy 提交于
      When iptables userspace adds an ipt_standard_target, it calculates the size
      of the entire entry as:
      
      sizeof(struct ipt_entry) + XT_ALIGN(sizeof(struct ipt_standard_target))
      
      ipt_standard_target looks like this:
      
        struct xt_standard_target
        {
              struct xt_entry_target target;
              int verdict;
        };
      
      xt_entry_target contains a pointer, so when compiled for 64 bit the
      structure gets an extra 4 byte of padding at the end. On 32 bit
      architectures where iptables aligns to 8 byte it will also have 4
      byte padding at the end because it is only 36 bytes large.
      
      The compat_ipt_standard_fn in the kernel adjusts the offsets by
      
        sizeof(struct ipt_standard_target) - sizeof(struct compat_ipt_standard_target),
      
      which will always result in 4, even if the structure from userspace
      was already padded to a multiple of 8. On x86 this works out by
      accident because userspace only aligns to 4, on all other
      architectures this is broken and causes incorrect adjustments to
      the size and following offsets.
      
      Thanks to Linus for lots of debugging help and testing.
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      46c5ea3c
  10. 25 4月, 2006 1 次提交
  11. 01 4月, 2006 1 次提交
  12. 23 3月, 2006 2 次提交
  13. 21 3月, 2006 3 次提交
  14. 21 1月, 2006 1 次提交
  15. 20 1月, 2006 1 次提交
  16. 13 1月, 2006 1 次提交
    • H
      [NETFILTER] x_tables: Abstraction layer for {ip,ip6,arp}_tables · 2e4e6a17
      Harald Welte 提交于
      This monster-patch tries to do the best job for unifying the data
      structures and backend interfaces for the three evil clones ip_tables,
      ip6_tables and arp_tables.  In an ideal world we would never have
      allowed this kind of copy+paste programming... but well, our world
      isn't (yet?) ideal.
      
      o introduce a new x_tables module
      o {ip,arp,ip6}_tables depend on this x_tables module
      o registration functions for tables, matches and targets are only
        wrappers around x_tables provided functions
      o all matches/targets that are used from ip_tables and ip6_tables
        are now implemented as xt_FOOBAR.c files and provide module aliases
        to ipt_FOOBAR and ip6t_FOOBAR
      o header files for xt_matches are in include/linux/netfilter/,
        include/linux/netfilter_{ipv4,ipv6} contains compatibility wrappers
        around the xt_FOOBAR.h headers
      
      Based on this patchset we're going to further unify the code,
      gradually getting rid of all the layer 3 specific assumptions.
      Signed-off-by: NHarald Welte <laforge@netfilter.org>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2e4e6a17