lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 22 May 2013 22:11:35 +0400
From:	Sergei Shtylyov <sergei.shtylyov@...entembedded.com>
To:	Simon Horman <horms@...ge.net.au>
CC:	Pablo Neira Ayuso <pablo@...filter.org>, lvs-devel@...r.kernel.org,
	netdev@...r.kernel.org, netfilter-devel@...r.kernel.org,
	Wensong Zhang <wensong@...ux-vs.org>,
	Julian Anastasov <ja@....bg>,
	Grzegorz Lyczba <grzegorz.lyczba@...il.com>
Subject: Re: [PATCH 2/2] ipvs: Fix reuse connection if real server is dead

Hello.

On 22-05-2013 9:56, Simon Horman wrote:

> From: Grzegorz Lyczba <grzegorz.lyczba@...il.com>

> Expire cached connection for new TCP/SCTP connection if real server is down

> Signed-off-by: Grzegorz Lyczba <grzegorz.lyczba@...il.com>
> Acked-by Hans Schillstrom <hans@...illstrom.com>

    Missing :.

> Signed-off-by: Simon Horman <horms@...ge.net.au>
> ---
>   net/netfilter/ipvs/ip_vs_core.c | 36 ++++++++++++++++++++++++++++++++++++
>   1 file changed, 36 insertions(+)

> diff --git a/net/netfilter/ipvs/ip_vs_core.c b/net/netfilter/ipvs/ip_vs_core.c
> index 085b588..7967d12 100644
> --- a/net/netfilter/ipvs/ip_vs_core.c
> +++ b/net/netfilter/ipvs/ip_vs_core.c
> @@ -1001,6 +1001,33 @@ static inline int is_tcp_reset(const struct sk_buff *skb, int nh_len)
>   	return th->rst;
>   }
>
> +static inline bool is_new_conn(const struct sk_buff *skb,
> +			       struct ip_vs_iphdr *iph)
> +{
> +	switch (iph->protocol) {
> +	case IPPROTO_TCP: {
> +		struct tcphdr _tcph, *th;
> +
> +		th = skb_header_pointer(skb, iph->len, sizeof(_tcph), &_tcph);
> +		if (th == NULL)
> +			return false;
> +		return th->syn;
> +	}
> +	case IPPROTO_SCTP: {
> +		sctp_chunkhdr_t *sch, schunk;
> +
> +		sch = skb_header_pointer(skb, iph->len + sizeof(sctp_sctphdr_t),
> +				sizeof(schunk), &schunk);

    This line should be aligned under the next character after (.

> +		if (sch == NULL)
> +			return false;
> +		return (sch->type == SCTP_CID_INIT);

    () not needed.

> +	}
> +	default:
> +		return false;
> +	}
> +}
> +
> +

    Too many empty lines?

WBR, Sergei

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