On Sun, Nov 11, 2012 at 7:36 PM, Jan Engelhardt <jengelh@xxxxxxx> wrote: > > On Sunday 2012-11-11 11:56, Aft nix wrote: >> >>static struct xt_target obsf_tg_reg __read_mostly = { >> >> .name = "OBSF", >> .family = NFPROTO_UNSPEC, >> .target = obsf_tg, >> .checkentry = obsf_tg_check, >> .targetsize = sizeof(struct xt_OBSF_tginfo), >> .me = THIS_MODULE, >>}; >> >>static struct nf_hook_ops inward_obsf_ops __read_mostly = { >> .pf = NFPROTO_IPV4, >> .priority = 1, >> .hooknum = NF_INET_PRE_ROUTING, >> .hook = ibss_obsf_inward_begin, >>}; >> >>a) Between ibss_obsf_inward_begin() and obsf_tg() who will be called first? > > The filter,mangle,etc. tables all have a specific and different priority > assigned (git grep NF_IP_PRI_ include/). Hi jan, Thanks for the reply. Now mangle tables has this: include/uapi/linux/netfilter_ipv4.h: NF_IP_PRI_MANGLE = -150, What i get from this list that which table will get priority. But i'm trying to know which function will be called first? I guess i should build a demo module to test to see which one called first. But i'm still confused about which function (one registered with struct xt_target , another registered with struct nf_hook_ops) will get priority? How does a table associated with different chains? -- -aft -- 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