[gdm/gnome-3-24] manager: don't allow autologin from transient displays
- From: Ray Strode <halfline src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gdm/gnome-3-24] manager: don't allow autologin from transient displays
- Date: Tue, 12 Sep 2017 14:16:52 +0000 (UTC)
commit 16f646db418aff5b22984b1ea22f05d6e70e072d
Author: Ray Strode <rstrode redhat com>
Date: Mon Sep 11 16:44:15 2017 -0400
manager: don't allow autologin from transient displays
In theory, we're only only supposed to allow autologin
the first time a session is run, but we only count a
session run, once it's finished. This means that if a
user creates a transient session to user switch, before
they've logged out the first time at boot up, that
transient session will begin autologin as well (which
actually gets treated as an auto unlock).
This commit makes sure autologin is only ever run on
the initial display.
https://bugzilla.gnome.org/show_bug.cgi?id=783779
daemon/gdm-manager.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/daemon/gdm-manager.c b/daemon/gdm-manager.c
index d080b30..6ef75bd 100644
--- a/daemon/gdm-manager.c
+++ b/daemon/gdm-manager.c
@@ -1573,10 +1573,13 @@ set_up_session (GdmManager *manager,
ActUserManager *user_manager;
ActUser *user;
gboolean loaded;
+ gboolean is_initial_display = FALSE;
gboolean autologin_enabled = FALSE;
char *username = NULL;
- if (!manager->priv->ran_once && display_is_on_seat0 (display))
+ g_object_get (G_OBJECT (display), "is-initial", &is_initial_display, NULL);
+
+ if (!manager->priv->ran_once && is_initial_display)
autologin_enabled = get_automatic_login_details (manager, &username);
if (!autologin_enabled) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]