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]
Message-ID: <20160822144358.m5jwuzvmgic4e7xw@alphalink.fr>
Date:   Mon, 22 Aug 2016 16:43:58 +0200
From:   Guillaume Nault <g.nault@...halink.fr>
To:     fgao@...ai8.com
Cc:     jchapman@...alix.com, philipp@...fish-solutions.com,
        davem@...emloft.net, netdev@...r.kernel.org, gfree.wind@...il.com
Subject: Re: [PATCH v4 net-next] l2tp: Refactor the codes with existing
 macros instead of literal number

On Mon, Aug 22, 2016 at 06:59:51PM +0800, fgao@...ai8.com wrote:
> From: Gao Feng <fgao@...ai8.com>
> 
> Use PPP_ALLSTATIONS, PPP_UI, and SEND_SHUTDOWN instead of 0xff,
> 0x03, and 2 separately.
> 
Apart from the checkpatch errors,

Acked-by: Guillaume Nault <g.nault@...halink.fr>

> @@ -325,8 +324,8 @@ static int pppol2tp_sendmsg(struct socket *sock, struct msghdr *m,
>  	skb_reserve(skb, uhlen);
>  
>  	/* Add PPP header */
> -	skb->data[0] = ppph[0];
> -	skb->data[1] = ppph[1];
> +	skb->data[0] = PPP_ALLSTATIONS; 
> 
Trailing whitespace.

> @@ -398,14 +396,14 @@ static int pppol2tp_xmit(struct ppp_channel *chan, struct sk_buff *skb)
>  		   sizeof(struct iphdr) + /* IP header */
>  		   uhlen +		/* UDP header (if L2TP_ENCAPTYPE_UDP) */
>  		   session->hdr_len +	/* L2TP header */
> -		   sizeof(ppph);	/* PPP header */
> +		   2;			/* 2 bytes for PPP_ALLSTATIONS & PPP_UI */
>  	if (skb_cow_head(skb, headroom))
>  		goto abort_put_sess_tun;
>  
>  	/* Setup PPP header */
> -	__skb_push(skb, sizeof(ppph));
> -	skb->data[0] = ppph[0];
> -	skb->data[1] = ppph[1];
> +	__skb_push(skb, 2); 
> 
Here too.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