Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752122AbdHHNWd convert rfc822-to-8bit (ORCPT ); Tue, 8 Aug 2017 09:22:33 -0400 Received: from g9t5009.houston.hpe.com ([15.241.48.73]:42486 "EHLO g9t5009.houston.hpe.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752030AbdHHNWb (ORCPT ); Tue, 8 Aug 2017 09:22:31 -0400 From: "Magalhaes, Guilherme (Brazil R&D-CL)" To: Stefan Berger , Mimi Zohar , "Serge E. Hallyn" CC: Mehmet Kayaalp , Yuqiong Sun , containers , linux-kernel , David Safford , "James Bottomley" , linux-security-module , ima-devel Subject: Re: [Linux-ima-devel] [RFC PATCH 1/5] ima: extend clone() with IMA Thread-Topic: [Linux-ima-devel] [RFC PATCH 1/5] ima: extend clone() with IMA Thread-Index: AdMQSQchvOFc25aIT/GGOsxjlh/tPQ== Date: Tue, 8 Aug 2017 13:22:23 +0000 Message-ID: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=guilherme.magalhaes@hpe.com; x-originating-ip: [15.211.195.12] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1;TU4PR84MB0303;6:+7VWenSqB1iHiGt10SMDBHZPj2mT8Qk0lpoNIsNl5RjGvPhpTPTdl5SLVMR3B4PcizCh0ycoj1Pa0C+e6oDJYtCLZszSATU0GGm33AZ5FGZDk4cV4+Wd50+0cxdwmbF+SXzv+cY+83itxbRArBKEge6t9+o++1Jz4RobYwu2e48Gs+YJCnbIqy/pdbKUkM1hVP/yBGRZ6GIkgWbyBLWWmQFpVUdAo8uDcPHPp8vrypSqJlIZJx+Vgf2Y3tiDezEu758dTl0WV97zZm75ep9uxOaw3XKGYMbsy1IW3tUeoQMH2XNndzfQ5YognJPRBxPe96qAArNxmrbKWQpLF3CmFw==;5:629INA2ihncW/jwcfj/3JAKIfzlGmNpqYqNsaNyNAL5tcLHM5B+Vhy/Yf9SHsh2D6xK2ijGNUGbBvXG7fOcGuJxJHdSg44MRFPn2YPMApslm5/h251Msz2VGQjOhaep/2AZqG7yYISLIiV/94JJrJg==;24:9Eegsl3mLGKuB0D+JonhdfbTQWZldS+AhNS7cpe5zMTyuT7EM6KV7U+FSxcnUkEvrxXtnVF3n10f2VaIq65CAqQWbgPec9xxoSFj5LR6vKI=;7:H6hA4niMJbE7ruwm1yoQomE15VvCuj7O7yP+w4vI8LYyNxT9aTXuPNPfmqBFU2E0LbTEWVm7ldAot/8DBORAnARhQUa+GhIpngCjwOpwiD9cq3pxWKk51ZUKXmEb048Auyy5cAmn1zF9So5vg2jS+Hy7cEJk79VqQw8fu+eHb2Hr0ACceEGMuGDTVvx2blpp+fTWaKwHXYWV5WBXijQYF1T7caNX076e3z+YipL/i9s= x-ms-exchange-antispam-srfa-diagnostics: SSOS; x-ms-office365-filtering-correlation-id: 5607eba5-b20c-4cbd-1b84-08d4de6081a6 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(48565401081)(300000503095)(300135400095)(2017052603031)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095);SRVR:TU4PR84MB0303; x-ms-traffictypediagnostic: TU4PR84MB0303: x-exchange-antispam-report-test: UriScan:(143289334528602)(227479698468861)(192374486261705)(9452136761055)(106981052589767)(42262312472803)(274839183919467)(104084551191319)(17755550239193); x-microsoft-antispam-prvs: x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(3002001)(93006095)(93001095)(10201501046)(100000703101)(100105400095)(6055026)(6041248)(20161123562025)(20161123555025)(20161123564025)(20161123558100)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123560025)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095);SRVR:TU4PR84MB0303;BCL:0;PCL:0;RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095);SRVR:TU4PR84MB0303; x-forefront-prvs: 03932714EB x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(6009001)(39850400002)(39400400002)(39410400002)(39840400002)(39860400002)(39450400003)(189002)(377454003)(199003)(13464003)(24454002)(35754003)(6436002)(39060400002)(8936002)(38730400002)(7416002)(6246003)(2906002)(74316002)(229853002)(68736007)(2900100001)(7696004)(189998001)(5660300001)(230783001)(101416001)(105586002)(66066001)(54356999)(97736004)(3660700001)(7736002)(55016002)(561944003)(305945005)(6116002)(478600001)(77096006)(50986999)(81156014)(106356001)(86362001)(102836003)(81166006)(4326008)(25786009)(3846002)(9686003)(3280700002)(54906002)(33656002)(53936002)(14454004)(53546010)(6506006)(8676002)(217873001);DIR:OUT;SFP:1102;SCL:1;SRVR:TU4PR84MB0303;H:TU4PR84MB0302.NAMPRD84.PROD.OUTLOOK.COM;FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-MS-Exchange-CrossTenant-originalarrivaltime: 08 Aug 2017 13:22:23.8049 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 105b2061-b669-4b31-92ac-24d304d195dc X-MS-Exchange-Transport-CrossTenantHeadersStamped: TU4PR84MB0303 X-OriginatorOrg: hpe.com Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 3647 Lines: 75 Stefan, Still on the vTPM requirements, could you help answering the following questions? 1. Where will the boot measurements be stored? What is the integrity measurement domain for this vTPM? The current proposal is that the vTPM would be used for the container (or namespace) files/inodes. What else will be available from the vTPM? For example, will the vTPM provide the UEFI measurements on the first PCRs (copied/proxied from physical TPM)? 2. From an attestation/quote perspective, how do you envision the key material to be managed (e.g. the vTPM EK and/or Attestation Key is fixed to the physical TPM, or it's cryptographically bound to it)? 3. Can you elaborate more on the alignment of this solution with the TCG requirements, especially considering the lack of isolation on the vTPM solution, do you have a future plan to cover those issues? 4. In a micro services pattern, or a serverless compute pattern, in which one or more containers are created to handle each individual request it is possible that there will be several thousand containers created per hour on a busy server. What is the expected performance and scalability of vTPMs within such an environment? -- Guilherme > -----Original Message----- > From: Stefan Berger [mailto:stefanb@linux.vnet.ibm.com] > Sent: quinta-feira, 27 de julho de 2017 17:52 > To: Magalhaes, Guilherme (Brazil R&D-CL) ; > Mimi Zohar ; Serge E. Hallyn > Cc: Mehmet Kayaalp ; Yuqiong Sun > ; containers foundation.org>; linux-kernel ; David Safford > ; James Bottomley > ; linux-security-module security-module@vger.kernel.org>; ima-devel devel@lists.sourceforge.net>; Yuqiong Sun > Subject: Re: [Linux-ima-devel] [RFC PATCH 1/5] ima: extend clone() with IMA > namespace support > > On 07/27/2017 03:39 PM, Magalhaes, Guilherme (Brazil R&D-CL) wrote: > > > >> There's a vTPM proxy driver in the kernel that enables spawning a > >> frontend /dev/tpm%d and an anonymous backend file descriptor where a > >> vTPM can listen on for TPM commands. I integrated this with 'swtpm' and > >> I have been working on integrating this into runc. Currently each > >> container started with runc can get one (or multiple) vTPMs and > >> /dev/tpm0 [and /dev/tpmrm0 in case of TPM2] then appear inside the > >> container. > >> > > This is an interesting solution especially for nested namespaces with the > > recursive application of measurements and a having list per container. > > > > Following the TCG specs/requirements, what could we say about security > > guarantees of real TPMs Vs this vTPM implementation? > > > A non-root user may not be able to do access the (permanent) state of > the vTPM state files since the container management stack would restrict > access to the files using DAC. Access to runtime data is also prevented > since the vTPM would not run under the account of the non-root user. > > To protect the vTPM's permanent state file from access by a root user it > comes down to preventing the root user from getting a hold of the key > used for encrypting that file. Encrypting the state of the vTPM is > probably the best we can do to approximate a temper-resistant chip, but > preventing the root user from accessing the key may be more challenging. > Preventing root from accessing runtime data could be achieved by using > XGS or a similar technology. > > Stefan >