From 63f6fbb0718aab3cbf710905a3ef045380af777d Mon Sep 17 00:00:00 2001 From: root Date: Tue, 30 Jul 2019 08:31:43 +0200 Subject: [PATCH] committing changes in /etc after apt run Package changes: +gdm3 3.28.3-0ubuntu18.04.4 amd64 --- .etckeeper | 24 +++ X11/default-display-manager | 2 +- dbus-1/system.d/gdm.conf | 81 +++++++++ gdm3/Init/Default | 89 ++++++++++ gdm3/PostLogin/Default.sample | 8 + gdm3/PostSession/Default | 3 + gdm3/PreSession/Default | 9 + gdm3/Prime/Default | 6 + gdm3/PrimeOff/Default | 6 + gdm3/Xsession | 237 +++++++++++++++++++++++++ gdm3/config-error-dialog.sh | 29 +++ gdm3/custom.conf | 29 +++ gdm3/greeter.dconf-defaults | 35 ++++ group | 1 + group- | 1 - gshadow | 1 + gshadow- | 1 - init.d/gdm3 | 93 ++++++++++ insserv.conf.d/gdm3 | 1 + pam.d/gdm-autologin | 23 +++ pam.d/gdm-fingerprint | 22 +++ pam.d/gdm-launch-environment | 10 ++ pam.d/gdm-password | 22 +++ passwd | 1 + passwd- | 2 +- rc0.d/K02gdm3 | 1 + rc1.d/K02gdm3 | 1 + rc2.d/S06gdm3 | 1 + rc3.d/S06gdm3 | 1 + rc4.d/S06gdm3 | 1 + rc5.d/S06gdm3 | 1 + rc6.d/K02gdm3 | 1 + shadow | 1 + systemd/system/display-manager.service | 2 +- 34 files changed, 741 insertions(+), 5 deletions(-) create mode 100644 dbus-1/system.d/gdm.conf create mode 100755 gdm3/Init/Default create mode 100755 gdm3/PostLogin/Default.sample create mode 100755 gdm3/PostSession/Default create mode 100755 gdm3/PreSession/Default create mode 100755 gdm3/Prime/Default create mode 100755 gdm3/PrimeOff/Default create mode 100755 gdm3/Xsession create mode 100644 gdm3/config-error-dialog.sh create mode 100644 gdm3/custom.conf create mode 100644 gdm3/greeter.dconf-defaults create mode 100755 init.d/gdm3 create mode 100644 insserv.conf.d/gdm3 create mode 100644 pam.d/gdm-autologin create mode 100644 pam.d/gdm-fingerprint create mode 100644 pam.d/gdm-launch-environment create mode 100644 pam.d/gdm-password create mode 120000 rc0.d/K02gdm3 create mode 120000 rc1.d/K02gdm3 create mode 120000 rc2.d/S06gdm3 create mode 120000 rc3.d/S06gdm3 create mode 120000 rc4.d/S06gdm3 create mode 120000 rc5.d/S06gdm3 create mode 120000 rc6.d/K02gdm3 diff --git a/.etckeeper b/.etckeeper index d37ec35..b076555 100755 --- a/.etckeeper +++ b/.etckeeper @@ -1236,6 +1236,7 @@ maybe chmod 0644 'dbus-1/system.d/com.ubuntu.SystemService.conf' maybe chmod 0644 'dbus-1/system.d/com.ubuntu.USBCreator.conf' maybe chmod 0644 'dbus-1/system.d/com.ubuntu.WhoopsiePreferences.conf' maybe chmod 0644 'dbus-1/system.d/dnsmasq.conf' +maybe chmod 0644 'dbus-1/system.d/gdm.conf' maybe chmod 0644 'dbus-1/system.d/io.snapcraft.SnapdLoginService.conf' maybe chmod 0644 'dbus-1/system.d/kerneloops.dbus' maybe chmod 0644 'dbus-1/system.d/net.hadess.SensorProxy.conf' @@ -1546,6 +1547,23 @@ maybe chmod 0755 'gconf/gconf.xml.mandatory' maybe chmod 0644 'gconf/gconf.xml.mandatory/%gconf-tree.xml' maybe chmod 0755 'gdb' maybe chmod 0644 'gdb/gdbinit' +maybe chmod 0755 'gdm3' +maybe chmod 0755 'gdm3/Init' +maybe chmod 0755 'gdm3/Init/Default' +maybe chmod 0755 'gdm3/PostLogin' +maybe chmod 0755 'gdm3/PostLogin/Default.sample' +maybe chmod 0755 'gdm3/PostSession' +maybe chmod 0755 'gdm3/PostSession/Default' +maybe chmod 0755 'gdm3/PreSession' +maybe chmod 0755 'gdm3/PreSession/Default' +maybe chmod 0755 'gdm3/Prime' +maybe chmod 0755 'gdm3/Prime/Default' +maybe chmod 0755 'gdm3/PrimeOff' +maybe chmod 0755 'gdm3/PrimeOff/Default' +maybe chmod 0755 'gdm3/Xsession' +maybe chmod 0644 'gdm3/config-error-dialog.sh' +maybe chmod 0644 'gdm3/custom.conf' +maybe chmod 0644 'gdm3/greeter.dconf-defaults' maybe chmod 0755 'geoclue' maybe chmod 0644 'geoclue/geoclue.conf' maybe chmod 0755 'ghostscript' @@ -1667,6 +1685,7 @@ maybe chmod 0755 'init.d/devolonetsvc' maybe chmod 0755 'init.d/dns-clean' maybe chmod 0755 'init.d/fancontrol' maybe chmod 0755 'init.d/fhem' +maybe chmod 0755 'init.d/gdm3' maybe chmod 0755 'init.d/grub-common' maybe chmod 0755 'init.d/halt' maybe chmod 0755 'init.d/hostname.sh' @@ -1808,6 +1827,7 @@ maybe chmod 0644 'inputrc' maybe chmod 0755 'insserv' maybe chmod 0644 'insserv.conf' maybe chmod 0755 'insserv.conf.d' +maybe chmod 0644 'insserv.conf.d/gdm3' maybe chmod 0644 'insserv.conf.d/mariadb' maybe chmod 0644 'insserv.conf.d/postfix' maybe chmod 0755 'insserv/overrides' @@ -2221,6 +2241,10 @@ maybe chmod 0644 'pam.d/common-session' maybe chmod 0644 'pam.d/common-session-noninteractive' maybe chmod 0644 'pam.d/cron' maybe chmod 0644 'pam.d/cups' +maybe chmod 0644 'pam.d/gdm-autologin' +maybe chmod 0644 'pam.d/gdm-fingerprint' +maybe chmod 0644 'pam.d/gdm-launch-environment' +maybe chmod 0644 'pam.d/gdm-password' maybe chmod 0644 'pam.d/gnome-screensaver' maybe chmod 0644 'pam.d/lightdm' maybe chmod 0644 'pam.d/lightdm-autologin' diff --git a/X11/default-display-manager b/X11/default-display-manager index 7d4e29b..8dc9fa8 100644 --- a/X11/default-display-manager +++ b/X11/default-display-manager @@ -1 +1 @@ -/usr/sbin/lightdm +/usr/sbin/gdm3 diff --git a/dbus-1/system.d/gdm.conf b/dbus-1/system.d/gdm.conf new file mode 100644 index 0000000..1e2695b --- /dev/null +++ b/dbus-1/system.d/gdm.conf @@ -0,0 +1,81 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/gdm3/Init/Default b/gdm3/Init/Default new file mode 100755 index 0000000..a8e6993 --- /dev/null +++ b/gdm3/Init/Default @@ -0,0 +1,89 @@ +#!/bin/sh +# Stolen from the debian kdm setup, aren't I sneaky +# Plus a lot of fun stuff added +# -George + +PATH="/usr/bin:$PATH" +OLD_IFS=$IFS + +gdmwhich () { + COMMAND="$1" + OUTPUT= + IFS=: + for dir in $PATH + do + if test -x "$dir/$COMMAND" ; then + if test "x$OUTPUT" = "x" ; then + OUTPUT="$dir/$COMMAND" + fi + fi + done + IFS=$OLD_IFS + echo "$OUTPUT" +} + +sysresources=/etc/X11/Xresources + +# merge in defaults +if [ -f "$sysresources" ]; then + xrdb -merge "$sysresources" +fi + +sysmodmap=/etc/X11/Xmodmap + +XMODMAP=`gdmwhich xmodmap` +if [ "x$XMODMAP" != "x" ] ; then + if [ "x$GDM_PARENT_DISPLAY" = "x" ]; then + if [ -f $sysmodmap ]; then + $XMODMAP $sysmodmap + fi + else + ( DISPLAY=$GDM_PARENT_DISPLAY XAUTHORITY=$GDM_PARENT_XAUTHORITY $XMODMAP -pke ) | $XMODMAP - + fi + + # + # Switch Sun's Alt and Meta mod mappings + # + + UNAME=`gdmwhich uname` + PROCESSOR=`$UNAME -p` + if [ "x$PROCESSOR" = "xsparc" ]; then + if $XMODMAP | grep mod4 | grep Alt > /dev/null 2>/dev/null + then + $XMODMAP -e "clear Mod1" \ + -e "clear Mod4" \ + -e "add Mod1 = Alt_L" \ + -e "add Mod1 = Alt_R" \ + -e "add Mod4 = Meta_L" \ + -e "add Mod4 = Meta_R" + fi + fi +fi + +SETXKBMAP=`gdmwhich setxkbmap` +if [ "x$SETXKBMAP" != "x" ] ; then + # FIXME: is this all right? Is this completely on crack? + # What this does is move the xkb configuration from the GDM_PARENT_DISPLAY + # FIXME: This should be done in code. Or there must be an easier way ... + if [ -n "$GDM_PARENT_DISPLAY" ]; then + XKBSETUP=`( DISPLAY=$GDM_PARENT_DISPLAY XAUTHORITY=$GDM_PARENT_XAUTHORITY $SETXKBMAP -v )` + if [ -n "$XKBSETUP" ]; then + XKBKEYMAP=`echo "$XKBSETUP" | grep '^keymap' | awk '{ print $2 }'` + XKBTYPES=`echo "$XKBSETUP" | grep '^types' | awk '{ print $2 }'` + XKBCOMPAT=`echo "$XKBSETUP" | grep '^compat' | awk '{ print $2 }'` + XKBSYMBOLS=`echo "$XKBSETUP" | grep '^symbols' | awk '{ print $2 }'` + XKBGEOMETRY=`echo "$XKBSETUP" | grep '^geometry' | awk '{ print $2 }'` + if [ -n "$XKBKEYMAP" ]; then + $SETXKBMAP -keymap "$XKBKEYMAP" + elif [ -n "$XKBTYPES" -a -n "$XKBCOMPAT" -a -n "$XKBSYMBOLS" -a -n "$XKBGEOMETRY" ]; then + $SETXKBMAP -types "$XKBTYPES" -compat "$XKBCOMPAT" -symbols "$XKBSYMBOLS" -geometry "$XKBGEOMETRY" + elif [ -n "$XKBTYPES" -a -n "$XKBCOMPAT" -a -n "$XKBSYMBOLS" ]; then + $SETXKBMAP -types "$XKBTYPES" -compat "$XKBCOMPAT" -symbols "$XKBSYMBOLS" + elif [ -n "$XKBSYMBOLS" ]; then + $SETXKBMAP -symbols "$XKBSYMBOLS" + fi + fi + fi +fi + +exit 0 diff --git a/gdm3/PostLogin/Default.sample b/gdm3/PostLogin/Default.sample new file mode 100755 index 0000000..efc6394 --- /dev/null +++ b/gdm3/PostLogin/Default.sample @@ -0,0 +1,8 @@ +#!/bin/sh +# +# Note: this is a sample and will not be run as is. Change the name of this +# file to /PostLogin/Default for this script to be run. This +# script will be run before any setup is run on behalf of the user and is +# useful if you for example need to do some setup to create a home directory +# for the user or something like that. $HOME, $LOGIN and such will all be +# set appropriately and this script is run as root. diff --git a/gdm3/PostSession/Default b/gdm3/PostSession/Default new file mode 100755 index 0000000..c52d3c2 --- /dev/null +++ b/gdm3/PostSession/Default @@ -0,0 +1,3 @@ +#!/bin/sh + +exit 0 diff --git a/gdm3/PreSession/Default b/gdm3/PreSession/Default new file mode 100755 index 0000000..23e5b86 --- /dev/null +++ b/gdm3/PreSession/Default @@ -0,0 +1,9 @@ +#!/bin/sh +# +# Note that any setup should come before the sessreg command as +# that must be 'exec'ed for the pid to be correct (sessreg uses the parent +# pid) +# +# Note that output goes into the .xsession-errors file for easy debugging +# +PATH="/usr/bin:$PATH" diff --git a/gdm3/Prime/Default b/gdm3/Prime/Default new file mode 100755 index 0000000..30caf03 --- /dev/null +++ b/gdm3/Prime/Default @@ -0,0 +1,6 @@ +#!/bin/sh + +primeoffload=/sbin/prime-offload +if [ -f "$primeoffload" ]; then + $primeoffload +fi diff --git a/gdm3/PrimeOff/Default b/gdm3/PrimeOff/Default new file mode 100755 index 0000000..5a61c3c --- /dev/null +++ b/gdm3/PrimeOff/Default @@ -0,0 +1,6 @@ +#!/bin/sh + +primeswitch=/sbin/prime-switch +if [ -f "$primeswitch" ]; then + $primeswitch +fi diff --git a/gdm3/Xsession b/gdm3/Xsession new file mode 100755 index 0000000..d7114ff --- /dev/null +++ b/gdm3/Xsession @@ -0,0 +1,237 @@ +#!/bin/bash +# +# This is SORT OF LIKE an X session, but not quite. You get a command as the +# first argument (it could be multiple words, so run it with "eval"). As a +# special case, the command can be: +# default - Run the appropriate Xclients startup (see the code below) +# custom - Run ~/.xsession and if that's not available run 'default' +# +# (Note that other arguments could also follow, but only the command one is +# right now relevant and supported) +# +# The output is ALREADY redirected to .xsession-errors in GDM. This way +# .xsession-errors actually gets more output such as if the PreSession script +# is failing. This also prevents DoS attacks if some app in the users session +# can be prodded to dump lots of stuff on the stdout/stderr. We wish to be +# robust don't we? In case you wish to use an existing script for other DM's, +# you can just not redirect when GDMSESSION is set. GDMSESSION will always +# be set from gdm. +# +# Also note that this is not run as a login shell, this is just executed. +# This is why we source the profile files below. +# +# based on: +# $XConsortium: Xsession /main/10 1995/12/18 18:21:28 gildea $ + +command="$@" + +# this will go into the .xsession-errors along with all other echo's +# good for debugging where things went wrong +echo "$0: Beginning session setup..." + +# temporary storage of error messages +ERR=$(mktemp --tmpdir config-err-XXXXXX) + +source_with_error_check () { + CONFIG_FILE="$1" + . "$CONFIG_FILE" 2>"$ERR" + if [ -s "$ERR" ]; then + . /etc/gdm3/config-error-dialog.sh + fi + cat "$ERR" >&2 + truncate -s 0 "$ERR" +} + +# First read /etc/profile and .profile +for file in /etc/profile "$HOME/.profile"; do + if [ -f "$file" ]; then + source_with_error_check "$file" + fi +done + +# Second read /etc/xprofile and .xprofile for X specific setup +for file in /etc/xprofile "$HOME/.xprofile"; do + if [ -f "$file" ]; then + source_with_error_check "$file" + fi +done + +# Translation stuff +if [ -x "/usr/lib/gdm3/gdmtranslate" ] ; then + gdmtranslate="/usr/lib/gdm3/gdmtranslate" +else + gdmtranslate= +fi + +# Note that this should only go to zenity dialogs which always expect utf8 +gettextfunc () { + if [ "x$gdmtranslate" != "x" ] ; then + "$gdmtranslate" --utf8 "$1" + else + echo "$1" + fi +} + +OLD_IFS=$IFS + +gdmwhich () { + COMMAND="$1" + OUTPUT= + IFS=: + for dir in $PATH + do + if test -x "$dir/$COMMAND" ; then + if test "x$OUTPUT" = "x" ; then + OUTPUT="$dir/$COMMAND" + fi + fi + done + IFS=$OLD_IFS + echo "$OUTPUT" +} + +zenity=`gdmwhich zenity` + +# Note: ~/.xsession-errors is now done in the daemon so that it +# works for ALL sessions (except ones named 'Failsafe') + +# clean up after xbanner +freetemp=`gdmwhich freetemp` +if [ -n "$freetemp" ] ; then + "$freetemp" +fi + +userresources="$HOME/.Xresources" +usermodmap="$HOME/.Xmodmap" +userxkbmap="$HOME/.Xkbmap" + +sysresources=/etc/X11/Xresources +sysmodmap=/etc/X11/Xmodmap +sysxkbmap=/etc/X11/Xkbmap + +rh6sysresources=/etc/X11/xinit/Xresources +rh6sysmodmap=/etc/X11/xinit/Xmodmap + +# merge in defaults +if [ -f "$rh6sysresources" ]; then + xrdb -nocpp -merge "$rh6sysresources" +fi + +if [ -f "$sysresources" ]; then + xrdb -nocpp -merge "$sysresources" +elif [ -d "$sysresources" ]; then + # directory of Xresources files on Debian/Ubuntu + for i in `ls "$sysresources"` ; do + if [ -r "$sysresources/$i" -a -f "$sysresources/$i" ] && expr "$i" : '^[[:alnum:]_-]\+$' > /dev/null; then + xrdb -nocpp -merge "$sysresources/$i" + fi + done +fi + +if [ -f "$userresources" ]; then + xrdb -nocpp -merge "$userresources" +fi + +# merge in keymaps +if [ -f "$sysxkbmap" ]; then + setxkbmap `cat "$sysxkbmap"` + XKB_IN_USE=yes +fi + +if [ -f "$userxkbmap" ]; then + setxkbmap `cat "$userxkbmap"` + XKB_IN_USE=yes +fi + +# +# Eeek, this seems like too much magic here +# +if [ -z "$XKB_IN_USE" -a ! -L /etc/X11/X ]; then + if grep '^exec.*/Xsun' /etc/X11/X > /dev/null 2>&1 && [ -f /etc/X11/XF86Config ]; then + xkbsymbols=`sed -n -e 's/^[ ]*XkbSymbols[ ]*"\(.*\)".*$/\1/p' /etc/X11/XF86Config` + if [ -n "$xkbsymbols" ]; then + setxkbmap -symbols "$xkbsymbols" + XKB_IN_USE=yes + fi + fi +fi + +# xkb and xmodmap don't play nice together +if [ -z "$XKB_IN_USE" ]; then + if [ -f "$rh6sysmodmap" ]; then + xmodmap "$rh6sysmodmap" + fi + + if [ -f "$sysmodmap" ]; then + xmodmap "$sysmodmap" + fi + + if [ -f "$usermodmap" ]; then + xmodmap "$usermodmap" + fi +fi + +unset XKB_IN_USE + +xhost +si:localuser:`id -un` || : + +# run all system xinitrc shell scripts. +if [ -d /etc/X11/xinit/xinitrc.d ]; then + for i in /etc/X11/xinit/xinitrc.d/* ; do + if [ -x "$i" -a ! -d "$i" ]; then + . "$i" + fi + done +fi + +# run /etc/X11/Xsession.d/ +OPTIONFILE=/etc/X11/Xsession.options +USERXSESSION=$HOME/.xsession +USERXSESSIONRC=$HOME/.xsessionrc +ALTUSERXSESSION=$HOME/.Xsession +if [ -d /etc/X11/Xsession.d ]; then + for i in `ls /etc/X11/Xsession.d/` ; do + if [ -r "/etc/X11/Xsession.d/$i" -a -f "/etc/X11/Xsession.d/$i" ] && expr "$i" : '^[[:alnum:]_-]\+$' > /dev/null; then + . "/etc/X11/Xsession.d/$i" + fi + done +fi + +if [ "x$command" = "xdefault" ] ; then + if [ -x "$HOME/.Xclients" ]; then + command="$HOME/.Xclients" + elif [ -x /etc/X11/xinit/Xclients ]; then + command="/etc/X11/xinit/Xclients" + elif [ -x /etc/X11/Xclients ]; then + command="/etc/X11/Xclients" + else + if [ -n "$zenity" ] ; then + disptext=`gettextfunc "System has no Xclients file, so starting a failsafe xterm session. Windows will have focus only if the mouse pointer is above them. To get out of this mode type 'exit' in the window."` + "$zenity" --info --text "$disptext" + else + echo "$0: Cannot find Xclients" + fi + exec xterm -geometry 80x24+0+0 + fi +fi + +# add ssh-agent if found +sshagent="`gdmwhich ssh-agent`" +if [ -n "$sshagent" ] && [ -x "$sshagent" ] && [ -z "$SSH_AUTH_SOCK" ]; then + command="$sshagent -- $command" +elif [ -z "$sshagent" ] ; then + echo "$0: ssh-agent not found!" +fi + +echo "$0: Setup done, will execute: $command" + +eval exec $command + +echo "$0: Executing $command failed, will run xterm" + +if [ -n "$zenity" ] ; then + disptext=`gettextfunc "Failed to start the session, so starting a failsafe xterm session. Windows will have focus only if the mouse pointer is above them. To get out of this mode type 'exit' in the window."` + "$zenity" --info --text "$disptext" +fi + +exec xterm -geometry 80x24+0+0 diff --git a/gdm3/config-error-dialog.sh b/gdm3/config-error-dialog.sh new file mode 100644 index 0000000..08cb7b9 --- /dev/null +++ b/gdm3/config-error-dialog.sh @@ -0,0 +1,29 @@ +# Copyright (C) 2014 Canonical Ltd +# Author: Gunnar Hjalmarsson +# +# This program is free software: you can redistribute it and/or modify it under +# the terms of the GNU General Public License as published by the Free Software +# Foundation, version 3 of the License. +# +# See http://www.gnu.org/copyleft/gpl.html the full text of the license. + +# This file may be sourced by the function source_with_error_check() in +# /etc/gdm/Xsession + +export TEXTDOMAIN=gdm +. /usr/bin/gettext.sh + +PARA1=$(eval_gettext 'Error found when loading $CONFIG_FILE:') +PARA2=$(gettext 'As a result the session will not be configured correctly. +You should fix the problem as soon as feasible.') + +TEXT="$PARA1\n\n$(fold -s $ERR)\n\n$PARA2" + +if [ -x /usr/bin/kdialog ]; then + TEXT_FILE=$(mktemp --tmpdir config-err-kdialog-XXXXXX) + echo -n "$TEXT" > "$TEXT_FILE" + kdialog --textbox "$TEXT_FILE" 500 300 + rm -f "$TEXT_FILE" +elif [ -x /usr/bin/zenity ]; then + zenity --warning --no-wrap --text="$TEXT" +fi diff --git a/gdm3/custom.conf b/gdm3/custom.conf new file mode 100644 index 0000000..92eeb5e --- /dev/null +++ b/gdm3/custom.conf @@ -0,0 +1,29 @@ +# GDM configuration storage +# +# See /usr/share/gdm/gdm.schemas for a list of available options. + +[daemon] +# Uncoment the line below to force the login screen to use Xorg +#WaylandEnable=false + +# Enabling automatic login +# AutomaticLoginEnable = true +# AutomaticLogin = user1 + +# Enabling timed login +# TimedLoginEnable = true +# TimedLogin = user1 +# TimedLoginDelay = 10 + +[security] + +[xdmcp] + +[chooser] + +[debug] +# Uncomment the line below to turn on debugging +# More verbose logs +# Additionally lets the X server dump core if it crashes +#Enable=true + diff --git a/gdm3/greeter.dconf-defaults b/gdm3/greeter.dconf-defaults new file mode 100644 index 0000000..62fa3b0 --- /dev/null +++ b/gdm3/greeter.dconf-defaults @@ -0,0 +1,35 @@ +# These are the options for the greeter session that can be set +# through GSettings. Any GSettings setting that is used by the +# greeter session can be set here. + +# Note that you must configure the path used by dconf to store the +# configuration, not the GSettings path. + + +# Theming options +# =============== +# - Change the GTK+ theme +# [org/gnome/desktop/interface] +# gtk-theme='Adwaita' +# - Use another background +# [org/gnome/desktop/background] +# picture-uri='file:///usr/share/themes/Adwaita/backgrounds/stripes.jpg' +# picture-options='zoom' +# - Or no background at all +# [org/gnome/desktop/background] +# picture-options='none' +# primary-color='#000000' + +# Login manager options +# ===================== +#[org/gnome/login-screen] +#logo='/usr/share/icons/hicolor/48x48/emblems/emblem-debian-white.png' +#fallback-logo='/usr/share/icons/hicolor/48x48/emblems/emblem-debian-white.png' + +# - Disable user list +# disable-user-list=true +# - Disable restart buttons +# disable-restart-buttons=true +# - Show a login welcome message +# banner-message-enable=true +# banner-message-text='Welcome' diff --git a/group b/group index df1a307..3e15810 100644 --- a/group +++ b/group @@ -85,3 +85,4 @@ iocard:x:141: usrp:x:142: nm-openvpn:x:143: mysql:x:144: +gdm:x:129: diff --git a/group- b/group- index 3e15810..df1a307 100644 --- a/group- +++ b/group- @@ -85,4 +85,3 @@ iocard:x:141: usrp:x:142: nm-openvpn:x:143: mysql:x:144: -gdm:x:129: diff --git a/gshadow b/gshadow index df2156c..4118c05 100644 --- a/gshadow +++ b/gshadow @@ -85,3 +85,4 @@ iocard:!:: usrp:!:: nm-openvpn:!:: mysql:!:: +gdm:!:: diff --git a/gshadow- b/gshadow- index 4118c05..df2156c 100644 --- a/gshadow- +++ b/gshadow- @@ -85,4 +85,3 @@ iocard:!:: usrp:!:: nm-openvpn:!:: mysql:!:: -gdm:!:: diff --git a/init.d/gdm3 b/init.d/gdm3 new file mode 100755 index 0000000..df234a8 --- /dev/null +++ b/init.d/gdm3 @@ -0,0 +1,93 @@ +#! /bin/sh +### BEGIN INIT INFO +# Provides: gdm3 +# Should-Start: console-screen dbus network-manager +# Required-Start: $local_fs $remote_fs +# Required-Stop: $local_fs $remote_fs +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: GNOME Display Manager +# Description: Debian init script for the GNOME Display Manager +### END INIT INFO +# +# Author: Ryan Murray +# +set -e + +PATH=/sbin:/bin:/usr/sbin:/usr/bin +DAEMON=/usr/sbin/gdm3 +PIDFILE=/var/run/gdm3.pid + +test -x $DAEMON || exit 0 + +if [ -r /etc/default/locale ]; then + . /etc/default/locale + export LANG LANGUAGE +fi + +. /lib/lsb/init-functions + +# To start gdm even if it is not the default display manager, change +# HEED_DEFAULT_DISPLAY_MANAGER to "false." +HEED_DEFAULT_DISPLAY_MANAGER=true +DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager + +activate_logind() { + # Try to dbus activate logind to avoid a race conditions if we are not + # running systemd as PID1 and we have systemd << 204 package installed (see: + # #747292) + if [ ! -d /run/systemd/system ] && [ -x /lib/systemd/systemd-logind-launch ]; then + dbus-send --system --print-reply --dest=org.freedesktop.DBus /org/freedesktop/DBus \ + org.freedesktop.DBus.StartServiceByName string:org.freedesktop.login1 uint32:0 2>&1 > /dev/null + fi +} + +case "$1" in + start) + CONFIGURED_DAEMON=$(basename "$(cat $DEFAULT_DISPLAY_MANAGER_FILE 2> /dev/null)") + if grep -wqs text /proc/cmdline; then + log_warning_msg "Not starting GNOME Display Manager; found 'text' in kernel commandline." + elif [ -e "$DEFAULT_DISPLAY_MANAGER_FILE" ] && \ + [ "$HEED_DEFAULT_DISPLAY_MANAGER" = "true" ] && \ + [ "$CONFIGURED_DAEMON" != gdm3 ] ; then + log_action_msg "Not starting GNOME Display Manager; it is not the default display manager" + else + log_daemon_msg "Starting GNOME Display Manager" "gdm3" + activate_logind || log_end_msg 1 + /usr/share/gdm/generate-config + start-stop-daemon --start --quiet --pidfile $PIDFILE \ + --background --exec $DAEMON || log_end_msg 1 + log_end_msg 0 + fi + ;; + stop) + log_daemon_msg "Stopping GNOME Display Manager" "gdm3" + set +e + start-stop-daemon --stop --quiet --pidfile $PIDFILE \ + --name gdm3 --retry 5 + set -e + log_end_msg $? + ;; + reload) + log_daemon_msg "Scheduling reload of GNOME Display Manager configuration" "gdm3" + /usr/share/gdm/generate-config + set +e + start-stop-daemon --stop --signal HUP --quiet --pidfile $PIDFILE \ + --name gdm3 + set -e + log_end_msg $? + ;; + status) + status_of_proc -p "$PIDFILE" "$DAEMON" gdm3 && exit 0 || exit $? + ;; + restart|force-reload) + $0 stop + $0 start + ;; + *) + echo "Usage: /etc/init.d/gdm3 {start|stop|restart|reload|force-reload|status}" + exit 1 + ;; +esac + +exit 0 diff --git a/insserv.conf.d/gdm3 b/insserv.conf.d/gdm3 new file mode 100644 index 0000000..165b123 --- /dev/null +++ b/insserv.conf.d/gdm3 @@ -0,0 +1 @@ +$x-display-manager gdm3 diff --git a/pam.d/gdm-autologin b/pam.d/gdm-autologin new file mode 100644 index 0000000..26e9701 --- /dev/null +++ b/pam.d/gdm-autologin @@ -0,0 +1,23 @@ +#%PAM-1.0 +auth requisite pam_nologin.so +auth required pam_succeed_if.so user != root quiet_success +auth optional pam_gdm.so +auth optional pam_gnome_keyring.so +auth required pam_permit.so +@include common-account +# SELinux needs to be the first session rule. This ensures that any +# lingering context has been cleared. Without this it is possible +# that a module could execute code in the wrong domain. +session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so close +session required pam_loginuid.so +# SELinux needs to intervene at login time to ensure that the process +# starts in the proper default security context. Only sessions which are +# intended to run in the user's context should be run after this. +session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so open +session optional pam_keyinit.so force revoke +session required pam_limits.so +session required pam_env.so readenv=1 +session required pam_env.so readenv=1 user_readenv=1 envfile=/etc/default/locale +@include common-session +session optional pam_gnome_keyring.so auto_start +@include common-password diff --git a/pam.d/gdm-fingerprint b/pam.d/gdm-fingerprint new file mode 100644 index 0000000..d5b901a --- /dev/null +++ b/pam.d/gdm-fingerprint @@ -0,0 +1,22 @@ +#%PAM-1.0 +auth requisite pam_nologin.so +auth required pam_succeed_if.so user != root quiet_success +auth required pam_fprintd.so +auth optional pam_gnome_keyring.so +@include common-account +# SELinux needs to be the first session rule. This ensures that any +# lingering context has been cleared. Without this it is possible +# that a module could execute code in the wrong domain. +session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so close +session required pam_loginuid.so +# SELinux needs to intervene at login time to ensure that the process +# starts in the proper default security context. Only sessions which are +# intended to run in the user's context should be run after this. +session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so open +session optional pam_keyinit.so force revoke +session required pam_limits.so +session required pam_env.so readenv=1 +session required pam_env.so readenv=1 user_readenv=1 envfile=/etc/default/locale +@include common-session +session optional pam_gnome_keyring.so auto_start +password required pam_fprintd.so diff --git a/pam.d/gdm-launch-environment b/pam.d/gdm-launch-environment new file mode 100644 index 0000000..aed9ae0 --- /dev/null +++ b/pam.d/gdm-launch-environment @@ -0,0 +1,10 @@ +#%PAM-1.0 +auth requisite pam_nologin.so +auth required pam_permit.so +@include common-account +session optional pam_keyinit.so force revoke +session required pam_limits.so +session required pam_env.so readenv=1 +session required pam_env.so readenv=1 user_readenv=1 envfile=/etc/default/locale +@include common-session +@include common-password diff --git a/pam.d/gdm-password b/pam.d/gdm-password new file mode 100644 index 0000000..7ed2b16 --- /dev/null +++ b/pam.d/gdm-password @@ -0,0 +1,22 @@ +#%PAM-1.0 +auth requisite pam_nologin.so +auth required pam_succeed_if.so user != root quiet_success +@include common-auth +auth optional pam_gnome_keyring.so +@include common-account +# SELinux needs to be the first session rule. This ensures that any +# lingering context has been cleared. Without this it is possible +# that a module could execute code in the wrong domain. +session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so close +session required pam_loginuid.so +# SELinux needs to intervene at login time to ensure that the process +# starts in the proper default security context. Only sessions which are +# intended to run in the user's context should be run after this. +session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so open +session optional pam_keyinit.so force revoke +session required pam_limits.so +session required pam_env.so readenv=1 +session required pam_env.so readenv=1 user_readenv=1 envfile=/etc/default/locale +@include common-session +session optional pam_gnome_keyring.so auto_start +@include common-password diff --git a/passwd b/passwd index f836714..0da304e 100644 --- a/passwd +++ b/passwd @@ -51,3 +51,4 @@ alle:x:1013:1014::/home/alle:/bin/false fhem:x:998:20::/opt/fhem:/bin/false nm-openvpn:x:130:143:NetworkManager OpenVPN,,,:/var/lib/openvpn/chroot:/usr/sbin/nologin mysql:x:131:144:MySQL Server,,,:/nonexistent:/bin/false +gdm:x:121:129:Gnome Display Manager:/var/lib/gdm3:/bin/false diff --git a/passwd- b/passwd- index 0da304e..3a869c9 100644 --- a/passwd- +++ b/passwd- @@ -51,4 +51,4 @@ alle:x:1013:1014::/home/alle:/bin/false fhem:x:998:20::/opt/fhem:/bin/false nm-openvpn:x:130:143:NetworkManager OpenVPN,,,:/var/lib/openvpn/chroot:/usr/sbin/nologin mysql:x:131:144:MySQL Server,,,:/nonexistent:/bin/false -gdm:x:121:129:Gnome Display Manager:/var/lib/gdm3:/bin/false +gdm:x:121:129::/var/lib/gdm3:/bin/false diff --git a/rc0.d/K02gdm3 b/rc0.d/K02gdm3 new file mode 120000 index 0000000..ad83344 --- /dev/null +++ b/rc0.d/K02gdm3 @@ -0,0 +1 @@ +../init.d/gdm3 \ No newline at end of file diff --git a/rc1.d/K02gdm3 b/rc1.d/K02gdm3 new file mode 120000 index 0000000..ad83344 --- /dev/null +++ b/rc1.d/K02gdm3 @@ -0,0 +1 @@ +../init.d/gdm3 \ No newline at end of file diff --git a/rc2.d/S06gdm3 b/rc2.d/S06gdm3 new file mode 120000 index 0000000..ad83344 --- /dev/null +++ b/rc2.d/S06gdm3 @@ -0,0 +1 @@ +../init.d/gdm3 \ No newline at end of file diff --git a/rc3.d/S06gdm3 b/rc3.d/S06gdm3 new file mode 120000 index 0000000..ad83344 --- /dev/null +++ b/rc3.d/S06gdm3 @@ -0,0 +1 @@ +../init.d/gdm3 \ No newline at end of file diff --git a/rc4.d/S06gdm3 b/rc4.d/S06gdm3 new file mode 120000 index 0000000..ad83344 --- /dev/null +++ b/rc4.d/S06gdm3 @@ -0,0 +1 @@ +../init.d/gdm3 \ No newline at end of file diff --git a/rc5.d/S06gdm3 b/rc5.d/S06gdm3 new file mode 120000 index 0000000..ad83344 --- /dev/null +++ b/rc5.d/S06gdm3 @@ -0,0 +1 @@ +../init.d/gdm3 \ No newline at end of file diff --git a/rc6.d/K02gdm3 b/rc6.d/K02gdm3 new file mode 120000 index 0000000..ad83344 --- /dev/null +++ b/rc6.d/K02gdm3 @@ -0,0 +1 @@ +../init.d/gdm3 \ No newline at end of file diff --git a/shadow b/shadow index 83d9d9c..a411377 100644 --- a/shadow +++ b/shadow @@ -51,3 +51,4 @@ alle:!:17781:0:99999:7::: fhem:!:17798:::::: nm-openvpn:*:18022:0:99999:7::: mysql:!:18060:0:99999:7::: +gdm:*:18107:0:99999:7::: diff --git a/systemd/system/display-manager.service b/systemd/system/display-manager.service index 88631e2..fb5dc19 120000 --- a/systemd/system/display-manager.service +++ b/systemd/system/display-manager.service @@ -1 +1 @@ -/lib/systemd/system/lightdm.service \ No newline at end of file +/lib/systemd/system/gdm3.service \ No newline at end of file -- 2.43.0