-
Notifications
You must be signed in to change notification settings - Fork 0
/
linux-2.6-527-iptables-classify-add-mark.patch
24 lines (20 loc) · 1.25 KB
/
linux-2.6-527-iptables-classify-add-mark.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
diff -NurpP --exclude '*.orig' --exclude '*.rej' linux-2.6.27.10-vs2.3.x-PS-522-523-524-525-526/include/linux/netfilter/xt_CLASSIFY.h linux-2.6.27.10-vs2.3.x-PS-522-523-524-525-526-527/include/linux/netfilter/xt_CLASSIFY.h
--- linux-2.6.27.10-vs2.3.x-PS-522-523-524-525-526/include/linux/netfilter/xt_CLASSIFY.h 2008-07-13 23:51:29.000000000 +0200
+++ linux-2.6.27.10-vs2.3.x-PS-522-523-524-525-526-527/include/linux/netfilter/xt_CLASSIFY.h 2009-01-21 03:49:25.000000000 +0100
@@ -3,6 +3,7 @@
struct xt_classify_target_info {
u_int32_t priority;
+ u_int8_t add_mark;
};
#endif /*_XT_CLASSIFY_H */
diff -NurpP --exclude '*.orig' --exclude '*.rej' linux-2.6.27.10-vs2.3.x-PS-522-523-524-525-526/net/netfilter/xt_CLASSIFY.c linux-2.6.27.10-vs2.3.x-PS-522-523-524-525-526-527/net/netfilter/xt_CLASSIFY.c
--- linux-2.6.27.10-vs2.3.x-PS-522-523-524-525-526/net/netfilter/xt_CLASSIFY.c 2008-07-13 23:51:29.000000000 +0200
+++ linux-2.6.27.10-vs2.3.x-PS-522-523-524-525-526-527/net/netfilter/xt_CLASSIFY.c 2009-01-21 03:51:49.000000000 +0100
@@ -34,6 +34,9 @@ classify_tg(struct sk_buff *skb, const s
const struct xt_classify_target_info *clinfo = targinfo;
skb->priority = clinfo->priority;
+ if (clinfo->add_mark)
+ skb->priority += skb->mark;
+
return XT_CONTINUE;
}