Changeset bc7e5a7


Ignore:
Timestamp:
01/12/2022 07:37:19 AM (2 years ago)
Author:
Pierre Labastie <pierre.labastie@…>
Branches:
11.1, 11.2, 11.3, 12.0, 12.1, kea, ken/TL2024, ken/inkscape-core-mods, ken/tuningfonts, lazarus, lxqt, plabs/newcss, plabs/python-mods, python3.11, qt5new, rahul/power-profiles-daemon, renodr/vulkan-addition, trunk, xry111/intltool, xry111/llvm18, xry111/soup3, xry111/test-20220226, xry111/xf86-video-removal
Children:
c26cfe08
Parents:
d128a3c
git-author:
Pierre Labastie <pierre.labastie@…> (01/12/2022 07:31:54 AM)
git-committer:
Pierre Labastie <pierre.labastie@…> (01/12/2022 07:37:19 AM)
Message:

Fix PAM config files of shadow apps

shadow applications chpasswd and newusers use the "password" type,
and expect to be able to pass the password to the PAM module. But
we use pam_permit.so, which does nothing except return PAM_SUCCESS.
So the applications themselves do nothing without returning an
error. Change the config files to include system-password.
Also clean up the config files so that only the types used by the
applications appear.
Fixes #15950

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • introduction/welcome/changelog.xml

    rd128a3c rbc7e5a7  
    4343    -->
    4444    <listitem>
     45      <para>January 12th, 2022</para>
     46      <itemizedlist>
     47        <listitem>
     48          <para>[pierre] - Change PAM configuration files of shadow
     49          applications so that only the types really used appear, and
     50          use system-password for the password type when needed. Fixes
     51          <ulink url="&blfs-ticket-root;15950">#15950</ulink>.</para>
     52        </listitem>
     53      </itemizedlist>
     54    </listitem>
     55
     56    <listitem>
    4557      <para>January 11th, 2022</para>
    4658      <itemizedlist>
  • postlfs/security/shadow.xml

    rd128a3c rbc7e5a7  
    462462
    463463      <sect4>
     464        <title>'chpasswd' and 'newusers'</title>
     465
     466<screen role="root"><userinput>cat &gt; /etc/pam.d/chpasswd &lt;&lt; "EOF"
     467<literal># Begin /etc/pam.d/chpasswd
     468
     469# always allow root
     470auth      sufficient  pam_rootok.so
     471
     472# include system auth and account settings
     473auth      include     system-auth
     474account   include     system-account
     475password  include     system-password
     476
     477# End /etc/pam.d/chpasswd</literal>
     478EOF
     479
     480sed -e /chpasswd/newusers/ /etc/pam.d/chpasswd >/etc/pam.d/newusers</userinput></screen>
     481      </sect4>
     482
     483      <sect4>
    464484        <title>'chage'</title>
    465485
     
    470490auth      sufficient  pam_rootok.so
    471491
    472 # include system auth, account, and session settings
     492# include system auth and account settings
    473493auth      include     system-auth
    474494account   include     system-account
    475 session   include     system-session
    476 
    477 # Always permit for authentication updates
    478 password  required    pam_permit.so
    479495
    480496# End /etc/pam.d/chage</literal>
     
    483499
    484500      <sect4>
    485         <title>Other common programs</title>
    486         <!--<title>'chfn', 'chgpasswd', 'chgpasswd', 'chsh', 'groupadd', 'groupdel',
    487         'groupmems', 'groupmod', 'newusers', 'useradd', 'userdel' and
    488         'usermod'</title>-->
    489 
    490 <screen role="root"><userinput>for PROGRAM in chfn chgpasswd chpasswd chsh groupadd groupdel \
    491                groupmems groupmod newusers useradd userdel usermod
     501        <title>Other shadow utilities</title>
     502
     503<screen role="root"><userinput>for PROGRAM in chfn chgpasswd chsh groupadd groupdel \
     504               groupmems groupmod useradd userdel usermod
    492505do
    493506    install -v -m644 /etc/pam.d/chage /etc/pam.d/${PROGRAM}
Note: See TracChangeset for help on using the changeset viewer.