1. 21 3月, 2006 22 次提交
  2. 13 3月, 2006 3 次提交
  3. 12 3月, 2006 1 次提交
  4. 08 3月, 2006 1 次提交
  5. 28 2月, 2006 3 次提交
    • P
      [NETFILTER]: Restore {ipt,ip6t,ebt}_LOG compatibility · bafac2a5
      Patrick McHardy 提交于
      The nfnetlink_log infrastructure changes broke compatiblity of the LOG
      targets. They currently use whatever log backend was registered first,
      which means that if ipt_ULOG was loaded first, no messages will be printed
      to the ring buffer anymore.
      
      Restore compatiblity by using the old log functions by default and only use
      the nf_log backend if the user explicitly said so.
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      bafac2a5
    • H
      [IPSEC]: Kill post_input hook and do NAT-T in esp_input directly · 752c1f4c
      Herbert Xu 提交于
      The only reason post_input exists at all is that it gives us the
      potential to adjust the checksums incrementally in future which
      we ought to do.
      
      However, after thinking about it for a bit we can adjust the
      checksums without using this post_input stuff at all.  The crucial
      point is that only the inner-most NAT-T SA needs to be considered
      when adjusting checksums.  What's more, the checksum adjustment
      comes down to a single u32 due to the linearity of IP checksums.
      
      We just happen to have a spare u32 lying around in our skb structure :)
      When ip_summed is set to CHECKSUM_NONE on input, the value of skb->csum
      is currently unused.  All we have to do is to make that the checksum
      adjustment and voila, there goes all the post_input and decap structures!
      
      I've left in the decap data structures for now since it's intricately
      woven into the sec_path stuff.  We can kill them later too.
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      752c1f4c
    • H
      [IPSEC] esp: Kill unnecessary block and indentation · 4bf05ece
      Herbert Xu 提交于
      We used to keep sg on the stack which is why the extra block was useful.
      We've long since stopped doing that so let's kill the block and save
      some indentation.
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      4bf05ece
  6. 24 2月, 2006 2 次提交
  7. 20 2月, 2006 2 次提交
    • P
      [NETFILTER]: Fix outgoing redirects to loopback · 8e249f08
      Patrick McHardy 提交于
      When redirecting an outgoing packet to loopback, it keeps the original
      conntrack reference and information from the outgoing path, which
      falsely triggers the check for DNAT on input and the dst_entry is
      released to trigger rerouting. ip_route_input refuses to route the
      packet because it has a local source address and it is dropped.
      
      Look at the packet itself to dermine if it was NATed. Also fix a
      missing inversion that causes unneccesary xfrm lookups.
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      8e249f08
    • P
      [NETFILTER]: Fix NAT PMTUD problems · bc6e14b6
      Patrick McHardy 提交于
      ICMP errors are only SNATed when their source matches the source of the
      connection they are related to, otherwise the source address is not
      changed. This creates problems with ICMP frag. required messages
      originating from a router behind the NAT, if private IPs are used the
      packet has a good change of getting dropped on the path to its destination.
      
      Always NAT ICMP errors similar to the original connection.
      
      Based on report by Al Viro.
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      bc6e14b6
  8. 16 2月, 2006 2 次提交
  9. 15 2月, 2006 1 次提交
    • P
      [NETFILTER]: Fix xfrm lookup after SNAT · ee68cea2
      Patrick McHardy 提交于
      To find out if a packet needs to be handled by IPsec after SNAT, packets
      are currently rerouted in POST_ROUTING and a new xfrm lookup is done. This
      breaks SNAT of non-unicast packets to non-local addresses because the
      packet is routed as incoming packet and no neighbour entry is bound to the
      dst_entry. In general, it seems to be a bad idea to replace the dst_entry
      after the packet was already sent to the output routine because its state
      might not match what's expected.
      
      This patch changes the xfrm lookup in POST_ROUTING to re-use the original
      dst_entry without routing the packet again. This means no policy routing
      can be used for transport mode transforms (which keep the original route)
      when packets are SNATed to match the policy, but it looks like the best
      we can do for now.
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      ee68cea2
  10. 14 2月, 2006 1 次提交
  11. 10 2月, 2006 2 次提交