Devuan bug report logs - #334
eudev service might be using an incomplete PATH

Package: eudev; Reported by: Guenther Brunthaler <gb_about_gnu@gmx.net>; Done: Svante Signell <svante.signell@gmail.com>; Maintainer for eudev is Devuan Dev Team <devuan-dev@lists.dyne.org>.

Message received at 334-close@bugs.devuan.org:


Received: (at 334-close) by bugs.devuan.org; 27 Jan 2020 11:31:45 +0000
Return-Path: <svante.signell@gmail.com>
Delivered-To: devuanbugs@dyne.org
Received: from tupac3.dyne.org [195.169.149.119]
	by doc.devuan.org with IMAP (fetchmail-6.4.0.beta4)
	for <debbugs@localhost> (single-drop); Mon, 27 Jan 2020 11:31:45 +0000 (UTC)
Received: from mail-lj1-f174.google.com (mail-lj1-f174.google.com [209.85.208.174])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by vm6.ganeti.dyne.org (Postfix) with ESMTPS id 45E92F60A43
	for <334-close@bugs.devuan.org>; Mon, 27 Jan 2020 12:31:13 +0100 (CET)
Authentication-Results: vm6.ganeti.dyne.org;
	dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="TzX0M1Dg";
	dkim-atps=neutral
Received: by mail-lj1-f174.google.com with SMTP id w1so10284395ljh.5
        for <334-close@bugs.devuan.org>; Mon, 27 Jan 2020 03:31:13 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=20161025;
        h=message-id:subject:from:reply-to:to:date:organization:user-agent
         :mime-version:content-transfer-encoding;
        bh=Dr+LCzZ2+qjOYQ+vdOVRy6Q+Qt3A/q8FyrAuFcoJXNc=;
        b=TzX0M1Dgp8OVTMgKh/G7lZLwk5ylsiDstbwGN6vjDN0iCrMmlYUVSil7qo8u+sXE2R
         g0OI5Vfh6pWDXMmUVA4WdwH+miJxfA5OKmNW5yRZ65HxJ749Ccjet394BriKaDTFqtR2
         NZ6JKBPp8XMm/vaS4GJK6ICWFGdisFxsndrBExgIIbrHaaSYSbCnR0aCgDTUix7h4bu/
         jbYDE/pP9PJaOlcTSx/78j+gJw3alHRElRyKexUtUPdUDOi0PJHF89UeH6v8E8lXV2KQ
         lfvd7+YUV/xyPgJRIWVbhnGs2nJQwhzjzz6T1ZHb27K447K0Glgty9TNOvoyhcppEcrG
         Kbfg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=1e100.net; s=20161025;
        h=x-gm-message-state:message-id:subject:from:reply-to:to:date
         :organization:user-agent:mime-version:content-transfer-encoding;
        bh=Dr+LCzZ2+qjOYQ+vdOVRy6Q+Qt3A/q8FyrAuFcoJXNc=;
        b=sOmxUaIWoRcmIagFEzgcpYtVMihnqdGGaRXPQlVyBEJoXIJI9saIBHo6Kx7SD2RbIL
         Veo4JhqAOpoOPYRVjtV2twLL2COtAiojXI9sCLFVlDeRVXEtBxbfiKt1SyUhLu45oR2O
         U2d1dMK2skbq2csnurkfv4imyvG84weYZPb0W9gptXm7Q7ysEGr81LZNOR3QPE9lWhJJ
         r1ZL4yD8GMhNXKGgEP/5LAWUQtMgnM3mX0dFjnWVgVxImTYMqBnwLZe7bbGkw7Xv84pF
         gFmJvxIn5Yy1Duvr91eBQGHKLEQ50KOmJDgiGvcdCmoSZQgRr9Qi81VDQSeKdKli7Zwh
         S6yQ==
X-Gm-Message-State: APjAAAXpVf5dDdr4FQEyrTvymu5EyT+ncnLubca/B8mjE6O5XHDy+QFm
	SMS7F+QXKKin5auNHxTPQljTmanI
X-Google-Smtp-Source: APXvYqyyqb+raJ83330cqrNKebDvesMYABliLBiXvf9X7e1OJEJR44zx6AzGkENCZ/1XbcI2zEbv1A==
X-Received: by 2002:a2e:8119:: with SMTP id d25mr9956465ljg.76.1580124672489;
        Mon, 27 Jan 2020 03:31:12 -0800 (PST)
Received: from G3620.lan (178-78-231-178.customers.ownit.se. [178.78.231.178])
        by smtp.gmail.com with ESMTPSA id t10sm7937357lji.61.2020.01.27.03.31.11
        (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);
        Mon, 27 Jan 2020 03:31:12 -0800 (PST)
