From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755330AbcHWUgf (ORCPT ); Tue, 23 Aug 2016 16:36:35 -0400 Received: from smtprelay0066.hostedemail.com ([216.40.44.66]:38878 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754726AbcHWUga (ORCPT ); Tue, 23 Aug 2016 16:36:30 -0400 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::::::,RULES_HIT:41:355:379:541:599:973:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2198:2199:2393:2553:2559:2562:2693:2828:3138:3139:3140:3141:3142:3352:3622:3653:3865:3866:3867:3868:3871:3873:3874:4321:5007:6119:7619:8603:10004:10400:10848:11232:11658:11783:11914:12043:12296:12517:12519:12663:12740:13069:13311:13357:13439:13894:14659:14721:21063:21067:21080:21434:30054:30090:30091,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:1,LUA_SUMMARY:none X-HE-Tag: seed26_4100516818c0e X-Filterd-Recvd-Size: 2447 Message-ID: <1471984445.3746.129.camel@perches.com> Subject: Re: CVE-2014-9900 fix is not upstream From: Joe Perches To: Al Viro , David Miller Cc: ben@decadent.org.uk, luis.henriques@canonical.com, avijitnsec@codeaurora.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Date: Tue, 23 Aug 2016 13:34:05 -0700 In-Reply-To: <20160823200941.GB2356@ZenIV.linux.org.uk> References: <1471959668-18209-1-git-send-email-luis.henriques@canonical.com> <20160823.094029.1244944495918162255.davem@davemloft.net> <1471973727.13300.162.camel@decadent.org.uk> <20160823.112406.549221808236512285.davem@davemloft.net> <20160823200941.GB2356@ZenIV.linux.org.uk> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.18.5.2-0ubuntu3 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2016-08-23 at 21:09 +0100, Al Viro wrote: > On Tue, Aug 23, 2016 at 11:24:06AM -0700, David Miller wrote: > > > On some versions and architectures.  Can you guarantee that you will > > > notice when an exception appears? > > Again, show me the assembler output exhibiting the lack of > > initialization, for this specific structure and situation. > > > > That's all that I'm asking. > ... and then we can file a bug report against the sodding compiler.  Note > that > struct ethtool_wolinfo { >         __u32   cmd; >         __u32   supported; >         __u32   wolopts; >         __u8    sopass[SOPASS_MAX]; // 6, actually > }; > is not going to *have* padding.  Not on anything even remotely sane. > If array of 6 char as member of a struct requires 64bit alignment on some > architecture, I would really like some of what the designers of that ABI > must have been smoking. try this on x86-64 $ pahole -C ethtool_wolinfo vmlinux struct ethtool_wolinfo { __u32                      cmd;                  /*     0     4 */ __u32                      supported;            /*     4     4 */ __u32                      wolopts;              /*     8     4 */ __u8                       sopass[6];            /*    12     6 */ /* size: 20, cachelines: 1, members: 4 */ /* padding: 2 */ /* last cacheline: 20 bytes */ };