diff --git a/recipes-support/sddm/sddm.inc b/recipes-support/sddm/sddm.inc index 21269c2..eac7763 100644 --- a/recipes-support/sddm/sddm.inc +++ b/recipes-support/sddm/sddm.inc @@ -25,7 +25,6 @@ DEPENDS = " \ SRC_URI = " \ git://github.com/sddm/${BPN};nobranch=1;protocol=https \ - file://0001-Workaround-missing-sessions.patch \ file://sddm.conf.plasma-desktop \ file://sddm.conf.plasma-mobile \ file://sddm.conf.plasma-bigscreen \ @@ -65,6 +64,7 @@ do_install:append() { install -d ${D}${sysconfdir}/pam.d install -m 644 ${WORKDIR}/sddm.pam ${D}${sysconfdir}/pam.d/sddm install -m 644 ${WORKDIR}/sddm-autologin.pam ${D}${sysconfdir}/pam.d/sddm-autologin + install -m 644 ${WORKDIR}/sddm-greeter.pam ${D}${sysconfdir}/pam.d/sddm-greeter install -d ${D}${localstatedir}/lib/sddm chown -R sddm:sddm ${D}${localstatedir}/lib/sddm diff --git a/recipes-support/sddm/sddm/0001-Workaround-missing-sessions.patch b/recipes-support/sddm/sddm/0001-Workaround-missing-sessions.patch deleted file mode 100644 index 25c0405..0000000 --- a/recipes-support/sddm/sddm/0001-Workaround-missing-sessions.patch +++ /dev/null @@ -1,55 +0,0 @@ -From cc0c929db02116516bb3475e5fd3ae7f43c88220 Mon Sep 17 00:00:00 2001 -From: =?UTF-8?q?Andreas=20M=C3=BCller?= -Date: Sun, 25 Nov 2018 00:29:17 +0100 -Subject: [PATCH] Workaround missing sessions -MIME-Version: 1.0 -Content-Type: text/plain; charset=UTF-8 -Content-Transfer-Encoding: 8bit - -The current approach is wrong in many ways: - -* In case a session file does not set TryExec it is kept enabled accidentlty -* Session files with TryExec without full path are ignored. Problem here: sddm - tries to find executables based on PATH environment. Problem at least for my - environment: There is no PATH variable set by systemd. So for session files - without path: Do not perform further checks / just trust for now. - -Upstream-Sttaus: Pending - -Signed-off-by: Andreas Müller - ---- - src/greeter/SessionModel.cpp | 19 ++++--------------- - 1 file changed, 4 insertions(+), 15 deletions(-) - -diff --git a/src/greeter/SessionModel.cpp b/src/greeter/SessionModel.cpp -index 58d8764..c2b5884 100644 ---- a/src/greeter/SessionModel.cpp -+++ b/src/greeter/SessionModel.cpp -@@ -138,22 +138,11 @@ namespace SDDM { - for (auto& session : qAsConst(sessions)) { - Session *si = new Session(type, session); - bool execAllowed = true; -- QFileInfo fi(si->tryExec()); -- if (fi.isAbsolute()) { -- if (!fi.exists() || !fi.isExecutable()) -+ if(!si->tryExec().isEmpty()) { -+ QFileInfo fi(si->tryExec()); -+ if (fi.isAbsolute()) { -+ if (!fi.exists() || !fi.isExecutable()) - execAllowed = false; -- } else { -- execAllowed = false; -- QProcessEnvironment env = QProcessEnvironment::systemEnvironment(); -- QString envPath = env.value(QStringLiteral("PATH")); -- const QStringList pathList = envPath.split(QLatin1Char(':')); -- for(const QString &path : pathList) { -- QDir pathDir(path); -- fi.setFile(pathDir, si->tryExec()); -- if (fi.exists() && fi.isExecutable()) { -- execAllowed = true; -- break; -- } - } - } - // add to sessions list diff --git a/recipes-support/sddm/sddm/sddm-greeter.pam b/recipes-support/sddm/sddm/sddm-greeter.pam new file mode 100644 index 0000000..44e209e --- /dev/null +++ b/recipes-support/sddm/sddm/sddm-greeter.pam @@ -0,0 +1,17 @@ +#%PAM-1.0 + +# Load environment from /etc/environment and ~/.pam_environment +auth required pam_env.so + +# Always let the greeter start without authentication +auth required pam_permit.so + +# No action required for account management +account required pam_permit.so + +# Can't change password +password required pam_deny.so + +# Setup session +session required pam_unix.so +session optional pam_systemd.so diff --git a/recipes-support/sddm/sddm_0.21.0.bb b/recipes-support/sddm/sddm_0.21.0.bb index 4a8fd6f..bc68bd5 100644 --- a/recipes-support/sddm/sddm_0.21.0.bb +++ b/recipes-support/sddm/sddm_0.21.0.bb @@ -2,4 +2,4 @@ # SPDX-License-Identifier: CC0-1.0 require ${PN}.inc -SRCREV = "63780fcd79f1dbf81a30eef48c28c699ab15aded" +SRCREV = "4ec29a8bba033d475f197693fac6cb0c383a1da2"