Skip to content

Commit

Permalink
pam_elogind: Mask check whether elogind is running. (#188)
Browse files Browse the repository at this point in the history
If elogind has not been started, yet, pam will call CreateSession via
dbus, and dbus will start elogind.

Closes: #188
Signed-off-by: Sven Eden <sven.eden@prydeworx.com>
(cherry picked from commit af66060)
  • Loading branch information
Yamakuzure committed Dec 25, 2020
1 parent e89d5a0 commit 2acad92
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/login/pam_elogind.c
Expand Up @@ -698,9 +698,11 @@ _public_ PAM_EXTERN int pam_sm_open_session(
if (r != PAM_SUCCESS)
return r;

#if 0 /// If elogind is not running, yet, dbus will start it when it is needed. (#188)
/* Make most of this a NOP on non-logind systems */
if (!logind_running())
goto success;
#endif // 0

/* Make sure we don't enter a loop by talking to
* elogind when it is actually waiting for the
Expand Down

0 comments on commit 2acad92

Please sign in to comment.