Message-ID: <accea08ec4dd728bbe8e3859275de89afb24fed3.camel@gmail.com>
Subject: [Devuan-bugs] bug#334: eudev service might be using an incomplete
 PATH
From: Svante Signell <svante.signell@gmail.com>
Reply-To: svante.signell@gmail.com
To: 334-close@bugs.devuan.org
Date: Mon, 27 Jan 2020 12:32:24 +0100
Organization: Home
Content-Type: text/plain
User-Agent: Evolution 3.30.5-1.1 
MIME-Version: 1.0
Content-Transfer-Encoding: quoted-printable
X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID,
	DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,
	RCVD_IN_MSPIKE_H2,SPF_PASS autolearn=disabled version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on tupac3.dyne.org

Fixed by eudev-3.2.9-1, closing.




Notification sent to Guenther Brunthaler <gb_about_gnu@gmx.net>:
bug acknowledged by developer. Full text available.
Reply sent to svante.signell@gmail.com:
You have taken responsibility. Full text available.

Message received at 334@bugs.devuan.org:


Received: (at 334) by bugs.devuan.org; 13 Jun 2019 22:40:06 +0000
Return-Path: <gb_about_gnu@gmx.net>
Delivered-To: devuanbugs@dyne.org
Received: from tupac3.dyne.org [195.169.149.119]
	by fulcanelli with IMAP (fetchmail-6.3.26)
	for <debbugs@localhost> (single-drop); Fri, 14 Jun 2019 00:40:06 +0200 (CEST)
Received: from mout.gmx.net (mout.gmx.net [212.227.15.18])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by vm6.ganeti.dyne.org (Postfix) with ESMTPS id 860DEF60BD2
	for <334@bugs.devuan.org>; Fri, 14 Jun 2019 00:39:47 +0200 (CEST)
Authentication-Results: vm6.ganeti.dyne.org;
	dkim=pass (1024-bit key; secure) header.d=gmx.net header.i=@gmx.net header.b="LTyLw/6p";
	dkim-atps=neutral
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net;
	s=badeba3b8450; t=1560465587;
	bh=TG1d88MQFWvsJmmdKrYQHlzs/kaxBI2q5bxvZJe+cp8=;
	h=X-UI-Sender-Class:Subject:To:References:From:Date:In-Reply-To;
	b=LTyLw/6pGBn1nKa5hvLYUuhLIp0ScySKzPTsmv+SMGYfsI14r+MW8l/FAgShMUF+A
	 Db3uUPN5rKy+BmOQJOsBQU4DF0SjAY870oTXljMkNV/x4auw7s9KqchoBBMfVM/MmP
	 D10BbeHwX6YgfcNXaTuwRz/Q75HEvPApUJQ3YbZ4=
