├── AUTHORS ├── COPYING ├── ChangeLog ├── INSTALL ├── MAINTAINERS ├── Makefile.am ├── NEWS ├── README ├── README.install ├── TODO ├── acconfig.h ├── acinclude.m4 ├── autogen.sh ├── common ├── Makefile.am ├── mdm-common-config.c ├── mdm-common-config.h ├── mdm-common.c ├── mdm-common.h ├── mdm-config.c ├── mdm-config.h ├── mdm-log.c ├── mdm-log.h ├── test-config.c ├── test-log.c ├── ve-signal.c └── ve-signal.h ├── config ├── Init.in ├── Makefile.am ├── PostLogin ├── PostSession.in ├── PreSession.in ├── SuperInit.in ├── SuperPost.in ├── XKeepsCrashing ├── Xsession.in ├── default.desktop.in.in ├── extract-shell.sh ├── gettextfoo.h ├── locale.alias ├── mdm ├── mdm-autologin ├── mdm.conf-custom.in ├── mdm.conf.in ├── mdmprefetchlist.in └── ssh.desktop.in.in ├── configure.ac ├── daemon ├── Makefile.am ├── auth.c ├── auth.h ├── cookie.c ├── cookie.h ├── display.c ├── display.h ├── errorgui.c ├── errorgui.h ├── filecheck.c ├── filecheck.h ├── fstype.c ├── getvt.c ├── getvt.h ├── md5.c ├── md5.h ├── mdm-daemon-config-entries.h ├── mdm-daemon-config-keys.h ├── mdm-daemon-config.c ├── mdm-daemon-config.h ├── mdm-net.c ├── mdm-net.h ├── mdm-socket-protocol.h ├── mdm.c ├── mdm.h ├── mdm.in ├── mdmconsolekit.c ├── mdmconsolekit.h ├── misc.c ├── misc.h ├── server.c ├── server.h ├── slave.c ├── slave.h ├── verify-crypt.c ├── verify-pam.c ├── verify-shadow.c └── verify.h ├── data ├── Makefile.am └── icons │ ├── 16x16 │ ├── Makefile.am │ └── apps │ │ ├── Makefile.am │ │ ├── mdmflexiserver.png │ │ ├── mdmflexiserver.xcf.bz2 │ │ ├── mdmsetup.png │ │ └── mdmsetup.svg │ ├── 22x22 │ ├── Makefile.am │ └── apps │ │ ├── Makefile.am │ │ ├── mdmflexiserver.png │ │ ├── mdmflexiserver.xcf.bz2 │ │ ├── mdmsetup.png │ │ └── mdmsetup.xcf.bz2 │ ├── 24x24 │ ├── Makefile.am │ └── apps │ │ ├── Makefile.am │ │ ├── mdmflexiserver.png │ │ └── mdmsetup.png │ ├── 32x32 │ ├── Makefile.am │ └── apps │ │ ├── Makefile.am │ │ ├── mdmflexiserver.png │ │ ├── mdmflexiserver.svg │ │ ├── mdmsetup.png │ │ └── mdmsetup.svg │ ├── 48x48 │ ├── Makefile.am │ └── apps │ │ ├── Makefile.am │ │ ├── mdmflexiserver.png │ │ └── mdmsetup.png │ ├── Makefile.am │ ├── README │ └── scalable │ ├── Makefile.am │ └── apps │ ├── Makefile.am │ ├── mdmflexiserver.svg │ └── mdmsetup.svg ├── debian ├── README.Debian ├── Xsession ├── changelog ├── compat ├── control ├── copyright ├── docs ├── extract-locales ├── insserv.conf.d │ └── mdm ├── locale.conf ├── mdm-autologin.pam ├── mdm.8.pod ├── mdm.config ├── mdm.dirs ├── mdm.init ├── mdm.install ├── mdm.manpages ├── mdm.menu ├── mdm.pam ├── mdm.postinst ├── mdm.postrm ├── mdm.prerm ├── mdm.service ├── mdm.templates ├── mdm.upstart ├── mdm.xpm ├── mdmflexiserver.1.pod ├── mdmlogin.8.pod ├── rules ├── source │ └── format └── watch ├── docs ├── C │ ├── legal.xml │ └── mdm.xml ├── ChangeLog ├── Makefile.am ├── en_GB │ └── en_GB.po ├── mdm.1 └── mdm.omf.in ├── files ├── Makefile ├── Makefile.am ├── Makefile.in ├── etc │ └── X11 │ │ └── Xsession.d │ │ └── 99mdm └── usr │ ├── bin │ ├── mdm-get-monitor-scale │ ├── mdm-recovery │ ├── mdm-set-keyboard-layout │ ├── mdm-theme-emulator │ └── mdm-unlock-logind │ └── share │ └── mdm │ ├── gtk-preview.png │ ├── locale │ ├── af │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── am │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ar │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── az │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── be │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── bg │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── bn │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── bs │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ca │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── cs │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── cy │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── da │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── de │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── el │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── en_AU │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── en_CA │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── en_GB │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── eo │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── es │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── et │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── eu │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── fa │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── fi │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── fr │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── fr_CA │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── frp │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ga │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── gd │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── gl │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── he │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── hi │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── hr │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── hu │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ia │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── id │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ii │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── is │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── it │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ja │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ka │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── kab │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── kk │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── km │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ko │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ksw │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ku │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ky │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── lo │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── lt │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── lv │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── mg │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ml │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── mr │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ms │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── mus │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── my │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── nb │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── nds │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ne │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── nl │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── nn │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── oc │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── om │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── pa │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── pap │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── pl │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── pt │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── pt_BR │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ro │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ru │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── rw │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── sc │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── shn │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── si │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── sk │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── sl │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── sq │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── sr │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── sr@latin │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── sv │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ta │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── tg │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── th │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── tr │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── uk │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── ur │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── uz │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── vi │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── zh_CN │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ ├── zh_HK │ │ └── LC_MESSAGES │ │ │ └── mdm.mo │ └── zh_TW │ │ └── LC_MESSAGES │ │ └── mdm.mo │ └── recovery │ └── mdm.conf ├── gui ├── Makefile.am ├── faces │ ├── Makefile.am │ └── user-generic.png ├── greeter │ ├── Makefile.am │ ├── greeter.c │ ├── greeter.dtd │ ├── greeter.h │ ├── greeter_canvas_item.c │ ├── greeter_canvas_item.h │ ├── greeter_canvas_text.c │ ├── greeter_canvas_text.h │ ├── greeter_configuration.h │ ├── greeter_events.c │ ├── greeter_events.h │ ├── greeter_geometry.c │ ├── greeter_geometry.h │ ├── greeter_item.c │ ├── greeter_item.h │ ├── greeter_item_capslock.c │ ├── greeter_item_capslock.h │ ├── greeter_item_clock.c │ ├── greeter_item_clock.h │ ├── greeter_item_customlist.c │ ├── greeter_item_customlist.h │ ├── greeter_item_pam.c │ ├── greeter_item_pam.h │ ├── greeter_item_timed.c │ ├── greeter_item_timed.h │ ├── greeter_item_ulist.c │ ├── greeter_item_ulist.h │ ├── greeter_parser.c │ ├── greeter_parser.h │ ├── greeter_session.c │ ├── greeter_session.h │ ├── greeter_system.c │ ├── greeter_system.h │ └── themes │ │ ├── Makefile.am │ │ └── circles │ │ ├── GdmGreeterTheme.desktop │ │ ├── GdmGreeterTheme.desktop.in │ │ ├── Makefile.am │ │ ├── background.svg │ │ ├── circles.xml │ │ └── screenshot.png ├── mdmcomm.c ├── mdmcomm.h ├── mdmcommon.c ├── mdmcommon.h ├── mdmconfig.c ├── mdmconfig.h ├── mdmflexiserver.c ├── mdmflexiserver.desktop ├── mdmflexiserver.desktop.in ├── mdmgreeter.c ├── mdmgreeter.h ├── mdmlanguages.c ├── mdmlanguages.h ├── mdmlogin.c ├── mdmsession.c ├── mdmsession.h ├── mdmsetup.c ├── mdmsetup.desktop ├── mdmsetup.desktop.in.in ├── mdmsetup.glade ├── mdmuser.c ├── mdmuser.h ├── mdmwebkit.c ├── mdmwm.c ├── mdmwm.h ├── misc.c ├── misc.h └── modules │ ├── AccessDwellMouseEvents.in │ ├── AccessKeyMouseEvents.in │ ├── Makefile.am │ ├── dwellmouselistener.c │ └── keymouselistener.c ├── launchpad-po ├── af.po ├── am.po ├── ar.po ├── az.po ├── be.po ├── bg.po ├── bn.po ├── bs.po ├── ca.po ├── cs.po ├── cy.po ├── da.po ├── de.po ├── el.po ├── en_AU.po ├── en_CA.po ├── en_GB.po ├── eo.po ├── es.po ├── et.po ├── eu.po ├── fa.po ├── fi.po ├── fr.po ├── fr_CA.po ├── frp.po ├── ga.po ├── gd.po ├── gl.po ├── he.po ├── hi.po ├── hr.po ├── hu.po ├── ia.po ├── id.po ├── ii.po ├── is.po ├── it.po ├── ja.po ├── ka.po ├── kab.po ├── kk.po ├── km.po ├── ko.po ├── ksw.po ├── ku.po ├── ky.po ├── lo.po ├── lt.po ├── lv.po ├── mdm.pot ├── mg.po ├── ml.po ├── mr.po ├── ms.po ├── mus.po ├── my.po ├── nb.po ├── nds.po ├── ne.po ├── nl.po ├── nn.po ├── oc.po ├── om.po ├── pa.po ├── pap.po ├── pl.po ├── pt.po ├── pt_BR.po ├── ro.po ├── ru.po ├── rw.po ├── sc.po ├── shn.po ├── si.po ├── sk.po ├── sl.po ├── sq.po ├── sr.po ├── sr@latin.po ├── sv.po ├── ta.po ├── tg.po ├── th.po ├── tr.po ├── uk.po ├── ur.po ├── uz.po ├── vi.po ├── zh_CN.po ├── zh_HK.po └── zh_TW.po ├── makepot ├── mdm.pot ├── pixmaps ├── 24x24 │ ├── Makefile.am │ ├── preferences-desktop-locale.png │ ├── preferences-desktop-remote-desktop.png │ ├── system-log-out.png │ ├── system-restart.png │ ├── system-shut-down.png │ ├── system-suspend.png │ └── user-desktop.png ├── 48x48 │ ├── Makefile.am │ └── mdm.png ├── Makefile.am ├── nobody.png └── nohost.png ├── po ├── ChangeLog ├── LINGUAS ├── POTFILES.in ├── POTFILES.skip ├── af.po ├── am.po ├── ar.po ├── as.po ├── az.po ├── be.po ├── bg.po ├── bn.po ├── bn_IN.po ├── bs.po ├── ca.po ├── cs.po ├── cy.po ├── da.po ├── de.po ├── dz.po ├── el.po ├── en_AU.po ├── en_CA.po ├── en_GB.po ├── eo.po ├── es.po ├── et.po ├── eu.po ├── fa.po ├── fi.po ├── fr.po ├── fr_CA.po ├── frp.po ├── ga.po ├── gd.po ├── gl.po ├── gu.po ├── he.po ├── hi.po ├── hr.po ├── hu.po ├── hy.po ├── ia.po ├── id.po ├── ii.po ├── is.po ├── it.po ├── ja.po ├── ka.po ├── kab.po ├── kk.po ├── km.po ├── kn.po ├── ko.po ├── ksw.po ├── ku.po ├── ky.po ├── lo.po ├── lt.po ├── lv.po ├── mg.po ├── mi.po ├── mk.po ├── ml.po ├── mn.po ├── mr.po ├── ms.po ├── mus.po ├── my.po ├── nb.po ├── nds.po ├── ne.po ├── nl.po ├── nn.po ├── nso.po ├── oc.po ├── om.po ├── or.po ├── pa.po ├── pap.po ├── pl.po ├── po-files │ ├── mdm-de.po │ ├── mdm-fr.po │ ├── mdm-pl.po │ └── mdm.pot ├── pt.po ├── pt_BR.po ├── ro.po ├── ru.po ├── rw.po ├── sc.po ├── shn.po ├── si.po ├── sk.po ├── sl.po ├── sq.po ├── sr.po ├── sr@Latn.po ├── sr@latin.po ├── sv.po ├── ta.po ├── te.po ├── tg.po ├── th.po ├── tr.po ├── uk.po ├── ur.po ├── uz.po ├── uz@cyrillic.po ├── vi.po ├── wa.po ├── xh.po ├── zh_CN.po ├── zh_HK.po ├── zh_TW.po └── zu.po └── utils ├── Makefile.am ├── mdm-dmx-reconnect-proxy.c ├── mdm-restart.in ├── mdm-safe-restart.in ├── mdm-ssh-session ├── mdm-stop.in ├── mdmaskpass.c ├── mdmopen.c ├── mdmprefetch.c ├── mdmsetup-pam ├── mdmsetup-security.in └── mdmtranslate.c /ChangeLog: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/ChangeLog -------------------------------------------------------------------------------- /MAINTAINERS: -------------------------------------------------------------------------------- 1 | #The Queen of England 2 | # 3 | Brian Cameron 4 | E-mail: Brian.Cameron@sun.com 5 | Userid: bcameron 6 | -------------------------------------------------------------------------------- /Makefile.am: -------------------------------------------------------------------------------- 1 | NULL = 2 | 3 | SUBDIRS = \ 4 | po \ 5 | config \ 6 | pixmaps \ 7 | common \ 8 | daemon \ 9 | gui \ 10 | utils \ 11 | docs \ 12 | data \ 13 | files \ 14 | $(NULL) 15 | 16 | # add these when help gets added back 17 | # docs omf-install 18 | 19 | EXTRA_DIST = \ 20 | MAINTAINERS \ 21 | ChangeLog \ 22 | README \ 23 | README.install \ 24 | intltool-extract.in \ 25 | intltool-merge.in \ 26 | intltool-update.in 27 | 28 | DISTCLEANFILES = \ 29 | intltool-extract \ 30 | intltool-merge \ 31 | intltool-update 32 | 33 | DISTCHECK_CONFIGURE_FLAGS = --disable-scrollkeeper 34 | 35 | distuninstallcheck_listfiles = find . -type f -print | grep -v '^\./var/scrollkeeper' | grep -v '^./share/.*/icons/hicolor/icon-theme.cache' 36 | -------------------------------------------------------------------------------- /NEWS: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/NEWS -------------------------------------------------------------------------------- /README: -------------------------------------------------------------------------------- 1 | 2 | MDM - MDM DISPLAY MANAGER 3 | 4 | The MDM Display Manager (MDM) is a display manager that 5 | implements all significant features required for managing 6 | local displays. 7 | 8 | Documentation: 9 | 10 | yelp ghelp:mdm 11 | 12 | Contact: 13 | 14 | #linuxmint-dev on irc.spotchat.org 15 | 16 | -------------------------------------------------------------------------------- /TODO: -------------------------------------------------------------------------------- 1 | 2 | This file is just a place to note ideas about MDM that are maybe 3 | experimental or not significant enough to report a bug. Refore 4 | to http://bugzilla.gnome.org in the "mdm" category for the real 5 | TODO list for MDM. 6 | 7 | + On Solaris MDM uses /etc/logindevperm (see README.install) 8 | and it might be useful to simply make MDM's PreSession and 9 | PostSession scripts process /etc/logindevperm directly and 10 | not call the library interface on Solaris. 11 | 12 | + Big TODO: Rewrite the slave to be based around a mainloop. 13 | So that we don't have to do things directly from signal handlers. 14 | Some work has already been started by making the slave use select 15 | calls instead of waitpid. This needs to be extended a bit. The 16 | big issue is things that hang. We need two things, some better 17 | general framework for things that hang and handling signals there 18 | (see daemon/misc.c for solution when using gethostbyaddr in the 19 | main daemon). We also need some way to do something like 20 | "sleep(5)" with the mainloop nicely. We want the slave to still 21 | be very synchronous, but just have some small handlers run from 22 | within the mainloop. The one thing that will always cause 23 | trouble here is the XDMCP server pinging, I think in this case 24 | it would be sane to do the setjmp thing and just ignore the ping 25 | if a signal comes, not sure how this will play with the X stuff 26 | and if this would completely whack us out. The other option is 27 | to have a separate "pinger process" but that seems to 28 | heavyweight. Another option here is to give up on complete 29 | mainloopishness and during pinging set up an alarm or some other 30 | polling thing that checks all the mainloops stuff. 31 | 32 | + Resource limits have been implemented into the MDM slaves, but 33 | perhaps more could be done. Always keep eye out for leaks. 34 | 35 | Small TODO things: 36 | 37 | + If we can't setup PAM display user visible errors and not just 38 | syslog stuff 39 | 40 | + Languages should be read from available locales. Right now the code 41 | stats each file in /usr/locale, which is slow. Would be faster to 42 | do a readdir on the direction and process them without doing stats. 43 | 44 | Perhaps stuff: 45 | 46 | + Keyboard layout menu. 47 | + native utmp/wtmp handling without sessreg 48 | + xsri like logo functionality 49 | + Handle all the XFree86 Xserver error thingies, such as No "Display" 50 | subsection for etc... 51 | + Add spacer files. Files which we can use in case there is disk 52 | shortage to write a new xauthority stuff so that someone can 53 | actually log on and clean up. Is this crack? Maybe. 54 | 55 | -------------------------------------------------------------------------------- /acconfig.h: -------------------------------------------------------------------------------- 1 | #undef PACKAGE 2 | #undef VERSION 3 | #undef GETTEXT_PACKAGE 4 | #undef HALT_COMMAND 5 | #undef REBOOT_COMMAND 6 | #undef SOUND_PROGRAM 7 | #undef SUSPEND_COMMAND 8 | #undef ENABLE_IPV6 9 | #undef ENABLE_NLS 10 | #undef ALWAYS_RESTART_SERVER 11 | #undef MDM_USER_PATH 12 | #undef MDM_RBAC_SYSCMD_KEYS 13 | #undef HAVE_CATGETS 14 | #undef HAVE_CHPASS 15 | #undef HAVE_CLEARENV 16 | #undef HAVE_CRYPT 17 | #undef HAVE_DEFOPEN 18 | #undef HAVE_GETTEXT 19 | #undef HAVE_LC_MESSAGES 20 | #undef HAVE_LIBSM 21 | #undef HAVE_LOGINCAP 22 | #undef HAVE_LOGINRESTRICTIONS 23 | #undef HAVE_PAM 24 | #undef HAVE_PASSWDEXPIRED 25 | #undef HAVE_SCHED_YIELD 26 | #undef HAVE_SELINUX 27 | #undef HAVE_SETENV 28 | #undef HAVE_SETRESUID 29 | #undef HAVE_SHADOW 30 | #undef HAVE_SOLARIS_XINERAMA 31 | #undef HAVE_STPCPY 32 | #undef HAVE_SYS_SOCKIO_H 33 | #undef HAVE_SYS_VT_H 34 | #undef HAVE_TCPWRAPPERS 35 | #undef HAVE_UNSETENV 36 | #undef HAVE_XINERAMA 37 | #undef HAVE_XFREE_XINERAMA 38 | #undef HAVE_XINPUT 39 | #undef UTMP_LINE_ATTACHED 40 | #undef UTMP_PSEUDO_DEVICE 41 | #undef X_SERVER 42 | #undef X_SERVER_PATH 43 | #undef X_CONFIG_OPTIONS 44 | #undef X_PATH 45 | #undef XSESSION_SHELL 46 | #undef XEVIE_OPTION 47 | #undef HAVE_UT_SYSLEN 48 | -------------------------------------------------------------------------------- /autogen.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Run this to generate all the initial makefiles, etc. 3 | test -n "$srcdir" || srcdir=$(dirname "$0") 4 | test -n "$srcdir" || srcdir=. 5 | 6 | olddir=$(pwd) 7 | 8 | cd $srcdir 9 | 10 | (test -f configure.ac) || { 11 | echo "*** ERROR: Directory '$srcdir' does not look like the top-level project directory ***" 12 | exit 1 13 | } 14 | 15 | # shellcheck disable=SC2016 16 | PKG_NAME=$(autoconf --trace 'AC_INIT:$1' configure.ac) 17 | 18 | if [ "$#" = 0 -a "x$NOCONFIGURE" = "x" ]; then 19 | echo "*** WARNING: I am going to run 'configure' with no arguments." >&2 20 | echo "*** If you wish to pass any to it, please specify them on the" >&2 21 | echo "*** '$0' command line." >&2 22 | echo "" >&2 23 | fi 24 | 25 | aclocal --install || exit 1 26 | intltoolize --force --copy --automake || exit 1 27 | autoreconf --verbose --force --install || exit 1 28 | 29 | cd "$olddir" 30 | if [ "$NOCONFIGURE" = "" ]; then 31 | $srcdir/configure "$@" || exit 1 32 | 33 | if [ "$1" = "--help" ]; then exit 0 else 34 | echo "Now type 'make' to compile $PKG_NAME" || exit 1 35 | fi 36 | else 37 | echo "Skipping configure process." 38 | fi 39 | -------------------------------------------------------------------------------- /common/Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce Makefile.in 2 | 3 | NULL = 4 | 5 | INCLUDES = \ 6 | -I. \ 7 | -I.. \ 8 | -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \ 9 | -DAUTHDIR=\"$(authdir)\" \ 10 | -DBINDIR=\"$(bindir)\" \ 11 | -DDATADIR=\"$(datadir)\" \ 12 | -DDMCONFDIR=\"$(dmconfdir)\" \ 13 | -DMDMCONFDIR=\"$(mdmconfdir)\" \ 14 | -DMDMLOCALEDIR=\"$(mdmlocaledir)\" \ 15 | -DLIBDIR=\"$(libdir)\" \ 16 | -DLIBEXECDIR=\"$(libexecdir)\" \ 17 | -DLOGDIR=\"$(logdir)\" \ 18 | -DPIXMAPDIR=\"$(pixmapdir)\" \ 19 | -DSBINDIR=\"$(sbindir)\" \ 20 | -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \ 21 | -DMDM_DEFAULTS_CONF=\"$(MDM_DEFAULTS_CONF)\" \ 22 | -DMDM_CUSTOM_CONF=\"$(MDM_CUSTOM_CONF)\" \ 23 | -DMDM_OLD_CONF=\"$(MDM_OLD_CONF)\" \ 24 | $(GLIB_CFLAGS) 25 | 26 | noinst_LIBRARIES = \ 27 | libmdmcommon.a \ 28 | $(null) 29 | 30 | libmdmcommon_a_SOURCES = \ 31 | mdm-common.h \ 32 | mdm-common.c \ 33 | mdm-common-config.h \ 34 | mdm-common-config.c \ 35 | mdm-config.h \ 36 | mdm-config.c \ 37 | mdm-log.h \ 38 | mdm-log.c \ 39 | ve-signal.h \ 40 | ve-signal.c \ 41 | $(NULL) 42 | 43 | noinst_PROGRAMS = \ 44 | test-config \ 45 | test-log \ 46 | $(NULL) 47 | 48 | test_config_SOURCES = \ 49 | $(top_builddir)/daemon/mdm-daemon-config-entries.h \ 50 | test-config.c \ 51 | $(NULL) 52 | 53 | test_config_LDADD = \ 54 | libmdmcommon.a \ 55 | $(GLIB_LIBS) \ 56 | $(NULL) 57 | 58 | test_log_SOURCES = \ 59 | test-log.c \ 60 | $(NULL) 61 | 62 | test_log_LDADD = \ 63 | libmdmcommon.a \ 64 | $(GLIB_LIBS) \ 65 | $(NULL) 66 | -------------------------------------------------------------------------------- /common/mdm-common-config.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * Copyright (C) 2007 William Jon McCann 4 | * 5 | * This library is free software; you can redistribute it and/or 6 | * modify it under the terms of the GNU Library General Public 7 | * License as published by the Free Software Foundation; either 8 | * version 2 of the License, or (at your option) any later version. 9 | * 10 | * This library is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * Library General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU Library General Public 16 | * License along with this library; if not, write to the 17 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 18 | * Boston, MA 02111-1307, USA. 19 | */ 20 | 21 | #ifndef _MDM_COMMON_CONFIG_H 22 | #define _MDM_COMMON_CONFIG_H 23 | 24 | #include 25 | 26 | G_BEGIN_DECLS 27 | 28 | GKeyFile * mdm_common_config_load (const char *filename, 29 | GError **error); 30 | GKeyFile * mdm_common_config_load_from_dirs (const char *filename, 31 | const char **dirs, 32 | GError **error); 33 | gboolean mdm_common_config_save (GKeyFile *config, 34 | const char *filename, 35 | GError **error); 36 | 37 | gboolean mdm_common_config_get_string (GKeyFile *config, 38 | const char *keystring, 39 | char **value, 40 | GError **error); 41 | gboolean mdm_common_config_get_translated_string (GKeyFile *config, 42 | const char *keystring, 43 | char **value, 44 | GError **error); 45 | gboolean mdm_common_config_get_int (GKeyFile *config, 46 | const char *keystring, 47 | int *value, 48 | GError **error); 49 | gboolean mdm_common_config_get_boolean (GKeyFile *config, 50 | const char *keystring, 51 | gboolean *value, 52 | GError **error); 53 | gboolean mdm_common_config_parse_key_string (const char *keystring, 54 | char **group, 55 | char **key, 56 | char **locale, 57 | char **value); 58 | 59 | void mdm_common_config_set_string (GKeyFile *config, 60 | const char *keystring, 61 | const char *value); 62 | void mdm_common_config_set_boolean (GKeyFile *config, 63 | const char *keystring, 64 | gboolean value); 65 | void mdm_common_config_set_int (GKeyFile *config, 66 | const char *keystring, 67 | int value); 68 | 69 | void mdm_common_config_remove_key (GKeyFile *config, 70 | const char *keystring, 71 | GError **error); 72 | 73 | G_END_DECLS 74 | 75 | #endif /* _MDM_COMMON_CONFIG_H */ 76 | -------------------------------------------------------------------------------- /common/mdm-common.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * (c) 2000 Eazel, Inc. 4 | * (c) 2001,2002 George Lebl 5 | * 6 | * This library is free software; you can redistribute it and/or 7 | * modify it under the terms of the GNU Library General Public 8 | * License as published by the Free Software Foundation; either 9 | * version 2 of the License, or (at your option) any later version. 10 | * 11 | * This library is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14 | * Library General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU Library General Public 17 | * License along with this library; if not, write to the 18 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 19 | * Boston, MA 02111-1307, USA. 20 | */ 21 | 22 | #ifndef _MDM_COMMON_H 23 | #define _MDM_COMMON_H 24 | 25 | #include 26 | #include 27 | #include 28 | #include 29 | #include 30 | #include 31 | #include 32 | #include 33 | #include 34 | 35 | #include "ve-signal.h" 36 | #include "mdm-common-config.h" 37 | #include "mdm-config.h" 38 | 39 | G_BEGIN_DECLS 40 | 41 | #define mdm_sockaddr_len(sa) (((struct sockaddr *)sa)->sa_family == AF_INET6 ? sizeof(struct sockaddr_in6) : sizeof(struct sockaddr_in)) 42 | 43 | gboolean mdm_address_equal (struct sockaddr_storage *sa, 44 | struct sockaddr_storage *sb); 45 | gboolean mdm_address_is_loopback (struct sockaddr_storage *sa); 46 | void mdm_address_get_info (struct sockaddr_storage *sa, 47 | char **host, 48 | char **port); 49 | int mdm_vector_len (char * const *v); 50 | 51 | void ve_clearenv (void); 52 | char * ve_first_word (const char *s); 53 | gboolean ve_first_word_executable (const char *s, 54 | gboolean only_existance); 55 | 56 | /* Gets the first existing command out of a list separated by semicolons */ 57 | char * ve_get_first_working_command (const char *list, 58 | gboolean only_existance); 59 | 60 | #define ve_string_empty(x) ((x)==NULL||(x)[0]=='\0') 61 | #define ve_sure_string(x) ((x)!=NULL?(x):"") 62 | 63 | /* These two functions will ALWAYS return a non-NULL string, 64 | * if there is an error, they return the unconverted string */ 65 | char * ve_locale_to_utf8 (const char *str); 66 | char * ve_locale_from_utf8 (const char *str); 67 | 68 | /* These two functions will ALWAYS return a non-NULL string, 69 | * if there is an error, they return the unconverted string */ 70 | char * ve_filename_to_utf8 (const char *str); 71 | char * ve_filename_from_utf8 (const char *str); 72 | 73 | /* function which doesn't stop on signals */ 74 | pid_t ve_waitpid_no_signal (pid_t pid, int *status, int options); 75 | 76 | /* Testing for existance of a certain locale */ 77 | gboolean ve_locale_exists (const char *loc); 78 | 79 | char * mdm_common_get_facefile (const char *homedir, const char *username, guint uid); 80 | 81 | #define VE_IGNORE_EINTR(expr) \ 82 | do { \ 83 | errno = 0; \ 84 | expr; \ 85 | } while G_UNLIKELY (errno == EINTR); 86 | 87 | G_END_DECLS 88 | 89 | #endif /* _MDM_COMMON_H */ 90 | -------------------------------------------------------------------------------- /common/mdm-log.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * Copyright (C) 2007 William Jon McCann 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 18 | * 19 | * Authors: William Jon McCann 20 | * 21 | */ 22 | 23 | #ifndef __MDM_LOG_H 24 | #define __MDM_LOG_H 25 | 26 | #include 27 | #include 28 | 29 | G_BEGIN_DECLS 30 | 31 | void mdm_log_default_handler (const gchar *log_domain, 32 | GLogLevelFlags log_level, 33 | const gchar *message, 34 | gpointer unused_data); 35 | void mdm_log_set_debug (gboolean debug); 36 | void mdm_log_init (void); 37 | void mdm_log_shutdown (void); 38 | 39 | /* compatibility */ 40 | #define mdm_error g_warning 41 | #define mdm_info g_message 42 | #define mdm_debug g_debug 43 | 44 | #define mdm_assert g_assert 45 | #define mdm_assert_not_reached g_assert_not_reached 46 | 47 | G_END_DECLS 48 | 49 | #endif /* __MDM_LOG_H */ 50 | -------------------------------------------------------------------------------- /common/test-log.c: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*- 2 | * 3 | * Copyright (C) 2007 William Jon McCann 4 | * 5 | * This program is free software; you can redistribute it and/or 6 | * modify it under the terms of the GNU General Public License as 7 | * published by the Free Software Foundation; either version 2 of the 8 | * License, or (at your option) any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, but 11 | * WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 13 | * General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 18 | * 02111-1307, USA. 19 | * 20 | */ 21 | 22 | #include "config.h" 23 | 24 | #include 25 | #include 26 | #include 27 | #include 28 | #include 29 | #include 30 | 31 | #include 32 | 33 | #include 34 | 35 | #include "mdm-common.h" 36 | #include "mdm-log.h" 37 | 38 | static void 39 | test_log (void) 40 | { 41 | mdm_log_init (); 42 | 43 | g_debug ("Test debug 1"); 44 | mdm_log_set_debug (TRUE); 45 | g_debug ("Test debug 2"); 46 | 47 | g_message ("Test message"); 48 | g_warning ("Test warning"); 49 | g_error ("Test error"); 50 | g_critical ("Test critical"); 51 | } 52 | 53 | int 54 | main (int argc, char **argv) 55 | { 56 | 57 | test_log (); 58 | 59 | return 0; 60 | } 61 | -------------------------------------------------------------------------------- /common/ve-signal.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * Signal routines 4 | * 5 | * (c) 2000, 2002 Queen of England 6 | * 7 | * This library is free software; you can redistribute it and/or 8 | * modify it under the terms of the GNU Library General Public 9 | * License as published by the Free Software Foundation; either 10 | * version 2 of the License, or (at your option) any later version. 11 | * 12 | * This library is distributed in the hope that it will be useful, 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 15 | * Library General Public License for more details. 16 | * 17 | * You should have received a copy of the GNU Library General Public 18 | * License along with this library; if not, write to the 19 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330, 20 | * Boston, MA 02111-1307, USA. 21 | */ 22 | 23 | #ifndef _VE_SIGNAL_H 24 | #define _VE_SIGNAL_H 25 | 26 | #include 27 | 28 | typedef gboolean (*VeSignalFunc) (int signal, 29 | gpointer data); 30 | guint ve_signal_add (int signal, 31 | VeSignalFunc function, 32 | gpointer data); 33 | guint ve_signal_add_full (int priority, 34 | int signal, 35 | VeSignalFunc function, 36 | gpointer data, 37 | GDestroyNotify destroy); 38 | /* You must handle the signal notify yourself, you add 39 | * this function as the signal notification function 40 | * however */ 41 | void ve_signal_notify (int signal); 42 | 43 | gboolean ve_signal_was_notified (int signal); 44 | void ve_signal_unnotify (int signal); 45 | 46 | #endif /* _VE_CONFIG_H */ 47 | -------------------------------------------------------------------------------- /config/Init.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Run as mdm user just before starting the greeter 3 | 4 | PATH="@X_PATH@:$PATH" 5 | OLD_IFS=$IFS 6 | 7 | if test -x "/sbin/initctl" ; then 8 | /sbin/initctl -q emit login-session-start DISPLAY_MANAGER=mdm 9 | fi 10 | 11 | mdmwhich () { 12 | COMMAND="$1" 13 | OUTPUT= 14 | IFS=: 15 | for dir in $PATH 16 | do 17 | if test -x "$dir/$COMMAND" ; then 18 | if test "x$OUTPUT" = "x" ; then 19 | OUTPUT="$dir/$COMMAND" 20 | fi 21 | fi 22 | done 23 | IFS=$OLD_IFS 24 | echo "$OUTPUT" 25 | } 26 | 27 | sysresources=/etc/X11/Xresources 28 | 29 | # merge in defaults 30 | if [ -f "$sysresources" ]; then 31 | xrdb -merge "$sysresources" 32 | fi 33 | 34 | sysmodmap=/etc/X11/Xmodmap 35 | 36 | XMODMAP=`mdmwhich xmodmap` 37 | if [ "x$XMODMAP" != "x" ] ; then 38 | if [ -f $sysmodmap ]; then 39 | $XMODMAP $sysmodmap 40 | fi 41 | fi 42 | 43 | DISPLAY=:0 /usr/bin/syndaemon -d -i 1.0 -t -K -R 44 | 45 | # Apply the keyboard configuration from /etc/default/keyboard 46 | # This is needed on some computers using Logitech USB keyboards 47 | /usr/bin/mdm-set-keyboard-layout 48 | 49 | exit 0 50 | -------------------------------------------------------------------------------- /config/PostLogin: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Note: this is a sample and will not be run as is. Change the name of this 4 | # file to /PostLogin/Default for this script to be run. This 5 | # script will be run before any setup is run on behalf of the user and is 6 | # useful if you for example need to do some setup to create a home directory 7 | # for the user or something like that. $HOME, $LOGNAME and such will all be 8 | # set appropriately and this script is run as root. 9 | -------------------------------------------------------------------------------- /config/PostSession.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | PATH="@X_PATH@:$PATH:/bin:/usr/bin" 4 | OLD_IFS=$IFS 5 | 6 | mdmwhich () { 7 | COMMAND="$1" 8 | OUTPUT= 9 | IFS=: 10 | for dir in $PATH 11 | do 12 | if test -x "$dir/$COMMAND" ; then 13 | if test "x$OUTPUT" = "x" ; then 14 | OUTPUT="$dir/$COMMAND" 15 | fi 16 | fi 17 | done 18 | IFS=$OLD_IFS 19 | echo "$OUTPUT" 20 | } 21 | 22 | # Use common Xreset framework if it exist 23 | if [ -x /etc/X11/Xreset ] ; then 24 | /etc/X11/Xreset 25 | fi 26 | 27 | exit 0 28 | -------------------------------------------------------------------------------- /config/PreSession.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Note that output goes into the .xsession-errors file for easy debugging 4 | # 5 | PATH="@X_PATH@:$PATH:/bin:/usr/bin" 6 | OLD_IFS=$IFS 7 | 8 | if test -x "/sbin/initctl" ; then 9 | /sbin/initctl -q emit desktop-session-start DISPLAY_MANAGER=mdm 10 | fi 11 | 12 | killall syndaemon 13 | 14 | mdmwhich () { 15 | COMMAND="$1" 16 | OUTPUT= 17 | IFS=: 18 | for dir in $PATH 19 | do 20 | if test -x "$dir/$COMMAND" ; then 21 | if test "x$OUTPUT" = "x" ; then 22 | OUTPUT="$dir/$COMMAND" 23 | fi 24 | fi 25 | done 26 | IFS=$OLD_IFS 27 | echo "$OUTPUT" 28 | } 29 | 30 | # Set background color 31 | XSETROOT=`mdmwhich xsetroot` 32 | if [ "x$XSETROOT" != "x" ] ; then 33 | 34 | # Background type can be 0=None, 1=Image & Color, 2=Color, or 3=Image 35 | BACKTYPE=`mdmflexiserver --command="GET_CONFIG greeter/BackgroundType $DISPLAY"` 36 | 37 | # Skip if background type does not include a color 38 | if [ "x$BACKTYPE" = "xOK 1" ] || [ "x$BACKTYPE" = "xOK 2" ]; then 39 | BACKCOLOR=`mdmflexiserver --command="GET_CONFIG greeter/BackgroundColor $DISPLAY"` 40 | 41 | CHECKBACKCOLOR=`echo $BACKCOLOR | sed 's/^\([^ ]*\) .*$/\1/'` 42 | if [ "x$CHECKBACKCOLOR" = "xOK" ]; then 43 | BACKCOLOR=`echo $BACKCOLOR | sed 's/^.* \(.*\)$/\1/'` 44 | else 45 | BACKCOLOR="" 46 | fi 47 | fi 48 | 49 | # Default value 50 | if [ "x$BACKCOLOR" = "x" ]; then 51 | BACKCOLOR="#000000" 52 | fi 53 | 54 | "$XSETROOT" -cursor_name left_ptr -solid "$BACKCOLOR" 55 | fi 56 | 57 | exit 0 58 | -------------------------------------------------------------------------------- /config/SuperInit.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # This script is run as root just before the greeter is started (Xorg is already running) 3 | 4 | logger -i -tag mdm-superinit "Starting..." 5 | 6 | # NVIDIA prime support 7 | primeoffload=/sbin/prime-offload 8 | if [ -f "$primeoffload" ]; then 9 | logger -i -tag mdm-superinit "Running prime-offload..." 10 | $primeoffload 11 | logger -i -tag mdm-superinit "Finished running prime-offload." 12 | fi 13 | 14 | logger -i -tag mdm-superinit "Finished" 15 | 16 | exit 0 17 | -------------------------------------------------------------------------------- /config/SuperPost.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # This script is run as root after a slave dies (server/greeter/session are killed by then. Xorg is not running for that particular slave). 3 | 4 | logger -i -tag mdm-superpost "Starting..." 5 | 6 | # NVIDIA prime support 7 | primeswitch=/sbin/prime-switch 8 | if [ -f "$primeswitch" ]; then 9 | logger -i -tag mdm-superpost "Running prime-switch..." 10 | $primeswitch 11 | logger -i -tag mdm-superpost "Finished running prime-switch." 12 | fi 13 | 14 | logger -i -tag mdm-superpost "Finished" 15 | 16 | exit 0 17 | -------------------------------------------------------------------------------- /config/default.desktop.in.in: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Encoding=UTF-8 3 | # The names/descriptions should really be better 4 | _Name=Default Session 5 | _Comment=Run the default session 6 | Exec=default 7 | # The "default" Exec is a very special one and is handled specially in 8 | # the Xsession script, you could also have "custom" which would just run 9 | # "~/.xsession" directly 10 | Icon= 11 | Type=Application 12 | -------------------------------------------------------------------------------- /config/extract-shell.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | echo "/* DO NOT CHANGE HEADER FILE BY HAND! CHANGE THE extract-shell.sh */" 3 | echo "/* SCRIPT THIS IS GENERATED. ADD A CHANGELOG ENTRY IF YOU MODIFY */" 4 | echo "/* THIS SCRIPT. */" 5 | echo "/* ALWAYS ADD A CHANGELOG OR I WILL PERSONALLY KICK YOUR ASS! */" 6 | grep gettextfunc | fgrep -v 'gettextfunc ()' | sed 's/^.*gettextfunc[^"]*\("[^"]*"\).*$/const char *foo = N_(\1);/' 7 | -------------------------------------------------------------------------------- /config/gettextfoo.h: -------------------------------------------------------------------------------- 1 | /* DO NOT CHANGE HEADER FILE BY HAND! CHANGE THE extract-shell.sh */ 2 | /* SCRIPT THIS IS GENERATED. ADD A CHANGELOG ENTRY IF YOU MODIFY */ 3 | /* THIS SCRIPT. */ 4 | /* ALWAYS ADD A CHANGELOG OR I WILL PERSONALLY KICK YOUR ASS! */ 5 | const char *foo = N_("Failed to start the X server (your graphical interface). It is likely that it is not set up correctly. You will need to log in on a console and reconfigure the X server. Then restart MDM."); 6 | const char *foo = N_("Would you like to try to configure the X server? Note that you will need the root password for this."); 7 | const char *foo = N_("Please type in the root (privileged user) password."); 8 | const char *foo = N_("Trying to restart the X server."); 9 | const char *foo = N_("The X server is now disabled. Restart MDM when it is configured correctly."); 10 | const char *foo = N_("Failed to start the X server (your graphical interface). It is likely that it is not set up correctly. Would you like to view the X server output to diagnose the problem?"); 11 | const char *foo = N_("Would you like to view the detailed X server output as well?"); 12 | const char *foo = N_("Failed to start the X server (your graphical interface). It seems that the pointer device (your mouse) is not set up correctly. Would you like to view the X server output to diagnose the problem?"); 13 | const char *foo = N_("Would you like to try to configure the mouse? Note that you will need the root password for this."); 14 | const char *foo = N_("Would you like to try to configure the mouse? Note that you will need the root password for this."); 15 | const char *foo = N_("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."); 16 | const char *foo = N_("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."); 17 | -------------------------------------------------------------------------------- /config/mdm: -------------------------------------------------------------------------------- 1 | #%PAM-1.0 2 | auth required pam_env.so 3 | auth required pam_stack.so service=system-auth 4 | auth required pam_nologin.so 5 | account required pam_stack.so service=system-auth 6 | password required pam_stack.so service=system-auth 7 | session required pam_stack.so service=system-auth 8 | session optional pam_console.so 9 | -------------------------------------------------------------------------------- /config/mdm-autologin: -------------------------------------------------------------------------------- 1 | #%PAM-1.0 2 | auth required pam_env.so 3 | auth required pam_nologin.so 4 | auth required pam_permit.so 5 | account required pam_stack.so service=system-auth 6 | password required pam_stack.so service=system-auth 7 | session required pam_stack.so service=system-auth 8 | session optional pam_console.so 9 | -------------------------------------------------------------------------------- /config/mdm.conf-custom.in: -------------------------------------------------------------------------------- 1 | # MDM Configuration file. 2 | # 3 | # This file is the appropriate place for specifying your customizations to the 4 | # MDM configuration. If you run mdmsetup, it will automatically edit this 5 | # file for you and will cause the daemon and any running MDM GUI programs to 6 | # automatically update with the new configuration. Not all configuration 7 | # options are supported by mdmsetup, so to modify some values it may be 8 | # necessary to modify this file directly by hand. 9 | # 10 | # This file overrides the default configuration settings. These settings 11 | # are stored in the MDM System Defaults configuration file, which is found 12 | # at the following location. 13 | # 14 | # @MDM_DEFAULTS_CONF@. 15 | # 16 | # Default settings are first overriden by you distribution in /usr/share/mdm/distro.conf 17 | # and then by the settings present in this file. 18 | # 19 | # This file contains comments about the meaning of each configuration option, 20 | # so is also a useful reference. In short, to hand-edit 21 | # this file, simply add or modify the key=value combination in the 22 | # appropriate section in the template below this comment section. 23 | # 24 | # For example, if you want to specify a different value for the Enable key 25 | # in the "[debug]" section of your MDM System Defaults configuration file, 26 | # then add "Enable=true" in the "[debug]" section of this file. If the 27 | # key already exists in this file, then simply modify it. 28 | # 29 | # If you hand edit a MDM configuration file, you can run the following 30 | # command and the MDM daemon will immediately reflect the change. Any 31 | # running MDM GUI programs will also be notified to update with the new 32 | # configuration. 33 | # 34 | # mdmflexiserver --command="UPDATE_CONFIG " 35 | # 36 | # e.g, the "Enable" key in the "[debug]" section would be "debug/Enable". 37 | # 38 | # You can also run mdm-restart or mdm-safe-restart to cause MDM to restart and 39 | # re-read the new configuration settings. You can also restart MDM by sending 40 | # a HUP or USR1 signal to the daemon. HUP behaves like mdm-restart and causes 41 | # any user session started by MDM to exit immediately while USR1 behaves like 42 | # mdm-safe-restart and will wait until all users log out before restarting MDM. 43 | # 44 | # 45 | # NOTE: Lines that begin with "#" are considered comments. 46 | # 47 | # Have fun! 48 | 49 | [daemon] 50 | 51 | [security] 52 | 53 | [xdmcp] 54 | 55 | [gui] 56 | 57 | [greeter] 58 | 59 | [chooser] 60 | 61 | [debug] 62 | 63 | # Note that to disable servers defined in the MDM System Defaults 64 | # configuration file (such as 0=Standard, you must put a line in this file 65 | # that says 0=inactive, as described in the Configuration section of the MDM 66 | # documentation. 67 | # 68 | [servers] 69 | 70 | # Also note, that if you redefine a [server-foo] section, then MDM will 71 | # use the definition in this file, not the MDM System Defaults configuration 72 | # file. It is currently not possible to disable a [server-foo] section 73 | # defined in the MDM System Defaults configuration file. 74 | # 75 | -------------------------------------------------------------------------------- /config/mdmprefetchlist.in: -------------------------------------------------------------------------------- 1 | # If MDM is built with the --with-prefetch option, then this file 2 | # is installed on the system, and the mdm.conf PreFetchProgram 3 | # value should be set properly to cause the first login program 4 | # managed to preload this list of libraries. It has been shown that 5 | # preloading these libraries improves first-time login performance 6 | # for the GNOME desktop. 7 | # 8 | # This list of libraries has been optimized for a GNOME session running 9 | # on Solaris. People who want to contribute alternative lists of 10 | # libraries for other distributions or desktop environments can 11 | # contribute them to the "mdm" category in http://bugzilla.gnome.org/, 12 | # and these can be made available in future releases of MDM. 13 | # 14 | /usr/share/icons/hicolor/icon-theme.cache 15 | /usr/share/icons/blueprint/icon-theme.cache 16 | /usr/share/icons/gnome/icon-theme.cache 17 | /usr/bin/nautilus 18 | /usr/bin/gnome-panel 19 | /usr/lib/libbonoboui-2.so 20 | /usr/lib/libwnck-1.so 21 | /usr/lib/libgnomevfs-2.so 22 | /usr/bin/metacity 23 | /usr/lib/libeel-2.so 24 | /usr/lib/libbonobo-2.so 25 | /usr/openwin/lib/libXt.so 26 | /usr/lib/libgnomeui-2.so 27 | /usr/lib/clock-applet 28 | /usr/lib/libORBit-2.so 29 | /usr/X11/lib/libGL.so 30 | /usr/openwin/lib/X11/fonts/TrueType/VeraMoIt.ttf 31 | /usr/lib/libgnome-desktop-2.so 32 | /usr/lib/wnck-applet 33 | /usr/lib/libgstreamer-0.10.so 34 | /usr/dt/lib/libXm.so 35 | /usr/lib/libpoppler.so 36 | /usr/lib/libgconf-2.so 37 | /usr/sfw/lib/libcrypto.so 38 | /usr/lib/nautilus/extensions-1.0/libevince-properties-page.so 39 | /usr/lib/gnome-vfs-2.0/modules/libmapping.so 40 | /usr/lib/libpoppler-glib.so 41 | /usr/lib/libpanel-applet-2.so 42 | /usr/lib/libstartup-notification-1.so 43 | /usr/lib/libatk-1.0.so 44 | -------------------------------------------------------------------------------- /config/ssh.desktop.in.in: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Encoding=UTF-8 3 | _Name=Secure Remote connection 4 | _Comment=This session logs you into a remote host using ssh 5 | Exec=@MDMSSHSESSIONCMD@ 6 | Type=Application 7 | -------------------------------------------------------------------------------- /daemon/Makefile.am: -------------------------------------------------------------------------------- 1 | NULL = 2 | 3 | # Note that we have cflags for just about everything even if 4 | # we don't link to everything 5 | INCLUDES = \ 6 | -I. \ 7 | -I.. \ 8 | -I$(top_srcdir)/common \ 9 | -DAUTHDIR=\"$(authdir)\" \ 10 | -DBINDIR=\"$(bindir)\" \ 11 | -DDATADIR=\"$(datadir)\" \ 12 | -DDMCONFDIR=\"$(dmconfdir)\" \ 13 | -DMDMCONFDIR=\"$(mdmconfdir)\" \ 14 | -DMDMLOCALEDIR=\"$(mdmlocaledir)\" \ 15 | -DLIBDIR=\"$(libdir)\" \ 16 | -DLIBEXECDIR=\"$(libexecdir)\" \ 17 | -DLOGDIR=\"$(logdir)\" \ 18 | -DPIXMAPDIR=\"$(pixmapdir)\" \ 19 | -DSBINDIR=\"$(sbindir)\" \ 20 | -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \ 21 | -DMDM_DEFAULTS_CONF=\"$(MDM_DEFAULTS_CONF)\" \ 22 | -DMDM_CUSTOM_CONF=\"$(MDM_CUSTOM_CONF)\" \ 23 | -DMDM_OLD_CONF=\"$(MDM_OLD_CONF)\" \ 24 | $(GUI_CFLAGS) \ 25 | $(DAEMON_CFLAGS) \ 26 | -DLANG_CONFIG_FILE=\"$(LANG_CONFIG_FILE)\" \ 27 | $(GNOME_INCLUDEDIR) \ 28 | -DGREETERTHEMEDIR=\""$(datadir)/mdm/themes"\" \ 29 | $(NULL) 30 | 31 | sbin_PROGRAMS = mdm-binary \ 32 | $(NULL) 33 | 34 | mdm_binary_SOURCES = \ 35 | mdm.c \ 36 | mdm.h \ 37 | mdm-daemon-config.c \ 38 | mdm-daemon-config.h \ 39 | mdm-daemon-config-entries.h \ 40 | mdm-daemon-config-keys.h \ 41 | mdm-socket-protocol.h \ 42 | display.c \ 43 | display.h \ 44 | fstype.c \ 45 | slave.c \ 46 | slave.h \ 47 | server.c \ 48 | server.h \ 49 | misc.c \ 50 | misc.h \ 51 | auth.c \ 52 | auth.h \ 53 | cookie.c \ 54 | cookie.h \ 55 | filecheck.c \ 56 | filecheck.h \ 57 | md5.c \ 58 | md5.h \ 59 | @VRFY@.c \ 60 | verify.h \ 61 | errorgui.c \ 62 | errorgui.h \ 63 | mdm-net.c \ 64 | mdm-net.h \ 65 | getvt.c \ 66 | getvt.h \ 67 | $(NULL) 68 | 69 | EXTRA_mdm_binary_SOURCES = \ 70 | verify-pam.c \ 71 | verify-crypt.c \ 72 | verify-shadow.c \ 73 | $(NULL) 74 | 75 | CONSOLE_KIT_SOURCES = \ 76 | mdmconsolekit.c \ 77 | mdmconsolekit.h \ 78 | $(NULL) 79 | 80 | EXTRA_mdm_binary_SOURCES += $(CONSOLE_KIT_SOURCES) 81 | 82 | # Note that these libs are in LDFLAGS because they should come before 83 | # everything else on the link line as they may override stuff 84 | mdm_binary_LDFLAGS = \ 85 | $(EXTRA_DAEMON_LIBS) \ 86 | $(NULL) 87 | 88 | mdm_binary_LDADD = \ 89 | $(DAEMON_LIBS) \ 90 | $(INTLLIBS) \ 91 | $(GLIB_LIBS) \ 92 | $(GOBJECT_LIBS) \ 93 | $(GDK_LIBS) \ 94 | $(top_builddir)/common/libmdmcommon.a \ 95 | $(X_LIBS) \ 96 | $(XINERAMA_LIBS) \ 97 | $(LIBWRAP_LIBS) \ 98 | -lXau \ 99 | -lX11 \ 100 | -lXext \ 101 | $(NULL) 102 | 103 | if WITH_CONSOLE_KIT 104 | mdm_binary_SOURCES += $(CONSOLE_KIT_SOURCES) 105 | mdm_binary_LDADD += $(DBUS_LIBS) 106 | INCLUDES += $(DBUS_CFLAGS) 107 | endif 108 | 109 | sbin_SCRIPTS = mdm 110 | CLEANFILES = mdm 111 | 112 | mdm: $(srcdir)/mdm.in 113 | sed -e 's,[@]sbindir[@],$(sbindir),g' <$(srcdir)/mdm.in >mdm 114 | 115 | EXTRA_DIST = mdm.in 116 | -------------------------------------------------------------------------------- /daemon/auth.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef MDM_AUTH_H 20 | #define MDM_AUTH_H 21 | 22 | #include "mdm.h" 23 | 24 | gboolean mdm_auth_secure_display (MdmDisplay *d); 25 | gboolean mdm_auth_user_add (MdmDisplay *d, uid_t user, const char *homedir); 26 | void mdm_auth_user_remove (MdmDisplay *d, uid_t user); 27 | 28 | /* Call XSetAuthorization */ 29 | void mdm_auth_set_local_auth (MdmDisplay *d); 30 | 31 | void mdm_auth_free_auth_list (GSList *list); 32 | 33 | #endif /* MDM_AUTH_H */ 34 | 35 | /* EOF */ 36 | -------------------------------------------------------------------------------- /daemon/cookie.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef MDM_COOKIE_H 20 | #define MDM_COOKIE_H 21 | 22 | void mdm_cookie_generate (char **cookie, 23 | char **bcookie); 24 | 25 | /* Add some more time based randomness, should be done 26 | * at less predictable events */ 27 | void mdm_random_tick (void); 28 | 29 | #endif /* MDM_COOKIE_H */ 30 | 31 | /* EOF */ 32 | -------------------------------------------------------------------------------- /daemon/errorgui.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef MDM_ERRORGUI_H 20 | #define MDM_ERRORGUI_H 21 | 22 | #include "mdm.h" 23 | #include 24 | 25 | void mdm_errorgui_error_box_full (MdmDisplay *d, 26 | GtkMessageType type, 27 | const char *error, 28 | const char *details_label, 29 | const char *details_file, 30 | /* zero doesn't mean root, 31 | we never wish to run as root, 32 | zero means use the mdm user */ 33 | uid_t uid, 34 | gid_t gid); 35 | 36 | void mdm_errorgui_error_box (MdmDisplay *d, 37 | GtkMessageType type, 38 | const char *error); 39 | 40 | char * mdm_errorgui_failsafe_question (MdmDisplay *d, 41 | const char *question, 42 | gboolean echo); 43 | 44 | gboolean mdm_errorgui_failsafe_yesno (MdmDisplay *d, 45 | const char *question); 46 | int mdm_errorgui_failsafe_ask_buttons (MdmDisplay *d, 47 | const char *question, 48 | char **but); 49 | 50 | #endif /* MDM_ERRORGUI_H */ 51 | 52 | /* EOF */ 53 | 54 | -------------------------------------------------------------------------------- /daemon/filecheck.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef MDM_FILECHECK_H 20 | #define MDM_FILECHECK_H 21 | 22 | gboolean mdm_file_check (const gchar *caller, uid_t user, const gchar *dir, 23 | const gchar *file, gboolean absentok, 24 | gboolean absentdirok, gint maxsize, 25 | gint perms); 26 | 27 | /* more paranoid on the file itself, doesn't check directory (for all we know 28 | it could be /tmp) */ 29 | gboolean mdm_auth_file_check (const gchar *caller, uid_t user, const gchar *authfile, gboolean absentok, struct stat *s); 30 | 31 | #endif /* MDM_FILECHECK_H */ 32 | 33 | /* EOF */ 34 | -------------------------------------------------------------------------------- /daemon/getvt.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 2002 Queen of England 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef GETVT_H 20 | #define GETVT_H 21 | 22 | /* Virtual terminals only supported on Linux, FreeBSD, DragonFly, or Solaris */ 23 | #if defined (__linux__) 24 | /* Must check HAVE_SYS_VT since older Solaris doesn't support this. */ 25 | #ifdef HAVE_SYS_VT_H 26 | #define MDM_USE_SYS_VT 27 | #endif 28 | #endif 29 | 30 | #if defined (__FreeBSD__) || defined (__DragonFly__) 31 | #define MDM_USE_CONSIO_VT 32 | #endif 33 | 34 | /* gets an argument we should pass to the X server, on 35 | * linux for example we get the first empty vt (higher than 36 | * or equal to MDM_KEY_FIRST_VT) and then return vt 37 | * (e.g. "vt7") as a newly allocated string. 38 | * Can return NULL if we can't figure out what to do 39 | * or if MDM_KEY_VT_ALLOCATION is false. */ 40 | /* fd is opened so that we are saying we have opened this 41 | * vt. This should be closed after the server has started. 42 | * This is to avoid race with other stuff openning this vt. 43 | * It can be set to -1 if nothing could be opened. */ 44 | char * mdm_get_empty_vt_argument (int *fd, 45 | int *vt); 46 | 47 | /* Change to the specified virtual terminal */ 48 | void mdm_change_vt (int vt); 49 | 50 | /* Get the current virtual terminal number or -1 if we can't */ 51 | int mdm_get_current_vt (void); 52 | long mdm_get_current_vtnum (Display *display); 53 | gchar * mdm_get_vt_device (int vtno); 54 | 55 | #endif /* GETVT_H */ 56 | -------------------------------------------------------------------------------- /daemon/md5.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef MdmMD5_H 20 | #define MdmMD5_H 21 | 22 | #include 23 | 24 | struct MdmMD5Context { 25 | guint32 buf[4]; 26 | guint32 bits[2]; 27 | unsigned char in[64]; 28 | }; 29 | 30 | void mdm_md5_init (struct MdmMD5Context *context); 31 | void mdm_md5_update (struct MdmMD5Context *context, unsigned char const *buf, 32 | unsigned len); 33 | void mdm_md5_final (unsigned char digest[16], struct MdmMD5Context *context); 34 | void mdm_md5_transform (guint32 buf[4], guint32 const in[16]); 35 | 36 | /* 37 | * This is needed to make RSAREF happy on some MS-DOS compilers. 38 | */ 39 | /* typedef struct mdm_md5_Context mdm_md5__CTX; */ 40 | 41 | #endif /* !MdmMD5_H */ 42 | -------------------------------------------------------------------------------- /daemon/mdm.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * MDM - The MDM Display Manager 4 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 5 | * 6 | * This program is free software; you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * This program is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | */ 20 | 21 | #ifndef MDM_H 22 | #define MDM_H 23 | 24 | #define MDM_MAX_PASS 256 /* Define a value for password length. Glibc 25 | * leaves MAX_PASS undefined. */ 26 | 27 | /* DO NOTE USE 1, that's used as error if x connection fails usually */ 28 | /* Note that there is no reason why these were a power of two, and note 29 | * that they have to fit in 256 */ 30 | /* These are the exit codes */ 31 | #define DISPLAY_REMANAGE 2 /* Restart display */ 32 | #define DISPLAY_ABORT 4 /* Houston, we have a problem */ 33 | #define DISPLAY_REBOOT 8 /* Rebewt */ 34 | #define DISPLAY_HALT 16 /* Halt */ 35 | #define DISPLAY_SUSPEND 17 /* Suspend (don't use, use the interrupt) */ 36 | #define DISPLAY_XFAILED 64 /* X failed */ 37 | #define DISPLAY_GREETERFAILED 65 /* greeter failed (crashed) */ 38 | #define DISPLAY_RESTARTGREETER 127 /* Restart greeter */ 39 | #define DISPLAY_RESTARTMDM 128 /* Restart MDM */ 40 | 41 | enum { 42 | DISPLAY_UNBORN /* Not yet started */, 43 | DISPLAY_ALIVE /* Yay! we're alive */, 44 | DISPLAY_DEAD /* Left for dead */, 45 | DISPLAY_CONFIG /* in process of being configured */ 46 | }; 47 | 48 | /* The dreaded miscellaneous category */ 49 | #define PIPE_SIZE 4096 50 | 51 | #define MDM_SESSION_AUTO "auto" 52 | 53 | #define MDM_STANDARD "Standard" 54 | 55 | #define MDM_RESPONSE_CANCEL "MDM_RESPONSE_CANCEL" 56 | 57 | /* If id == NULL, then get the first X server */ 58 | void mdm_final_cleanup (void); 59 | 60 | #endif /* MDM_H */ 61 | 62 | /* EOF */ 63 | -------------------------------------------------------------------------------- /daemon/mdm.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # A script so that 4 | # 1) we read the standard system env vars 5 | # 2) syadmins/integrators can add their own private options etc... 6 | 7 | test -f /etc/profile && . /etc/profile 8 | 9 | # Try to set LC_MESSAGES to LANG if neither LC_MESSAGES or LC_ALL is set. 10 | # This ensures that mdm can display in a system's default language if only 11 | # LANG is set. 12 | 13 | # Make sure LANG is set 14 | # 15 | if [ -z "$LANG" ] 16 | then 17 | if [ -f /etc/sysconfig/language ] 18 | then 19 | LANG=`. /etc/sysconfig/language; echo $RC_LANG` 20 | export LANG 21 | fi 22 | fi 23 | 24 | if [ -z "$LC_MESSAGES" ] 25 | then 26 | if [ -z "$LC_ALL" ] 27 | then 28 | LC_MESSAGES=$LANG 29 | export LC_MESSAGES 30 | fi 31 | fi 32 | 33 | exec @sbindir@/mdm-binary "$@" 34 | 35 | -------------------------------------------------------------------------------- /daemon/mdmconsolekit.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * Copyright (C) 2006 William Jon McCann 4 | * 5 | * This program is free software; you can redistribute it and/or modify 6 | * it under the terms of the GNU General Public License as published by 7 | * the Free Software Foundation; either version 2 of the License, or 8 | * (at your option) any later version. 9 | * 10 | * This program is distributed in the hope that it will be useful, 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | * GNU General Public License for more details. 14 | * 15 | * You should have received a copy of the GNU General Public License 16 | * along with this program; if not, write to the Free Software 17 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 18 | * 19 | */ 20 | 21 | 22 | #ifndef __MDM_CONSOLE_KIT_H 23 | #define __MDM_CONSOLE_KIT_H 24 | 25 | #include 26 | 27 | #include "display.h" /* for MdmDisplay */ 28 | 29 | G_BEGIN_DECLS 30 | 31 | char * open_ck_session (struct passwd *pwent, 32 | MdmDisplay *display, 33 | const char *session); 34 | void close_ck_session (const char *cookie); 35 | void unlock_ck_session (const char *user, 36 | const char *x11_display); 37 | 38 | G_END_DECLS 39 | 40 | #endif /* __MDM_CONSOLE_KIT_H */ 41 | -------------------------------------------------------------------------------- /daemon/server.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * MDM - The MDM Display Manager 4 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 5 | * 6 | * This program is free software; you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * This program is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | */ 20 | 21 | #ifndef MDM_SERVER_H 22 | #define MDM_SERVER_H 23 | 24 | #include "display.h" 25 | 26 | typedef struct _MdmXserver MdmXserver; 27 | 28 | struct _MdmXserver 29 | { 30 | char *id; 31 | char *name; 32 | char *command; 33 | gboolean flexible; 34 | gboolean choosable; /* not implemented yet */ 35 | gboolean chooser; /* instead of greeter, run chooser */ 36 | gboolean handled; 37 | int priority; 38 | }; 39 | 40 | /* These are the servstat values, also used as server 41 | * process exit codes */ 42 | #define SERVER_TIMEOUT 2 /* Server didn't start */ 43 | #define SERVER_DEAD 250 /* Server stopped */ 44 | #define SERVER_PENDING 251 /* Server started but not ready for connections yet */ 45 | #define SERVER_RUNNING 252 /* Server running and ready for connections */ 46 | #define SERVER_ABORT 253 /* Server failed badly. Suspending display. */ 47 | 48 | /* Wipe cookie files */ 49 | void mdm_server_wipe_cookies (MdmDisplay *disp); 50 | 51 | void mdm_server_whack_lockfile (MdmDisplay *disp); 52 | 53 | gboolean mdm_server_start (MdmDisplay *d, 54 | gboolean try_again_if_busy, 55 | gboolean treat_as_flexi, 56 | int min_flexi_disp, 57 | int flexi_retries); 58 | void mdm_server_stop (MdmDisplay *d); 59 | void mdm_server_whack_clients (Display *dsp); 60 | void mdm_server_checklog (MdmDisplay *disp); 61 | 62 | gboolean mdm_server_resolve_command_line (MdmDisplay *disp, 63 | gboolean resolve_flags, 64 | const char *vtarg, 65 | int *argc, 66 | char ***argv); 67 | MdmXserver * mdm_server_resolve (MdmDisplay *disp); 68 | 69 | 70 | 71 | #endif /* MDM_SERVER_H */ 72 | 73 | /* EOF */ 74 | -------------------------------------------------------------------------------- /daemon/slave.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef MDM_SLAVE_H 20 | #define MDM_SLAVE_H 21 | 22 | #include 23 | 24 | #include "mdm.h" 25 | #include "display.h" 26 | 27 | typedef enum { 28 | MDM_SESSION_RECORD_TYPE_LOGIN, 29 | MDM_SESSION_RECORD_TYPE_LOGOUT, 30 | MDM_SESSION_RECORD_TYPE_FAILED_ATTEMPT 31 | } MdmSessionRecordType; 32 | 33 | void mdm_slave_start (MdmDisplay *d); 34 | void mdm_slave_greeter_ctl_no_ret (char cmd, const char *str); 35 | char *mdm_slave_greeter_ctl (char cmd, const char *str); 36 | gboolean mdm_slave_greeter_check_interruption (void); 37 | gboolean mdm_slave_action_pending (void); 38 | 39 | void mdm_slave_send (const char *str, gboolean wait_for_ack); 40 | void mdm_slave_send_num (const char *opcode, long num); 41 | void mdm_slave_send_string (const char *opcode, const char *str); 42 | gboolean mdm_slave_final_cleanup (void); 43 | 44 | void mdm_slave_whack_temp_auth_file (void); 45 | 46 | gboolean mdm_slave_check_user_wants_to_log_in (const char *user); 47 | gboolean mdm_is_session_magic (const char *session_name); 48 | 49 | /* This is the slave child handler so that we can chain to it from elsewhere */ 50 | void mdm_slave_child_handler (int sig); 51 | void mdm_slave_write_utmp_wtmp_record (MdmDisplay *d, 52 | MdmSessionRecordType record_type, 53 | const gchar *username, 54 | GPid pid); 55 | gchar * mdm_slave_get_display_device (MdmDisplay *d); 56 | 57 | 58 | #endif /* MDM_SLAVE_H */ 59 | 60 | /* EOF */ 61 | 62 | -------------------------------------------------------------------------------- /daemon/verify.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef MDM_VERIFY_H 20 | #define MDM_VERIFY_H 21 | 22 | #include "mdm.h" 23 | #include "display.h" 24 | 25 | /* If username is NULL, we ask, if local is FALSE, don't start 26 | * the timed login timer */ 27 | gchar *mdm_verify_user (MdmDisplay *d, 28 | const char *username, 29 | gboolean allow_retry); 30 | void mdm_verify_cleanup (MdmDisplay *d); 31 | void mdm_verify_select_user (const char *user); 32 | 33 | /* used in pam */ 34 | gboolean mdm_verify_setup_env (MdmDisplay *d); 35 | gboolean mdm_verify_setup_user (MdmDisplay *d, 36 | const gchar *login, 37 | char **new_login); 38 | 39 | #endif /* MDM_VERIFY_H */ 40 | 41 | /* EOF */ 42 | -------------------------------------------------------------------------------- /data/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = icons -------------------------------------------------------------------------------- /data/icons/16x16/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = apps 2 | -------------------------------------------------------------------------------- /data/icons/16x16/apps/Makefile.am: -------------------------------------------------------------------------------- 1 | themedir = $(datadir)/icons/hicolor 2 | size = 16x16 3 | context = apps 4 | 5 | iconsdir = $(themedir)/$(size)/$(context) 6 | 7 | icons_DATA = \ 8 | mdmflexiserver.png \ 9 | mdmsetup.png 10 | 11 | 12 | noinst_DATA = \ 13 | mdmflexiserver.xcf.bz2 \ 14 | mdmsetup.svg 15 | 16 | EXTRA_DIST = \ 17 | $(icons_DATA) \ 18 | $(noinst_DATA) 19 | -------------------------------------------------------------------------------- /data/icons/16x16/apps/mdmflexiserver.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/16x16/apps/mdmflexiserver.png -------------------------------------------------------------------------------- /data/icons/16x16/apps/mdmflexiserver.xcf.bz2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/16x16/apps/mdmflexiserver.xcf.bz2 -------------------------------------------------------------------------------- /data/icons/16x16/apps/mdmsetup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/16x16/apps/mdmsetup.png -------------------------------------------------------------------------------- /data/icons/22x22/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = apps 2 | -------------------------------------------------------------------------------- /data/icons/22x22/apps/Makefile.am: -------------------------------------------------------------------------------- 1 | themedir = $(datadir)/icons/hicolor 2 | size = 22x22 3 | context = apps 4 | 5 | iconsdir = $(themedir)/$(size)/$(context) 6 | 7 | icons_DATA = \ 8 | mdmflexiserver.png \ 9 | mdmsetup.png 10 | 11 | 12 | noinst_DATA = \ 13 | mdmflexiserver.xcf.bz2 \ 14 | mdmsetup.xcf.bz2 15 | 16 | EXTRA_DIST = \ 17 | $(icons_DATA) \ 18 | $(noinst_DATA) 19 | -------------------------------------------------------------------------------- /data/icons/22x22/apps/mdmflexiserver.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/22x22/apps/mdmflexiserver.png -------------------------------------------------------------------------------- /data/icons/22x22/apps/mdmflexiserver.xcf.bz2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/22x22/apps/mdmflexiserver.xcf.bz2 -------------------------------------------------------------------------------- /data/icons/22x22/apps/mdmsetup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/22x22/apps/mdmsetup.png -------------------------------------------------------------------------------- /data/icons/22x22/apps/mdmsetup.xcf.bz2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/22x22/apps/mdmsetup.xcf.bz2 -------------------------------------------------------------------------------- /data/icons/24x24/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = apps 2 | -------------------------------------------------------------------------------- /data/icons/24x24/apps/Makefile.am: -------------------------------------------------------------------------------- 1 | themedir = $(datadir)/icons/hicolor 2 | size = 24x24 3 | context = apps 4 | 5 | iconsdir = $(themedir)/$(size)/$(context) 6 | 7 | icons_DATA = \ 8 | mdmflexiserver.png \ 9 | mdmsetup.png 10 | 11 | 12 | noinst_DATA = 13 | 14 | EXTRA_DIST = \ 15 | $(icons_DATA) \ 16 | $(noinst_DATA) 17 | -------------------------------------------------------------------------------- /data/icons/24x24/apps/mdmflexiserver.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/24x24/apps/mdmflexiserver.png -------------------------------------------------------------------------------- /data/icons/24x24/apps/mdmsetup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/24x24/apps/mdmsetup.png -------------------------------------------------------------------------------- /data/icons/32x32/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = apps 2 | -------------------------------------------------------------------------------- /data/icons/32x32/apps/Makefile.am: -------------------------------------------------------------------------------- 1 | themedir = $(datadir)/icons/hicolor 2 | size = 32x32 3 | context = apps 4 | 5 | iconsdir = $(themedir)/$(size)/$(context) 6 | 7 | icons_DATA = \ 8 | mdmflexiserver.png \ 9 | mdmsetup.png 10 | 11 | 12 | noinst_DATA = \ 13 | mdmflexiserver.svg \ 14 | mdmsetup.svg 15 | 16 | EXTRA_DIST = \ 17 | $(icons_DATA) \ 18 | $(noinst_DATA) 19 | -------------------------------------------------------------------------------- /data/icons/32x32/apps/mdmflexiserver.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/32x32/apps/mdmflexiserver.png -------------------------------------------------------------------------------- /data/icons/32x32/apps/mdmsetup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/32x32/apps/mdmsetup.png -------------------------------------------------------------------------------- /data/icons/48x48/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = apps 2 | -------------------------------------------------------------------------------- /data/icons/48x48/apps/Makefile.am: -------------------------------------------------------------------------------- 1 | themedir = $(datadir)/icons/hicolor 2 | size = 48x48 3 | context = apps 4 | 5 | iconsdir = $(themedir)/$(size)/$(context) 6 | 7 | icons_DATA = \ 8 | mdmflexiserver.png \ 9 | mdmsetup.png 10 | 11 | noinst_DATA = 12 | 13 | EXTRA_DIST = \ 14 | $(icons_DATA) \ 15 | $(noinst_DATA) 16 | -------------------------------------------------------------------------------- /data/icons/48x48/apps/mdmflexiserver.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/48x48/apps/mdmflexiserver.png -------------------------------------------------------------------------------- /data/icons/48x48/apps/mdmsetup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/data/icons/48x48/apps/mdmsetup.png -------------------------------------------------------------------------------- /data/icons/Makefile.am: -------------------------------------------------------------------------------- 1 | 2 | SUBDIRS = 16x16 22x22 24x24 32x32 48x48 scalable 3 | 4 | gtk_update_icon_cache = gtk-update-icon-cache -f -t $(datadir)/icons/hicolor 5 | 6 | install-data-hook: update-icon-cache 7 | uninstall-hook: update-icon-cache 8 | update-icon-cache: 9 | @-if test -z "$(DESTDIR)"; then \ 10 | echo "Updating Gtk icon cache."; \ 11 | $(gtk_update_icon_cache); \ 12 | else \ 13 | echo "*** Icon cache not updated. After (un)install, run this:"; \ 14 | echo "*** $(gtk_update_icon_cache)"; \ 15 | fi 16 | -------------------------------------------------------------------------------- /data/icons/README: -------------------------------------------------------------------------------- 1 | GNOME DISPLAY MANAGER ICONS 2 | 3 | This directory stores named (or themeable) icons for MDM designed to use the 4 | Tango style for appearance and Icon Naming Spec for names. 5 | 6 | By now the following icons are included: 7 | 8 | | Icon Name | Context | Role | 9 | |---------------------|--------------|------------------------------| 10 | | mdmsetup | apps | Window and launcher icon | 11 | | | | for mdmsetup | 12 | | | | (Login Window) application | 13 | |---------------------|--------------|------------------------------| 14 | | mdmflexiserver | apps | Launcher icon for | 15 | | | | mdmflexiserver (New Login) | 16 | | | | application | 17 | |_____________________|______________|______________________________| 18 | 19 | The installed icons are available in following formats/sizes: 20 | PNG - 16 x 16 pixels 21 | PNG - 22 x 22 pixels 22 | SNG - 32 x 32 pixels 23 | SVG - 48 x 48 pixels (canvas size and unit) 24 | 25 | Those additional sizes/formats are also available 26 | * PNG 24x24 pixels --> generated from 22x22 addind 1 pixel transparent border 27 | (see tango.freedesktop.org for details) 28 | * PNG 48x48 pixels --> generated from SVG, useful if the system needs to 29 | draw the icon at this exact size without rendering the 30 | svg one. 31 | 32 | When relevant, source files (GIMP's XCF or SVG) are available for future changes 33 | or other needs like derivative icons. Those files have the same name of the 34 | final icon, but of course different extension (for example, in 32x32/apps 35 | directory you have mdmsetup.png file, the installed one, and mdmsetup.svg file, 36 | the source one, used to generate the first and useful for future changes). 37 | 38 | If you need to provide a new named icon, you have to: 39 | * draw it at different sizes or search for a good artist 40 | * place them in proper directory, based on size and role. Note that only 41 | applications with "apps" context can be installed under "hicolor" theme. 42 | See http://live.gnome.org/ThemableAppSpecificIcons for details 43 | * include new icons to build, editing Makefile.am as follow: 44 | - add the icon to install to "icons_DATA" value in Makefile.am 45 | - add the source image, if any, to "noinst_DATA" value in Makefile.am 46 | - repeat for each size 47 | * if ensure, ask on gnome-themes-list@gnome.org 48 | -------------------------------------------------------------------------------- /data/icons/scalable/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = apps 2 | -------------------------------------------------------------------------------- /data/icons/scalable/apps/Makefile.am: -------------------------------------------------------------------------------- 1 | themedir = $(datadir)/icons/hicolor 2 | size = scalable 3 | context = apps 4 | 5 | iconsdir = $(themedir)/$(size)/$(context) 6 | 7 | icons_DATA = \ 8 | mdmflexiserver.svg \ 9 | mdmsetup.svg 10 | 11 | noinst_DATA = 12 | 13 | EXTRA_DIST = \ 14 | $(icons_DATA) \ 15 | $(noinst_DATA) 16 | -------------------------------------------------------------------------------- /debian/README.Debian: -------------------------------------------------------------------------------- 1 | MDM for Debian 2 | ============== 3 | 4 | "I get ugly fonts" 5 | ------------------ 6 | 7 | In the past, as a quick workaround, MDM imposed a 96 DPI settings by 8 | passing "-dpi 96" to the X server on startup. This is a bad idea has 9 | there's no reason to override standard DPI detection mechanisms for all 10 | screens which might or might not be 96 DPI screens. 11 | 12 | DPI should be computed automatically based on the information on your 13 | screen that Xorg gets; ideally, Xorg would get the DPI right, but you 14 | can help Xorg by configuring it with your exact screen properties. 15 | If it's too complicated, you may still get the old behavior by 16 | setting: 17 | [server-Standard] 18 | command=/usr/bin/X -dpi 96 -audit 0 19 | in your mdm.conf. See the defaults.conf file to see how it's configured 20 | by default. 21 | 22 | 23 | Face Browser 24 | ------------ 25 | 26 | If you enable the face browser in /etc/mdm/mdm.conf, mdm will look 27 | for face files (any gtk+-supported image format; see 28 | /usr/lib/gtk-2.0/2.2.0/loaders or similar for a list of installed 29 | loaders) in ~/.gnome2/photo or /, 30 | whichever is found first. Note that there is no filename extension 31 | for either location. greeter/GlobalFaceDir is set in 32 | /etc/mdm/mdm.conf 33 | 34 | 35 | Screen Saver 36 | ------------ 37 | 38 | If you want a screensaver running with the greeter, you should use the 39 | BackgroundProgram option in /etc/mdm/mdm.conf, or make sure if you start 40 | a gtk program in the PreSession script, that it is started with the mdm 41 | userid, and not root 42 | 43 | 44 | Secure System Menu 45 | ------------------ 46 | 47 | Debian versions 2.4.1.6-1 through 2.8.0.6-2 featured a 48 | "SecureSystemMenu" option in mdm.conf, that would require the root 49 | password to be entered for the reboot, shutdown, and suspend options 50 | on the system menu. Some time after MDM 2.4.1.6 was released, other parts 51 | of the GNOME desktop began talking to the mdm daemon, so that one could 52 | reboot or shutdown without having to return to the mdm login screen. These 53 | programs didn't support this option, and would have needed changes to do so. 54 | With mdm 2.13.0.10, the patch broke and would need a lot of debugging to get 55 | working again, and other programs talking to the daemon (cinnamon-session) would 56 | still have to be patched to support the option, or mdm patched to ignore 57 | them when they don't do authentication. If anyone really wants this 58 | functionality back, I suggest working with upstream so it can be integrated 59 | into all the parts of the GNOME desktop that it would now impact. 60 | 61 | 62 | Translation of the Debconf templates 63 | ------------------------------------ 64 | 65 | A note to translators about the debconf templates -- translations 66 | should be sent to the xdm package. I don't use gettext-based 67 | templates in the source, because I sync to the ones in the xdm 68 | package, and don't have any that are not shared. 69 | 70 | -------------------------------------------------------------------------------- /debian/compat: -------------------------------------------------------------------------------- 1 | 5 2 | -------------------------------------------------------------------------------- /debian/control: -------------------------------------------------------------------------------- 1 | Source: mdm 2 | Section: gnome 3 | Priority: optional 4 | Maintainer: Clement Lefebvre 5 | Build-Depends: libpam0g-dev (>= 0.99.7.1), 6 | libdbus-glib-1-dev (>= 0.78), 7 | libglib2.0-dev (>= 2.37.3), 8 | libgdk-pixbuf2.0-dev (>= 2.22.0), 9 | libgtk2.0-dev (>= 2.24.0), 10 | libpango1.0-dev (>= 1.14.0), 11 | libglade2-dev (>= 1:1.99.2), 12 | libgnomecanvas2-dev (>= 2.11.1), 13 | librsvg2-dev (>= 2.14.4), 14 | libxml2-dev (>= 2.7.4), 15 | libart-2.0-dev (>= 2.3.17), 16 | libwrap0-dev, 17 | debhelper (>= 5), 18 | gettext, 19 | intltool (>= 0.35.0), 20 | libselinux1-dev [linux-any], 21 | libattr1-dev, 22 | x11proto-core-dev, 23 | x11proto-input-dev, 24 | libxau-dev, 25 | libxt-dev, 26 | libxdmcp-dev, 27 | libxinerama-dev, 28 | libdmx-dev, 29 | sharutils, 30 | gnome-pkg-tools, 31 | quilt, 32 | zenity, 33 | libpopt-dev, 34 | xserver-xorg, 35 | libwebkitgtk-dev (>= 1.3.10), 36 | gnome-common, 37 | yelp-tools, 38 | libxml2-utils, 39 | dh-systemd (>= 1.5) 40 | Standards-Version: 3.9.5 41 | 42 | Package: mdm 43 | Architecture: any 44 | Depends: ${shlibs:Depends}, 45 | ${misc:Depends}, 46 | adduser, 47 | libpam-modules (>= 0.99.7.1), 48 | libpam-runtime (>= 0.99.7.1), 49 | cinnamon-session | gnome-session | x-session-manager | x-window-manager | x-terminal-emulator, 50 | gksu (>= 1.0.7), 51 | lsb-base (>= 3.2-14), 52 | librsvg2-common, 53 | gir1.2-webkit-3.0, 54 | gir1.2-gtk-3.0, 55 | python, 56 | mdm-themes 57 | Recommends: whiptail | dialog, 58 | zenity, 59 | xserver-xorg 60 | Suggests: locales, 61 | pm-utils, 62 | libpam-gnome-keyring 63 | Provides: x-display-manager 64 | Conflicts: fast-user-switch-applet (<< 2.17.4), 65 | gnome-session (<< 2.19.2), 66 | gnome-panel (<< 2.19.2), 67 | gnome-screensaver (<< 2.17.7), 68 | gdm, 69 | gdm3 70 | Description: MDM Display Manager 71 | MDM stands for MDM Display Manager (not Mint Display Manager and not MATE Display Manager) :) 72 | . 73 | It provides your system with a nice login screen which is easy to use, to configure and to theme. 74 | -------------------------------------------------------------------------------- /debian/copyright: -------------------------------------------------------------------------------- 1 | This package originally Debianised by Steve Haslam , 2 | 10th March 1999. It was maintained by Raphaël Hertzog 3 | until December 1999. It was maintained by Ryan Murray 4 | until May 2007. It is now maintained by the GNOME Team. 5 | 6 | Copyright (C) 1998, 1999 Martin Kasper Petersen 7 | 8 | It was downloaded from 9 | 10 | License: 11 | 12 | This package is free software; you can redistribute it and/or modify 13 | it under the terms of the GNU General Public License as published by 14 | the Free Software Foundation; either version 2 of the License, or 15 | (at your option) any later version. 16 | 17 | This package is distributed in the hope that it will be useful, 18 | but WITHOUT ANY WARRANTY; without even the implied warranty of 19 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 20 | GNU General Public License for more details. 21 | 22 | You should have received a copy of the GNU General Public License 23 | along with this package; if not, write to the Free Software 24 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 25 | 26 | On Debian systems, the complete text of the GNU General 27 | Public License can be found in `/usr/share/common-licenses/GPL'. 28 | -------------------------------------------------------------------------------- /debian/docs: -------------------------------------------------------------------------------- 1 | AUTHORS 2 | NEWS 3 | README 4 | README.install 5 | TODO 6 | -------------------------------------------------------------------------------- /debian/extract-locales: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl 2 | # 3 | # Takes a list of locales like /usr/share/i18n/SUPPORTED on standard input 4 | # or on the command line, and writes out a locale.alias format file for all 5 | # listed locales on standard output. 6 | # 7 | my %locales; 8 | # whether or not locales should always specify charset or not. 9 | my $always_charset = 0; 10 | 11 | chdir("/usr/share/i18n/locales") or die "can't find /usr/share/i18n/locales"; 12 | while (<>) { 13 | my $language; 14 | my $territory; 15 | chomp; 16 | @line = split / /; 17 | ($file = $line[0]) =~ s/\..*$//; 18 | open F, $file or die "can't open $file\n"; 19 | while () { 20 | chomp; 21 | $title = $1 if /^title\s+"(.*)"/; 22 | $language = $1 if /^language\s+"(.*)"/; 23 | $territory = $1 if /^territory\s+"(.*)"/; 24 | last if /^END LC_IDENTIFICATION/; 25 | } 26 | close F; 27 | 28 | if ($always_charset and $line[1] and $line[0] =~ s/(\@.*)$//) { 29 | my $suffix = $1; 30 | $line[1] =~ s/$/$suffix/; 31 | } 32 | 33 | $language =~ s/ /_/g; 34 | $territory =~ s/ /_/g; 35 | if (!$always_charset or $line[0] =~ /\./) { 36 | print "$language($territory)\t$line[0]\n"; 37 | } else { 38 | print "$language($territory)\t$line[0].$line[1]\n"; 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /debian/insserv.conf.d/mdm: -------------------------------------------------------------------------------- 1 | $x-display-manager mdm 2 | -------------------------------------------------------------------------------- /debian/mdm-autologin.pam: -------------------------------------------------------------------------------- 1 | #%PAM-1.0 2 | auth requisite pam_nologin.so 3 | auth required pam_permit.so 4 | @include common-account 5 | session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so close 6 | session required pam_limits.so 7 | @include common-session 8 | session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so open 9 | session required pam_env.so readenv=1 10 | session required pam_env.so readenv=1 user_readenv=1 envfile=/etc/default/locale 11 | @include common-password 12 | -------------------------------------------------------------------------------- /debian/mdm.8.pod: -------------------------------------------------------------------------------- 1 | =head1 NAME 2 | 3 | mdm - MDM Display Manager 4 | 5 | =head1 SYNOPSIS 6 | 7 | mdm 8 | 9 | =head1 DESCRIPTION 10 | 11 | B is the equivalent of xdm(1x) or wdm(1x), but uses the GNOME 12 | libraries to provide a GNOME look-and-feel. It provides the GNOME 13 | equivalent of a "login:" prompt. 14 | 15 | B reads F for its configuration. For each 16 | local display, mdm starts an X server and runs mdmlogin(8x) on that 17 | display. The main mdm process also listens for XDMCP requests from 18 | remote displays. These requests can either be direct, causing B 19 | to start a mdmlogin(8x) on the remote display, or indirect, causing 20 | a mdmchooser(8x) to be opened. 21 | 22 | When managing a display, B attempts to execute 23 | FI, or F if that does 24 | not exist. When a user logs in, B first attempts 25 | FI (or F), 26 | and then one of the sessions in F. When the session 27 | has completed, B attempts to run 28 | FI, or 29 | FI. Of all these files, only the 30 | F one is required to exist. 31 | 32 | B maintains information about the displays it is managing in 33 | F. This includes xauth information, so this directory 34 | is not readable to normal users. 35 | 36 | B uses PAM to perform authentication using the config file 37 | F. 38 | 39 | =head1 AUTHOR 40 | 41 | Martin Kasper Petersen 42 | 43 | This manual page written by Steve Haslam for 44 | Debian GNU/Linux. Updated by Raphaël Hertzog . 45 | Updated by Ryan Murray . 46 | 47 | =cut 48 | -------------------------------------------------------------------------------- /debian/mdm.config: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Debian mdm package configuration script 3 | # Copyright 2000-2001 Branden Robinson. 4 | # Licensed under the GNU General Public License, version 2. See the file 5 | # /usr/share/common-licenses/GPL or . 6 | 7 | set -e 8 | 9 | # source debconf library 10 | . /usr/share/debconf/confmodule 11 | 12 | THIS_PACKAGE=mdm 13 | DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager 14 | 15 | # update old mdm/daemon_name path 16 | db_set mdm/daemon_name /usr/sbin/mdm 17 | 18 | # set default display manager 19 | OLD_DEFAULT= 20 | 21 | db_metaget shared/default-x-display-manager owners 22 | OWNERS="$RET" 23 | db_metaget shared/default-x-display-manager choices 24 | CHOICES="$RET" 25 | 26 | if [ "$OWNERS" != "$CHOICES" ]; then 27 | db_subst shared/default-x-display-manager choices $OWNERS 28 | db_fset shared/default-x-display-manager seen false 29 | fi 30 | 31 | if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE" ]; then 32 | OLD_DAEMON="$(grep -v '^[[:space:]]*#' \ 33 | "$DEFAULT_DISPLAY_MANAGER_FILE" | 34 | head -n 1)" 35 | OLD_DEFAULT="$(basename $OLD_DAEMON 2>/dev/null || true)" 36 | if [ -n "$OLD_DEFAULT" ]; then 37 | db_set shared/default-x-display-manager "$OLD_DEFAULT" 38 | fi 39 | else 40 | if db_get shared/default-x-display-manager; then 41 | OLD_DEFAULT="$RET" 42 | fi 43 | fi 44 | 45 | db_input high shared/default-x-display-manager || true 46 | db_go 47 | 48 | # using this display manager? 49 | db_get shared/default-x-display-manager 50 | CURRENT_DEFAULT="$RET" 51 | # remove the default display manager file if we're going to change it 52 | if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE" ]; then 53 | if [ "$OLD_DEFAULT" != "$CURRENT_DEFAULT" ] || 54 | [ "$OLD_DAEMON" = /usr/bin/mdm ]; then 55 | mv $DEFAULT_DISPLAY_MANAGER_FILE $DEFAULT_DISPLAY_MANAGER_FILE.dpkg-tmp 56 | fi 57 | fi 58 | 59 | exit 0 60 | -------------------------------------------------------------------------------- /debian/mdm.dirs: -------------------------------------------------------------------------------- 1 | var/log/mdm 2 | var/lib/mdm 3 | usr/share/faces 4 | usr/share/hosts 5 | usr/share/sounds 6 | etc/pam.d 7 | etc/X11 8 | etc/mdm/Init 9 | etc/mdm/PreSession 10 | etc/mdm/PostSession 11 | usr/share/mdm/themes 12 | -------------------------------------------------------------------------------- /debian/mdm.init: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | ### BEGIN INIT INFO 3 | # Provides: mdm 4 | # Should-Start: console-screen kbd acpid dbus hal network-manager 5 | # Required-Start: $local_fs $remote_fs x11-common 6 | # Required-Stop: $local_fs $remote_fs 7 | # Default-Start: 2 3 4 5 8 | # Default-Stop: 0 1 6 9 | # Short-Description: MDM Display Manager 10 | # Description: Debian init script for the MDM Display Manager 11 | ### END INIT INFO 12 | # 13 | # Author: Ryan Murray 14 | # 15 | set -e 16 | 17 | PATH=/sbin:/bin:/usr/sbin:/usr/bin 18 | DAEMON=/usr/sbin/mdm 19 | 20 | test -x $DAEMON || exit 0 21 | 22 | if [ -r /etc/default/locale ]; then 23 | . /etc/default/locale 24 | export LANG LANGUAGE 25 | fi 26 | 27 | . /lib/lsb/init-functions 28 | 29 | # To start mdm even if it is not the default display manager, change 30 | # HEED_DEFAULT_DISPLAY_MANAGER to "false." 31 | HEED_DEFAULT_DISPLAY_MANAGER=true 32 | DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager 33 | 34 | case "$1" in 35 | start) 36 | CONFIGURED_DAEMON=$(basename "$(cat $DEFAULT_DISPLAY_MANAGER_FILE 2> /dev/null)") 37 | if grep -wqs text /proc/cmdline; then 38 | log_warning_msg "Not starting MDM Display Manager; found 'text' in kernel commandline." 39 | elif [ -e "$DEFAULT_DISPLAY_MANAGER_FILE" ] && \ 40 | [ "$HEED_DEFAULT_DISPLAY_MANAGER" = "true" ] && \ 41 | [ "$CONFIGURED_DAEMON" != mdm ] ; then 42 | log_action_msg "Not starting MDM Display Manager; it is not the default display manager" 43 | else 44 | log_daemon_msg "Starting MDM Display Manager" "mdm" 45 | start_daemon $DAEMON 46 | log_end_msg $? 47 | fi 48 | ;; 49 | stop) 50 | log_daemon_msg "Stopping MDM Display Manager" "mdm" 51 | set +e 52 | start-stop-daemon --stop --quiet --pidfile /var/run/mdm.pid \ 53 | --name mdm --retry 5 54 | set -e 55 | log_end_msg $? 56 | ;; 57 | reload) 58 | log_daemon_msg "Scheduling reload of MDM Display Manager configuration" "mdm" 59 | set +e 60 | start-stop-daemon --stop --signal USR1 --quiet --pidfile \ 61 | /var/run/mdm.pid --name mdm 62 | set -e 63 | log_end_msg $? 64 | ;; 65 | status) 66 | status_of_proc -p "$PIDFILE" "$DAEMON" mdm && exit 0 || exit $? 67 | ;; 68 | restart|force-reload) 69 | $0 stop 70 | $0 start 71 | ;; 72 | *) 73 | echo "Usage: /etc/init.d/mdm {start|stop|restart|reload|force-reload|status}" 74 | exit 1 75 | ;; 76 | esac 77 | 78 | exit 0 79 | -------------------------------------------------------------------------------- /debian/mdm.install: -------------------------------------------------------------------------------- 1 | debian/*.xpm usr/share/pixmaps/ 2 | debian/locale.conf etc/mdm 3 | debian/Xsession etc/mdm 4 | debian/insserv.conf.d etc 5 | debian/tmp/etc/dm 6 | debian/tmp/etc/mdm/Init 7 | debian/tmp/etc/mdm/SuperInit 8 | debian/tmp/etc/mdm/SuperPost 9 | debian/tmp/etc/mdm/PreSession 10 | debian/tmp/etc/mdm/PostSession 11 | debian/tmp/etc/mdm/mdm.conf 12 | debian/tmp/etc/mdm/XKeepsCrashing 13 | debian/tmp/etc/mdm/PostLogin 14 | debian/tmp/etc/mdm/modules 15 | debian/tmp/etc/X11/Xsession.d 16 | debian/tmp/usr/bin 17 | debian/tmp/usr/lib/mdm 18 | debian/tmp/usr/lib/gtk-2.0/modules/*.so 19 | debian/tmp/usr/sbin/mdmsetup 20 | debian/tmp/usr/sbin/mdm-binary 21 | debian/tmp/usr/share/mdm/applications 22 | debian/tmp/usr/share/mdm/themes 23 | debian/tmp/usr/share/mdm/defaults.conf 24 | debian/tmp/usr/share/mdm/BuiltInSessions 25 | debian/tmp/usr/share/mdm/*.glade 26 | debian/tmp/usr/share/mdm/locale 27 | debian/tmp/usr/share/mdm/recovery 28 | debian/tmp/usr/share/mdm/gtk-preview.png 29 | debian/tmp/usr/share/icons/hicolor 30 | debian/tmp/usr/share/locale 31 | debian/tmp/usr/share/help 32 | debian/tmp/usr/share/pixmaps 33 | -------------------------------------------------------------------------------- /debian/mdm.manpages: -------------------------------------------------------------------------------- 1 | debian/*.[0-9] 2 | -------------------------------------------------------------------------------- /debian/mdm.menu: -------------------------------------------------------------------------------- 1 | ?package(mdm):needs="X11" section="Applications/System/Administration" \ 2 | title="MDM flexiserver" command="mdmflexiserver"\ 3 | hints="Display Manager"\ 4 | icon="/usr/share/pixmaps/mdm.xpm"\ 5 | longtitle="New MDM Session" 6 | ?package(mdm):needs="X11" section="Applications/System/Administration" \ 7 | title="MDM Setup" command="su-to-root -X -p root -c /usr/sbin/mdmsetup"\ 8 | hints="Display Manager"\ 9 | icon="/usr/share/pixmaps/mdm.xpm"\ 10 | longtitle="MDM Setup" 11 | -------------------------------------------------------------------------------- /debian/mdm.pam: -------------------------------------------------------------------------------- 1 | #%PAM-1.0 2 | auth requisite pam_nologin.so 3 | auth sufficient pam_succeed_if.so user ingroup nopasswdlogin 4 | @include common-auth 5 | auth optional pam_gnome_keyring.so 6 | auth optional pam_kwallet.so 7 | @include common-account 8 | session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so close 9 | session required pam_limits.so 10 | @include common-session 11 | session [success=ok ignore=ignore module_unknown=ignore default=bad] pam_selinux.so open 12 | session optional pam_gnome_keyring.so auto_start 13 | session optional pam_kwallet.so auto_start 14 | session required pam_env.so readenv=1 15 | session required pam_env.so readenv=1 user_readenv=1 envfile=/etc/default/locale 16 | @include common-password 17 | -------------------------------------------------------------------------------- /debian/mdm.postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -e 4 | 5 | . /usr/share/debconf/confmodule 6 | 7 | THIS_PACKAGE=mdm 8 | DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager 9 | 10 | # creating mdm group if it isn't already there 11 | if ! getent group mdm >/dev/null; then 12 | addgroup --system mdm 13 | fi 14 | 15 | # creating mdm user if it isn't already there 16 | if ! getent passwd mdm >/dev/null; then 17 | adduser --system --ingroup mdm --home /var/lib/mdm mdm 18 | usermod -c "MDM Display Manager" mdm 19 | usermod -d "/var/lib/mdm" mdm 20 | usermod -g "mdm" mdm 21 | usermod -s "/bin/false" mdm 22 | fi 23 | 24 | # Creating the nopasswdlogin group if it isn't already there. 25 | # Needed for passwordless logins, working thanks to MDM's PAM policy. 26 | if ! getent group nopasswdlogin >/dev/null; then 27 | addgroup --system nopasswdlogin 28 | fi 29 | 30 | if [ -d /var/lib/mdm ]; then 31 | chown -R mdm:mdm /var/lib/mdm 32 | chmod 0750 /var/lib/mdm 33 | fi 34 | 35 | # debconf is not a registry, so we only fiddle with the default file if it 36 | # does not exist 37 | if [ ! -e $DEFAULT_DISPLAY_MANAGER_FILE ]; then 38 | if db_get shared/default-x-display-manager; then 39 | # workaround debconf passthru bug (#379198) 40 | if [ -z "$RET" ]; then 41 | $RET="$THIS_PACKAGE" 42 | fi 43 | if [ "$THIS_PACKAGE" != "$RET" ]; then 44 | echo "Please be sure to run \"dpkg --configure $RET\"." 45 | fi 46 | if db_get "$RET"/daemon_name; then 47 | echo "$RET" > $DEFAULT_DISPLAY_MANAGER_FILE 48 | fi 49 | fi 50 | fi 51 | 52 | # remove the displaced old default display manager file if it exists 53 | if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE.dpkg-tmp" ]; then 54 | rm "$DEFAULT_DISPLAY_MANAGER_FILE.dpkg-tmp" 55 | fi 56 | 57 | # debconf hangs if mdm gets started below without this 58 | db_stop || true 59 | 60 | if [ -d /usr/lib/upstart ]; then 61 | echo "Upstart detected. Removing rc.d links." 62 | update-rc.d -f mdm remove 63 | else 64 | echo "Init.d detected. Setting up rc.d links." 65 | update-rc.d -f mdm remove 66 | update-rc.d -f mdm defaults 30 01 >/dev/null 2>&1 67 | fi 68 | 69 | if [ ! -e /usr/bin/gdmflexiserver ]; then 70 | echo "Linking /usr/bin/gdmflexiserver to /usr/bin/mdmflexiserver" 71 | ln -s /usr/bin/mdmflexiserver /usr/bin/gdmflexiserver 72 | fi 73 | 74 | #DEBHELPER# 75 | 76 | exit 0 77 | -------------------------------------------------------------------------------- /debian/mdm.postrm: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager 4 | 5 | if [ "$1" = "abort-install" ] || [ "$1" = "abort-upgrade" ]; then 6 | if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE.dpkg-tmp" ]; then 7 | mv "$DEFAULT_DISPLAY_MANAGER_FILE.dpkg-tmp" "$DEFAULT_DISPLAY_MANAGER_FILE" 8 | fi 9 | fi 10 | 11 | if [ "$1" = "purge" ] ; then 12 | update-rc.d mdm remove >/dev/null 13 | rm -f /etc/default/mdm 14 | if [ -d /etc/mdm ]; then 15 | rmdir --ignore-fail-on-non-empty /etc/mdm/Init /etc/mdm/PreSession /etc/mdm/PostSession /etc/mdm/PostLogin /etc/mdm/Sessions /etc/mdm 2>/dev/null 16 | fi 17 | if [ -d /var/lib/mdm ]; then 18 | rm -r /var/lib/mdm 19 | fi 20 | if [ -d /var/log/mdm ]; then 21 | rm -r /var/log/mdm 22 | fi 23 | if getent passwd mdm >/dev/null; then 24 | if [ -x /usr/sbin/deluser ]; then 25 | deluser --system mdm 26 | fi 27 | fi 28 | if getent group mdm >/dev/null; then 29 | if [ -x /usr/sbin/delgroup ]; then 30 | delgroup --system mdm 31 | fi 32 | fi 33 | fi 34 | #DEBHELPER# 35 | exit 0 36 | -------------------------------------------------------------------------------- /debian/mdm.prerm: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | # Debian mdm package pre-removal script 3 | # Copyright 2001 Branden Robinson. 4 | # Licensed under the GNU General Public License, version 2. See the file 5 | # /usr/share/common-licenses/GPL or . 6 | # Acknowlegements to Stephen Early, Mark Eichin, and Manoj Srivastava. 7 | 8 | set -e 9 | 10 | THIS_PACKAGE=mdm 11 | DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager 12 | 13 | if [ "$1" = "remove" -o "$1" = "deconfigure" ]; then 14 | if [ -e /usr/share/debconf/confmodule ]; then 15 | . /usr/share/debconf/confmodule 16 | # disown this question 17 | db_unregister shared/default-x-display-manager || true 18 | # does the question still exist? 19 | if db_get shared/default-x-display-manager; then 20 | db_metaget shared/default-x-display-manager owners 21 | db_subst shared/default-x-display-manager choices "$RET" 22 | db_get shared/default-x-display-manager 23 | # are we removing the currently selected display manager? 24 | if [ "$THIS_PACKAGE" = "$RET" ]; then 25 | if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE" ]; then 26 | db_get "$RET"/daemon_name 27 | if [ "$(cat $DEFAULT_DISPLAY_MANAGER_FILE)" = "$RET" ]; then 28 | rm "$DEFAULT_DISPLAY_MANAGER_FILE" 29 | fi 30 | fi 31 | # ask the user to choose a new default 32 | db_fset shared/default-x-display-manager seen false 33 | db_input critical shared/default-x-display-manager || true 34 | db_go 35 | # if the display manager file doesn't exist, write it with the path 36 | # to the new default display manager 37 | if [ ! -e $DEFAULT_DISPLAY_MANAGER_FILE ]; then 38 | db_get shared/default-x-display-manager 39 | echo "Please be sure to run \"dpkg-reconfigure $RET\"." 40 | db_get "$RET"/daemon_name 41 | echo "$RET" > "$DEFAULT_DISPLAY_MANAGER_FILE" 42 | fi 43 | fi 44 | fi 45 | fi 46 | fi 47 | 48 | if [ "$1" = "remove" ]; then 49 | if [ -x /etc/init.d/mdm ]; then 50 | nostop= 51 | for hostname in "" "localhost" "$(hostname)" "$(hostname -f)"; do 52 | if echo $DISPLAY | grep -q "^$hostname:0.*"; then 53 | nostop=yes 54 | fi 55 | done 56 | if [ -z $nostop ]; then 57 | invoke-rc.d mdm stop 58 | fi 59 | fi 60 | fi 61 | 62 | 63 | if [ -L /usr/bin/gdmflexiserver ]; then 64 | echo "Removing link /usr/bin/gdmflexiserver" 65 | rm -f /usr/bin/gdmflexiserver 66 | fi 67 | 68 | #DEBHELPER# 69 | 70 | exit 0 71 | -------------------------------------------------------------------------------- /debian/mdm.service: -------------------------------------------------------------------------------- 1 | [Unit] 2 | Description=MDM Display Manager 3 | Documentation=man:mdm(1) 4 | Conflicts=getty@tty7.service 5 | After=systemd-user-sessions.service getty@tty7.service plymouth-quit.service 6 | 7 | [Service] 8 | ExecStart=/usr/sbin/mdm --nodaemon 9 | ExecReload=/usr/sbin/mdm-restart 10 | ExecStop=/usr/sbin/mdm-stop 11 | StandardOutput=journal 12 | Restart=always 13 | RestartSec=1s 14 | TimeoutStopSec=5s 15 | IgnoreSIGPIPE=no 16 | 17 | [Install] 18 | WantedBy=graphical.target 19 | Alias=display-manager.service 20 | 21 | -------------------------------------------------------------------------------- /debian/mdm.upstart: -------------------------------------------------------------------------------- 1 | # mdm - MDM Display Manager 2 | # 3 | # The display manager service manages the X servers running on the 4 | # system, providing login and auto-login services 5 | 6 | description "MDM Display Manager" 7 | author "Linux Mint " 8 | 9 | start on ((filesystem 10 | and runlevel [!06] 11 | and started dbus 12 | and plymouth-ready) 13 | or runlevel PREVLEVEL=S) 14 | 15 | stop on runlevel [016] 16 | 17 | emits login-session-start 18 | emits desktop-session-start 19 | emits desktop-shutdown 20 | 21 | script 22 | if [ -n "$UPSTART_EVENTS" ] 23 | then 24 | # Check kernel command-line for inhibitors, unless we are being called 25 | # manually 26 | for ARG in $(cat /proc/cmdline); do 27 | if [ "$ARG" = "text" ]; then 28 | plymouth quit || : 29 | stop 30 | exit 0 31 | fi 32 | done 33 | 34 | if [ -f /etc/X11/default-display-manager ]; then 35 | [ "$(cat /etc/X11/default-display-manager 2>/dev/null)" = "/usr/sbin/mdm" ] || { stop; exit 0; } 36 | else 37 | type lightdm >/dev/null 2>&1 && { stop; exit 0; } || true 38 | fi 39 | 40 | if [ "$RUNLEVEL" = S -o "$RUNLEVEL" = 1 ] 41 | then 42 | # Single-user mode 43 | plymouth quit || : 44 | exit 0 45 | fi 46 | fi 47 | 48 | # Ignore errors temporarily (we don't want to fail if something in the environment isn't set properly 49 | set +e 50 | 51 | test -f /etc/profile && . /etc/profile 52 | 53 | if [ -r /etc/default/locale ]; then 54 | . /etc/default/locale 55 | export LANG LANGUAGE LC_MESSAGES LC_ALL 56 | elif [ -r /etc/environment ]; then 57 | . /etc/environment 58 | export LANG LANGUAGE LC_MESSAGES LC_ALL 59 | fi 60 | 61 | set -e 62 | 63 | exec mdm 64 | end script 65 | 66 | post-stop script 67 | if [ "$UPSTART_STOP_EVENTS" = runlevel ]; then 68 | initctl emit desktop-shutdown 69 | fi 70 | end script 71 | -------------------------------------------------------------------------------- /debian/mdmflexiserver.1.pod: -------------------------------------------------------------------------------- 1 | =head1 NAME 2 | 3 | mdmflexiserver - start a MDM session using the MDM I mechanism 4 | 5 | =head1 SYNOPSIS 6 | 7 | B GNOME options mdmflexiserver options 8 | 9 | =head1 DESCRIPTION 10 | 11 | The I mechanism allows to run MDM sessions on demand. 12 | 13 | =head1 OPTIONS 14 | 15 | In addition to the common Gtk and GNOME options, B accepts the 16 | following options: 17 | 18 | =over 4 19 | 20 | =item B<-c> I, B<--command>=I 21 | 22 | Send the specified protocol command to mdm 23 | 24 | =item B<-l>, B<--no-lock> 25 | 26 | Do not lock current screen 27 | 28 | =item B<-d>, B<--debug> 29 | 30 | Debugging output 31 | 32 | =item B<-a>, B<--authenticate> 33 | 34 | Authenticate before running B<--command> 35 | 36 | =back 37 | 38 | =head1 SEE ALSO 39 | 40 | mdm(8) 41 | 42 | =head1 AUTHORS 43 | 44 | B is part of the B software package. This manpage was written by Yann Dirson for 45 | the Debian system, but may be used by others. 46 | -------------------------------------------------------------------------------- /debian/mdmlogin.8.pod: -------------------------------------------------------------------------------- 1 | =head1 NAME 2 | 3 | mdmlogin - MDM Display Manager greeting window 4 | 5 | =head1 SYNOPSIS 6 | 7 | mdmlogin 8 | 9 | =head1 DESCRIPTION 10 | 11 | B is invoked by mdm(8). It displays a GNOME login window 12 | and obtains a login/password combination from the user. This is then 13 | sent to the controlling B process for verification. 14 | 15 | =head1 SEE ALSO 16 | 17 | mdm(8) 18 | 19 | =head1 AUTHOR 20 | 21 | Martin Kasper Petersen 22 | 23 | This manual page written by Steve Haslam for 24 | Debian GNU/Linux. Updated by Raphaël Hertzog . 25 | Updated by Ryan Murray . 26 | 27 | =cut 28 | -------------------------------------------------------------------------------- /debian/source/format: -------------------------------------------------------------------------------- 1 | 3.0 (native) 2 | -------------------------------------------------------------------------------- /debian/watch: -------------------------------------------------------------------------------- 1 | version=2 2 | http://ftp.gnome.org/pub/gnome/sources/mdm/2.20/mdm-([\d\.]+)\.tar\.gz debian uupdate 3 | -------------------------------------------------------------------------------- /docs/C/legal.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | Permission is granted to copy, distribute and/or modify this 4 | document under the terms of the GNU Free Documentation 5 | License (GFDL), Version 1.1 or any later version published 6 | by the Free Software Foundation with no Invariant Sections, 7 | no Front-Cover Texts, and no Back-Cover Texts. You can find 8 | a copy of the GFDL at this link or in the file COPYING-DOCS 10 | distributed with this manual. 11 | 12 | 13 | 14 | Many of the names used by companies to distinguish their 15 | products and services are claimed as trademarks. Where those 16 | names appear in any documentation the names are in capital 17 | letters or initial capital letters. 18 | 19 | 20 | 21 | DOCUMENT AND MODIFIED VERSIONS OF THE DOCUMENT ARE PROVIDED 22 | UNDER THE TERMS OF THE GNU FREE DOCUMENTATION LICENSE 23 | WITH THE FURTHER UNDERSTANDING THAT: 24 | 25 | 26 | 27 | DOCUMENT IS PROVIDED ON AN "AS IS" BASIS, 28 | WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR 29 | IMPLIED, INCLUDING, WITHOUT LIMITATION, WARRANTIES 30 | THAT THE DOCUMENT OR MODIFIED VERSION OF THE 31 | DOCUMENT IS FREE OF DEFECTS MERCHANTABLE, FIT FOR 32 | A PARTICULAR PURPOSE OR NON-INFRINGING. THE ENTIRE 33 | RISK AS TO THE QUALITY, ACCURACY, AND PERFORMANCE 34 | OF THE DOCUMENT OR MODIFIED VERSION OF THE 35 | DOCUMENT IS WITH YOU. SHOULD ANY DOCUMENT OR 36 | MODIFIED VERSION PROVE DEFECTIVE IN ANY RESPECT, 37 | YOU (NOT THE INITIAL WRITER, AUTHOR OR ANY 38 | CONTRIBUTOR) ASSUME THE COST OF ANY NECESSARY 39 | SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER 40 | OF WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS 41 | LICENSE. NO USE OF ANY DOCUMENT OR MODIFIED 42 | VERSION OF THE DOCUMENT IS AUTHORIZED HEREUNDER 43 | EXCEPT UNDER THIS DISCLAIMER; AND 44 | 45 | 46 | 47 | UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL 48 | THEORY, WHETHER IN TORT (INCLUDING NEGLIGENCE), 49 | CONTRACT, OR OTHERWISE, SHALL THE AUTHOR, 50 | INITIAL WRITER, ANY CONTRIBUTOR, OR ANY 51 | DISTRIBUTOR OF THE DOCUMENT OR MODIFIED VERSION 52 | OF THE DOCUMENT, OR ANY SUPPLIER OF ANY OF SUCH 53 | PARTIES, BE LIABLE TO ANY PERSON FOR ANY 54 | DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR 55 | CONSEQUENTIAL DAMAGES OF ANY CHARACTER 56 | INCLUDING, WITHOUT LIMITATION, DAMAGES FOR LOSS 57 | OF GOODWILL, WORK STOPPAGE, COMPUTER FAILURE OR 58 | MALFUNCTION, OR ANY AND ALL OTHER DAMAGES OR 59 | LOSSES ARISING OUT OF OR RELATING TO USE OF THE 60 | DOCUMENT AND MODIFIED VERSIONS OF THE DOCUMENT, 61 | EVEN IF SUCH PARTY SHALL HAVE BEEN INFORMED OF 62 | THE POSSIBILITY OF SUCH DAMAGES. 63 | 64 | 65 | 66 | 67 | 68 | 69 | -------------------------------------------------------------------------------- /docs/Makefile.am: -------------------------------------------------------------------------------- 1 | @YELP_HELP_RULES@ 2 | 3 | HELP_ID = mdm 4 | HELP_FILES = mdm.xml legal.xml 5 | HELP_MEDIA = 6 | HELP_LINGUAS = en_GB 7 | # it ja zh_CN zh_HK zh_TW need to be transitioned to gnome-doc-utils 8 | 9 | man_MANS = mdm.1 10 | EXTRA_DIST = mdm.1 11 | -------------------------------------------------------------------------------- /docs/mdm.1: -------------------------------------------------------------------------------- 1 | .\" mdm.1 - MDM Display Manager 2 | .\" Copyright 2003 Red Hat, Inc. 3 | .TH MDM 1 "Aug 21 2003" "MDM 2.4.2.102" 4 | .SH NAME 5 | MDM \- The MDM Display Manager 6 | .SH SYNOPSIS 7 | .B mdm [options] 8 | .br 9 | .B mdmsetup [options] 10 | .SH DESCRIPTION 11 | MDM is a replacement for XDM, the X Display Manager. Unlike its 12 | competitors (X3DM, KDM, WDM) MDM was written from scratch and 13 | does not contain any original XDM / X Consortium code. MDM runs and 14 | manages the X servers for both local and remote logins (using XDMCP). 15 | See https://github.com/linuxmint/mdm/ for more details. 16 | .P 17 | .B mdm 18 | is main executable. 19 | .B mdmsetup 20 | is a graphical tool for easily changing the most commonly 21 | used options. 22 | .P 23 | For full documentation see the GNOME help browser 24 | under the 25 | .B Applications / System Tools 26 | section. 27 | .SH OPTIONS 28 | .B mdm 29 | and thus also 30 | .B mdm 31 | accept the following options: 32 | .TP 33 | .BI \-nodaemon 34 | Do not fork into the background 35 | .TP 36 | .BI \-\-no\-console 37 | No console (local) servers to be run 38 | .TP 39 | .BI \-\-preserve\-ld\-vars 40 | Preserve LD_* variables 41 | .TP 42 | .BI \-\-version 43 | Print the MDM version 44 | .TP 45 | .BI \-\-help 46 | Print simple description of accepted options 47 | .P 48 | .B mdmsetup 49 | accepts all standard GNOME options. 50 | .SH CONFIGURATION 51 | Configuration is done either by running 52 | .B mdmsetup 53 | or by editting the /etc/X11/mdm/mdm.conf (usually, 54 | could also be /etc/mdm/mdm.conf) file. The graphical 55 | tool does not support all the options possible so 56 | editting the configuration file is sometimes necessary. 57 | .SH AUTHOR 58 | .B MDM 59 | is being written and maintained by George (Jiri) Lebl 60 | based on the original codebase by Martin K. Peterson . 61 | .SH SEE ALSO 62 | .BR X (7x), 63 | .BR xdm (1), 64 | .BR Xsecurity (7x), 65 | .BR Xserver (1), 66 | -------------------------------------------------------------------------------- /docs/mdm.omf.in: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | manual 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /files/Makefile.am: -------------------------------------------------------------------------------- 1 | install-data-hook: 2 | find -mindepth 1 -maxdepth 1 -type d -exec cp -R {} $(DESTDIR)/ \; 3 | 4 | uninstall-hook: 5 | find -mindepth 1 -type f -exec rm $(DESTDIR)/{} \; 6 | -------------------------------------------------------------------------------- /files/etc/X11/Xsession.d/99mdm: -------------------------------------------------------------------------------- 1 | 2 | # Install MDM desktop files to a non-default desktop file 3 | # location (/usr/share/mdm/applications) and MDM appends 4 | # this directory to the end of the XDG_DATA_DIR environment 5 | # variable. This way, MDM menu choices never appear if 6 | # using a different display manager. 7 | 8 | if [ -n "$MDMSESSION" ]; then 9 | if [ -n "$XDG_DATA_DIRS" ]; then 10 | XDG_DATA_DIRS="$XDG_DATA_DIRS":"/usr/share/mdm/" 11 | else 12 | XDG_DATA_DIRS="/usr/local/share/:/usr/share/:/usr/share/mdm/" 13 | fi 14 | export XDG_DATA_DIRS 15 | fi 16 | -------------------------------------------------------------------------------- /files/usr/bin/mdm-get-monitor-scale: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python2 2 | 3 | import gi 4 | gi.require_version('Gdk', '3.0') 5 | from gi.repository import Gdk 6 | import sys 7 | import os 8 | import syslog 9 | 10 | IDEAL_DPI = 170 11 | CURSOR_SIZE = 24 12 | 13 | def get_window_scale(): 14 | window_scale = 1.0 15 | try: 16 | display = Gdk.Display.get_default() 17 | screen = display.get_default_screen() 18 | primary = screen.get_primary_monitor() 19 | 20 | rect = screen.get_monitor_geometry(primary) 21 | width_mm = screen.get_monitor_width_mm(primary) 22 | height_mm = screen.get_monitor_height_mm(primary) 23 | monitor_scale = screen.get_monitor_scale_factor(primary) 24 | 25 | # Return 1.0 if the screen size isn't available (some TVs report their aspect ratio instead ... 16/9 or 16/10) 26 | if ((width_mm == 160 and height_mm == 90) \ 27 | or (width_mm == 160 and height_mm == 100) \ 28 | or (width_mm == 16 and height_mm == 9) \ 29 | or (width_mm == 16 and height_mm == 10)): 30 | return 1.0 31 | 32 | # Return if the resolution isn't high enough 33 | if rect.width < 2000 or rect.height < 1200: 34 | return 1.0 35 | 36 | if width_mm > 0 and height_mm > 0: 37 | witdh_inch = width_mm / 25.4 38 | height_inch = height_mm / 25.4 39 | dpi_x = rect.width * monitor_scale / witdh_inch 40 | dpi_y = rect.height * monitor_scale / height_inch 41 | if dpi_x > IDEAL_DPI and dpi_y > IDEAL_DPI: 42 | window_scale = round(dpi_x / IDEAL_DPI, 1) 43 | syslog.syslog("Detected hidpi dpi %d, resolution %dx%d dimensions %dx%d. Applying scale: %s, res: %dx%d." % (dpi_x, rect.width, rect.height, witdh_inch, height_inch, window_scale, rect.width / window_scale, rect.height / window_scale)) 44 | except Exception, detail: 45 | syslog.syslog("Error while detecting hidpi mode: %s" % detail) 46 | 47 | return window_scale 48 | 49 | if __name__ == '__main__': 50 | window_scale = get_window_scale() * 10; # points/commas fail to be interpreted properly depending on the locale, so we pass an int instead. 51 | print window_scale 52 | sys.exit(0) 53 | -------------------------------------------------------------------------------- /files/usr/bin/mdm-recovery: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python 2 | 3 | import os, sys, signal 4 | 5 | def signal_handler(signal, frame): 6 | sys.exit(0) 7 | 8 | signal.signal(signal.SIGINT, signal_handler) 9 | 10 | print """ 11 | WELCOME TO MDM RECOVERY 12 | ----------------------- 13 | 14 | This utility will perform the following actions: 15 | 16 | - Make a backup copy of your login screen configuration in /etc/mdm/mdm.recovery-backup 17 | - Set your login screen to use a safe configuration 18 | - Reboot your computer 19 | 20 | Note: This utility requires root permission and might ask you for your password. 21 | 22 | Please press [Enter] to continue or [CTRL+C] to cancel. 23 | 24 | """ 25 | raw_input('') 26 | 27 | if os.path.exists("/etc/mdm/mdm.conf"): 28 | os.system("sudo cp /etc/mdm/mdm.conf /etc/mdm/mdm.recovery-backup") 29 | 30 | os.system("sudo cp /usr/share/mdm/recovery/mdm.conf /etc/mdm/mdm.conf") 31 | 32 | os.system("sudo sync") 33 | 34 | os.system("sudo reboot") 35 | -------------------------------------------------------------------------------- /files/usr/bin/mdm-set-keyboard-layout: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python3 2 | 3 | import sys 4 | import os 5 | import syslog 6 | import subprocess 7 | 8 | if __name__ == '__main__': 9 | 10 | try: 11 | 12 | # Exit if something is missing 13 | for required_file in ["/etc/default/keyboard", "/usr/bin/setxkbmap"]: 14 | if not os.path.exists(required_file): 15 | syslog.syslog("%s not found." % required_file) 16 | sys.exit(0) 17 | 18 | # Log current keyboard configuration 19 | output = subprocess.check_output(["setxkbmap", "-query"]).decode("UTF-8") 20 | syslog.syslog("Current keyboard configuration: %s" % output) 21 | 22 | # Parse keyboard configuration file 23 | XKBMODEL = "" 24 | XKBLAYOUT = "" 25 | XKBVARIANT = "" 26 | XKBOPTIONS = "" 27 | with open("/etc/default/keyboard", "r") as keyboard: 28 | for line in keyboard: 29 | line = line.strip() 30 | if "XKBMODEL=" in line: 31 | XKBMODEL = line.split('=')[1].replace('"', '') 32 | if "XKBLAYOUT=" in line: 33 | XKBLAYOUT = line.split('=')[1].replace('"', '') 34 | if "XKBVARIANT=" in line: 35 | XKBVARIANT = line.split('=')[1].replace('"', '') 36 | if "XKBOPTIONS=" in line: 37 | XKBOPTIONS = line.split('=')[1].replace('"', '') 38 | 39 | # Apply keyboard configuration 40 | command = ["setxkbmap", "-model", XKBMODEL, "-layout", XKBLAYOUT, "-variant", XKBVARIANT, "-option", XKBOPTIONS, "-v"] 41 | syslog.syslog("Applying keyboard configuration: %s" % command) 42 | output = subprocess.check_output(command).decode("UTF-8") 43 | syslog.syslog("Result: %s" % output) 44 | 45 | # Log new keyboard configuration 46 | output = subprocess.check_output(["setxkbmap", "-query"]).decode("UTF-8") 47 | syslog.syslog("New keyboard configuration: %s" % output) 48 | 49 | except Exception as e: 50 | # best effort, syslog it and bail out 51 | syslog.syslog("ERROR: %s" % e) 52 | 53 | sys.exit(0) 54 | -------------------------------------------------------------------------------- /files/usr/bin/mdm-unlock-logind: -------------------------------------------------------------------------------- 1 | #!/usr/bin/python 2 | 3 | from gi.repository import Gio 4 | 5 | import sys 6 | import syslog 7 | 8 | (sys_executable, sys_username, sys_display) = sys.argv 9 | 10 | syslog.syslog("Trying to unlock logind session for %s on %s" % (sys_username, sys_display)) 11 | 12 | # Get the system bus 13 | bus = Gio.bus_get_sync(Gio.BusType.SYSTEM, None) 14 | 15 | # Get the Manager interface 16 | manager_proxy = Gio.DBusProxy.new_sync(bus, Gio.DBusProxyFlags.NONE, None, 'org.freedesktop.login1', '/org/freedesktop/login1', 'org.freedesktop.login1.Manager', None) 17 | 18 | # List all sessions 19 | logind_sessions = manager_proxy.ListSessions() 20 | for logind_session in logind_sessions: 21 | (session_id, user_id, user_name, seat_id, session_object_path) = logind_session 22 | if (user_name == sys_username): 23 | # Get the Session interface if it belongs to the required username 24 | session_properties_proxy = Gio.DBusProxy.new_sync(bus, Gio.DBusProxyFlags.NONE, None, 'org.freedesktop.login1', session_object_path, 'org.freedesktop.DBus.Properties', None) 25 | display = session_properties_proxy.Get('(ss)', 'org.freedesktop.login1.Session', 'Display') 26 | if (display == sys_display): 27 | syslog.syslog("Found session %s" % session_id) 28 | # If the display matches the one we're looking for, unlock the session 29 | #manager_proxy.UnlockSession('(s)', session_object_path) 30 | session_proxy = Gio.DBusProxy.new_sync(bus, Gio.DBusProxyFlags.NONE, None, 'org.freedesktop.login1', session_object_path, 'org.freedesktop.login1.Session', None) 31 | session_proxy.Unlock() 32 | syslog.syslog("Session is now unlocked") 33 | -------------------------------------------------------------------------------- /files/usr/share/mdm/gtk-preview.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/gtk-preview.png -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/af/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/af/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/am/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/am/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ar/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ar/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/az/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/az/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/be/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/be/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/bg/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/bg/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/bn/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/bn/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/bs/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/bs/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ca/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ca/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/cs/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/cs/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/cy/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/cy/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/da/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/da/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/de/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/de/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/el/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/el/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/en_AU/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/en_AU/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/en_CA/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/en_CA/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/en_GB/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/en_GB/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/eo/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/eo/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/es/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/es/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/et/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/et/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/eu/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/eu/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/fa/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/fa/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/fi/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/fi/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/fr/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/fr/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/fr_CA/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/fr_CA/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/frp/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/frp/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ga/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ga/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/gd/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/gd/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/gl/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/gl/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/he/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/he/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/hi/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/hi/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/hr/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/hr/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/hu/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/hu/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ia/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ia/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/id/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/id/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ii/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ii/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/is/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/is/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/it/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/it/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ja/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ja/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ka/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ka/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/kab/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/kab/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/kk/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/kk/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/km/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/km/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ko/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ko/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ksw/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ksw/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ku/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ku/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ky/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ky/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/lo/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/lo/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/lt/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/lt/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/lv/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/lv/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/mg/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/mg/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ml/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ml/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/mr/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/mr/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ms/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ms/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/mus/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/mus/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/my/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/my/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/nb/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/nb/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/nds/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/nds/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ne/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ne/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/nl/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/nl/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/nn/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/nn/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/oc/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/oc/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/om/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/om/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/pa/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/pa/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/pap/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/pap/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/pl/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/pl/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/pt/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/pt/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/pt_BR/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/pt_BR/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ro/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ro/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ru/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ru/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/rw/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/rw/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/sc/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/sc/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/shn/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/shn/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/si/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/si/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/sk/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/sk/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/sl/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/sl/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/sq/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/sq/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/sr/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/sr/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/sr@latin/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/sr@latin/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/sv/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/sv/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ta/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ta/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/tg/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/tg/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/th/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/th/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/tr/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/tr/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/uk/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/uk/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/ur/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/ur/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/uz/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/uz/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/vi/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/vi/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/zh_CN/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/zh_CN/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/zh_HK/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/zh_HK/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/locale/zh_TW/LC_MESSAGES/mdm.mo: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/files/usr/share/mdm/locale/zh_TW/LC_MESSAGES/mdm.mo -------------------------------------------------------------------------------- /files/usr/share/mdm/recovery/mdm.conf: -------------------------------------------------------------------------------- 1 | [greeter] 2 | 3 | [debug] 4 | Enable=true 5 | 6 | [daemon] 7 | Greeter=/usr/lib/mdm/mdmlogin 8 | SelectLastLogin=false 9 | 10 | [security] 11 | -------------------------------------------------------------------------------- /gui/faces/Makefile.am: -------------------------------------------------------------------------------- 1 | 2 | imagedir = $(datadir)/pixmaps/faces 3 | 4 | image_DATA = \ 5 | user-generic.png 6 | 7 | EXTRA_DIST = \ 8 | $(image_DATA) 9 | 10 | -------------------------------------------------------------------------------- /gui/faces/user-generic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/gui/faces/user-generic.png -------------------------------------------------------------------------------- /gui/greeter/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = . themes 2 | 3 | ## Process this file with automake to produce makefile.in 4 | INCLUDES = \ 5 | -I. \ 6 | -I$(top_srcdir)/gui \ 7 | -I$(top_srcdir)/daemon \ 8 | -I$(top_srcdir)/common \ 9 | -DAUTHDIR=\""$(authdir)"\" \ 10 | -DDATADIR=\""$(datadir)"\" \ 11 | -DMDM_DATADIR=\""$(pkgdatadir)"\" \ 12 | -DDMCONFDIR=\""$(dmconfdir)"\" \ 13 | -DMDM_CONFIG_FILE=\"$(mdmconfdir)/mdm.conf\" \ 14 | -DMDMLOCALEDIR=\""$(mdmlocaledir)"\" \ 15 | -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \ 16 | -DLIBEXECDIR=\""$(libexecdir)"\" \ 17 | -DSBINDIR=\""$(sbindir)"\" \ 18 | -DPIXMAPDIR=\""$(pixmapdir)"\" \ 19 | $(GUI_CFLAGS) \ 20 | $(PANGO_CFLAGS) \ 21 | $(PANGOFT_CFLAGS) \ 22 | $(GREETER_CFLAGS) 23 | 24 | # 25 | # -DG_DISABLE_DEPRECATED \ 26 | # -DGDK_DISABLE_DEPRECATED \ 27 | # -DGDK_PIXBUF_DISABLE_DEPRECATED \ 28 | # -DGTK_DISABLE_DEPRECATED \ 29 | # -DGNOME_DISABLE_DEPRECATED \ 30 | # 31 | 32 | libexec_PROGRAMS = \ 33 | mdmgreeter 34 | 35 | mdmgreeter_SOURCES = \ 36 | greeter.c \ 37 | greeter.h \ 38 | greeter_canvas_text.c \ 39 | greeter_canvas_text.h \ 40 | greeter_canvas_item.c \ 41 | greeter_canvas_item.h \ 42 | greeter_configuration.h \ 43 | greeter_events.c \ 44 | greeter_events.h \ 45 | greeter_geometry.c \ 46 | greeter_geometry.h \ 47 | greeter_item.c \ 48 | greeter_item_timed.c \ 49 | greeter_item_timed.h \ 50 | greeter_item_capslock.c \ 51 | greeter_item_capslock.h \ 52 | greeter_item_clock.c \ 53 | greeter_item_clock.h \ 54 | greeter_item.h \ 55 | greeter_item_pam.c \ 56 | greeter_item_pam.h \ 57 | greeter_item_ulist.c \ 58 | greeter_item_ulist.h \ 59 | greeter_item_customlist.c \ 60 | greeter_item_customlist.h \ 61 | greeter_parser.c \ 62 | greeter_parser.h \ 63 | greeter_session.c \ 64 | greeter_session.h \ 65 | greeter_system.c \ 66 | greeter_system.h 67 | 68 | mdmgreeter_LDADD = \ 69 | $(EXTRA_GREETER_LIBS) \ 70 | -L$(top_builddir)/gui \ 71 | -lmdmwm \ 72 | -lmdmcommon \ 73 | -lmdmgreeter \ 74 | $(top_builddir)/common/libmdmcommon.a \ 75 | $(GLIB_LIBS) \ 76 | $(GOBJECT_LIBS) \ 77 | $(PANGO_LIBS) \ 78 | $(PANGOFT_LIBS) \ 79 | $(GDK_LIBS) \ 80 | $(GDKPIXBUF_LIBS) \ 81 | $(GREETER_LIBS) \ 82 | $(X_EXTRA_LIBS) \ 83 | $(XINERAMA_LIBS) \ 84 | $(X_LIBS) \ 85 | -lX11 \ 86 | -lm \ 87 | -lXau 88 | 89 | EXTRA_DIST = \ 90 | greeter.dtd 91 | -------------------------------------------------------------------------------- /gui/greeter/greeter.dtd: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 25 | 26 | 33 | 43 | 46 | 49 | 52 | 55 | 64 | 65 | 69 | 72 | 75 | 79 | 80 | -------------------------------------------------------------------------------- /gui/greeter/greeter.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef __GREETER_H__ 20 | #define __GREETER_H__ 21 | 22 | #include 23 | 24 | extern gboolean DOING_MDM_DEVELOPMENT; 25 | extern GtkWidget *canvas; 26 | extern GtkWidget *window; 27 | 28 | extern gboolean greeter_probably_login_prompt; 29 | 30 | void greeter_ignore_buttons (gboolean val); 31 | 32 | #endif 33 | -------------------------------------------------------------------------------- /gui/greeter/greeter_canvas_item.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef GREETER_CANVAS_ITEM_H 20 | #define GREETER_CANVAS_ITEM_H 21 | 22 | void greeter_item_create_canvas_item (GreeterItemInfo *item); 23 | 24 | void greeter_canvas_item_break_set_string (GreeterItemInfo *info, 25 | const char *orig, 26 | gboolean markup, 27 | int max_width, 28 | int *width, 29 | int *height, 30 | GnomeCanvas *canvas, 31 | GnomeCanvasItem *real_item); 32 | 33 | #endif /* GREETER_CANVAS_ITEM_H */ 34 | -------------------------------------------------------------------------------- /gui/greeter/greeter_canvas_text.h: -------------------------------------------------------------------------------- 1 | #ifndef GREETER_CANVAS_TEXT_H 2 | #define GREETER_CANVAS_TEXT_H 3 | 4 | #include 5 | #include 6 | 7 | G_BEGIN_DECLS 8 | 9 | #define GREETER_TYPE_CANVAS_TEXT (greeter_canvas_text_get_type ()) 10 | #define GREETER_CANVAS_TEXT(obj) (GTK_CHECK_CAST ((obj), GREETER_TYPE_CANVAS_TEXT, GreeterCanvasText)) 11 | #define GREETER_CANVAS_TEXT_CLASS(klass) (GTK_CHECK_CLASS_CAST ((klass), GREETER_TYPE_CANVAS_TEXT, GreeterCanvasTextClass)) 12 | #define GREETER_IS_CANVAS_TEXT(obj) (GTK_CHECK_TYPE ((obj), GREETER_TYPE_CANVAS_TEXT)) 13 | #define GREETER_IS_CANVAS_TEXT_CLASS(klass) (GTK_CHECK_CLASS_TYPE ((klass), GREETER_TYPE_CANVAS_TEXT)) 14 | #define GREETER_CANVAS_TEXT_GET_CLASS(obj) (GTK_CHECK_GET_CLASS ((obj), GREETER_TYPE_CANVAS_TEXT, GreeterCanvasTextClass)) 15 | 16 | 17 | typedef struct _GreeterCanvasText GreeterCanvasText; 18 | typedef struct _GreeterCanvasTextClass GreeterCanvasTextClass; 19 | 20 | struct _GreeterCanvasText { 21 | GnomeCanvasText text; 22 | }; 23 | 24 | struct _GreeterCanvasTextClass { 25 | GnomeCanvasTextClass parent_class; 26 | }; 27 | 28 | 29 | GType greeter_canvas_text_get_type (void) G_GNUC_CONST; 30 | 31 | G_END_DECLS 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /gui/greeter/greeter_configuration.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef GREETER_CONFIGURATION_H 20 | #define GREETER_CONFIGURATION_H 21 | 22 | extern gboolean MdmUseCirclesInEntry; 23 | extern gboolean MdmUseInvisibleInEntry; 24 | extern gboolean MdmShowGnomeFailsafeSession; 25 | extern gboolean MdmShowXtermFailsafeSession; 26 | extern gboolean MdmShowLastSession; 27 | extern gboolean MdmSystemMenu; 28 | extern gboolean MdmConfigAvailable; 29 | extern gboolean MdmChooserButton; 30 | extern gchar *MdmHalt; 31 | extern gchar *MdmReboot; 32 | extern gchar *MdmSuspend; 33 | extern gchar *MdmConfigurator; 34 | extern gboolean MdmHaltFound; 35 | extern gboolean MdmRebootFound; 36 | extern gboolean MdmCustomCmdFound; 37 | extern gboolean *MdmCustomCmdsFound; 38 | extern gboolean MdmAnyCustomCmdsFound; 39 | extern gboolean MdmSuspendFound; 40 | extern gboolean MdmConfiguratorFound; 41 | extern gchar *MdmSessionDir; 42 | extern gchar *MdmDefaultSession; 43 | extern gchar *MdmDefaultLocale; 44 | extern gchar *MdmLocaleFile; 45 | extern gboolean MdmTimedLoginEnable; 46 | extern gboolean MdmUse24Clock; 47 | extern gchar *MdmTimedLogin; 48 | extern gint MdmTimedLoginDelay; 49 | extern gchar *MdmGlobalFaceDir; 50 | extern gchar *MdmDefaultFace; 51 | extern gint MdmIconMaxHeight; 52 | extern gint MdmIconMaxWidth; 53 | extern gchar *MdmExclude; 54 | extern int MdmMinimalUID; 55 | extern gboolean MdmAllowRoot; 56 | extern gboolean MdmAllowRemoteRoot; 57 | extern gchar *MdmWelcome; 58 | extern gchar *MdmServAuthDir; 59 | extern gchar *MdmInfoMsgFile; 60 | extern gchar *MdmInfoMsgFont; 61 | extern gchar *MdmSoundProgram; 62 | extern gchar *MdmSoundOnLoginReadyFile; 63 | extern gchar *MdmSoundOnLoginSuccessFile; 64 | extern gchar *MdmSoundOnLoginFailureFile; 65 | extern gboolean MdmSoundOnLoginReady; 66 | extern gboolean MdmSoundOnLoginSuccess; 67 | extern gboolean MdmSoundOnLoginFailure; 68 | 69 | extern gboolean MDM_IS_LOCAL; 70 | extern gboolean DOING_MDM_DEVELOPMENT; 71 | 72 | #endif /* GREETER_CONFIGURATION_H */ 73 | -------------------------------------------------------------------------------- /gui/greeter/greeter_events.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef GREETER_EVENTS_H 20 | #define GREETER_EVENTS_H 21 | 22 | typedef void (*ActionFunc) (GreeterItemInfo *info, 23 | gpointer user_data); 24 | 25 | gint greeter_item_event_handler (GnomeCanvasItem *item, 26 | GdkEvent *event, 27 | gpointer data); 28 | 29 | void greeter_item_register_action_callback (char *id, 30 | ActionFunc func, 31 | gpointer user_data); 32 | 33 | void greeter_item_run_action_callback (const char *id); 34 | 35 | #endif /* GREETER_EVENTS_H */ 36 | -------------------------------------------------------------------------------- /gui/greeter/greeter_geometry.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef GREETER_GEOMETRY_H 20 | #define GREETER_GEOMETRY_H 21 | 22 | #include "greeter_item.h" 23 | 24 | void greeter_layout (GreeterItemInfo *root_item, 25 | GnomeCanvas *canvas); 26 | 27 | #endif 28 | -------------------------------------------------------------------------------- /gui/greeter/greeter_item_capslock.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef __GREETER_ITEM_CAPSLOCK_H__ 20 | #define __GREETER_ITEM_CAPSLOCK_H__ 21 | 22 | #include "greeter_item.h" 23 | 24 | gboolean greeter_item_capslock_setup (GtkWidget *window); 25 | gboolean greeter_is_capslock_on (void); 26 | 27 | #endif 28 | -------------------------------------------------------------------------------- /gui/greeter/greeter_item_clock.c: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #include "config.h" 20 | 21 | #include 22 | #include 23 | #include "greeter_item_clock.h" 24 | #include "greeter_parser.h" 25 | 26 | static gboolean 27 | update_clock (gpointer data) 28 | { 29 | GreeterItemInfo *info = data; 30 | struct tm *the_tm; 31 | time_t the_time; 32 | gint time_til_next_min; 33 | 34 | greeter_item_update_text (info); 35 | 36 | time (&the_time); 37 | the_tm = localtime (&the_time); 38 | /* account for leap seconds */ 39 | time_til_next_min = 60 - the_tm->tm_sec; 40 | time_til_next_min = (time_til_next_min>=0?time_til_next_min:0); 41 | 42 | g_timeout_add (time_til_next_min*1000, update_clock, info); 43 | 44 | return FALSE; 45 | } 46 | 47 | 48 | gboolean 49 | greeter_item_clock_setup (void) 50 | { 51 | GreeterItemInfo *info; 52 | 53 | info = greeter_lookup_id ("clock"); 54 | if (info) 55 | update_clock (info); 56 | 57 | return TRUE; 58 | } 59 | 60 | void 61 | greeter_item_clock_update (void) 62 | { 63 | GreeterItemInfo *info; 64 | 65 | info = greeter_lookup_id ("clock"); 66 | if (info) 67 | greeter_item_update_text (info); 68 | } 69 | -------------------------------------------------------------------------------- /gui/greeter/greeter_item_clock.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef __GREETER_ITEM_CLOCK_H__ 20 | #define __GREETER_ITEM_CLOCK_H__ 21 | 22 | #include "greeter_item.h" 23 | 24 | gboolean greeter_item_clock_setup (void); 25 | void greeter_item_clock_update (void); 26 | 27 | #endif 28 | -------------------------------------------------------------------------------- /gui/greeter/greeter_item_customlist.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef __GREETER_ITEM_CUSTOMLIST_H__ 20 | #define __GREETER_ITEM_CUSTOMLIST_H__ 21 | 22 | #include "greeter_item.h" 23 | 24 | gboolean greeter_item_customlist_setup (void); 25 | void greeter_custom_set_session (gchar *session); 26 | void lang_set_custom_callback (gchar *language); 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /gui/greeter/greeter_item_pam.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef GREETER_ITEM_PAM_H 20 | #define GREETER_ITEM_PAM_H 21 | 22 | #include "greeter_item.h" 23 | 24 | gboolean greeter_item_pam_setup (void); 25 | void greeter_item_pam_prompt (const char *message, 26 | int entry_len, 27 | gboolean entry_visible); 28 | void greeter_item_pam_message (const char *message); 29 | void greeter_item_pam_error (const char *message); 30 | void greeter_item_pam_set_user (const char *user); 31 | void greeter_item_pam_leftover_messages (void); 32 | void greeter_item_pam_login (GtkEntry *entry, GreeterItemInfo *info); 33 | 34 | extern gchar *greeter_current_user; 35 | 36 | #endif 37 | -------------------------------------------------------------------------------- /gui/greeter/greeter_item_timed.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef GREETER_ITEM_TIMED_H 20 | #define GREETER_ITEM_TIMED_H 21 | 22 | #include "greeter_item.h" 23 | 24 | gboolean greeter_item_timed_setup (void); 25 | void greeter_item_timed_start (void); 26 | void greeter_item_timed_stop (void); 27 | gboolean greeter_item_timed_is_timed (void); 28 | 29 | #endif 30 | -------------------------------------------------------------------------------- /gui/greeter/greeter_item_ulist.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef GREETER_ITEM_ULIST_H 20 | #define GREETER_ITEM_ULIST_H 21 | 22 | #include "greeter_item.h" 23 | 24 | gboolean greeter_item_ulist_setup (void); 25 | void greeter_item_ulist_enable (void); 26 | void greeter_item_ulist_disable (void); 27 | void greeter_item_ulist_set_user (const char *user); 28 | void greeter_item_ulist_unset_selected_user (void); 29 | void greeter_item_ulist_select_user (gchar *login); 30 | void greeter_item_ulist_check_show_userlist (void); 31 | 32 | #endif 33 | -------------------------------------------------------------------------------- /gui/greeter/greeter_parser.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef __GREETER_PARSER_H__ 20 | #define __GREETER_PARSER_H__ 21 | 22 | #include 23 | #include "greeter_item.h" 24 | 25 | 26 | typedef enum 27 | { 28 | GREETER_PARSER_ERROR_NO_FILE, 29 | GREETER_PARSER_ERROR_BAD_XML, 30 | GREETER_PARSER_ERROR_WRONG_TYPE, 31 | GREETER_PARSER_ERROR_BAD_SPEC 32 | } GreeterParseError; 33 | 34 | #define GREETER_PARSER_ERROR greeter_parser_error_quark() 35 | GQuark greeter_parser_error_quark (void); 36 | 37 | GreeterItemInfo *greeter_parse (const char *file, 38 | const char *data_dir, 39 | GnomeCanvas *canvas, 40 | int width, 41 | int height, 42 | GError **error); 43 | 44 | GreeterItemInfo *greeter_lookup_id (const char *id); 45 | const GList *greeter_custom_items (void); 46 | gboolean greeter_show_only_background (GreeterItemInfo *root_item); 47 | 48 | #endif /* __GREETER_PARSER_H__ */ 49 | -------------------------------------------------------------------------------- /gui/greeter/greeter_session.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef __GREETER_SESSION_H__ 20 | #define __GREETER_SESSION_H__ 21 | 22 | void greeter_session_init (void); 23 | void greeter_item_session_setup (void); 24 | void greeter_set_session (char *session); 25 | 26 | #endif /* __GREETER_SESSION_H__ */ 27 | -------------------------------------------------------------------------------- /gui/greeter/greeter_system.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef __GREETER_SYSTEM_H__ 20 | #define __GREETER_SYSTEM_H__ 21 | 22 | #include "greeter_item.h" 23 | #include "greeter_events.h" 24 | 25 | void greeter_item_system_setup (void); 26 | void greeter_system_append_system_menu (GtkWidget *menu); 27 | 28 | #endif 29 | 30 | -------------------------------------------------------------------------------- /gui/greeter/themes/Makefile.am: -------------------------------------------------------------------------------- 1 | SUBDIRS = circles 2 | -------------------------------------------------------------------------------- /gui/greeter/themes/circles/GdmGreeterTheme.desktop.in: -------------------------------------------------------------------------------- 1 | # This is not really a .desktop file like the rest, but it's useful to treat 2 | # it as such 3 | 4 | [GdmGreeterTheme] 5 | Encoding=UTF-8 6 | Greeter=circles.xml 7 | _Name=Circles 8 | _Description=Theme with blue circles 9 | _Author=Unknown 10 | _Copyright=(c) 2002 11 | Screenshot=screenshot.png 12 | -------------------------------------------------------------------------------- /gui/greeter/themes/circles/Makefile.am: -------------------------------------------------------------------------------- 1 | circlesdir = $(datadir)/mdm/themes/circles 2 | circles_DATA = \ 3 | GdmGreeterTheme.desktop \ 4 | circles.xml \ 5 | background.svg \ 6 | screenshot.png 7 | 8 | circles_in_files = \ 9 | GdmGreeterTheme.desktop.in 10 | 11 | @INTLTOOL_DESKTOP_RULE@ 12 | 13 | EXTRA_DIST = $(circles_DATA) $(circles_in_files) 14 | 15 | clean-local: 16 | /bin/rm -f GdmGreeterTheme.desktop 17 | -------------------------------------------------------------------------------- /gui/greeter/themes/circles/background.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | 7 | 8 | 9 | ]> 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | -------------------------------------------------------------------------------- /gui/greeter/themes/circles/screenshot.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/gui/greeter/themes/circles/screenshot.png -------------------------------------------------------------------------------- /gui/mdmcomm.h: -------------------------------------------------------------------------------- 1 | /* 2 | * MDM - THe MDM Display Manager 3 | * Copyright (C) 2001 Queen of England, (c)2002 George Lebl 4 | * 5 | * MDMcommunication routines 6 | * 7 | * This program is free software; you can redistribute it and/or modify 8 | * it under the terms of the GNU General Public License as published by 9 | * the Free Software Foundation; either version 2 of the License, or 10 | * (at your option) any later version. 11 | * 12 | * This program is distributed in the hope that it will be useful, 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | * GNU General Public License for more details. 16 | * 17 | * You should have received a copy of the GNU General Public License 18 | * along with this program; if not, write to the Free Software 19 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 20 | * 21 | */ 22 | 23 | #ifndef MDMCOMM_H 24 | #define MDMCOMM_H 25 | 26 | void mdmcomm_set_debug (gboolean enable); 27 | void mdmcomm_set_quiet_errors (gboolean enable); 28 | char * mdmcomm_send_cmd_to_daemon_with_args (const char *command, const char * auth_cookie, int tries); 29 | char * mdmcomm_send_cmd_to_daemon (const char *command); 30 | void mdmcomm_set_allow_sleep (gboolean val); 31 | void mdmcomm_open_connection_to_daemon (void); 32 | void mdmcomm_close_connection_to_daemon (void); 33 | const char * mdmcomm_get_display (void); 34 | 35 | /* This just gets a cookie of MIT-MAGIC-COOKIE-1 type */ 36 | char * mdmcomm_get_a_cookie (gboolean binary); 37 | 38 | /* get the mdm auth cookie */ 39 | char * mdmcomm_get_auth_cookie (void); 40 | 41 | gboolean mdmcomm_is_daemon_running (gboolean show_dialog); 42 | const char * mdmcomm_get_error_message (const char *ret); 43 | 44 | #endif /* MDMCOMM_H */ 45 | -------------------------------------------------------------------------------- /gui/mdmcommon.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * MDM - The MDM Display Manager 4 | * Copyright (C) 1999, 2000 Martin K. Petersen 5 | * 6 | * This file Copyright (c) 2003 George Lebl 7 | * - Common routines for the greeters. 8 | * 9 | * This program is free software; you can redistribute it and/or modify 10 | * it under the terms of the GNU General Public License as published by 11 | * the Free Software Foundation; either version 2 of the License, or 12 | * (at your option) any later version. 13 | * 14 | * This program is distributed in the hope that it will be useful, 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | * GNU General Public License for more details. 18 | * 19 | * You should have received a copy of the GNU General Public License 20 | * along with this program; if not, write to the Free Software 21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 22 | */ 23 | 24 | #ifndef MDM_COMMON_H 25 | #define MDM_COMMON_H 26 | 27 | #include 28 | 29 | #include "misc.h" 30 | 31 | /* Handle error messages */ 32 | void mdm_common_log_init (void); 33 | void mdm_common_log_set_debug (gboolean enable); 34 | void mdm_common_fail_exit (const gchar *format, ...) 35 | G_GNUC_PRINTF (1, 2); 36 | void mdm_common_fail_greeter (const gchar *format, ...) 37 | G_GNUC_PRINTF (1, 2); 38 | void mdm_common_info (const gchar *format, ...) 39 | G_GNUC_PRINTF (1, 2); 40 | void mdm_common_error (const gchar *format, ...) 41 | G_GNUC_PRINTF (1, 2); 42 | void mdm_common_warning (const gchar *format, ...) 43 | G_GNUC_PRINTF (1, 2); 44 | void mdm_common_debug (const gchar *format, ...) 45 | G_GNUC_PRINTF (1, 2); 46 | 47 | /* Misc. Common Functions */ 48 | void mdm_common_setup_cursor (GdkCursorType type); 49 | 50 | void mdm_common_setup_builtin_icons (void); 51 | 52 | void mdm_common_login_sound (const gchar *MdmSoundProgram, 53 | const gchar *MdmSoundOnLoginReadyFile, 54 | gboolean MdmSoundOnLoginReady); 55 | 56 | void mdm_common_setup_blinking (void); 57 | void mdm_common_setup_blinking_entry (GtkWidget *entry); 58 | 59 | GdkPixbuf *mdm_common_get_face (const char *filename, 60 | const char *fallback_filename, 61 | guint max_width, 62 | guint max_height); 63 | 64 | gchar* mdm_common_text_to_escaped_utf8 (const char *text); 65 | gchar* mdm_common_get_config_file (void); 66 | gchar* mdm_common_get_custom_config_file (void); 67 | gboolean mdm_common_select_time_format (void); 68 | void mdm_common_setup_background_color (gchar *bg_color); 69 | void mdm_common_set_root_background (GdkPixbuf *pb); 70 | gchar* mdm_common_get_welcomemsg (void); 71 | void mdm_common_pre_fetch_launch (void); 72 | void mdm_common_atspi_launch (void); 73 | gchar* mdm_common_expand_text (const gchar *text); 74 | gchar* mdm_common_get_clock (struct tm **the_tm); 75 | gboolean mdm_common_locale_is_displayable (const gchar *locale); 76 | gboolean mdm_common_is_action_available (gchar *action); 77 | #endif /* MDM_COMMON_H */ 78 | -------------------------------------------------------------------------------- /gui/mdmconfig.h: -------------------------------------------------------------------------------- 1 | /* 2 | * MDM - THe MDM Display Manager 3 | * Copyright (C) 2001 Queen of England, (c)2002 George Lebl 4 | * 5 | * MDMcommunication routines 6 | * 7 | * This program is free software; you can redistribute it and/or modify 8 | * it under the terms of the GNU General Public License as published by 9 | * the Free Software Foundation; either version 2 of the License, or 10 | * (at your option) any later version. 11 | * 12 | * This program is distributed in the hope that it will be useful, 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | * GNU General Public License for more details. 16 | * 17 | * You should have received a copy of the GNU General Public License 18 | * along with this program; if not, write to the Free Software 19 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 20 | * 21 | */ 22 | 23 | #ifndef _MDMCONFIG_H 24 | #define _MDMCONFIG_H 25 | 26 | #include "glib.h" 27 | 28 | void mdm_config_never_cache (gboolean never_cache); 29 | void mdm_config_set_comm_retries (int tries); 30 | gchar * mdm_config_get_string (const gchar *key); 31 | gchar * mdm_config_get_translated_string (const gchar *key); 32 | gint mdm_config_get_int (const gchar *key); 33 | gboolean mdm_config_get_bool (const gchar *key); 34 | gboolean mdm_config_reload_string (const gchar *key); 35 | gboolean mdm_config_reload_int (const gchar *key); 36 | gboolean mdm_config_reload_bool (const gchar *key); 37 | GSList * mdm_config_get_xservers (gboolean flexible); 38 | 39 | void mdm_save_customlist_data (const gchar *file, 40 | const gchar *key, 41 | const gchar *id); 42 | char * mdm_get_theme_greeter (const gchar *file, 43 | const char *fallback); 44 | 45 | #endif /* _MDMCONFIG_H */ 46 | -------------------------------------------------------------------------------- /gui/mdmflexiserver.desktop.in: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Encoding=UTF-8 3 | _Name=New Login 4 | _GenericName=New Login 5 | _Comment=Log in as another user without logging out 6 | Exec=mdmflexiserver 7 | Icon=mdmflexiserver 8 | Terminal=false 9 | Type=Application 10 | Categories=GNOME;GTK;System; 11 | X-GNOME-Bugzilla-Bugzilla=GNOME 12 | X-GNOME-Bugzilla-Product=mdm 13 | X-GNOME-Bugzilla-Component=general 14 | -------------------------------------------------------------------------------- /gui/mdmgreeter.c: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * MDM - The MDM Display Manager 4 | * Copyright (C) 1999, 2000 Martin K. Petersen 5 | * 6 | * This file Copyright (c) 2003 George Lebl 7 | * - Common routines for the greeters. 8 | * 9 | * This program is free software; you can redistribute it and/or modify 10 | * it under the terms of the GNU General Public License as published by 11 | * the Free Software Foundation; either version 2 of the License, or 12 | * (at your option) any later version. 13 | * 14 | * This program is distributed in the hope that it will be useful, 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | * GNU General Public License for more details. 18 | * 19 | * You should have received a copy of the GNU General Public License 20 | * along with this program; if not, write to the Free Software 21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 22 | */ 23 | 24 | #include "config.h" 25 | 26 | #include 27 | 28 | #include "mdmgreeter.h" 29 | 30 | #include 31 | #include 32 | #include 33 | 34 | #include "mdm.h" 35 | #include "mdm-common.h" 36 | #include "mdmconfig.h" 37 | #include "mdm-daemon-config-keys.h" 38 | 39 | /* 40 | * This file is for functions that are only used by mdmlogin, 41 | * mdmgreeter, and mdmsetup 42 | */ 43 | 44 | gboolean 45 | mdm_common_is_action_available (gchar *action) 46 | { 47 | gchar **allowsyscmd = NULL; 48 | const gchar *allowsyscmdval; 49 | gboolean ret = FALSE; 50 | int i; 51 | 52 | allowsyscmdval = mdm_config_get_string (MDM_KEY_SYSTEM_COMMANDS_IN_MENU); 53 | if (allowsyscmdval) 54 | allowsyscmd = g_strsplit (allowsyscmdval, ";", 0); 55 | 56 | if (allowsyscmd) { 57 | for (i = 0; allowsyscmd[i] != NULL; i++) { 58 | if (strcmp (allowsyscmd[i], action) == 0) { 59 | ret = TRUE; 60 | break; 61 | } 62 | } 63 | } 64 | 65 | g_strfreev (allowsyscmd); 66 | 67 | return ret; 68 | } 69 | 70 | -------------------------------------------------------------------------------- /gui/mdmgreeter.h: -------------------------------------------------------------------------------- 1 | /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- 2 | * 3 | * MDM - The MDM Display Manager 4 | * Copyright (C) 1999, 2000 Martin K. Petersen 5 | * 6 | * This file Copyright (c) 2003 George Lebl 7 | * - Common routines for the greeters. 8 | * 9 | * This program is free software; you can redistribute it and/or modify 10 | * it under the terms of the GNU General Public License as published by 11 | * the Free Software Foundation; either version 2 of the License, or 12 | * (at your option) any later version. 13 | * 14 | * This program is distributed in the hope that it will be useful, 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 | * GNU General Public License for more details. 18 | * 19 | * You should have received a copy of the GNU General Public License 20 | * along with this program; if not, write to the Free Software 21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 22 | */ 23 | 24 | #ifndef MDM_GREETER_H 25 | #define MDM_GREETER_H 26 | 27 | #include 28 | 29 | gboolean mdm_common_is_action_available (gchar *action); 30 | #endif /* MDM_GREETER_H */ 31 | -------------------------------------------------------------------------------- /gui/mdmlanguages.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This file Copyright (c) 2001 George Lebl 5 | * 6 | * This program is free software; you can redistribute it and/or modify 7 | * it under the terms of the GNU General Public License as published by 8 | * the Free Software Foundation; either version 2 of the License, or 9 | * (at your option) any later version. 10 | * 11 | * This program is distributed in the hope that it will be useful, 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | * GNU General Public License for more details. 15 | * 16 | * You should have received a copy of the GNU General Public License 17 | * along with this program; if not, write to the Free Software 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 | */ 20 | 21 | #ifndef MDM_LANGUAGES_H 22 | #define MDM_LANGUAGES_H 23 | 24 | #include 25 | 26 | enum { 27 | LOCALE_COLUMN, 28 | TRANSLATED_NAME_COLUMN, 29 | UNTRANSLATED_NAME_COLUMN, 30 | NUM_COLUMNS 31 | }; 32 | 33 | enum { 34 | ASK_RESTART = 0, 35 | ALWAYS_RESTART 36 | }; 37 | 38 | /* This is the interface for translating languages. Language translations 39 | * are now hardocded in, but that may change */ 40 | 41 | const char * mdm_lang_group1 (void); 42 | const char * mdm_lang_group2 (void); 43 | 44 | char * mdm_lang_name (const char *language, 45 | gboolean never_encoding, 46 | gboolean no_group, 47 | gboolean untranslated, 48 | gboolean markup); 49 | gboolean mdm_lang_name_translated (const char *language); 50 | 51 | /* NULL if not found */ 52 | char * mdm_lang_untranslated_name (const char *language, 53 | gboolean markup); 54 | 55 | GList * mdm_lang_read_locale_file (const char *file); 56 | 57 | GtkListStore * mdm_lang_get_model (void); 58 | void mdm_lang_initialize_model (gchar *locale_file); 59 | gchar * mdm_lang_check_language (const char *old_language); 60 | void mdm_lang_set (char *language); 61 | void mdm_lang_set_restart_dialog (char *language); 62 | gint mdm_lang_get_savelang_setting (void); 63 | void mdm_lang_handler (gpointer user_data); 64 | void mdm_lang_op_lang (const gchar *args); 65 | void mdm_lang_op_slang (const gchar *args); 66 | void mdm_lang_op_setlang (const gchar *args); 67 | void mdm_lang_op_always_restart (const gchar *args); 68 | gint mdm_lang_ask_restart (gchar *language); 69 | 70 | #endif /* MDM_LANGUAGES_H */ 71 | -------------------------------------------------------------------------------- /gui/mdmsession.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1999, 2000 Martin K. Petersen 3 | * 4 | * This file Copyright (c) 2003 George Lebl 5 | * - Common routines for the greeters. 6 | * 7 | * This program is free software; you can redistribute it and/or modify 8 | * it under the terms of the GNU General Public License as published by 9 | * the Free Software Foundation; either version 2 of the License, or 10 | * (at your option) any later version. 11 | * 12 | * This program is distributed in the hope that it will be useful, 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | * GNU General Public License for more details. 16 | * 17 | * You should have received a copy of the GNU General Public License 18 | * along with this program; if not, write to the Free Software 19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 20 | */ 21 | 22 | #ifndef MDM_SESSION_H 23 | #define MDM_SESSION_H 24 | 25 | #include "misc.h" 26 | 27 | #define LAST_SESSION "Last" 28 | #define SESSION_NAME "SessionName" 29 | 30 | typedef struct { 31 | char *name; 32 | char *comment; 33 | } MdmSession; 34 | 35 | void mdm_session_list_init (void); 36 | void _mdm_session_list_init (GHashTable **sessnames, 37 | GList **sessions, 38 | gchar **default_session, 39 | const gchar **current_session); 40 | gint mdm_session_sort_func (const char *a, const char *b); 41 | const char * mdm_session_name (const char *name); 42 | void mdm_session_list_from_hash_table_func (const char *key, 43 | const char *value, 44 | GList **sessions); 45 | gint mdm_session_sort_func (const char *a, 46 | const char *b); 47 | const char * mdm_get_default_session (void); 48 | 49 | #endif /* MDM_SESSION_H */ 50 | -------------------------------------------------------------------------------- /gui/mdmsetup.desktop.in.in: -------------------------------------------------------------------------------- 1 | [Desktop Entry] 2 | Encoding=UTF-8 3 | _Name=Login Window 4 | _Comment=Configure MDM login window appearance and behavior 5 | TryExec=@sbindir@/mdmsetup 6 | Exec=gksu @sbindir@/mdmsetup 7 | Icon=mdmsetup 8 | StartupNotify=true 9 | Terminal=false 10 | Type=Application 11 | Categories=GNOME;GTK;Settings;System;XFCE;X-XFCE-SettingsDialog;X-XFCE-SystemSettings; 12 | X-KDE-SubstituteUID=true 13 | X-GNOME-Bugzilla-Bugzilla=GNOME 14 | X-GNOME-Bugzilla-Product=mdm 15 | X-GNOME-Bugzilla-Component=general 16 | -------------------------------------------------------------------------------- /gui/mdmuser.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager 2 | * Copyright (C) 1999, 2000 Martin K. Petersen 3 | * 4 | * This file Copyright (c) 2003 George Lebl 5 | * - Common routines for the greeters. 6 | * 7 | * This program is free software; you can redistribute it and/or modify 8 | * it under the terms of the GNU General Public License as published by 9 | * the Free Software Foundation; either version 2 of the License, or 10 | * (at your option) any later version. 11 | * 12 | * This program is distributed in the hope that it will be useful, 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 | * GNU General Public License for more details. 16 | * 17 | * You should have received a copy of the GNU General Public License 18 | * along with this program; if not, write to the Free Software 19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 20 | */ 21 | 22 | #include "misc.h" 23 | 24 | #ifndef MDM_USER_H 25 | #define MDM_USER_H 26 | 27 | typedef struct _MdmUser MdmUser; 28 | struct _MdmUser { 29 | uid_t uid; 30 | char *login; 31 | char *homedir; 32 | char *gecos; 33 | GdkPixbuf *picture; 34 | }; 35 | 36 | gboolean mdm_is_user_valid (const char *username); 37 | gint mdm_user_uid (const char *username); 38 | const char *get_root_user (void); 39 | void mdm_users_init (GList **users, GList **users_string, 40 | char *exclude_user, GdkPixbuf *defface, 41 | int *size_of_users, gboolean is_local, 42 | gboolean read_faces); 43 | 44 | #endif /* MDM_USER_H */ 45 | -------------------------------------------------------------------------------- /gui/misc.h: -------------------------------------------------------------------------------- 1 | /* MDM - The MDM Display Manager - misc functions 2 | * Copyright (C) 1998, 1999, 2000 Martin K. Petersen 3 | * 4 | * This program is free software; you can redistribute it and/or modify 5 | * it under the terms of the GNU General Public License as published by 6 | * the Free Software Foundation; either version 2 of the License, or 7 | * (at your option) any later version. 8 | * 9 | * This program is distributed in the hope that it will be useful, 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 12 | * GNU General Public License for more details. 13 | * 14 | * You should have received a copy of the GNU General Public License 15 | * along with this program; if not, write to the Free Software 16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 17 | */ 18 | 19 | #ifndef MISC_H 20 | #define MISC_H 21 | 22 | void mdm_set_theme (const char *theme_name); 23 | gboolean mdm_working_command_exists (const char *commands); 24 | 25 | #endif /* MISC_H */ 26 | 27 | /* EOF */ 28 | -------------------------------------------------------------------------------- /gui/modules/AccessDwellMouseEvents.in: -------------------------------------------------------------------------------- 1 | # This is the configuration file for the keymouselistener.so module. 2 | # The confiuration syntax is as follows: 3 | # 4 | # crossing inital_direction timeout executable_path +args 5 | # 6 | # For executable_path give the full executable path path of the program or the 7 | # DefaultPath is used. 8 | # 9 | # where: 10 | # 11 | # + crossing is a string that includes any combination of TBLR characters, where 12 | # T means Top, B means Bottom, L means Left, and R means Right. 13 | # 14 | # + initial_direction can be either the I or O character which indicates 15 | # that the initial crossing is a motion In or Out of the window. 16 | # 17 | # e.g. 18 | # TBLR I 10000 @AT_BINDIR@/gok --login --access-method=dwellselection 19 | # 20 | # Means the user crosses into the top border, out the bottom border, into the left 21 | # border, and then out the right border (in that order). The initial_direction 22 | # value of I is what specifies that the first crossing is into the top border 23 | # rather than out of the top border. Each border crossing must occur within 24 | # 10000ms of the last border crossing for the gesture to be valid. 25 | # 26 | # It is possible to invoke multiple actions from a single gesture using the 27 | # keyword. Action specified with are invoked by the previous gesture 28 | # defined in the file. If the action is the first action defined in the 29 | # file, then it is ignored. 30 | # 31 | # e.g. 32 | # 33 | # @AT_BINDIR@/orca -n -d main-window 34 | # 35 | 36 | # AT Progarm - GOK (GNOME On-screen Keyboard) 37 | # 38 | # Support several different options for different user needs. Note these 39 | # gestures all start by moving the mouse into the top window border. 40 | # 41 | TBLR I 10000 @AT_BINDIR@/gok --login --access-method=dwellselection 42 | TLBR I 10000 @AT_BINDIR@/gok --login --access-method=automaticscanning --scan-action=switch1 --select-action=switch1 43 | TRBL I 10000 @AT_BINDIR@/gok --login --access-method=inversescanning --scan-action=switch1 --select-action=switch2 44 | TBRL I 10000 @AT_BINDIR@/gok --login --access-method=automaticscanning --scan-action=switch3 --select-action=switch3 45 | 46 | # AT Program - ORCA 47 | # 48 | # Note these gestures all start by moving the mouse into the bottom window 49 | # border. 50 | # 51 | # Speech 52 | # 53 | BTRL I 10000 @AT_BINDIR@/orca -n -d main-window 54 | 55 | # Magnifier 56 | # 57 | BTLR I 10000 @AT_BINDIR@/orca -n -d main-window -d speech -e magnifier 58 | 59 | # Speech and Magnifier 60 | # 61 | BRTL I 10000 @AT_BINDIR@/orca -n -d main-window -e magnifier 62 | 63 | -------------------------------------------------------------------------------- /gui/modules/Makefile.am: -------------------------------------------------------------------------------- 1 | ## Process this file with automake to produce makefile.in 2 | 3 | INCLUDES = \ 4 | -I. \ 5 | -I.. \ 6 | -DMDMCONFDIR=\"${mdmconfdir}\" \ 7 | -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \ 8 | $(GUI_CFLAGS) 9 | 10 | # 11 | # -DG_DISABLE_DEPRECATED \ 12 | # -DGDK_DISABLE_DEPRECATED \ 13 | # -DGDK_PIXBUF_DISABLE_DEPRECATED \ 14 | # -DGTK_DISABLE_DEPRECATED \ 15 | # -DGNOME_DISABLE_DEPRECATED \ 16 | # 17 | 18 | libkeymouselistener_la_SOURCES = \ 19 | keymouselistener.c 20 | 21 | libkeymouselistener_la_LDFLAGS = \ 22 | -rpath $(moduledir) -module -avoid-version \ 23 | $(GUI_LIBS) \ 24 | $(X_LIBS) \ 25 | $(X_EXTRA_LIBS) 26 | 27 | libdwellmouselistener_la_SOURCES = \ 28 | dwellmouselistener.c 29 | 30 | libdwellmouselistener_la_LDFLAGS = \ 31 | -rpath $(moduledir) -module -avoid-version \ 32 | $(GUI_LIBS) \ 33 | $(X_LIBS) \ 34 | $(X_EXTRA_LIBS) 35 | 36 | moduledir = $(libdir)/gtk-2.0/modules 37 | 38 | module_LTLIBRARIES = \ 39 | libkeymouselistener.la \ 40 | libdwellmouselistener.la 41 | 42 | moduleconfdir = $(mdmconfdir)/modules 43 | 44 | noinst_DATA = \ 45 | AccessKeyMouseEvents \ 46 | AccessDwellMouseEvents 47 | 48 | EXTRA_DIST = \ 49 | AccessKeyMouseEvents.in \ 50 | AccessDwellMouseEvents.in 51 | 52 | CLEANFILES = AccessKeyMouseEvents AccessDwellMouseEvents 53 | 54 | AccessKeyMouseEvents: $(srcdir)/AccessKeyMouseEvents.in 55 | sed -e 's,[@]AT_BINDIR[@],$(AT_BINDIR),g' \ 56 | <$(srcdir)/AccessKeyMouseEvents.in >AccessKeyMouseEvents 57 | 58 | AccessDwellMouseEvents: $(srcdir)/AccessDwellMouseEvents.in 59 | sed -e 's,[@]AT_BINDIR[@],$(AT_BINDIR),g' \ 60 | <$(srcdir)/AccessDwellMouseEvents.in >AccessDwellMouseEvents 61 | 62 | uninstall-hook: 63 | rm -f $(DESTDIR)$(moduleconfdir)/AccessKeyMouseEvents \ 64 | $(DESTDIR)$(moduleconfdir)/factory-AccessKeyMouseEvents \ 65 | $(DESTDIR)$(moduleconfdir)/AccessDwellMouseEvents \ 66 | $(DESTDIR)$(moduleconfdir)/factory-AccessDwellMouseEvents 67 | 68 | install-data-hook: AccessKeyMouseEvents AccessDwellMouseEvents 69 | if test '!' -d $(DESTDIR)$(moduleconfdir); then \ 70 | $(mkinstalldirs) $(DESTDIR)$(moduleconfdir); \ 71 | chmod 755 $(DESTDIR)$(moduleconfdir); \ 72 | fi 73 | -if cmp -s $(DESTDIR)$(moduleconfdir)/AccessKeyMouseEvents $(DESTDIR)$(moduleconfdir)/factory-AccessKeyMouseEvents 2>&1 /dev/null ; then \ 74 | cp -f $(DESTDIR)$(moduleconfdir)/AccessKeyMouseEvents $(DESTDIR)$(moduleconfdir)/AccessKeyMouseEvents.orig; \ 75 | $(INSTALL_DATA) AccessKeyMouseEvents $(DESTDIR)$(moduleconfdir)/AccessKeyMouseEvents; \ 76 | fi 77 | if test '!' -f $(DESTDIR)$(moduleconfdir)/AccessKeyMouseEvents; then \ 78 | $(INSTALL_DATA) AccessKeyMouseEvents $(DESTDIR)$(moduleconfdir)/AccessKeyMouseEvents; \ 79 | fi 80 | $(INSTALL_DATA) AccessKeyMouseEvents $(DESTDIR)$(moduleconfdir)/factory-AccessKeyMouseEvents 81 | -if cmp -s $(DESTDIR)$(moduleconfdir)/AccessDwellMouseEvents $(DESTDIR)$(moduleconfdir)/factory-AccessDwellMouseEvents 2>&1 /dev/null ; then \ 82 | cp -f $(DESTDIR)$(moduleconfdir)/AccessDwellMouseEvents $(DESTDIR)$(moduleconfdir)/AccessDwellMouseEvents.orig; \ 83 | $(INSTALL_DATA) AccessDwellMouseEvents $(DESTDIR)$(moduleconfdir)/AccessDwellMouseEvents; \ 84 | fi 85 | if test '!' -f $(DESTDIR)$(moduleconfdir)/AccessDwellMouseEvents; then \ 86 | $(INSTALL_DATA) AccessDwellMouseEvents $(DESTDIR)$(moduleconfdir)/AccessDwellMouseEvents; \ 87 | fi 88 | $(INSTALL_DATA) AccessDwellMouseEvents $(DESTDIR)$(moduleconfdir)/factory-AccessDwellMouseEvents 89 | -------------------------------------------------------------------------------- /makepot: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | intltool-extract --type=gettext/glade gui/mdmsetup.glade 4 | 5 | xgettext --language=C --from-code=UTF-8 --keyword=_ --keyword=N_ --output=mdm.pot gui/mdmwebkit.c gui/mdmsetup.c gui/mdmsetup.glade.h 6 | 7 | rm -f gui/mdmsetup.glade.h 8 | 9 | -------------------------------------------------------------------------------- /pixmaps/24x24/Makefile.am: -------------------------------------------------------------------------------- 1 | # This file will be processed with automake-1.7 to create Makefile.in 2 | 3 | icons = \ 4 | preferences-desktop-locale.png \ 5 | preferences-desktop-remote-desktop.png \ 6 | system-log-out.png \ 7 | system-restart.png \ 8 | system-shut-down.png \ 9 | system-suspend.png \ 10 | user-desktop.png 11 | 12 | icon_names = \ 13 | preferences_desktop_locale_24 $(srcdir)/preferences-desktop-locale.png \ 14 | preferences_desktop_remote_desktop_24 $(srcdir)/preferences-desktop-remote-desktop.png \ 15 | system_log_out_24 $(srcdir)/system-log-out.png \ 16 | system_restart_24 $(srcdir)/system-restart.png \ 17 | system_shut_down_24 $(srcdir)/system-shut-down.png \ 18 | system_suspend_24 $(srcdir)/system-suspend.png \ 19 | user_desktop_24 $(srcdir)/user-desktop.png 20 | 21 | EXTRA_DIST = $(icons) 22 | BUILT_SOURCES = inlines.h 23 | CLEANFILES = $(BUILT_SOURCES) 24 | 25 | inlines.h: $(icons) 26 | gdk-pixbuf-csource --raw --build-list $(icon_names) > $@ 27 | 28 | -------------------------------------------------------------------------------- /pixmaps/24x24/preferences-desktop-locale.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/24x24/preferences-desktop-locale.png -------------------------------------------------------------------------------- /pixmaps/24x24/preferences-desktop-remote-desktop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/24x24/preferences-desktop-remote-desktop.png -------------------------------------------------------------------------------- /pixmaps/24x24/system-log-out.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/24x24/system-log-out.png -------------------------------------------------------------------------------- /pixmaps/24x24/system-restart.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/24x24/system-restart.png -------------------------------------------------------------------------------- /pixmaps/24x24/system-shut-down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/24x24/system-shut-down.png -------------------------------------------------------------------------------- /pixmaps/24x24/system-suspend.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/24x24/system-suspend.png -------------------------------------------------------------------------------- /pixmaps/24x24/user-desktop.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/24x24/user-desktop.png -------------------------------------------------------------------------------- /pixmaps/48x48/Makefile.am: -------------------------------------------------------------------------------- 1 | # This file will be processed with automake-1.7 to create Makefile.in 2 | 3 | appsicondir = \ 4 | $(datadir)/icons/hicolor/48x48/apps 5 | dist_appsicon_DATA = \ 6 | mdm.png 7 | 8 | MAINTAINERCLEANFILES = \ 9 | Makefile.in 10 | -------------------------------------------------------------------------------- /pixmaps/48x48/mdm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/48x48/mdm.png -------------------------------------------------------------------------------- /pixmaps/Makefile.am: -------------------------------------------------------------------------------- 1 | 2 | SUBDIRS = \ 3 | 24x24 48x48 4 | 5 | pixmapdir = $(datadir)/pixmaps 6 | 7 | BITMAPS = nobody.png nohost.png 8 | 9 | pixmap_DATA = $(BITMAPS) 10 | 11 | EXTRA_DIST = $(BITMAPS) 12 | 13 | gtk_update_icon_cache = gtk-update-icon-cache -f -t $(datadir)/icons/hicolor 14 | 15 | install-data-hook: update-icon-cache 16 | uninstall-hook: update-icon-cache 17 | update-icon-cache: 18 | @-if test -z "$(DESTDIR)"; then \ 19 | echo "Updating Gtk icon cache."; \ 20 | $(gtk_update_icon_cache); \ 21 | else \ 22 | echo "*** Icon cache not updated. After (un)install, run this:"; \ 23 | echo "*** $(gtk_update_icon_cache)"; \ 24 | fi 25 | -------------------------------------------------------------------------------- /pixmaps/nobody.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/nobody.png -------------------------------------------------------------------------------- /pixmaps/nohost.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/linuxmint/mdm/31845a618704ea6b4adcd44f69a70cba1f949b95/pixmaps/nohost.png -------------------------------------------------------------------------------- /po/LINGUAS: -------------------------------------------------------------------------------- 1 | # please keep this list sorted alphabetically 2 | # 3 | af 4 | am 5 | ar 6 | as 7 | az 8 | be 9 | bg 10 | bn 11 | bn_IN 12 | bs 13 | ca 14 | cs 15 | cy 16 | da 17 | de 18 | dz 19 | el 20 | en_AU 21 | en_CA 22 | en_GB 23 | eo 24 | es 25 | et 26 | eu 27 | fa 28 | fi 29 | fr 30 | fr_CA 31 | frp 32 | ga 33 | gd 34 | gl 35 | gu 36 | he 37 | hi 38 | hr 39 | hu 40 | hy 41 | ia 42 | id 43 | ii 44 | is 45 | it 46 | ja 47 | ka 48 | kab 49 | kk 50 | km 51 | kn 52 | ko 53 | ksw 54 | ku 55 | ky 56 | lo 57 | lt 58 | lv 59 | mg 60 | mi 61 | mk 62 | ml 63 | mn 64 | mr 65 | ms 66 | mus 67 | my 68 | nb 69 | nds 70 | ne 71 | nl 72 | nn 73 | nso 74 | oc 75 | om 76 | or 77 | pa 78 | pap 79 | pl 80 | pt 81 | pt_BR 82 | ro 83 | ru 84 | rw 85 | sc 86 | shn 87 | si 88 | sk 89 | sl 90 | sq 91 | sr 92 | sr@latin 93 | sr@Latn 94 | sv 95 | ta 96 | te 97 | tg 98 | th 99 | tr 100 | uk 101 | ur 102 | uz 103 | uz@cyrillic 104 | vi 105 | wa 106 | xh 107 | zh_CN 108 | zh_HK 109 | zh_TW 110 | zu 111 | -------------------------------------------------------------------------------- /po/POTFILES.in: -------------------------------------------------------------------------------- 1 | # Files with translatable strings. 2 | # Please keep this file in alphabetical order. 3 | common/mdm-config.c 4 | config/CDE.desktop.in 5 | config/default.desktop.in.in 6 | config/gettextfoo.h 7 | config/gnome.desktop.in.in 8 | config/ssh.desktop.in.in 9 | daemon/auth.c 10 | daemon/display.c 11 | daemon/errorgui.c 12 | daemon/filecheck.c 13 | daemon/mdm-daemon-config-keys.h 14 | daemon/mdm-daemon-config.c 15 | daemon/mdm-net.c 16 | daemon/mdm-xdmcp-manager.c 17 | daemon/mdm.c 18 | daemon/misc.c 19 | daemon/server.c 20 | daemon/slave.c 21 | daemon/verify-crypt.c 22 | daemon/verify-pam.c 23 | daemon/verify-shadow.c 24 | daemon/xdmcp.c 25 | gui/mdmXnestchooser.c 26 | gui/mdmchooser.c 27 | gui/mdmchooser.glade 28 | gui/mdmcomm.c 29 | gui/mdmcommon.c 30 | gui/mdmdynamic.c 31 | gui/mdmflexiserver-xnest.desktop.in.in 32 | gui/mdmflexiserver.c 33 | gui/mdmflexiserver.desktop.in 34 | gui/mdmlanguages.c 35 | gui/mdmlogin.c 36 | gui/mdmphotosetup.c 37 | gui/mdmphotosetup.desktop.in 38 | gui/mdmphotosetup.glade 39 | gui/mdmsession.c 40 | gui/mdmsetup.c 41 | gui/mdmsetup.desktop.in.in 42 | gui/mdmsetup.glade 43 | gui/mdmuser.c 44 | gui/mdmwm.c 45 | gui/greeter/greeter.c 46 | gui/greeter/greeter_canvas_item.c 47 | gui/greeter/greeter_item.c 48 | gui/greeter/greeter_item_customlist.c 49 | gui/greeter/greeter_item_ulist.c 50 | gui/greeter/greeter_parser.c 51 | gui/greeter/greeter_session.c 52 | gui/greeter/greeter_system.c 53 | gui/greeter/themes/circles/MdmGreeterTheme.desktop.in 54 | gui/greeter/themes/happygnome-list/MdmGreeterTheme.desktop.in 55 | gui/greeter/themes/happygnome/MdmGreeterTheme.desktop.in 56 | gui/modules/dwellmouselistener.c 57 | gui/modules/keymouselistener.c 58 | utils/mdm-dmx-reconnect-proxy.c 59 | utils/mdmaskpass.c 60 | -------------------------------------------------------------------------------- /po/POTFILES.skip: -------------------------------------------------------------------------------- 1 | # Files with translatable strings to skip. 2 | # Please keep this file in alphabetical order. 3 | # 4 | # The following three desktop.in files are generated files, so 5 | # it is not necessary to check them for translatable strings. 6 | # Without these files, "make distcheck" fails. Please do not 7 | # remove these unless you fix "make distcheck" a different way. 8 | # 9 | config/default.desktop.in 10 | config/gnome.desktop.in 11 | config/ssh.desktop.in 12 | gui/mdmsetup.desktop.in 13 | gui/mdmflexiserver-xnest.desktop.in 14 | vicious-extensions/glade-helper.c 15 | vicious-extensions/ve-nongnome.c 16 | -------------------------------------------------------------------------------- /utils/Makefile.am: -------------------------------------------------------------------------------- 1 | NULL = 2 | 3 | DEFS = @DEFS@ -DMDM_CONFIG_FILE=\"$(mdmconfdir)/mdm.conf\" \ 4 | -DMDM_FACTORY_CONFIG_FILE=\"$(mdmconfdir)/factory-mdm.conf\" \ 5 | -DMDM_GLADE_DIR=\"@datadir@/mdm\" 6 | 7 | INCLUDES = \ 8 | -I. \ 9 | -I.. \ 10 | -I$(top_srcdir)/daemon \ 11 | -I$(top_srcdir)/vicious-extensions \ 12 | -DGNOMELOCALEDIR=\""$(datadir)/locale"\" \ 13 | $(UTILS_CFLAGS) 14 | 15 | edit = sed \ 16 | -e 's|@sbindir[@]|$(sbindir)|g' \ 17 | -e 's|@sysconfdir[@]|$(sysconfdir)|g' \ 18 | -e 's|@localstatedir[@]|$(localstatedir)|g' \ 19 | -e 's|@MDM_PID_FILE[@]|$(MDM_PID_FILE)|g' 20 | 21 | mdm-stop: mdm-stop.in Makefile 22 | $(edit) $< >$@ 23 | mdm-restart: mdm-restart.in Makefile 24 | $(edit) $< >$@ 25 | mdm-safe-restart: mdm-safe-restart.in Makefile 26 | $(edit) $< >$@ 27 | mdmsetup: mdmsetup-security.in 28 | $(edit) mdmsetup 29 | 30 | 31 | sbin_SCRIPTS = \ 32 | mdm-stop \ 33 | mdm-restart \ 34 | mdm-safe-restart \ 35 | $(NULL) 36 | 37 | EXTRA_DIST = \ 38 | mdm-ssh-session \ 39 | mdm-stop.in \ 40 | mdm-restart.in \ 41 | mdm-safe-restart.in \ 42 | mdmsetup-pam \ 43 | mdmsetup-security.in \ 44 | $(NULL) 45 | 46 | libexec_SCRIPTS = \ 47 | @MDMSSHSESSION@ 48 | 49 | libexec_PROGRAMS = \ 50 | @MDMASKPASS@ \ 51 | @MDMOPEN@ \ 52 | @MDMPREFETCH@ \ 53 | mdmtranslate 54 | 55 | if DMX_SUPPORT 56 | bin_PROGRAMS = mdm-dmx-reconnect-proxy 57 | endif 58 | 59 | EXTRA_SCRIPTS = mdm-ssh-session 60 | EXTRA_PROGRAMS = mdmaskpass mdmopen mdmprefetch 61 | 62 | mdmaskpass_SOURCES = \ 63 | mdmaskpass.c 64 | 65 | mdmtranslate_SOURCES = \ 66 | mdmtranslate.c 67 | 68 | mdmopen_SOURCES = \ 69 | mdmopen.c 70 | 71 | mdmprefetch_SOURCES = \ 72 | mdmprefetch.c 73 | 74 | mdmaskpass_LDADD = \ 75 | $(INTLLIBS) \ 76 | -lpam \ 77 | $(EXTRA_MDMASKPASS_LIBS) 78 | 79 | mdmopen_LDADD = \ 80 | $(INTLLIBS) 81 | 82 | mdmtranslate_LDADD = \ 83 | $(INTLLIBS) 84 | 85 | if DMX_SUPPORT 86 | mdm_dmx_reconnect_proxy_SOURCES = \ 87 | mdm-dmx-reconnect-proxy.c 88 | 89 | mdm_dmx_reconnect_proxy_LDADD = \ 90 | $(GLIB_LIBS) \ 91 | $(X_EXTRA_LIBS) \ 92 | $(X_LIBS) \ 93 | -lX11 \ 94 | $(DMX_LIBS) 95 | endif 96 | 97 | if CONSOLE_HELPER 98 | cappsdir = $(PAM_PREFIX)/security/console.apps 99 | capps_DATA = mdmsetup 100 | 101 | install-data-local: 102 | $(mkinstalldirs) $(DESTDIR)$(PAM_PREFIX)/pam.d 103 | $(INSTALL_DATA) $(srcdir)/mdmsetup-pam $(DESTDIR)$(PAM_PREFIX)/pam.d/mdmsetup 104 | else 105 | install-data-local: 106 | endif 107 | 108 | CLEANFILES = \ 109 | mdmsetup-security \ 110 | $(NULL) 111 | 112 | DISTCLEANFILES = \ 113 | mdmsetup \ 114 | mdm-stop \ 115 | mdm-restart \ 116 | mdm-safe-restart \ 117 | $(NULL) 118 | 119 | -------------------------------------------------------------------------------- /utils/mdm-restart.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | PIDFILE=@MDM_PID_FILE@ 4 | if test '!' -f $PIDFILE ; then 5 | echo "$PIDFILE doesn't exist, perhaps MDM isn't running" 6 | exit 1 7 | fi 8 | # exec the kill to get the correct return code 9 | exec kill -HUP `cat $PIDFILE` 10 | -------------------------------------------------------------------------------- /utils/mdm-safe-restart.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | PIDFILE=@MDM_PID_FILE@ 4 | if test '!' -f $PIDFILE ; then 5 | echo "$PIDFILE doesn't exist, perhaps MDM isn't running" 6 | exit 1 7 | fi 8 | # exec the kill to get the correct return code 9 | exec kill -USR1 `cat $PIDFILE` 10 | -------------------------------------------------------------------------------- /utils/mdm-ssh-session: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | ZENITY=`which zenity` 4 | TARGETHOSTPORT=`$ZENITY --title "Host and Port to connect to" --entry --text "Enter the name of the host and Port (host:port) you want to log in to."` 5 | TARGETHOST=${TARGETHOSTPORT%:*} 6 | TARGETPORT=${TARGETHOSTPORT#*:} 7 | 8 | if [[ ! $TARGETHOSTPORT =~ ":" ]]; then 9 | TARGETPORT="22" 10 | fi 11 | 12 | # @@@ should probably get a user name too; 13 | # for now can bet set using the $USERNAME@ convention 14 | # @@@ should it do an ssh-add so the user doesn't have to enter its passphrase again? 15 | ssh -A -X -T -n "$TARGETHOST" -p "$TARGETPORT" /etc/X11/Xsession 16 | -------------------------------------------------------------------------------- /utils/mdm-stop.in: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | PIDFILE=@MDM_PID_FILE@ 4 | if test '!' -f $PIDFILE ; then 5 | echo "$PIDFILE doesn't exist, perhaps MDM isn't running" 6 | exit 1 7 | fi 8 | # exec the kill to get the correct return code 9 | exec kill -TERM `cat $PIDFILE` 10 | -------------------------------------------------------------------------------- /utils/mdmaskpass.c: -------------------------------------------------------------------------------- 1 | /* Simple pam thingie to ask the root password, for use in XKeepsCrashing 2 | * script. */ 3 | #include "config.h" 4 | #include 5 | #include 6 | #include 7 | #include 8 | #include 9 | #include 10 | 11 | static struct pam_conv conv = { 12 | misc_conv, 13 | NULL 14 | }; 15 | 16 | int 17 | main (int argc, char *argv[]) 18 | { 19 | pam_handle_t *pamh; 20 | const char *username = "root"; 21 | int retval; 22 | int tries = 3; 23 | 24 | if (getuid () != geteuid () || 25 | getuid () != 0) { 26 | fprintf (stderr, _("mdmaskpass only runs as root\n")); 27 | return 1; 28 | } 29 | 30 | if (argc >= 2) { 31 | username = argv[1]; 32 | } 33 | 34 | setlocale (LC_ALL, ""); 35 | bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR); 36 | textdomain (GETTEXT_PACKAGE); 37 | 38 | for (tries = 3; tries > 0; tries --) { 39 | if ((retval = pam_start ("mdm", username, &conv, &pamh)) != PAM_SUCCESS) { 40 | pam_end (pamh, retval); 41 | pamh = NULL; 42 | printf (_("Authentication failure!\n")); 43 | continue; 44 | } 45 | if ((retval = pam_authenticate (pamh, 0)) != PAM_SUCCESS) { 46 | pam_end (pamh, retval); 47 | pamh = NULL; 48 | printf (_("Authentication failure!\n")); 49 | continue; 50 | } 51 | break; 52 | } 53 | 54 | if (pamh != NULL) 55 | pam_end (pamh, retval); 56 | 57 | return (retval == PAM_SUCCESS) ? 0 : 1; 58 | } 59 | -------------------------------------------------------------------------------- /utils/mdmsetup-pam: -------------------------------------------------------------------------------- 1 | #%PAM-1.0 2 | auth sufficient pam_rootok.so 3 | auth include system-auth 4 | session required pam_permit.so 5 | session optional pam_xauth.so 6 | account required pam_permit.so 7 | -------------------------------------------------------------------------------- /utils/mdmsetup-security.in: -------------------------------------------------------------------------------- 1 | USER=root 2 | PROGRAM=@sbindir@/mdmsetup 3 | SESSION=true 4 | FALLBACK=false 5 | 6 | -------------------------------------------------------------------------------- /utils/mdmtranslate.c: -------------------------------------------------------------------------------- 1 | #include "config.h" 2 | #include 3 | #include 4 | #include 5 | #include 6 | 7 | #define gboolean char 8 | #define FALSE 0 9 | #define TRUE 1 10 | 11 | #ifdef ENABLE_NLS 12 | #include 13 | #define _(String) gettext(String) 14 | #else /* !ENABLE_NLS */ 15 | #define _(String) (String) 16 | #endif 17 | 18 | int 19 | main (int argc, char *argv[]) 20 | { 21 | char *string; 22 | gboolean is_utf8 = FALSE; 23 | 24 | if (argc == 3 && 25 | strcmp (argv[1], "--utf8") == 0) { 26 | string = argv[2]; 27 | is_utf8 = TRUE; 28 | } else if (argc == 2) { 29 | string = argv[1]; 30 | is_utf8 = FALSE; 31 | } else { 32 | fprintf (stderr, "usage: mdmtranslate [--utf8] \n"); 33 | return 0; 34 | } 35 | 36 | if (getenv ("UNSAFE_TO_TRANSLATE") != NULL && 37 | strcmp (getenv ("UNSAFE_TO_TRANSLATE"), "yes") == 0) { 38 | printf ("%s\n", string); 39 | return 0; 40 | } 41 | 42 | setlocale (LC_ALL, ""); 43 | bindtextdomain (GETTEXT_PACKAGE, GNOMELOCALEDIR); 44 | if (is_utf8) 45 | bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8"); 46 | textdomain (GETTEXT_PACKAGE); 47 | 48 | printf ("%s\n", _(string)); 49 | 50 | return 0; 51 | } 52 | --------------------------------------------------------------------------------