libnss-sss removes config when not being purged

Bug #1916562 reported by Braden McGrath
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
sssd (Ubuntu)
Triaged
Medium
Unassigned
Focal
Triaged
Medium
Unassigned
Hirsute
Won't Fix
Medium
Unassigned
Impish
Won't Fix
Medium
Unassigned

Bug Description

lsb_release -rdc
Description: Ubuntu 20.04.2 LTS
Release: 20.04
Codename: focal

apt-cache policy libnss-sss
libnss-sss:
  Installed: 2.2.3-3ubuntu0.3
  Candidate: 2.2.3-3ubuntu0.3
  Version table:
 *** 2.2.3-3ubuntu0.3 500
        500 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages
        100 /var/lib/dpkg/status
     2.2.3-3ubuntu0.1 500
        500 http://security.ubuntu.com/ubuntu focal-security/main amd64 Packages
     2.2.3-3 500
        500 http://archive.ubuntu.com/ubuntu focal/main amd64 Packages

libnss-sss has a postinst script that modifies /etc/nsswitch.conf and adds "sss" to many of the lines. (/var/lib/dpkg/info/libnss-sss:amd64.postinst)

After running `apt remove libnss-sss`, the same lines are modified again in /etc/nsswitch.conf to remove the changes.

If you then install libnss-sss again, nsswitch.conf is NOT re-modified on subsequent installs. libnss-sss will only re-modify /etc/nsswitch.conf if it has been purged first / "clean" install.

Expectation: if config is changed *only* during initial install, then config should be left behind during a remove, and config only removed when the package is *purged*.

The only exception I can think of is if there's some specific reason to want to back out the changes to /etc/nsswitch.conf any time libnss-sss is removed (but *not* purged)... and if this is the case, then I'd think maybe the postinst script should be *re-adding* "sss" to nsswitch.conf on *any* install/reinstall (even if it wasn't purged first).

I'm happy to provide any other information needed, but this is my first filed bug so I apologize if I'm lacking. :)

Braden McGrath (zprime)
description: updated
Changed in sssd (Ubuntu):
status: New → Triaged
Revision history for this message
Sergio Durigan Junior (sergiodj) wrote :

Thanks for the report. I can indeed confirm the bug. I could also verify that the behaviour still happens as of Hirsute.

I've subscribed the Ubuntu Server team to the bug; we will look into it as time permits. This does not seem to be an urgent issue, though, so it may take a while until it is resolved.

Changed in sssd (Ubuntu):
importance: Undecided → Medium
Changed in sssd (Ubuntu Focal):
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
Lucas Kanashiro (lucaskanashiro) wrote :

This is still true in Impish.

Revision history for this message
Brian Murray (brian-murray) wrote :

The Hirsute Hippo has reached End of Life, so this bug will not be fixed for that release.

Changed in sssd (Ubuntu Hirsute):
status: Triaged → Won't Fix
Revision history for this message
Lena Voytek (lvoytek) wrote :

This is still an issue in focal, impish, and jammy

Revision history for this message
Brian Murray (brian-murray) wrote :

Ubuntu 21.10 (Impish Indri) has reached end of life, so this bug will not be fixed for that specific release.

Changed in sssd (Ubuntu Impish):
status: Triaged → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.