These two patches change the beahvior of the sssd pam provider to avoid costly online initgroups calls when a user session is already active on the system.
The reasoning is that if a user session is active then most of the authentications happening for the user are for tools that are not instantiating a new login sessions, therefore paying the price of an online initgroups is not worth it. And for the rare actual login session (say ssh into the machine from another) then we know that initgroups was already recently run and we get the same answer making sessions consistent.
If an admin change groups this is not a security issue because an active session means the user already has whatever group memebrships an can still do any operation on the machine. Admins already know that if they want to take away privileges they need to purge any user process from the machine first.
I tested personally these two patches on my machine, they reduced login time from 10-20 seconds down to a few seconds.
note that this also reduces load on a central LDAP/IPA/NIS/whatever server so it is a new win-win in all cases.
These two patches change the beahvior of the sssd pam provider to avoid costly online initgroups calls when a user session is already active on the system.
The reasoning is that if a user session is active then most of the authentications happening for the user are for tools that are not instantiating a new login sessions, therefore paying the price of an online initgroups is not worth it. And for the rare actual login session (say ssh into the machine from another) then we know that initgroups was already recently run and we get the same answer making sessions consistent.
If an admin change groups this is not a security issue because an active session means the user already has whatever group memebrships an can still do any operation on the machine. Admins already know that if they want to take away privileges they need to purge any user process from the machine first.
I tested personally these two patches on my machine, they reduced login time from 10-20 seconds down to a few seconds.
note that this also reduces load on a central LDAP/IPA/NIS/whatever server so it is a new win-win in all cases.