X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c
Received: from [10.157.146.248] ([91.141.2.127]) by mail.gmx.com (mrgmx005
 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MgesQ-1iIJBe3Ssm-00h37y for
 <334@bugs.devuan.org>; Fri, 14 Jun 2019 00:39:47 +0200
Subject: This might actually be a compatibility issue in the eudev code
To: 334@bugs.devuan.org
References: <cc341dd2-d3bc-32a8-063b-ae6c9b410881@gmx.net>
 <handler.334.B.156046260630478.ack@bugs.devuan.org>
From: Guenther Brunthaler <gb_about_gnu@gmx.net>
Message-ID: <44046b0a-9ea5-98b3-b756-e2e4b3bd3cd3@gmx.net>
Date: Fri, 14 Jun 2019 00:39:44 +0200
User-Agent: Mozilla/5.0 (X11; Linux armv7l; rv:52.0) Gecko/20100101
 Thunderbird/52.9.1
MIME-Version: 1.0
In-Reply-To: <handler.334.B.156046260630478.ack@bugs.devuan.org>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Language: de-AT
Content-Transfer-Encoding: quoted-printable
X-Provags-ID: V03:K1:NJJ9EsK9uMdOa7U6ysolTHNtEN9QYJ14DE9A9jC/dLh0TXnVdrx
 VhHZtKgpDaKrYFrAafZcnAVRdxaY384mE5C3/yfr6rc9MeOzwGpy0jV/uxBwpASy22hqH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5/Fpo34GPfixyrKZY4PIleSkQwmvT8tvR3dU7+gDuku0ZYGgF0v8uaqC
 kNOmiQiGXCTExEzNUN9JiLHfdnfV1g4/hYA/Zg5+kAy1awUcL412/
X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID,
	DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS
	autolearn=disabled version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on tupac3.dyne.org

I have just compared the functionality of

/lib/systemd/systemd-udevd --daemon

on Raspbian with that of

/sbin/udevd --daemon

on Devuan.

The result is that both installations of the rule file from bug #333 are
identical:

$ cksum /lib/udev/rules.d/40-usb_modeswitch.rules
194757299 40499 /lib/udev/rules.d/40-usb_modeswitch.rules

and neither does Raspbian add /lib/udev to the front of PATH, which I
verified by temporarily modifying /lib/udev/usb_modeswitch so that it
logs its PATH setting, which showed:

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin

You see, no /lib/udev.

Yet systemd-udevd correctly invokes /lib/udev/usb_modeswitch rather than
/usr/sbin/usb_modeswitch when the udev rule just says

$ grep symlink-name /lib/udev/rules.d/40-usb_modeswitch.rules
KERNEL=3D=3D"ttyUSB*", ATTRS{bNumConfigurations}=3D=3D"*",
PROGRAM=3D"usb_modeswitch --symlink-name %p %s{idVendor} %s{idProduct}
%E{PRODUCT}", SYMLINK+=3D"%c"

It follows, that systemd-udevd seems to use an augmented PATH for
exec'ing its PROGRAM, but does not "export" that augmented PATH to the
invoked program.

Therefore, to remain compatible with systemd-udevd, eudev should do the
same.

One might even suspect this was a subtle change deliberately introduced
by some people who wanted to make eudev look bad, but it does not really
matter and just needs to be fixed.

I suppose this is an upstream bug and not Devuan-specific, and should be
escalated to upstream.

Im I supposed to do that, or will you Devuan guys do it?


Acknowledgement sent to Guenther Brunthaler <gb_about_gnu@gmx.net>:
Extra info received and forwarded to list. Copy sent to owner@bugs.devuan.org. Full text available.
Information forwarded to devuan-bugs@lists.dyne.org, owner@bugs.devuan.org:
bug#334; Package eudev. Full text available.

Message received at submit@bugs.devuan.org:


Received: (at submit) by bugs.devuan.org; 13 Jun 2019 21:50:06 +0000
Return-Path: <gb_about_gnu@gmx.net>
Delivered-To: devuanbugs@dyne.org
Received: from tupac3.dyne.org [195.169.149.119]
	by fulcanelli with IMAP (fetchmail-6.3.26)
	for <debbugs@localhost> (single-drop); Thu, 13 Jun 2019 23:50:06 +0200 (CEST)
Received: from mout.gmx.net (mout.gmx.net [212.227.15.15])
	(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
	(No client certificate requested)
	by vm6.ganeti.dyne.org (Postfix) with ESMTPS id BDD1DF60BBF
	for <submit@bugs.devuan.org>; Thu, 13 Jun 2019 23:44:56 +0200 (CEST)
Authentication-Results: vm6.ganeti.dyne.org;
	dkim=pass (1024-bit key; secure) header.d=gmx.net header.i=@gmx.net header.b="LFF8+sNN";
	dkim-atps=neutral
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net;
	s=badeba3b8450; t=1560462296;
	bh=C9wkP/r+J8ZZiujzZiXZm3awwYK5VqeiY6RiwyA5C1I=;
	h=X-UI-Sender-Class:From:Subject:To:Date;
	b=LFF8+sNN1injtxkRNgEJBL19gkTmSW7Log74u94cBut0FvdQZYBhIFc03cHYLuS98
	 etulbejSY5fwMREWEculssDJM3vjCmVqOiZXGroFRNlxhW80JvUCQKK09wfVkLfa31
	 EjH4InHFUEubw7zHAcJkNg7BMnAvUy7XUSfCGBs8=
X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c
Received: from [10.157.146.248] ([91.141.3.40]) by mail.gmx.com (mrgmx003
 [212.227.17.190]) with ESMTPSA (Nemesis) id 0LqzIJ-1iEjp63e0B-00ebiV for
 <submit@bugs.devuan.org>; Thu, 13 Jun 2019 23:44:56 +0200
From: Guenther Brunthaler <gb_about_gnu@gmx.net>
Subject: eudev service might be using an incomplete PATH
To: submit@bugs.devuan.org
Message-ID: <cc341dd2-d3bc-32a8-063b-ae6c9b410881@gmx.net>
Date: Thu, 13 Jun 2019 23:44:54 +0200
User-Agent: Mozilla/5.0 (X11; Linux armv7l; rv:52.0) Gecko/20100101
 Thunderbird/52.9.1
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Language: en-US
Content-Transfer-Encoding: quoted-printable
X-Provags-ID: V03:K1:fBO/qHT4Ta1hwvXxHeryk4/zbH3dnkiaPAQCO+kbXtqAG2R+8CM
 3PDJGFzhQIqpUXHvvYyFEndUk9uylzwAjMMp9FaihEYrHvydr2udeF1m3H+NpKxs9XSxmwy
 3YF1YNUWfK+3D5mOeqKplL6C8LZfrrk/oebdKEFqSETlZAgbXvuhZkO0dVLiDp06G364CGQ
 Vb7fd/e17FzkMWG1q9M8A==
X-UI-Out-Filterresults: notjunk:1;V03:K0:GtVcZQuz7KY=:fKqi+SCAX0VoEC8faleTtT
 s66l90Wey1zgbP0allur5Dl2cyRLSq6vgRiHbBA6GyODUhP2dSP0fMQj7qZZwxV9HHRo/j1yT
 ygUDAcqPiUrQ/0r6yd3Tov6sVJwMaWshCKCQ32bAUpEGL8FJO17PIIQzGEGenD0JpkfDO7qSR
 OdROxI02/q4rsHNZDpk3dMDnbKpBDbxBU0FjM68kP0eN3hNH4U+wGdH2Ma4M9yd608Rq7kWUR
 BPAn8savbLCuLy7QaUqGEvEvF9nqUJgkapTuovgIQl/mC0iAHwmMO3/WFtMqDSxF1RCZRCtLA
 woBJhzu+wwevk5wE6Crdqb4Uu+36UO1Pt8QdLtujBAHbCSMJGlw/681Ux9EAcbDrEn2wqwiOO
 lfK4IAKzAs1vfh7o8KrBTMZVcjtv3vB2aH6KDwkZVVGhxfTsaHoeaPTLkZ9qpLZ2WgJ81V3+p
 KaDhXlEVcNRPLTR0duoav3qEdex3AGi8sCNkuDM3H6eQuiEyZuxL5BTbLP5iDm0lIz2v/E88F
 hPUkzsvLQOON41yfwPUL+PGaTun6ps+z25j52n/0lrIduL836p5ALF4uKweS8Cxep4kD+LC+u
 5542cUy/HAGQ5rqrK1/R00oR62+Nuf8git2iHVoNwaqFSN5DD/LXBACRq86RJUbFE2W0lIVD+
 iM9IVStWN7wWLKtxQAgB8EQmDdzMx63noPEYUK+YEDQ9nmYPYG3qMvzlRmVvVh54r5Lci73Et
 OvuNs0Ts5/i+lSIrW/MEMev2ia2hSxbA6JLSBF7dOFYM1RBhQEWReDW737rCGL0vBNDVfty0L
 zToeJOACN19FA4jP/ascyGDJ9NUnmVglr9E5jxAbzr3aoyir1+8XhVjNzM12T/IIFJ0Q9hHDo
 2JxKOV60QN8fLCUAjmtHtEKn3oBiecbmbggtx1ie+WXttUweEnDCScDsFKudbnTUmERMTkNmB
 cjsS6cnMyFa8qsscJFi/imlScosTNbdzExptLRbdlCruOcYNTMsBf
X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID,
	DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS
	autolearn=disabled version=3.4.2
X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on tupac3.dyne.org

Package: eudev
Version: 3.2.2-13

Bug #333 is caused by an udev rule invoking the wrong executable,
because it obviously wanted to execute a script in /lib/udev but did not
specify the full path, and thus invoked a binary of the same name in
/usr/sbin which was not intended.

Assuming the udev-rule from the usb-modeswitch-data is correct and
standard, it follows that the eudev service is currently using an
inadequate PATH.

The following modification made the problem with bug #333 go away:

$ diff -u /etc/udev/udev.conf.upstream /etc/udev/udev.conf
=2D-- /etc/udev/udev.conf.upstream        2019-06-13 23:14:29.000000000 +0=
200
+++ /etc/udev/udev.conf 2019-06-13 23:15:17.000000000 +0200
@@ -4,3 +4,5 @@
  # initramfs should be rebuilt.

  #udev_log=3D"info"
+
+PATH=3D/lib/udev:$PATH

I therefore suggest changing the line

$ grep PATH /etc/init.d/eudev
PATH=3D"/sbin:/bin"

into

PATH=3D/lib/udev:/sbin:/bin

I am using Devuan GNU/Linux 2.0 (ascii)
on branch ascii
with kernel
Linux xeeepc 4.9.0-9-686 #1 SMP Debian 4.9.168-1+deb9u2 (2019-05-13)
i686 GNU/Linux


Acknowledgement sent to Guenther Brunthaler <gb_about_gnu@gmx.net>:
New bug report received and forwarded. Copy sent to owner@bugs.devuan.org. Full text available.
Report forwarded to devuan-bugs@lists.dyne.org, owner@bugs.devuan.org:
bug#334; Package eudev. Full text available.

Devuan BTS -- Powered by Debian bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.

Devuan Bugs Owner <owner@bugs.devuan.org>.
Last modified: Sun, 5 Jul 2020 16:39:01 UTC