• Bug#1098508: adduser lacks dependency on libperl5.40 for Encode.pm

    From Yves-Alexis Perez@21:1/5 to All on Fri Feb 21 17:40:02 2025
    Package: adduser
    Version: 3.139
    Severity: grave

    Hi Marc,

    adduser 3.139 uses Encode.pm but doesn't depend on the package providing
    it (libperl5.40 is optional). It's likely the package is still installed
    on most standard installations but it won't be on minimal installs

    I noticed the bug on a piupart run on salsa CI:

    https://salsa.debian.org/debian/strongswan/-/jobs/7132445#L5105

    I guess that could also happens in buildds or minimal containers.

    Not sure about the correct solution but feel free to discuss it here :)

    Regards,
    --
    Yves-Alexis

    -- System Information:
    Debian Release: trixie/sid
    APT prefers unstable-debug
    APT policy: (500, 'unstable-debug'), (500, 'unstable'), (500, 'testing'), (450, 'experimental')
    Architecture: amd64 (x86_64)
    Foreign Architectures: i386

    Kernel: Linux 6.12.13-amd64 (SMP w/4 CPU threads; PREEMPT)
    Kernel taint flags: TAINT_WARN, TAINT_FIRMWARE_WORKAROUND
    Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), LANGUAGE not set
    Shell: /bin/sh linked to /usr/bin/dash
    Init: systemd (via /run/systemd/system)
    LSM: AppArmor: enabled

    Versions of packages adduser depends on:
    ii passwd 1:4.17.2-5

    adduser recommends no packages.

    Versions of packages adduser suggests:
    ii cron 3.0pl1-192
    ii liblocale-gettext-perl 1.07-7+b1
    ii perl 5.40.1-2
    pn quota <none>

    -- debconf information:
    adduser/homedir-permission: true
    adduser/title:

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Chris Hofstaedtler@21:1/5 to Yves-Alexis Perez on Fri Feb 21 17:50:02 2025
    Hi perl Maintainers,

    On Fri, Feb 21, 2025 at 05:32:08PM +0100, Yves-Alexis Perez wrote:
    adduser 3.139 uses Encode.pm but doesn't depend on the package providing
    it (libperl5.40 is optional). It's likely the package is still installed
    on most standard installations but it won't be on minimal installs

    I'm not the adduser maintainer, but asking anyway: would it be
    possible for perl-base to include Encode.pm? Then adduser could use
    it without pulling in a full perl on most systems...

    Chris

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Niko Tyni@21:1/5 to Chris Hofstaedtler on Fri Feb 21 19:20:01 2025
    On Fri, Feb 21, 2025 at 05:43:54PM +0100, Chris Hofstaedtler wrote:
    Hi perl Maintainers,

    On Fri, Feb 21, 2025 at 05:32:08PM +0100, Yves-Alexis Perez wrote:
    adduser 3.139 uses Encode.pm but doesn't depend on the package providing
    it (libperl5.40 is optional). It's likely the package is still installed
    on most standard installations but it won't be on minimal installs

    If a dependency is to be added, please make it 'perl' rather than 'libperl5.40'.

    I'm not the adduser maintainer, but asking anyway: would it be
    possible for perl-base to include Encode.pm? Then adduser could use
    it without pulling in a full perl on most systems...

    It's certainly technically possible, but it's not something to be done
    lightly. As the Policy says, "removing functionality from the Essential
    set is very difficult and is almost never done. Any capability added
    to an essential package therefore creates an obligation to support that capability as part of the Essential set in perpetuity."

    I'm not very clear on the background here. I saw something on IRC
    about the apt -> adduser dependency being relevant here. But that's
    an alternative dependency (base-passwd (>= 3.6.1) | adduser) AFAICS,
    and I don't know why minimal containers wouldn't be fine with just a
    recent base-passwd and no adduser.

    From my point of view, perl-base exists for the benefit of the Debian
    installer and maintainer scripts (prerm and preinst in particular),
    and no end user systems should end up without the full perl installed.
    So 'pulling in a full perl on most systems' is actually desirable.

    Also I'm not sure how useful Encode.pm would be on its own. A lot of
    the functionality in the upstream Encode distribution is split out to
    separate modules like Encode::Alias, Encode::MIME::Header etc. I would
    prefer not to have to add them piecemeal as bug reports pile in, even
    less so at this stage of the release cycle.

    And I haven't looked at what dependencies Encode itself might require,
    so I don't know if it would pull other modules from the full perl into perl-base.

    All that said, if there's consensus that adding Encode.pm is necessary,
    I'm not blocking it. But I think this requires some research and at
    least a debian-devel discussion first.

    ( For full disclosure, I note that there is also a separate libencode-perl
    package in the archive. But that one depends on the full perl too,
    it's mainly just a way to make newer versions available sooner. I
    fear making it useful in this context would probably not be quite as
    trivial as might seem at first glance.)

    Sorry for not making things easier,
    --
    Niko

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Marc Haber@21:1/5 to Niko Tyni on Fri Feb 21 19:50:01 2025
    On Fri, Feb 21, 2025 at 08:09:20PM +0200, Niko Tyni wrote:
    On Fri, Feb 21, 2025 at 05:43:54PM +0100, Chris Hofstaedtler wrote:
    Hi perl Maintainers,

    On Fri, Feb 21, 2025 at 05:32:08PM +0100, Yves-Alexis Perez wrote:
    adduser 3.139 uses Encode.pm but doesn't depend on the package providing it (libperl5.40 is optional). It's likely the package is still installed on most standard installations but it won't be on minimal installs

    If a dependency is to be added, please make it 'perl' rather than 'libperl5.40'.

    I'd rather pull the encode usage again instead of pulling a full perl
    into all Debian installations. Adduser has code to pull in some other dependencies conditionally, I'd like to have that for encode as well.
    That doesn't work at the moment though.

    Greetings
    Marc

    -- ----------------------------------------------------------------------------- Marc Haber | "I don't trust Computers. They | Mailadresse im Header Leimen, Germany | lose things." Winona Ryder | Fon: *49 6224 1600402 Nordisch by Nature | How to make an American Quilt | Fax: *49 6224 1600421

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Debian Bug Tracking System@21:1/5 to All on Sat Feb 22 08:00:02 2025
    Processing control commands:

    tag -1 pending
    Bug #1098508 [adduser] adduser lacks dependency on libperl5.40 for Encode.pm Bug #1098509 [adduser] adduser: Encode import is missing dependency
    Added tag(s) pending.
    Added tag(s) pending.

    --
    1098508: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1098508
    1098509: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1098509
    Debian Bug Tracking System
    Contact owner@bugs.debian.org with problems

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Marc Haber@21:1/5 to All on Sat Feb 22 08:00:02 2025
    Control: tag -1 pending

    Hello,

    Bug #1098508 in adduser reported by you has been fixed in the
    Git repository and is awaiting an upload. You can see the commit
    message below and you can check the diff of the fix at:

    https://salsa.debian.org/debian/adduser/-/commit/42c88018a546f414ae3fff695d147d3836a56503

    ------------------------------------------------------------------------
    allow adduser to run without Encode and I18N::Langinfo installed

    Thanks: Yves-Alexis Perez, Bastian Germann
    Closes: #1098508

    It turned out that autopkgtest chroots are not minimal, most probably
    since the package is built inside the same chroot before the tests are
    run. Thus, adduser's inability to run without libperl5.40 was not
    detected, and I had the impression that libperl5.40 would belong to the
    minimal package set, which is not the case. In passing, we changed the
    code to block eval, which allows us to run with perlcritic right now.
    That required $codeset to be a variable. ------------------------------------------------------------------------

    (this message was generated automatically)
    --
    Greetings

    https://bugs.debian.org/1098508

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Debian Bug Tracking System@21:1/5 to All on Sat Feb 22 10:10:02 2025
    This is a multi-part message in MIME format...

    Your message dated Sat, 22 Feb 2025 08:56:56 +0000
    with message-id <E1tllJg-008bkV-Lw@fasolo.debian.org>
    and subject line Bug#1098508: fixed in adduser 3.140
    has caused the Debian Bug report #1098508,
    regarding adduser lacks dependency on libperl5.40 for Encode.pm
    to be marked as done.

    This means that you claim that the problem has been dealt with.
    If this is not the case it is now your responsibility to reopen the
    Bug report if necessary, and/or fix the problem forthwith.

    (NB: If you are a system administrator and have no idea what this
    message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact owner@bugs.debian.org
    immediately.)


    --
    1098508: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1098508
    Debian Bug Tracking System
    Contact owner@bugs.debian.org with problems

    Received: (at submit) by bugs.debian.org; 21 Feb 2025 16:32:14 +0000 X-Spam-Checker-Version: SpamAssassin 3.4.6-bugs.debian.org_2005_01_02
    (2021-04-09) on buxtehude.debian.org
    X-Spam-Level:
    X-Spam-Status: No, score=-120.5 required=4.0 tests=BAYES_00,
    BODY_INCLUDES_PACKAGE,DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,
    DKIM_VALID_AU,DKIM_VALID_EF,FOURLA,FROMDEVELOPER,HAS_PACKAGE,
    SPF_HELO_NONE,SPF_NONE,UNPARSEABLE_RELAY,USER_IN_DKIM_WELCOMELIST,
    USER_IN_DKIM_WHITELIST,XMAILER_REPORTBUG autolearn=ham
    autolearn_force=no version=3.4.6-bugs.debian.org_2005_01_02 X-Spam-Bayes: score:0.0000 Tokens: new, 18; hammy, 150; neutral, 111; spammy,
    0. spammytokens:
    hammytokens:0.000-+--Hx-spam-relays-external:sk:stravin,
    0.000-+--H*RT:sk:stravin, 0.000-+--Hx-spam-relays-external:311,
    0.000-+--H*RT:311, 0.000-+--H*RT:108
    Return-path: <corsac@debian.org>
    Received