On Wed, Dec 5, 2012 at 4:45 PM, Willem de Bruijn <willemb@xxxxxxxxxx> wrote: > On Wed, Dec 5, 2012 at 3:00 PM, Jan Engelhardt <jengelh@xxxxxxx> wrote: >> On Wednesday 2012-12-05 20:28, Willem de Bruijn wrote: >> >>>Somehow, the first part of this email went missing. Not critical, >>>but for completeness: >>> >>>These two patches each add an xtables match. >>> >>>The xt_priority match is a straighforward addition in the style of >>>xt_mark, adding the option to filter on one more sk_buff field. I >>>have an immediate application for this. The amount of code (in >>>kernel + userspace) to add a single check proved quite large. >> >> Hm so yeah, can't we just place this in xt_mark.c? > > I'm happy to do so, but note that that breaks the custom of > having one static struct xt_$NAME for each file xt_$NAME.[ch]. > > It may be reasonable, as the same issue may keep popping up > as additional sk_buff fields are found useful for filtering. For > instance, skb->queue_mapping could be used in conjuction with > network flow classification (ethtool -N). bad example: queue_mapping is tx only. I thought of rxqueues. > All the ancillary data > accessible from BPF likely has some use and could be ported > to iptables (rxhash, pkt_type, ...). > > To avoid rule explosion, I considered an xt_skbuff match rule that > applies the same mask operation, range and inversion tests, and > takes a field id to select the sk_buff field to operate on. I think > the BPF patch is a better long term solution. -- To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html