From patchwork Tue Apr 25 20:06:13 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Guido Trentalancia X-Patchwork-Id: 9699573 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id A235360245 for ; Tue, 25 Apr 2017 20:07:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 8DBF628634 for ; Tue, 25 Apr 2017 20:07:16 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 827932866C; Tue, 25 Apr 2017 20:07:16 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from emsm-gh1-uea11.nsa.gov (smtp.nsa.gov [8.44.101.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 9F28F28634 for ; Tue, 25 Apr 2017 20:07:14 +0000 (UTC) X-IronPort-AV: E=Sophos;i="5.37,250,1488844800"; d="scan'208";a="5208643" IronPort-PHdr: =?us-ascii?q?9a23=3A9UT/ZBbb4o9HbxJfIuXNGTH/LSx+4OfEezUN459i?= =?us-ascii?q?sYplN5qZoc+5YB7h7PlgxGXEQZ/co6odzbGH7ea8AydZvcrJmUtBWaQEbwUCh8?= =?us-ascii?q?QSkl5oK+++Imq/EsTXaTcnFt9JTl5v8iLzG0FUHMHjew+a+SXqvnYdFRrlKAV6?= =?us-ascii?q?OPn+FJLMgMSrzeCy/IDYbxlViDanb75/KBS7oR/eu8UIjoduN6k8xxTUqXZUZu?= =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Ked3CilBJ1WfXpKCleWEXfnb4+EQesDaDqOIs99lTwJ?= =?us-ascii?q?TbqhS4072h6ytw/60L1nLuzV+i0Grp/j2tx15/DclB4p6Dx0Cdid03yXQ2FzhG?= =?us-ascii?q?MISCc83Lpjrkxl1leDza94juRWFNxS4/NJVxk1NYTHwux0Fd/9RwXBfs2TR1a+?= =?us-ascii?q?WNWmBjMxQcwtzN8SeUp9HM+ijh/b1SqwH7AVj6CLBIAz8q/Ewnf+O8N9y3HA1K?= =?us-ascii?q?k9klUrWdVPOnO8hq5+9gnTAIjJn1+fl6m0aaQWxDTN+3ubzWqSoEFYVxZ9XrjZ?= =?us-ascii?q?XX8FfEvbtsj25kTHT7CyE7snKRdBxdSEKqRUdt3jlU9GS+v7ONTCf2KxnH+9BB?= =?us-ascii?q?aJx7OLaornYGAd3CHEBEgFlQAf53CGOhIkBieiomLeEiJhGUjpY0zy7el0sGm7?= =?us-ascii?q?QVMszwGWc01h0KK49QANhfOGUfMT36kEtTw5qzpuBla93snWC8KEpwV7YKpTf8?= =?us-ascii?q?kx4FBd1WLWrwZ9JICvL7h+hl4CdAR6p03u1w9tBYVGjccqrWgqwRF3KaKA0VNN?= =?us-ascii?q?biiY3J7rOrHNLWny5h+vYbbM2l7CyNaW5rsP6PMgplXgpg6pFU0i82h83tlWyX?= =?us-ascii?q?Sc5ZLKDBcIXZL2SEY3+ABwp6vGbSkl+4PUyXpsPLGuvTDfwdIpBfUqygy7cthF?= =?us-ascii?q?LKyEERX+E8oAB8ihMOYqgUSmbgoYPOBO8645J9imd/Wc2K6sJ+ZggCmrjX9B4I?= =?us-ascii?q?B63EOM8jBzSujS05YD3f6YwhONVy3gg1e5rsD3hYdEaCkcH2WlzSjkGJBeZrdp?= =?us-ascii?q?fYsQF2ehPde3yc5jh57oQXJY80SjB1we0s+zZRWSd0D93RFX1UkPvXyohDa3zz?= =?us-ascii?q?1unDEttaeQwCvOw+H+exUdIW5LWHNujVHyLoiol9oaRlSnbxA1lBu54kb3365b?= =?us-ascii?q?pKV7L2nXX0hIZDP7IHt8XauqsbqOeclP6IknsS9PSuSzfUiaSqLhoxsdyy7jAW?= =?us-ascii?q?peyywndzGtoJX1hQB1iGKaLHZ1o3rUYsVwxRbZ5NPGX/5R2SAKRC5iiTnYHlK8?= =?us-ascii?q?JcWm/c2Il5ffteCzT2ahVpxIcSn31I+ArzW05WlrAR25gvCylcbqERMi0S/60d?= =?us-ascii?q?lqVDnHrA3mbontyau6LfptflN0C1/k98p6BoZ+n5MqhJEX3Xgagoua/WAbnmf0?= =?us-ascii?q?P9RWwrn+bGcRSj4Q2dLV5xLl2EJ7JHKT2435TmmdwtdmZ9SiemMZwD8978RQBK?= =?us-ascii?q?iO9rBLhix1ol6krQLWZ/hwhTIdxeco6H4dn+4FogwtwTuBAroKB0lXITTslwiU?= =?us-ascii?q?79C5tKhXZ3igcb6r1EdlntCuEreCohpaWHnnZpcuByhw7t9wMFjUyn389pnkeM?= =?us-ascii?q?XMbdIUrhCUjRHAgPVOJZIvkPoFmCpnNXj7vXI71+4xlQZu0o2ivIibN2Vt+7q0?= =?us-ascii?q?AgZCOT3oY8Me4S3ijadCnseWxoyvEI9uGjMRUJvvV/KoHyoYte77OAaWDD08tn?= =?us-ascii?q?CbFKLHHQCF9Udmq2zAE4ixOHGROHkW089iSQKAJExEng8URi46koQiFgCt2czh?= =?us-ascii?q?alt26S4f5l7/sBtMxfxnOwP5UmjBuAeici00R4SHLBpK8gFC4F/YMcKE4eJ1Ay?= =?us-ascii?q?FY+ZihoReDKmOFegtICnsJVVacB1D5Obmu58fP/PSEBuakKPvOe7qOo/REV/iU?= =?us-ascii?q?3ZKvzpdm/zGUO8WKJHZiC/k71VRfXXBlAcvWgS4CSyoJmCLRdM6UuA2z+jVpoc?= =?us-ascii?q?yl9vTkRh7v75OVC7ROKdVv5wy2gaCbOu6Knip4JyxU1pYWyn/Mz7ge3EUfhDty?= =?us-ascii?q?eDmoC7gAsjTNTK3IkK9NExEbcz9zNNdP768k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SZLSzmcTqpPiEZphTp3/Q8F0wKj3QuxsdxfyoVQZ7dYylh2?= =?us-ascii?q?3uIJAsQTJMt8ZiBQVgHItTAM4AtA6nA5mImKGnld++5V51t/UNsarqBfDAzM65?= =?us-ascii?q?0JlpX5hG+UyLOy7cBLFsgkRhlOuymPnB0p71CcPsYt4EUe97QmnearDYAoq/MD?= =?us-ascii?q?WOOtnne05H9b6c36h1UhKLZCD2R6CGrjGrNO144UUnzYx1ZOTTwyIp77HawNv9?= =?us-ascii?q?eXpWpyairX6MMZtQ8kbKBejAUB5OTvqF6mllF7UNbYTo7OcOLcAiwN+E7gh99D?= =?us-ascii?q?RCysqFLLS/oULX30J7dI7bLFH31CojXokKOhu/O1M2gWDFsnTdHWhcLs+8JMlq?= =?us-ascii?q?hNaaEAfg51F1mW43fW5BBmvoSsuNOWgBxc2xeheG9ARVANYfh+S3Y1I3trWuSe?= =?us-ascii?q?l0PZVIgeGqtLQBkdZ0JCDDXcxaPyDLLL9qJTpcFeTPq0IuYh4DqbQ1XZ01ZZeW?= =?us-ascii?q?KkMdLEiA0T/yzRfF0UDsbNyjyqKJICcQ8nVawLPJ1jdCpxW5ufmHmM3sTqjZY4?= =?us-ascii?q?vtUf7RLiUlTDeaSio2EUmy5FektOAIvP2CIWcQuloUeD6dCBYPpqBzqtjdFmrT?= =?us-ascii?q?lvd/c50KhfCaXSfwRTZmlKozACZEq0SMQ/sFFQnLYH7tmm1cuBatJvVU53Lqc6?= =?us-ascii?q?WYxrZJW+wRGoZMcOeWQ9jfef9FPDooizMZOPq8f93bsrY53VLITXcDH6nO6lKe?= =?us-ascii?q?UFacQuaAyDLzQYUVo480tzIn+t3KhSB3CaXIMKibpzO17I64iDyXufbfVmkweU?= =?us-ascii?q?A1hvwNAHWZyhlaNG4EE80VuF3qQqOYZUZM0XUpifh02x8NYwR+SXtu3WdTnPmj?= =?us-ascii?q?G81VU1kUjHmhQPcedlB4ECsw/VOW4g31edEAos7TR2pC+bYNSocQN+co55fNOK?= =?us-ascii?q?sRwfcp2zRmrDY8syqDE1NXlhiF/LbIHKJg2r1C4nE1//NxXkGJRzPSaW3HxZS7?= =?us-ascii?q?BMJBwiduu2zr2NTOsuBrKrRau9IxPFBfGi9yJ9bA7RhdQGr03020pB/9EzOAcx?= =?us-ascii?q?wD5zNeCjEEeuE98/V2tgrBct/H4kKZ//YutUqnDi6XELeyxJVPA8fi1Az+byRX?= =?us-ascii?q?J2b4X6tqo+pAwY5BKZgsYpKzVgqZIw=3D=3D?= X-IPAS-Result: =?us-ascii?q?A2E8DAAErP9Y/wHyM5BbHAEBBAEBCgEBFgEBAQMBAQEJAQE?= =?us-ascii?q?BgwApZIEJg2eLCJB7DGSWdi+KGlcBAQEBAQEBAQIBAmgogjMKglgBAQICAQECI?= =?us-ascii?q?AQLAUkCAQkBARcLAgIiBAICAwFTGQWITIFDCASqSIFsOiYCiy6BC4clgmWCA4J?= =?us-ascii?q?ZgzWCQB8BBIk6B4ZKhj6GeJNwgRaBYINTg0IXDIY/j3CEKViBBm4KhGlEHIFlc?= =?us-ascii?q?4k2AQEB?= Received: from unknown (HELO tarius.tycho.ncsc.mil) ([144.51.242.1]) by emsm-gh1-uea11.nsa.gov with ESMTP; 25 Apr 2017 20:07:12 +0000 Received: from prometheus.infosec.tycho.ncsc.mil (prometheus [192.168.25.40]) by tarius.tycho.ncsc.mil (8.14.4/8.14.4) with ESMTP id v3PK6VGt030720; Tue, 25 Apr 2017 16:06:38 -0400 Received: from tarius.tycho.ncsc.mil (tarius.infosec.tycho.ncsc.mil [144.51.242.1]) by prometheus.infosec.tycho.ncsc.mil (8.15.2/8.15.2) with ESMTP id v3PK6Shh114519 for ; Tue, 25 Apr 2017 16:06:28 -0400 Received: from goalie.tycho.ncsc.mil (goalie [144.51.242.250]) by tarius.tycho.ncsc.mil (8.14.4/8.14.4) with ESMTP id v3PK6RHG030700 for ; Tue, 25 Apr 2017 16:06:28 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A1B7CgAErP9YgCswWFFbHAEBBAEBCgEBgyuBDS9ag2eLCJB7DGSXBIYkAoRsAQIBAQEBAQITAQELCwkIJoVGAQECAgEjBAsBSwsjAgImAgJXGYhRgUMMqkiBbDqLVoELhyWCZYIDglmDNYJAHwWJOgeGSoY+hniTcIEWgWCDU4NCI4Y/j3CEKYFdbgqFLRyBZXOJNgEBAQ X-IPAS-Result: A1B7CgAErP9YgCswWFFbHAEBBAEBCgEBgyuBDS9ag2eLCJB7DGSXBIYkAoRsAQIBAQEBAQITAQELCwkIJoVGAQECAgEjBAsBSwsjAgImAgJXGYhRgUMMqkiBbDqLVoELhyWCZYIDglmDNYJAHwWJOgeGSoY+hniTcIEWgWCDU4NCI4Y/j3CEKYFdbgqFLRyBZXOJNgEBAQ X-IronPort-AV: E=Sophos;i="5.37,250,1488862800"; d="scan'208";a="6029786" Received: from emsm-gh1-uea11.corp.nsa.gov (HELO emsm-gh1-uea11.nsa.gov) ([10.208.41.37]) by goalie.tycho.ncsc.mil with ESMTP; 25 Apr 2017 16:06:26 -0400 IronPort-PHdr: =?us-ascii?q?9a23=3ArEjCfx0tEw70nVF3smDT+DRfVm0co7zxezQtwd8Z?= =?us-ascii?q?seIXLPad9pjvdHbS+e9qxAeQG96KtbQY0aGP7/yocFdDyK7JiGoFfp1IWk1Nou?= =?us-ascii?q?QttCtkPvS4D1bmJuXhdS0wEZcKflZk+3amLRodQ56mNBXdrXKo8DEdBAj0OxZr?= =?us-ascii?q?KeTpAI7SiNm82/yv95HJbQhFgDuwbal9IRmoogndq8YbjIR/Iast1xXFpWdFdf?= =?us-ascii?q?5Lzm1yP1KTmBj85sa0/JF99ilbpuws+c1dX6jkZqo0VbNXAigoPGAz/83rqALM?= =?us-ascii?q?TRCT6XsGU2UZiQRHDg7Y5xznRJjxsy/6tu1g2CmGOMD9UL45VSi+46ptVRTmlT?= =?us-ascii?q?8HOCQ88G/VlMN/lr9Urwy7pxJ/wo7bfoWVO+djda3fY9wVX3dOUdhLVydcH42z?= =?us-ascii?q?c4wPD/AAPeZeoIn2ul8CoBWiCQWpAu7k1z1GiWLs3aAi0OovDAHI0hIuEd0Mvn?= =?us-ascii?q?TbsNL7O6gdX+2u0KnFzi/OY+9M1Dvh6oXFdA0qr/GWXbJ3dMrc0UghFx7EjlqN?= =?us-ascii?q?rozuIi2b1v4TvGid8+pvT+avhHQhqw5tozig3Nonh47GhoIIy1DL6CJ5zZ0pJd?= =?us-ascii?q?2iVkF7Z8KkH4FUty6AMYt5XsIiTHtytCY81LIGpYe2cS4Xw5ok3x7Sc/+Kf5WS?= =?us-ascii?q?7h/gV+udOzh1iXF/dL+wiRu+6Uytx+PmWsS7zVpGtCVInsXWun0J0RHY99KJRe?= =?us-ascii?q?Fn/ki73DaCzwDT5f9AIUAzjafUMYMhwqIwlpoItETDAjf2lF/sjKCIeUUk+/Oo?= =?us-ascii?q?6/j5bbX8vJOcNpN0hhn/MqQohMO/Hfw1PwsTU2SB+umx16fv8EL6TblQgfA7nL?= =?us-ascii?q?HVsJXAKsQaoq65DRVV0oEm6xunADemzdUYkmQALF9eZBKHlZbmO1fSIP/iCfew?= =?us-ascii?q?mVKsnytqx//cJLHhBIvCLmTbnLf7Ybl981JcyBY0zd1H/JJbFLUBIPP1Wk/su9?= =?us-ascii?q?3VFQM5MgyozObnD9VxzIUeWXmVDaODP6PStkGItaoTJLyXaYsUvivtA+Q07P7p?= =?us-ascii?q?y3kikBkSerf684EQbSWXA/VqJA2le3fqnt4FGGEBvwN2GOP3iVGFeSJJanCuVq?= =?us-ascii?q?Y14Do6AcSgAJuVFdPlu6CIwCruRs4eXWtBEF3ZSi/l?= X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0HYBADYqv9YgCswWFFbHAEBBAEBCgEBF?= =?us-ascii?q?wEBBAEBCgEBgwCBDYEJg2eLCJB7DGSXBIYkAoRsAQEBAQEBAQECAQIQAQELCwk?= =?us-ascii?q?IJjGCMwqCWAEBAgIBIwQLAUsLIwICJgICVxmIUYFDDKpIgWw6i1aBC4clgmWCA?= =?us-ascii?q?4JZgzWCQB8FiToHhkqGPoZ4k3CBFoFgg1ODQiOGP49whCmBXm4KhS0cgWVziTY?= =?us-ascii?q?BAQE?= X-IPAS-Result: =?us-ascii?q?A0HYBADYqv9YgCswWFFbHAEBBAEBCgEBFwEBBAEBCgEBgwC?= =?us-ascii?q?BDYEJg2eLCJB7DGSXBIYkAoRsAQEBAQEBAQECAQIQAQELCwkIJjGCMwqCWAEBA?= =?us-ascii?q?gIBIwQLAUsLIwICJgICVxmIUYFDDKpIgWw6i1aBC4clgmWCA4JZgzWCQB8FiTo?= =?us-ascii?q?HhkqGPoZ4k3CBFoFgg1ODQiOGP49whCmBXm4KhS0cgWVziTYBAQE?= X-IronPort-AV: E=Sophos;i="5.37,250,1488844800"; d="scan'208";a="5208602" X-IronPort-Outbreak-Status: No, level 0, Unknown - Unknown Received: from authsmtp20.register.it (HELO authsmtp.register.it) ([81.88.48.43]) by emsm-gh1-uea11.nsa.gov with ESMTP/TLS/DHE-RSA-AES128-SHA; 25 Apr 2017 20:06:25 +0000 Received: from [192.168.1.1] ([93.41.40.9]) by paganini32 with id Ck6P1v00R0BrE9Z01k6PvN; Tue, 25 Apr 2017 22:06:24 +0200 X-Rid: guido@trentalancia.net@93.41.40.9 Message-ID: <1493150773.12050.2.camel@trentalancia.net> Subject: [PATCH v2] libsemanage: remove lock files From: Guido Trentalancia To: selinux@tycho.nsa.gov Date: Tue, 25 Apr 2017 22:06:13 +0200 In-Reply-To: <201704251630.03844.russell@coker.com.au> References: <58517705.198270.1492699110308@pim.register.it> <100DD2AB-228E-47B5-8058-C9F030AEA665@trentalancia.net> <201704251630.03844.russell@coker.com.au> X-Mailer: Evolution 3.24.0 Mime-Version: 1.0 X-BeenThere: selinux@tycho.nsa.gov X-Mailman-Version: 2.1.20 Precedence: list List-Id: "Security-Enhanced Linux \(SELinux\) mailing list" List-Post: List-Help: Errors-To: selinux-bounces@tycho.nsa.gov Sender: "Selinux" X-Virus-Scanned: ClamAV using ClamSMTP Hello. What follows is a reply to Russell comments and a new, hopefully better, version of the original patch. On Tue, 25/04/2017 at 16.30 +1000, Russell Coker wrote: > On Tue, 25 Apr 2017 04:38:40 AM Guido Trentalancia wrote: > > Also, another major benefit of not using flock() comes when using > NFS > > (probably a very rare circumstance, but not entirely impossibile). > >  > > It is possible to use the presence of a file (with the same name) > to > > indicate an "active" lock: such file should store the PID of the > process > > that is requiring the lock. > >  > > If a lock is found with a PID that does not exist, then such lock > is > > considered invalid and it is removed.  That is it really... > > Pidfile locking doesn't work well as pids are not unique, you can > have a  > process die and be replaced by another process with the same pid.  > Also a  > reboot is expected to have pid conflicts as pids are allocated > sequentially and  > most daemons end up with low numbers.  Using a tmpfs for /run solves > some of  > these problems as it's reliably cleared out at boot. > > Things get even more exciting if you use systemd-nspawn and have > multiple pid  > namespaces on the same system with bind mounts of directories that > have  > pidfiles. > > Pidfile locking also never works across network filesystems as pids > are local to  > a system.  You could have some combination of pid and hostname (as > done by  > some web browsers) but that gets ugly. No, I didn't mean the complicate circumstance of NFS shared amongst multiple systems. I only meant the simpler (and most common) situation where the NFS is mounted for only one system, therefore PIDs are unique and there is no need to include the hostname. > Really pidfiles are so horrible that one of the noteworthy features > of systemd  > is removing the need for them. I am not that pessimistic about locking with aid of PIDs. To be honest, the current situation has more drawbacks in my opinion. In particular, I don't like the fact that it leaves unused lock files around the filesystem. > Having multiple systems operate with NFS root and a shared > /etc/selinux is  > never going to work well.  Even if everything works well (and it > probably  > won't) you will end up with systems that have the policy in > /etc/selinux not  > matching what is running. Please forget sharing NFS. I meant dedicated NFS. Anyway, I have created a new version of the patch that should probably improve the previous race condition. If you have a way of testing a dedicated store over NFS, then I'd like to hear back from you the result of such testing ! But, if you are not interested in testing it, then never mind... --- Do not use flock() for file locking, but instead use generic text files that keep track of the process ID (PID) of the locking process. Remove semanage read and transaction lock files upon releasing them. Signed-off-by: Guido Trentalancia --- src/Makefile | 2 src/semanage_store.c | 205 ++++++++++++++++++++++++++++++++++++++------------- 2 files changed, 154 insertions(+), 53 deletions(-) --- a/src/Makefile 2016-10-14 17:31:26.000000000 +0200 +++ b/src/Makefile 2017-04-25 00:54:58.916827639 +0200 @@ -91,7 +91,7 @@ $(LIBA): $(OBJS) $(RANLIB) $@ $(LIBSO): $(LOBJS) - $(CC) $(CFLAGS) $(LDFLAGS) -shared -o $@ $^ -lsepol -laudit -lselinux -lbz2 -lustr -L$(LIBDIR) -Wl,-soname,$(LIBSO),--version-script=libsemanage.map,-z,defs + $(CC) $(CFLAGS) $(LDFLAGS) -shared -o $@ $^ -lm -lsepol -laudit -lselinux -lbz2 -lustr -L$(LIBDIR) -Wl,-soname,$(LIBSO),--version-script=libsemanage.map,-z,defs ln -sf $@ $(TARGET) $(LIBPC): $(LIBPC).in ../VERSION --- a/src/semanage_store.c 2016-10-14 17:31:26.000000000 +0200 +++ b/src/semanage_store.c 2017-04-25 21:52:51.977563955 +0200 @@ -45,6 +45,8 @@ typedef struct dbase_policydb dbase_t; #include #include #include +#include +#include #include #include #include @@ -52,11 +54,24 @@ typedef struct dbase_policydb dbase_t; #include #include #include +#include #include #include #include #include +#include + +#ifndef CONFIG_BASE_SMALL +#define CONFIG_BASE_SMALL 0 +#endif + +#include + +#ifndef PID_MAX_DEFAULT +#define PID_MAX_DEFAULT 32768 +#endif + #include "debug.h" #include "utilities.h" @@ -76,6 +91,8 @@ enum semanage_file_defs { static char *semanage_paths[SEMANAGE_NUM_STORES][SEMANAGE_STORE_NUM_PATHS]; static char *semanage_files[SEMANAGE_NUM_FILES] = { NULL }; static int semanage_paths_initialized = 0; +static int pid_max; +static ssize_t pid_max_length; /* These are paths relative to the bottom of the module store */ static const char *semanage_relative_files[SEMANAGE_NUM_FILES] = { @@ -425,8 +442,23 @@ cleanup: int semanage_check_init(semanage_handle_t *sh, const char *prefix) { int rc; + int fd; + char root[PATH_MAX]; + ssize_t amount_read; + if (semanage_paths_initialized == 0) { - char root[PATH_MAX]; + pid_max = PID_MAX_DEFAULT; + pid_max_length = ceil(log10(PID_MAX_DEFAULT + 1)); + + fd = open("/proc/sys/kernel/pid_max", O_RDONLY); + if (fd > 0) { + char sysctlstring[pid_max_length]; + amount_read = read(fd, sysctlstring, pid_max_length); + if (amount_read > 0) { + pid_max = atoi(sysctlstring); + pid_max_length = ceil(log10(pid_max + 1)); + } + } rc = snprintf(root, sizeof(root), @@ -526,16 +558,23 @@ char *semanage_conf_path(void) /**************** functions that create module store ***************/ -/* Check that the semanage store exists. If 'create' is non-zero then - * create the directories. Returns 0 if module store exists (either - * already or just created), -1 if does not exist or could not be - * read, or -2 if it could not create the store. */ +/* Check that the semanage store exists and that the read lock can be + * taken. If 'create' is non-zero then it creates the directories + * and the lock file. Returns 0 if the module store exists (either + * already or just created) and the read lock can be taken, -1 if it + * does not exist or it is not possible to read from it, or -2 if it + * could not create the store or it could not take the lock file. */ int semanage_create_store(semanage_handle_t * sh, int create) { struct stat sb; int mode_mask = R_OK | W_OK | X_OK; const char *path = semanage_files[SEMANAGE_ROOT]; int fd; + pid_t pid, lock_pid; + char *pid_string, *lock_pid_string; + size_t pid_length; + ssize_t pid_bytes; + int invalid_lock = 0; if (stat(path, &sb) == -1) { if (errno == ENOENT && create) { @@ -605,26 +644,82 @@ int semanage_create_store(semanage_handl return -1; } } + pid = getpid(); + pid_string = malloc(pid_max_length * sizeof(char)); + sprintf(pid_string, "%d", pid); + pid_length = strlen(pid_string); path = semanage_files[SEMANAGE_READ_LOCK]; if (stat(path, &sb) == -1) { if (errno == ENOENT && create) { if ((fd = creat(path, S_IRUSR | S_IWUSR)) == -1) { ERR(sh, "Could not create lock file at %s.", path); + free(pid_string); return -2; } + pid_bytes = write(fd, pid_string, pid_length); close(fd); + free(pid_string); + if (pid_bytes == (ssize_t) pid_length) + return 0; + else { + ERR(sh, "Could not create lock file at %s.", path); + return -2; + } } else { ERR(sh, "Could not read lock file at %s.", path); + free(pid_string); return -1; } } else { if (!S_ISREG(sb.st_mode) || access(path, R_OK | W_OK) == -1) { ERR(sh, "Could not access lock file at %s.", path); + free(pid_string); return -1; - } + } else { + fd = open(path, O_RDWR); + if (fd > 0) { + lock_pid_string = malloc(pid_max_length * sizeof(char)); + pid_bytes = read(fd, lock_pid_string, pid_max_length); + if (pid_bytes > 0) { + lock_pid = (pid_t) atoi(lock_pid_string); + if (lock_pid > pid_max) + invalid_lock = 1; + else if (kill(lock_pid, 0) != 0) + if (errno == ESRCH) + invalid_lock = 1; + + if (!invalid_lock) { + ERR(sh, "Could not create lock file at %s.", path); + close(fd); + free(pid_string); + free(lock_pid_string); + return -2; + } + } else + invalid_lock = 1; + + if (invalid_lock) { + pid_bytes = pwrite(fd, pid_string, pid_length, 0); + close(fd); + free(pid_string); + free(lock_pid_string); + if (pid_bytes == (ssize_t) pid_length) + return 0; + else { + ERR(sh, "Could not create lock file at %s.", path); + return -2; + } + } else { + ERR(sh, "Could not create lock file at %s.", path); + close(fd); + free(pid_string); + free(lock_pid_string); + return -2; + } + } + } } - return 0; } /* returns <0 if the active store cannot be read or doesn't exist @@ -1788,64 +1883,74 @@ int semanage_install_sandbox(semanage_ha static int semanage_get_lock(semanage_handle_t * sh, const char *lock_name, const char *lock_file) { + pid_t pid, lock_pid; + char *pid_string, *lock_pid_string; int fd; - struct timeval origtime, curtime; + size_t pid_length; + ssize_t pid_bytes; int got_lock = 0; + int overwritten_lock = 0; - if ((fd = open(lock_file, O_RDONLY)) == -1) { - if ((fd = - open(lock_file, O_RDWR | O_CREAT | O_TRUNC, - S_IRUSR | S_IWUSR)) == -1) { + pid = getpid(); + pid_string = malloc(pid_max_length * sizeof(char)); + sprintf(pid_string, "%d", pid); + pid_length = strlen(pid_string); + if ((fd = open(lock_file, O_RDWR | O_CREAT, S_IRUSR | S_IWUSR)) == -1) { ERR(sh, "Could not open direct %s at %s.", lock_name, lock_file); + free(pid_string); return -1; + } else { + lock_pid_string = malloc(pid_max_length * sizeof(char)); + pid_bytes = pread(fd, lock_pid_string, pid_max_length, 0); + if (pid_bytes == 0) { + overwritten_lock = 1; + pid_bytes = write(fd, pid_string, pid_length); + if (pid_bytes == (ssize_t) pid_length) + got_lock = 1; + } else { + lock_pid = (pid_t) atoi(lock_pid_string); + if (lock_pid > pid_max) { + overwritten_lock = 1; + pid_bytes = pwrite(fd, pid_string, pid_length, 0); + if (pid_bytes == (ssize_t) pid_length) + got_lock = 1; + } else { + if (lock_pid = pid) + got_lock = 1; + else if (kill(lock_pid, 0) != 0) + if (errno == ESRCH) { + overwritten_lock = 1; + pid_bytes = pwrite(fd, pid_string, pid_length, 0); + if (pid_bytes == (ssize_t) pid_length) + got_lock = 1; + } + } } } - if (fcntl(fd, F_SETFD, FD_CLOEXEC) < 0) { - ERR(sh, "Could not set close-on-exec for %s at %s.", lock_name, - lock_file); + + if (!got_lock) { close(fd); + free(pid_string); + free(lock_pid_string); + if (overwritten_lock) + unlink(lock_file); + ERR(sh, "Could not get direct %s at %s.", lock_name, lock_file); return -1; } - if (sh->timeout == 0) { - /* return immediately */ - origtime.tv_sec = 0; - } else { - origtime.tv_sec = sh->timeout; - } - origtime.tv_usec = 0; - do { - curtime.tv_sec = 1; - curtime.tv_usec = 0; - if (flock(fd, LOCK_EX | LOCK_NB) == 0) { - got_lock = 1; - break; - } else if (errno != EAGAIN) { - ERR(sh, "Error obtaining direct %s at %s.", lock_name, - lock_file); - close(fd); - return -1; - } - if (origtime.tv_sec > 0 || sh->timeout == -1) { - if (select(0, NULL, NULL, NULL, &curtime) == -1) { - if (errno == EINTR) { - continue; - } - ERR(sh, - "Error while waiting to get direct %s at %s.", - lock_name, lock_file); - close(fd); - return -1; - } - origtime.tv_sec--; - } - } while (origtime.tv_sec > 0 || sh->timeout == -1); - if (!got_lock) { - ERR(sh, "Could not get direct %s at %s.", lock_name, lock_file); + if (fcntl(fd, F_SETFD, FD_CLOEXEC) < 0) { + ERR(sh, "Could not set close-on-exec for %s at %s.", lock_name, + lock_file); close(fd); + free(pid_string); + free(lock_pid_string); + unlink(lock_file); return -1; } + + free(pid_string); + free(lock_pid_string); return fd; } @@ -1894,29 +1999,27 @@ int semanage_get_active_lock(semanage_ha } } -/* Releases the transaction lock. Does nothing if there was not one already - * there. */ +/* Releases the transaction lock: the lock file is removed */ void semanage_release_trans_lock(semanage_handle_t * sh) { int errsv = errno; if (sh->u.direct.translock_file_fd >= 0) { - flock(sh->u.direct.translock_file_fd, LOCK_UN); close(sh->u.direct.translock_file_fd); sh->u.direct.translock_file_fd = -1; } + unlink(semanage_files[SEMANAGE_TRANS_LOCK]); errno = errsv; } -/* Releases the read lock. Does nothing if there was not one already - * there. */ +/* Releases the read lock: the lock file is removed */ void semanage_release_active_lock(semanage_handle_t * sh) { int errsv = errno; if (sh->u.direct.activelock_file_fd >= 0) { - flock(sh->u.direct.activelock_file_fd, LOCK_UN); close(sh->u.direct.activelock_file_fd); sh->u.direct.activelock_file_fd = -1; } + unlink(semanage_files[SEMANAGE_READ_LOCK]); errno = errsv; }