Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1120058imm; Wed, 23 May 2018 10:34:50 -0700 (PDT) X-Google-Smtp-Source: AB8JxZo+VKk9Ik6pYpT/JvVi9UkzkK2xQYMN9/uvvBh8KUNk4IArJDKr153ous/QWX2/jjpLFGG6 X-Received: by 2002:a65:4a03:: with SMTP id s3-v6mr3020590pgq.376.1527096890879; Wed, 23 May 2018 10:34:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527096890; cv=none; d=google.com; s=arc-20160816; b=ucqTPrOavCgbHUKOoqz2R6HNzy59oVx2rJWlPEJ3tgedqMo2LhPBuyZ3KFKd/6XU+K FXAxfpWkSCJJLP9r0DYph6d9YJOVAhd6RTn4cJqWzmckRiOnj8BCUYFbM0IbOH7IKfcx +ZIKLzzF78Q+2qW/4tHsL8AuTsaVcC5M7xazJi4X1IEyIRrb6SNFSstmNqF0ZcAWN8cT 3MTkzh9w2cWRxvrg/HEwf3sCXROlbIKbFDtnMygUANkA/YQunydkpWY5g3bCjeTkUR9q EwjNkaRk0eCgt6MQrUOnuSbKeoarp4lNHvWA46uKp8Dnv8NSmaN+HyGDiQZPOISQvpzW LRxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=J4U6648KUtz04Uc8Zsz6/r0mzpNM3o+bGK+EQhLiss4=; b=t+irDvvRwxGLs4BlNzOjIUy6CHl+ayUp1QgUe6Y2e7CZiodftjJ7nf+RN6tMrhWgUR XL8YDhBC7Zto+Q3U6cBhS/YFZ9K2TOaPllIwJLVbPdruDlPRMq9nTKwBWhKgJyVnRTvd YtlmwQq76wVzEMmmwj2VgqRmNuZ2hKo+hBObA6Z9Avo9EKj8OhuV0IH8WiPplP0Dj2F/ XIFjXb+aSpI9FQDxM1zoeLSKVEcJ7uD5QzvaXGAIxk3hTHHZwFjvESlEyNBILW9JDkxj s/rIrfbaQTYCfSnMcM9wr2nO+zERQ8K3quXzz/Bb1iaudid7Crf5Gfnlc0ILsQiT1aNM ZxVg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=v960WmB3; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d10-v6si15645968pgu.626.2018.05.23.10.34.35; Wed, 23 May 2018 10:34:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=v960WmB3; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933851AbeEWReX (ORCPT + 99 others); Wed, 23 May 2018 13:34:23 -0400 Received: from mail.kernel.org ([198.145.29.99]:38248 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932667AbeEWReV (ORCPT ); Wed, 23 May 2018 13:34:21 -0400 Received: from localhost (LFbn-1-12247-202.w90-92.abo.wanadoo.fr [90.92.61.202]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 408022086E; Wed, 23 May 2018 17:34:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1527096860; bh=mMoK620kdaW7rSnNNDmgNSSrv2xXWNZ7FEvGHkq3erw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=v960WmB38h4NEVA3oPNMuYexpmywh3DKOxbxknbmDwbFbVcAPUhSkVcmQ4+5j1EMP lOsp8CaTfWbMWdO9yUkzDJbLtz3DaLE2eu1HqU4WgyA7v4VrxuvEvCo0B3BmCgP6Rh CKcuHcCW4zExt2NAmbl1yp6qbxfWuf+3QCmcEdbw= Date: Wed, 23 May 2018 19:33:51 +0200 From: Greg KH To: David Miller Cc: ast@kernel.org, daniel@iogearbox.net, torvalds@linux-foundation.org, luto@amacapital.net, mcgrof@kernel.org, keescook@chromium.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, kernel-team@fb.com Subject: Re: [PATCH v3 net-next 0/2] bpfilter Message-ID: <20180523173351.GA10104@kroah.com> References: <20180522022230.2492505-1-ast@kernel.org> <20180523.132648.459690706167609338.davem@davemloft.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180523.132648.459690706167609338.davem@davemloft.net> User-Agent: Mutt/1.10.0 (2018-05-17) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 23, 2018 at 01:26:48PM -0400, David Miller wrote: > From: Alexei Starovoitov > Date: Mon, 21 May 2018 19:22:28 -0700 > > > v2->v3: > > - followed Luis's suggestion and significantly simplied first patch > > with shmem_kernel_file_setup+kernel_write. Added kdoc for new helper > > - fixed typos and race to access pipes with mutex > > - tested with bpfilter being 'builtin'. CONFIG_BPFILTER_UMH=y|m both work. > > Interesting to see a usermode executable being embedded inside vmlinux. > > - it doesn't hurt to enable bpfilter in .config. > > ip_setsockopt commands sent to usermode via pipes and -ENOPROTOOPT is > > returned from userspace, so kernel falls back to original iptables code > > > > v1->v2: > > this patch set is almost a full rewrite of the earlier umh modules approach > > The v1 of patches and follow up discussion was covered by LWN: > > https://lwn.net/Articles/749108/ > > > > I believe the v2 addresses all issues brought up by Andy and others. > > Mainly there are zero changes to kernel/module.c > > Instead of teaching module loading logic to recognize special > > umh module, let normal kernel modules execute part of its own > > .init.rodata as a new user space process (Andy's idea) > > Patch 1 introduces this new helper: > > int fork_usermode_blob(void *data, size_t len, struct umh_info *info); > > Input: > > data + len == executable file > > Output: > > struct umh_info { > > struct file *pipe_to_umh; > > struct file *pipe_from_umh; > > pid_t pid; > > }; > > Series applied, let the madness begin... :-) Yeah, this is going to be fun :)