nss-cache: cache lookup-failures
nss-cache: cache lookup-failures

NSS lookups are potentially slow, and cause us to log a warning, so try even
harder to avoid them, by remembering when a given lookup failed so it is not
retried.

Note that this is ok as the cache is meant to be short-lived and flushed
between each configuration reload, so if a UID/GID/user/group becomes
valid it will be picked up on the next reload.

Before:

Jul 05 15:26:46 teg-x270 dbus-broker-launch[758]: Looking up NSS user entry for 'foo'...
Jul 05 15:26:46 teg-x270 dbus-broker-launch[758]: NSS returned no entry for 'foo'
Jul 05 15:26:46 teg-x270 dbus-broker-launch[758]: Invalid user-name in /etc/dbus-1/system.d/foo.conf +24: user="foo"
Jul 05 15:26:46 teg-x270 dbus-broker-launch[758]: Looking up NSS user entry for 'foo'...
Jul 05 15:26:46 teg-x270 dbus-broker-launch[758]: NSS returned no entry for 'foo'
Jul 05 15:26:46 teg-x270 dbus-broker-launch[758]: Invalid user-name in /etc/dbus-1/system.d/foo.conf +28: user="foo"

After:

Jul 05 15:29:59 teg-x270 dbus-broker-launch[768]: Looking up NSS user entry for 'foo'...
Jul 05 15:29:59 teg-x270 dbus-broker-launch[768]: NSS returned no entry for 'foo'
Jul 05 15:29:59 teg-x270 dbus-broker-launch[768]: Invalid user-name in /etc/dbus-1/system.d/foo.conf +24: user="foo"
Jul 05 15:29:59 teg-x270 dbus-broker-launch[768]: Invalid user-name in /etc/dbus-1/system.d/foo.conf +28: user="foo"

Signed-off-by: Tom Gundersen <7c8224529a7c718e876cb2496c973509fde1e50e@jklm.no>

bus1/dbus-broker