LVS
lvs-devel
Google
 
Web LinuxVirtualServer.org

Re: [*v4 PATCH 9/9] IPVS: skb defrag in L7 helpers BAD version

To: "horms@xxxxxxxxxxxx" <horms@xxxxxxxxxxxx>
Subject: Re: [*v4 PATCH 9/9] IPVS: skb defrag in L7 helpers BAD version
Cc: "ja@xxxxxx" <ja@xxxxxx>, "lvs-devel@xxxxxxxxxxxxxxx" <lvs-devel@xxxxxxxxxxxxxxx>, "wensong@xxxxxxxxxxxx" <wensong@xxxxxxxxxxxx>
From: Hans Schillstrom <hans.schillstrom@xxxxxxxxxxxx>
Date: Fri, 12 Nov 2010 10:45:20 +0100
On Friday 12 November 2010 10:41:32 Hans Schillström wrote:
> L7 helpers like sip needs skb defrag
> since L7 data can be fragmented.
> 
> This patch requires "IPVS Break ports-2 into src_port and dst_port" patch
> 
> *v3
>   Removed unneeded if (skb_shinfo(skb)->nr_frags)
>   from Julian.
> 
> Signed-off-by: Hans Schillstrom <hans.schillstrom@xxxxxxxxxxxx>
> ---
>  net/netfilter/ipvs/ip_vs_pe_sip.c |    3 +++
>  1 files changed, 3 insertions(+), 0 deletions(-)
> 
> diff --git a/net/netfilter/ipvs/ip_vs_pe_sip.c 
> b/net/netfilter/ipvs/ip_vs_pe_sip.c
> index b8b4e96..0d83bc0 100644
> --- a/net/netfilter/ipvs/ip_vs_pe_sip.c
> +++ b/net/netfilter/ipvs/ip_vs_pe_sip.c
> @@ -71,6 +71,7 @@ ip_vs_sip_fill_param(struct ip_vs_conn_param *p, struct 
> sk_buff *skb)
>       struct ip_vs_iphdr iph;
>       unsigned int dataoff, datalen, matchoff, matchlen;
>       const char *dptr;
> +     int retc;
>  
>       ip_vs_fill_iphdr(p->af, skb_network_header(skb), &iph);
>  
> @@ -83,6 +84,8 @@ ip_vs_sip_fill_param(struct ip_vs_conn_param *p, struct 
> sk_buff *skb)
>       if (dataoff >= skb->len)
>               return -EINVAL;
>  
> +     if ((retc=skb_linearize(skb)) < 0)
> +             return retc;
>       dptr = skb->data + dataoff;
>       datalen = skb->len - dataoff;
>  

The correct version shoud be v3 (not v4)
-- 
Regards
Hans Schillstrom <hans.schillstrom@xxxxxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe lvs-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

<Prev in Thread] Current Thread [Next in Thread>