From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail.openvz.org (mail.openvz.org [69.168.225.77]) by lore.virtuozzo.com (Postfix) with ESMTPS id 9BF2E80027 for ; Fri, 20 Nov 2026 13:48:49 +0000 (UTC) Received: from mail.openvz.org (localhost [127.0.0.1]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 6AKDlXNh022672; Fri, 20 Nov 2026 16:47:34 +0300 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.openvz.org 6AKDlXNh022672 Authentication-Results: mail.openvz.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=virtuozzo.com header.i=@virtuozzo.com header.b="BpmX8l/X" Received: from mail-yw1-f199.google.com (mail-yw1-f199.google.com [209.85.128.199]) by mail.openvz.org (8.14.4/8.14.4) with ESMTP id 6AKDlUUV022664 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=FAIL) for ; Fri, 20 Nov 2026 16:47:31 +0300 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.openvz.org 6AKDlUUV022664 Received: by mail-yw1-f199.google.com with SMTP id 00721157ae682-8b37869f851so14529737b3.2 for ; Fri, 20 Nov 2026 05:47:30 -0800 (PST) X-Gm-Message-State: APuU4Z8PnMYPklxTWuo1oCIfN2uY0i3GWtCaXU25ibOFrIUIZuiy3FAr m26MPtdOOVQg8jPhFcOg88MMkDrzszjnY+CurjpR6lXSGesI9r3WnSp4nSgTILSZvhlmaSJkywO aL4UAjkM1M+5bfgbIijUBe1NGwQNjHvsCQVGGBcfbtG5iRX8lyrbduw== X-Gm-Gg: AZFdTZchkXzwXmIs/6AKxpADQ687Ornmfk2yqLBp2JL5J8JRT68AUWaSqVsE1+WbwCT jvCxqtr+HXPFj8ovZcB1GT0CLVkEEtp+vefxy5sJ5760yWIBCa32bN4DJ2AAlzgqNkkTCJCH+lP fI8iNJkR/kWhiuhw/G195aNiTyPbvVZC4m4LialfrM7jTI5OVqYxnMq9qVC1IGG9g4zxqVOmg34 T0IgO5HBc1FIuNfAuc8+SfGdnHjJSqROTglYF/EhmpNsREjO+nLvGlz0FOo81KjDLGL+y6aZAop zFmbTpUSLu1rO7hgnYj6fnpaWGahh/qSw48LibYU6T1WB30NGuHdRU+EJIt6qnxaorP42Wswgui HxNkeDoeP/YIdAJLjaw4/u6WgLLRV/MEKqTR2/Zn336qeeNPXlLs/q0nMHWdaIG0p8XolKpiNEo 4UTMs0UdrraOvaKN0ov3NEBUXNw/XLm7ax X-Received: by 2002:a05:690c:9c05:b0:873:5bd1:98cf with SMTP id 00721157ae682-8b520518e34mr10759707b3.65.1795182449583; Fri, 20 Nov 2026 05:47:29 -0800 (PST) X-Received: by 2002:a05:690c:9c05:b0:873:5bd1:98cf with SMTP id 00721157ae682-8b520518e34mr10759657b3.65.1795182448975; Fri, 20 Nov 2026 05:47:28 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1795182448; cv=pass; d=google.com; s=arc-20260327; b=U2HBEpNzs/7qvNRgUdbvOY+3JiLdJCh6rBziPO+zfjLwnZTTEHhbRl75vALZh4yMNg 0Fsht8WDs/4Kvg/U+zr6mo7JlREDciwvDbeYPe6nJp91QNwQaxJagNCb1yj+1L6mBzZj k05J0woV3CRl67GrLJGCAJXyXP9X0WJUeQ0inBNxvNVPuIaJfECjYJ/HSeufI+IyVBdK pdkau5yAu4WafPUATvHefp9wYkBS24mcUCamjLKw7+wLXwcafW1j09btDdsl/lmHJj5B ZYsNStJlBdoFdcVwhL7vcxGyQU+1UTdscP6xjH7lEO+AjlKBt8Ud7U4N1DGxaRnZlPRT b6dw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=mime-version:content-transfer-encoding:in-reply-to:from :content-language:references:cc:to:subject:user-agent:date :message-id:dkim-signature; bh=wisaFwHc3RSnNnwO8d6VrrkVMVyD2UMaOfGZY2qXNGI=; fh=wZwd5yRbW8HRNLtAnbjmPgrqfPdwPW1GvOQXIFYLV2Y=; b=myspBQwGZjiXyvwgE7JOwpA/iZ8QbP9Hf2zLPisVmSpioV8/y3uBe8GFNFB43mcoCX S/pc9g0u7SQpHqjbnbaYSTlHKbCqD26dnzCiSyfXsFEzywtkue1vvLZRR9CisMd8/SrD 3C8x2HAQAxzO86ZJupbdC5wzYBZ1vTpTemMdOqRF6X7U4UNmyscWwd72VYCEI+CwLo2Q y5Klh/eFOzGKZDlnOAjUN/Qa5vUTpWh6rr0oVyN4El+GO8bhfEINHILrB2nVSQgKGZqG FeA2BRLwvu2LVwRMTlXBttHJBu8NCTtR/Yr2FGlkyJo5yDd7sXixVY2WWjS+NJssJApi QptA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@virtuozzo.com header.s=selector2 header.b="BpmX8l/X"; arc=pass (i=1 spf=pass spfdomain=virtuozzo.com dkim=pass dkdomain=virtuozzo.com dmarc=pass fromdomain=virtuozzo.com); spf=pass (google.com: domain of mirian.shilakadze@virtuozzo.com designates 2a01:111:f403:c201::6 as permitted sender) smtp.mailfrom=mirian.shilakadze@virtuozzo.com; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=virtuozzo.com Received: from AM0PR02CU008.outbound.protection.outlook.com (mail-westeuropeazlp170130006.outbound.protection.outlook.com. [2a01:111:f403:c201::6]) by mx.google.com with ESMTPS id 00721157ae682-8b52037d41bsi11364327b3.140.2026.11.20.05.47.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 20 Nov 2026 05:47:28 -0800 (PST) Received-SPF: pass (google.com: domain of mirian.shilakadze@virtuozzo.com designates 2a01:111:f403:c201::6 as permitted sender) client-ip=2a01:111:f403:c201::6; Authentication-Results: mx.google.com; dkim=pass header.i=@virtuozzo.com header.s=selector2 header.b="BpmX8l/X"; arc=pass (i=1 spf=pass spfdomain=virtuozzo.com dkim=pass dkdomain=virtuozzo.com dmarc=pass fromdomain=virtuozzo.com); spf=pass (google.com: domain of mirian.shilakadze@virtuozzo.com designates 2a01:111:f403:c201::6 as permitted sender) smtp.mailfrom=mirian.shilakadze@virtuozzo.com; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=virtuozzo.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=pNrRpQbDUhYY7hhGEtViUWPrut3dcgB9oajUsv2OgZB1SJICbpUieEbga2TD4icfRgntOehi7qldq6fbl+YHs7XkYS84xIDmrva7+qTEEFLMLWfi1iBtNBrmU76/s5WfhClLRJUeEQIt69JPiffhmKa9BodWrDda7OemiAeSw4Nvi0KOybZbVhMjalmW9IuFzxNAi/THIrFcq7/M6MOg6eHnziqQ/AVX4nyo8ctW6lJ/jXkd0b0zmz1+dKtL+JymkimZurobVi88JhYJ9VB7F38Kh1QMnvXsGe16Rm9KPdJAH4pHReU7U26BjnN6tTZtKBvTHBvdtRsfPad42r0Nqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=wisaFwHc3RSnNnwO8d6VrrkVMVyD2UMaOfGZY2qXNGI=; b=TkFVNrI2Cm1GNM2L+biE7ioVCHiOf2uH8HKrrKTUMDxpVNvKOPqh1QYEX0Dfx3QsRdxfdTPT0k89kO8bwLEhpR+UqgdU0JH6d7Rxxx70vcW0VXwSuLfJboCPTuu/jOISnNIcBZU0gHT8vpFqzXBxvMXh4bTFEUXANZpUxVY+oo9MviN6lvZHbsyKalJAFHG3PZ6eHksfahY7bLlGP92WcyScBA6hgGBl4gw66YyzpjjSOYHY46stUTCOTUYPWdKFhevxTAZjSdWT7Cqq97Bs/XKfBQ7XwLhU2lYZyiwx05sCQkgWaWLwEsr00Y2HYHUNh9njGw9zUkGPWXWU/6iHxw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=virtuozzo.com; dmarc=pass action=none header.from=virtuozzo.com; dkim=pass header.d=virtuozzo.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=virtuozzo.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=wisaFwHc3RSnNnwO8d6VrrkVMVyD2UMaOfGZY2qXNGI=; b=BpmX8l/XHve6k1k712dBErCitdap4agCcjfGmgau08IfRAWXTyhFyOGY3ehDTJAvlAqTP8mt5PJ+/+AvS3h/oYpuLPUMZIhQnELIO6GBxvJRvtAlccX7QYY3b0Tn8ZW8CV0oxqaJWD4GY4yX8WWEPtgf6n/gUaXLWbSnknGcOSVNkC0GMKrRnIrMJgJYxqaDeFKth5NDO/m/7N36NeLPxnCsX5aAN/Du+nJNVw5iDj2haZQFA+dqIXPR3G3b95cj9iZnisdTvz/I1U1MbBNJ0ZIpk0MGkFwPc89u6c70syaNsXBFCw6m3+q5GFNUNiK9OAChMsd71CIR/kP4EvrXvQ== Authentication-Results: mx.microsoft.com 1; dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=virtuozzo.com; Received: from AM0PR08MB787278.eurprd08.prod.outlook.com (2603:10a6:20b:7f0::6) by PAVPR08MB9064.eurprd08.prod.outlook.com (2603:10a6:102:2ff::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.21.639.12; Fri, 20 Nov 2026 13:47:25 +0000 Received: from AM0PR08MB787278.eurprd08.prod.outlook.com ([fe80::d027:373b:f4f9:dcd1]) by AM0PR08MB787278.eurprd08.prod.outlook.com ([fe80::d027:373b:f4f9:dcd1%6]) with mapi id 15.21.0639.011; Fri, 20 Nov 2026 13:47:25 +0000 Message-ID: <5898b3a7-0bf1-46c3-9a7d-5de30eab7560@virtuozzo.com> Date: Fri, 20 Nov 2026 17:47:23 +0400 User-Agent: Mozilla Thunderbird To: Konstantin Khorenko , Pavel Tikhomirov References: <20261120-b4-prep-khorenko-vstor-156164-ve-setup-task-pseudosuper-v2-0-c85e827c1dba@virtuozzo.com> <20261120-b4-prep-khorenko-vstor-156164-ve-setup-task-pseudosuper-v2-2-c85e827c1dba@virtuozzo.com> Content-Language: en-US From: Mirian Shilakadze In-Reply-To: <20261120-b4-prep-khorenko-vstor-156164-ve-setup-task-pseudosuper-v2-2-c85e827c1dba@virtuozzo.com> X-ClientProxiedBy: FR0P281CA0142.DEUP281.PROD.OUTLOOK.COM (2603:10a6:d10:96::15) To AM0PR08MB787278.eurprd08.prod.outlook.com (2603:10a6:20b:7f0::6) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: AM0PR08MB787278:EE_|PAVPR08MB9064:EE_ X-MS-Office365-Filtering-Correlation-Id: 4b5776a3-8c43-48e4-ebbf-08df470ccf78 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230040|1800799024|23010399003|376014|366016|22082099003|18002099003|6133799003|261009223027099003|56012099006|10067099003|4143699003|261102123227099003|261026140227099003|261022105027099003|261026121527099003|261028144727099003|261021121427099003|261021123027099003; X-Microsoft-Antispam-Message-Info: dn7nBfOHGrLoNguhcaU/a4OwVgN4udzT1t4uerbb7Jam77t92GQeIl3HgaByQdaCnTyhdAnvxpMprVLjn7P39nDD2Ec2ZBD3j8qF1KstU5x/Cm3OEhMh3S4+bGjSea8YDBy38TJyNMuVNPhj7+0dO1CmO+3SzqNAHSsXI6JgppUAUl/1/X/vo2aloVqcb5Y0M85C+4yXhprTcDR8Q5R9BUNCc140Gafeitcr5QRAL0tQRU96Rbv/V25iGwEqzYz4BvZxZFGIzx1vjUzYQuf2G+7XO+hwqkLyM2aXfXz83fUu2pS5rHQxNtSAhs/5zIylp5/wxqOa4OmGV7mQqrLMktNnRorNKKwJzb0p0Qtz6ewnKqUxAJB9QHqohCaeTo+60nFN7O6hdcjhA5BM15UIQkg7bPOh4aGDMYPMTPnk+TD4wbJXeG0yCUnuNV34A+cKol7LKG+vepndIiN38IH6v4TpWgNZ0LKD8lz2mHb4XaAiXjOh1jjHtBsr4pF09ZuHnH0Uis/rSjTRUOKHl3KcFJSUCmBm0C11GaXs7tyrcC8hX8UqwgpLSK/N8lcacOIAhUac2jqvzo5qDUqpjWTfp8e3yCBDl4zsII7USEblEQu88p/M39wFcryA3k/OK1hD X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:AM0PR08MB787278.eurprd08.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230040)(1800799024)(23010399003)(376014)(366016)(22082099003)(18002099003)(6133799003)(261009223027099003)(56012099006)(10067099003)(4143699003)(261102123227099003)(261026140227099003)(261022105027099003)(261026121527099003)(261028144727099003)(261021121427099003)(261021123027099003); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?dEtibERWWDhneWtOS2NhRDc2KzhuTHB2N0c3d0JKZ1VZNmVNK2ZTblRpQUNn?= =?utf-8?B?SG1MREZHYXJMcVRSc3ByTFpKaXAra3NtdEhjcmFSVVhSWFF4YUJ2aFBCZEUw?= =?utf-8?B?TXVleDZnLzMzZEVrVlduRzNiL21ieVUzd3BxSUlQYllhSVZiZWYrYndhbjVL?= =?utf-8?B?N045bTIvRVhhUkh6ditDVVU4SjhTVnNTREZJM0plMnlaTGQrNHBqZTBvSm1n?= =?utf-8?B?d21peGNkQ0RoK3J3UjJmcWE5c1VKYmtMZ3NBV2JnSXNGRlUrVHoyelBGMk14?= =?utf-8?B?RXpIVFo3cHZ1Y3BhcXZnMCtUMTY5M3djL1BWTUxPOUNJZWVyMjdyK2I0dEdq?= =?utf-8?B?VnkxYlEvREtPU0tJaTBOQ2ZBMEcyZmZrNWdSQUdRNUN0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?B?MTRERUhudTliRjN2NDBBZXdzeUxQV1hQTE5KQy85UHp6bE9SaXpDU1FKV1FB?= =?utf-8?B?WTN2Tk02MVF5OHZpZUUyUmM3dmJ5S1NnT29PS3lHNHl4RXViUzFjSnRaZndJ?= =?utf-8?B?dkhPNTJ0N2k0cUkvaytYcXhkRHZ4T2c0Vm80TlFiM1Rvd0dJUWtCVzFVQzZ4?= =?utf-8?Q?E+pV3/ZfaicxzLT0=3D?= X-OriginatorOrg: virtuozzo.com X-MS-Exchange-CrossTenant-Network-Message-Id: 4b5776a3-8c43-48e4-ebbf-08df470ccf78 X-MS-Exchange-CrossTenant-AuthSource: AM0PR08MB787278.eurprd08.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Nov 2026 13:47:25.6491 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 0bc7f26d-0264-416e-a6fc-8352af79c58f X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Tl+qOsuX8Qy/yT24vUcl+GvH9yibd8n5XkO7bZurOtonwGE9CStI97ZO/2x1c1qFkfDCK92eQstD8qcaK/rcw0OD3x1xnLFpVLkA8gch+Pk= X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAVPR08MB9064 X-OZ-Fwd: true Cc: devel@openvz.org Subject: Re: [Devel] [PATCH hci-8.2 v2 2/2] selftests/ve: check a host task entering a pseudosuper VE reaches its init X-BeenThere: devel@openvz.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: OpenVZ development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Sender: devel-bounces@openvz.org Errors-To: devel-bounces@openvz.org On 11/20/26 5:15 PM, Konstantin Khorenko wrote: > libvzctl before 10.0.144 starts a Container with ve.pseudosuper set: > the init it clones writes START to ve.state, then a helper forked on > the host enters the init's namespaces and opens its /proc//ns/mnt. > While the VE is pseudosuper the init, a setup task, is reachable only > from the host's tasks, so the helper must count as one. > > Start a VE the same way and check that a host task entering it through > the ve namespace reaches the init, and that a binary exec'd inside the > VE still does not. Before the fix the first test fails with EACCES, the > error vzctl start reports. > > https://virtuozzo.atlassian.net/browse/VSTOR-156164 > > Feature: trace: prohibit tracing sensitive tasks from CT > Signed-off-by: Konstantin Khorenko > --- > tools/testing/selftests/ve/.gitignore | 1 + > tools/testing/selftests/ve/Makefile | 1 + > tools/testing/selftests/ve/ve_setup_task_test.c | 295 ++++++++++++++++++++++++ > 3 files changed, 297 insertions(+) > > diff --git a/tools/testing/selftests/ve/.gitignore b/tools/testing/selftests/ve/.gitignore > index a468ef980e28b..fbaea9c8ee39d 100644 > --- a/tools/testing/selftests/ve/.gitignore > +++ b/tools/testing/selftests/ve/.gitignore > @@ -7,3 +7,4 @@ ve_numa_migrate_test > ve_aio_ring_test > ve_numa_syscalls_prohibited_test > ve_tmpfs_mpol_test > +ve_setup_task_test > diff --git a/tools/testing/selftests/ve/Makefile b/tools/testing/selftests/ve/Makefile > index fa4f858227e5e..baf035219da98 100644 > --- a/tools/testing/selftests/ve/Makefile > +++ b/tools/testing/selftests/ve/Makefile > @@ -10,6 +10,7 @@ TEST_GEN_PROGS += ve_numa_migrate_test > TEST_GEN_PROGS += ve_aio_ring_test > TEST_GEN_PROGS += ve_numa_syscalls_prohibited_test > TEST_GEN_PROGS += ve_tmpfs_mpol_test > +TEST_GEN_PROGS += ve_setup_task_test > > # CPUID faulting is x86-64 only. ARCH says "x86" for 32-bit too and lib.mk > # picks the clang target by its emptiness, so decide by the compiler. > diff --git a/tools/testing/selftests/ve/ve_setup_task_test.c b/tools/testing/selftests/ve/ve_setup_task_test.c > new file mode 100644 > index 0000000000000..4d18ba3d57104 > --- /dev/null > +++ b/tools/testing/selftests/ve/ve_setup_task_test.c > @@ -0,0 +1,295 @@ > +// SPDX-License-Identifier: GPL-2.0 > +/* > + * ve_setup_task selftest > + * > + * libvzctl before 10.0.144 starts a Container with ve.pseudosuper set: > + * the init it clones writes START to ve.state, and only then a helper > + * forked on the host enters the init's namespaces and opens its > + * /proc//ns/mnt. While the VE is pseudosuper the init, a setup > + * task, is reachable only from the host's tasks, so the helper must > + * count as one, or the start fails with EACCES. A container binary, one > + * exec'd inside the VE, must still not reach the init. > + * > + * The tests start a VE that way and check that: > + * > + * - a host task entering the running pseudosuper VE reaches the init > + * - a binary exec'd inside the VE does not > + */ > +#define _GNU_SOURCE > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > + > +#include "../kselftest_harness.h" > +#include "ve_selftest.h" > + > +/* Re-exec of the test binary: open the mnt namespace of the given pid. */ > +#define PROBE_ARG "--open-mnt-ns" > + > +FIXTURE(ve_setup_task) > +{ > + int cgv2_fd; > + int ctid; > + pid_t init_pid; > + int init_release; /* its read end holds the init */ > + struct namespace_ctx ns_ctx; /* the VE namespace of the init */ > + char exe[PATH_MAX]; /* this binary, for the probe exec */ > +}; > + > +/* 0 when /proc/@pid/ns/mnt opens, else errno. */ > +static int open_mnt_ns(pid_t pid) > +{ > + char path[64]; > + int fd; > + > + snprintf(path, sizeof(path), "/proc/%d/ns/mnt", pid); > + fd = open(path, O_RDONLY); > + if (fd < 0) > + return errno; > + close(fd); > + return 0; > +} > + > +static int ve_write(FIXTURE_DATA(ve_setup_task) * self, const char *file, > + const char *val) > +{ > + char path[64]; > + > + snprintf(path, sizeof(path), "%d/%s", self->ctid, file); > + return write_file_at(self->cgv2_fd, path, val); > +} > + > +static int ve_read(FIXTURE_DATA(ve_setup_task) * self, const char *file, > + char *buf, size_t len) > +{ > + char path[64]; > + > + snprintf(path, sizeof(path), "%d/%s", self->ctid, file); > + return read_file_at(self->cgv2_fd, path, buf, len); > +} > + > +/* > + * The init of the VE: start it, report the result and stay until the > + * test closes the release pipe. > + */ > +static void run_init(FIXTURE_DATA(ve_setup_task) * self, int status[2], > + int release[2]) > +{ > + char c; > + > + prctl(PR_SET_PDEATHSIG, SIGKILL); > + close(status[0]); > + close(release[1]); > + c = ve_write(self, "ve.state", "START") ? errno : 0; > + if (write(status[1], &c, 1) != 1) > + _exit(1); > + close(status[1]); > + while (read(release[0], &c, 1) < 0 && errno == EINTR) > + ; > + _exit(0); > +} > + > +/* Wait for the VE to stop after the init is released, then remove it. */ > +static void stop_ve(FIXTURE_DATA(ve_setup_task) * self) > +{ > + char state[32], path[64]; > + int i; > + > + if (self->init_release >= 0) > + close(self->init_release); > + if (self->init_pid > 0) > + waitpid(self->init_pid, NULL, 0); > + for (i = 0; i < 500; i++) { > + if (ve_read(self, "ve.state", state, sizeof(state)) < 0 || > + !strncmp(state, "STOPPED", 7) || > + !strncmp(state, "STARTING", 8)) > + break; > + usleep(10000); > + } > + ve_write(self, "ve.pseudosuper", "0"); > + /* The start makes a vz.slice child under the VE root */ > + snprintf(path, sizeof(path), "%d/vz.slice", self->ctid); > + unlinkat(self->cgv2_fd, path, AT_REMOVEDIR); > + destroy_ve(self->cgv2_fd, self->ctid); > +} > + > +/* > + * Start the VE the way vzctl does: pseudosuper first, then an init cloned > + * from the host writes START. The start needs the init in its own pid, > + * cgroup and net namespaces. Returns -1 with the failed step in @what. > + */ > +static int start_ve(FIXTURE_DATA(ve_setup_task) * self, const char **what) > +{ > + struct clone_args cargs = { > + .flags = CLONE_NEWVE | CLONE_NEWPID | CLONE_NEWCGROUP | > + CLONE_NEWNS | CLONE_NEWNET, > + .exit_signal = SIGCHLD, > + }; > + char state[32], path[64], val[32]; > + int status[2], release[2]; > + unsigned int veid; > + int ret; > + char c; > + > + *what = "ve cgroup"; > + self->ctid = make_ve(self->cgv2_fd, CTID_MIN); > + if (self->ctid < 0) > + return -1; > + > + /* A random high veid, as a container gets, so it clashes with none */ > + *what = "ve.veid"; > + if (getrandom(&veid, sizeof(veid), 0) != sizeof(veid)) > + return -1; > + veid = (veid >> 2) | (1u << 30); > + snprintf(val, sizeof(val), "%u", veid); > + if (ve_write(self, "ve.veid", val) < 0) > + return -1; > + *what = "ve.pseudosuper"; > + if (ve_write(self, "ve.pseudosuper", "1") < 0) > + return -1; > + > + *what = "pipe"; > + if (pipe(status) < 0) > + return -1; > + if (pipe(release) < 0) { > + close(status[0]); > + close(status[1]); > + return -1; > + } > + > + /* The init: a host task cloned into the VE while it starts */ > + *what = "clone3"; > + if (enter_cgroup(self->cgv2_fd, self->ctid) >= 0) > + self->init_pid = syscall(__NR_clone3, &cargs, sizeof(cargs)); > + if (self->init_pid == 0) > + run_init(self, status, release); > + close(status[1]); > + close(release[0]); > + self->init_release = release[1]; > + if (enter_cgroup(self->cgv2_fd, 0) < 0 || self->init_pid < 0) { > + close(status[0]); > + return -1; > + } > + > + *what = "ve.state START"; > + ret = read(status[0], &c, 1); > + close(status[0]); > + if (ret != 1) > + return -1; > + if (c) { > + errno = c; > + return -1; > + } > + *what = "ve.state is not RUNNING"; > + if (ve_read(self, "ve.state", state, sizeof(state)) <= 0 || > + strncmp(state, "RUNNING", 7)) > + return -1; > + > + *what = "/proc//ns/ve"; > + snprintf(path, sizeof(path), "/proc/%d/ns/ve", self->init_pid); > + self->ns_ctx.ve_fd = open(path, O_RDONLY); > + if (self->ns_ctx.ve_fd < 0) > + return -1; > + self->ns_ctx.ns_save_mask = CLONE_NEWVE; > + return 0; > +} > + > +FIXTURE_SETUP(ve_setup_task) > +{ > + const char *what; > + ssize_t len; > + int ret, err; > + > + self->ctid = -1; > + self->init_pid = -1; > + self->init_release = -1; > + self->ns_ctx.ns_save_mask = 0; > + > + len = readlink("/proc/self/exe", self->exe, sizeof(self->exe) - 1); > + ASSERT_GT(len, 0); > + self->exe[len] = '\0'; > + > + self->cgv2_fd = mount_cg2_fd(); This does not build on the current branch-rh10-6.12.0-211.75.1.26.x.vz10-ovz tip: 26182b5f9943 replaced mount_cg2_fd() with open_cg2_fd() in ve_selftest.h. The .gitignore and Makefile hunks conflict there too. open_cg2_fd() also leaves nsdelegate and memory_recursiveprot on the host cgroup2 mount alone. > + if (self->cgv2_fd < 0) > + SKIP(return, "cannot mount cgroup2: %s", strerror(errno)); > + if (write_file_at(self->cgv2_fd, "cgroup.subtree_control", > + VE_CONTROLLERS) < 0) > + SKIP(return, "cannot enable the ve controller: %s", > + strerror(errno)); > + > + /* The harness skips the teardown when the setup fails */ > + ret = start_ve(self, &what); > + err = errno; > + if (ret) { > + stop_ve(self); > + close(self->cgv2_fd); > + } > + ASSERT_EQ(ret, 0) TH_LOG("%s: %s", what, strerror(err)); > +} > + > +FIXTURE_TEARDOWN(ve_setup_task) > +{ > + if (self->ctid < 0) > + return; > + close_namespace_fds(&self->ns_ctx); > + stop_ve(self); > + close(self->cgv2_fd); > +} > + > +static int open_init_mnt_ns(void *arg) > +{ > + int err = open_mnt_ns(*(pid_t *)arg); > + > + if (err) > + fprintf(stderr, "%s: /proc//ns/mnt: %s\n", __func__, > + strerror(err)); > + return err ? -1 : 0; > +} > + > +TEST_F(ve_setup_task, host_task_reaches_init) > +{ > + EXPECT_EQ(run_in_ve(self->cgv2_fd, self->ctid, &self->ns_ctx, > + CLONE_NEWVE, open_init_mnt_ns, &self->init_pid), 0); > +} > + > +TEST_F(ve_setup_task, exec_in_ve_does_not_reach_init) > +{ > + char pid[16]; > + int status; > + pid_t p; > + > + snprintf(pid, sizeof(pid), "%d", self->init_pid); > + p = fork(); > + ASSERT_GE(p, 0); > + if (p == 0) { > + if (enter_cgroup(self->cgv2_fd, self->ctid) < 0 || > + enter_namespaces(&self->ns_ctx, CLONE_NEWVE) < 0) > + _exit(254); > + execl(self->exe, self->exe, PROBE_ARG, pid, NULL); > + fprintf(stderr, "execl(%s): %s\n", self->exe, strerror(errno)); > + _exit(254); > + } > + ASSERT_EQ(waitpid(p, &status, 0), p); > + ASSERT_TRUE(WIFEXITED(status)); > + ASSERT_NE(WEXITSTATUS(status), 254); > + EXPECT_EQ(WEXITSTATUS(status), EACCES) > + TH_LOG("open of the init's mnt namespace: %s", > + strerror(WEXITSTATUS(status))); > +} > + > +int main(int argc, char **argv) > +{ > + if (argc == 3 && !strcmp(argv[1], PROBE_ARG)) > + return open_mnt_ns(atoi(argv[2])); > + return test_harness_run(argc, argv); > +} > -- Best regards, Mirian Shilakadze Linux C Virtualization Developer, Virtuozzo. _______________________________________________ Devel mailing list Devel@openvz.org https://lists.openvz.org/mailman/listinfo/devel