From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx3-rdu2.redhat.com ([66.187.233.73]:33980 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751112AbeERPi0 (ORCPT ); Fri, 18 May 2018 11:38:26 -0400 Date: Fri, 18 May 2018 11:38:25 -0400 From: Steve Grubb To: Richard Guy Briggs Cc: cgroups@vger.kernel.org, containers@lists.linux-foundation.org, linux-api@vger.kernel.org, Linux-Audit Mailing List , linux-fsdevel@vger.kernel.org, LKML , netdev@vger.kernel.org, ebiederm@xmission.com, luto@kernel.org, jlayton@redhat.com, carlos@redhat.com, dhowells@redhat.com, viro@zeniv.linux.org.uk, simo@redhat.com, eparis@parisplace.org, serge@hallyn.com Subject: Re: [RFC PATCH ghak32 V2 01/13] audit: add container id Message-ID: <20180518113825.4ceeadf6@ivy-bridge> In-Reply-To: <20180518152106.do5b3mu6e6eyvo7q@madcap2.tricolour.ca> References: <20180517170053.7d4afa87@ivy-bridge> <20180517215600.dyswlkvqdtgjwr5y@madcap2.tricolour.ca> <20180518095636.56ff322d@ivy-bridge> <20180518152106.do5b3mu6e6eyvo7q@madcap2.tricolour.ca> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-fsdevel-owner@vger.kernel.org List-ID: On Fri, 18 May 2018 11:21:06 -0400 Richard Guy Briggs wrote: > On 2018-05-18 09:56, Steve Grubb wrote: > > On Thu, 17 May 2018 17:56:00 -0400 > > Richard Guy Briggs wrote: > > > > > > During syscall events, the path info is returned in a a record > > > > simply called AUDIT_PATH, cwd info is returned in AUDIT_CWD. So, > > > > rather than calling the record that gets attached to everything > > > > AUDIT_CONTAINER_INFO, how about simply AUDIT_CONTAINER. > > > > > > Considering the container initiation record is different than the > > > record to document the container involved in an otherwise normal > > > syscall, we need two names. I don't have a strong opinion what > > > they are. > > > > > > I'd prefer AUDIT_CONTAIN and AUDIT_CONTAINER_INFO so that the two > > > are different enough to be visually distinct while leaving > > > AUDIT_CONTAINERID for the field type in patch 4 ("audit: add > > > containerid filtering") > > (Sorry, I had intended AUDIT_CONTAINER for the first in that paragraph > above.) > > > How about AUDIT_CONTAINER for the auxiliary record? The one that > > starts the container, I don't have a strong opinion on. Could be > > AUDIT_CONTAINER_INIT, AUDIT_CONTAINER_START, AUDIT_CONTAINERID, > > AUDIT_CONTAINER_ID, or something else. The API call that sets the ID > > for filtering could be AUDIT_CID or AUDIT_CONTID if that helps > > decide what the initial event might be. Normally, it should match > > the field being filtered. > > Ok, I had shortened the record field name to "contid=" to be unique > enough while not using too much netlink bandwidth. I could have used > "cid=" but that could be unobvious or ambiguous. I didn't want to use > the full "containerid=" due to that. I suppose I could change the > field name macro to AUDIT_CONTID. > > For the one that starts the container, I'd prefer to leave the name a > bit more general than "_INIT", "_START", so maybe I'll swap them > around and use AUDIT_CONTAINER_INFO for the startup record, and use > AUDIT_CONTAINER for the syscall auxiliary record. > > Does that work? I'll go along with that. Thanks. But making that swap frees up AUDIT_CONTAINER_ID which could be the first event. But AUDIT_CONTAINER_INFO is also fine with me. Best Regards, -Steve