From mboxrd@z Thu Jan 1 00:00:00 1970 From: "H. Peter Anvin" Subject: Re: [PATCH 2/3] [RFC] seccomp: give BPF x32 bit when restoring x32 filter Date: Fri, 11 Jul 2014 09:13:48 -0700 Message-ID: <53C00D3C.7080808@zytor.com> References: <6a69eb94b4cfac5f94b229c2eb2ebc402aac722a.1405023592.git.rgb@redhat.com> <53BF62AA.20105@zytor.com> <1458762.ra4TnS54ZN@sifl> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1458762.ra4TnS54ZN@sifl> Sender: linux-kernel-owner@vger.kernel.org To: Paul Moore Cc: Richard Guy Briggs , linux-audit@redhat.com, linux-kernel@vger.kernel.org, Eric Paris , Al Viro , Will Drewry List-Id: linux-audit@redhat.com On 07/11/2014 09:11 AM, Paul Moore wrote: > On Thursday, July 10, 2014 09:06:02 PM H. Peter Anvin wrote: >> Incidentally: do seccomp users know that on an x86-64 system you can >> recevie system calls from any of the x86 architectures, regardless of >> how the program is invoked? (This is unusual, so normally denying those >> "alien" calls is the right thing to do.) > > I obviously can't speak for all seccomp users, but libseccomp handles this by > checking the seccomp_data->arch value at the start of the filter and killing > (by default) any non-native architectures. If you want, you can change this > default behavior or add support for other architectures (e.g. create a filter > that allows both x86-64 and x32 but disallows x86, or any combination of the > three for that matter). > OK, that seems reasonable. -hpa