summaryrefslogtreecommitdiff
path: root/daemon/gdm-session-direct.c
Commit message (Collapse)AuthorAgeFilesLines
* Add ConsoleKit MultiSeat support. See bug 536355.wip/multi-seatBrian Cameron2011-12-151-0/+263
|
* daemon: don't set LANG to empty valueRay Strode2011-06-131-6/+12
| | | | | | This makes PAM not set it to a proper value later. https://bugzilla.gnome.org/show_bug.cgi?id=649413
* daemon: Distinguish "pam module failed" from "authentication failed"Ray Strode2011-06-131-3/+23
| | | | | | | | If pam_start() fails, that suggests the configured service stack is failing independent of the user account. This commit exposes that failure as "service unavailable" instead of "authentication failed".
* daemon: Store multiple conversations in the sessionRay Strode2011-06-131-181/+418
| | | | | | We keep multiple conversations in the session now, keyed off of which PAM service is at the other end. Much of the guts still only operate on the first conversation added though.
* daemon: Rename session worker to the service it's managingRay Strode2011-06-131-1/+6
| | | | | This way when we're running multiple PAM conversations at once it will be obvious which worker is managing which conversation.
* daemon: Make current pam conversation explicit throughout codeRay Strode2011-06-131-120/+194
| | | | | | | | | | | | | | We want to eventually support having multiple simultaneous PAM conversations in one login screen (so, e.g., username/password, smart card, and fingerprint all work at the same time). This commit refactors the session code to be in terms of a conversation object. With this change, it should be easier later to have multiple conversation objects. The conversation is named by the pam service the login screen is talking to.
* daemon,greeter: drop support for keyboard layout selectionRay Strode2011-01-311-122/+0
| | | | | It's no longer exposed in the UI, and it never really worked well, so drop it for now.
* daemon: drop GDM_KEYBOARD_LAYOUT environment variableRay Strode2011-01-271-7/+0
| | | | | | | | | I just noticed commit 4b177ed3c1998d9cd2f203f5c635b3f73ca4aecd reversed the conditional and that was many, many moons ago, so the code is essentially useless. Drop it.
* Reorganize logindevperm code so that logindevperm logout is called from the ↵Brian Cameron2010-12-171-0/+8
| | | | | | slave rather than the worker.
* Fix various compiler warningsWilliam Jon McCann2010-06-171-4/+7
|
* Don't leak the fallback session nameWilliam Jon McCann2010-06-171-6/+25
|
* Various memory leak fixesWang Xin2010-06-171-5/+2
| | | | | https://bugzilla.gnome.org/show_bug.cgi?id=620430 With help from Pablo Castellano
* Add missing include left out of previous commit.Brian Cameron2010-06-091-0/+1
|
* If the user's .dmrc file specifies the "custom" session, then accept itBrian Cameron2010-06-091-9/+15
| | | | | | even if there is no corresponding desktop file since it has special meaning to the /etc/gdm/Xsession script for launching $HOME/.xsession. Fixes bug 619129.
* Check envrioment WINDOWPATH before setting it.Halton Huo2010-05-141-3/+5
| | | | Fixes https://bugzilla.gnome.org/show_bug.cgi?id=618510
* Sort session using file basenameFrederic Crozat2010-05-031-5/+23
| | | | | Ensure behaviour in default / fallback session is consistent with gdm <= 2.20. Fixes Mandriva bug 58501 / GNOME bug 617516.
* Set WINDOWPATH for user session. Fixes bug #609272.Brian Cameron2010-04-211-6/+11
|
* Don't tear down greeter until pam_open_session finishesRay Strode2010-02-081-0/+67
| | | | | | Some PAM modules ask questions at that late stage of the game, and so we need a greeter to forward the questions on to the user.
* Rename session "Open" method to "StartConversation"Ray Strode2010-02-081-5/+5
| | | | | | | Open is very general. If we rename it, then we can use the term "open" for the state after PAM finishes checking identity, authorizing, and giving out credentials, before a session is started.
* Revert "init session pid to -1"Ray Strode2010-02-081-0/+1
| | | | | | This reverts commit da3d88004af9e0fc69a70282f261df409a008eb2. It's not correct and was accidentally pushed.
* init session pid to -1Ray Strode2010-02-081-1/+0
|
* Allow building without libxklavier. Fixes bug #606808.Brian Cameron2010-01-261-2/+6
|
* Don't double-free TryExec variableRay Strode2010-01-201-0/+1
| | | | | If the program could not be found the exec variable would get freed twice.
* Fix crash in getting system keyboard layoutMartin Pitt2010-01-181-11/+12
| | | | | | | | | | | In get_system_default_layout(), use a static variable for xkl_engine_get_instance() result, and don't close the X Display. This fixes the crash that happens at the second call of get_system_default_layout(): xkl_engine_get_instance() returns a singleton which saves the passed X Display instance, so we must never close it. https://launchpad.net/bugs/505972
* Detect default layout with xklavierMartin Pitt2010-01-121-3/+36
| | | | | | Try to read the default layout by connecting to the X server. https://bugzilla.gnome.org/show_bug.cgi?id=572765
* Fix X-GDM-BypassXSession to X-GDM-BypassXsession.Brian Cameron2009-11-241-1/+1
|
* Allow session scripts to bypass Xsession launcherNiall Power2009-11-181-1/+56
| | | | | | | | | | | It is occasionally useful to launch sessions that aren't run through Xsession. This is good, for starting a bare xterm session for instance. We now allow a session to specify that it shouldn't be run through the Xsession script with the key file entry: X-GDM-BypassXsession=true
* Don't send auth-failed when worker diesRay Strode2009-10-221-10/+2
| | | | | | Authentication hasn't failed, it just got aborted before it could. This prevents a crash that happens when switching runlevels while the login screen is up.
* Drop "stopped" signal from worker-job classRay Strode2009-10-211-14/+0
| | | | It was unused, dead code.
* Fix a g_debug line that is crashing on Solaris due to a NULL being passed in.Brian Cameron2009-09-031-1/+2
| | | | | The crash would happen if Autologin is turned on, but gdm-autologin is not defined in /etc/pam.conf.
* Don't ever bubble up messages about "workers" to the userRay Strode2009-07-171-10/+2
| | | | | That's a made up concept used solely by the implementation, and is not something the user should ever be confronted with.
* Only set GDM_KEYBOARD_LAYOUT if layout is not-defaultRay Strode2009-07-161-3/+6
| | | | | | | If it's default then the right thing should automatically anyway. See http://bugzilla.gnome.org/show_bug.cgi?id=572765
* Propagate PAM error messages up to userDavid Liang2009-07-151-5/+5
| | | | | | Previously, some messages were getting dropped. http://bugzilla.gnome.org/show_bug.cgi?id=574338
* Remove duplicate codeDavid Liang2009-07-151-12/+0
| | | | | Some conditional checks were repeated in a large else if block in session_worker_message leading to dead code.
* Set is_authenticated to TRUE when authenticatedRay Strode2009-05-071-0/+2
| | | | | | Before the flag was never getting set causing btmp records to get written when the session and slave are killed around the same time (by switching runlevels)
* Use a callback for the fatal handler instead of supplying the main_loop.William Jon McCann2008-08-151-0/+14
| | | | | | | | | | | | | | | | | | | | | 2008-08-15 William Jon McCann <jmccann@redhat.com> * common/gdm-signal-handler.c (signal_io_watch), (gdm_signal_handler_set_fatal_func): * common/gdm-signal-handler.h: * daemon/factory-slave-main.c (main): * daemon/gdm-session-direct.c (stop_worker): * daemon/gdm-session-worker-job.c (session_worker_job_child_watch): * daemon/main.c (main): * daemon/product-slave-main.c (main): * daemon/session-worker-main.c (main): * daemon/simple-slave-main.c (main): * daemon/xdmcp-chooser-slave-main.c (main): Use a callback for the fatal handler instead of supplying the main_loop. svn path=/trunk/; revision=6382
* Move ConsoleKit registration into the worker so that ConsoleKit can probeWilliam Jon McCann2008-07-311-90/+0
| | | | | | | | | | | | | | | | 2008-07-30 William Jon McCann <jmccann@redhat.com> * daemon/Makefile.am: * daemon/gdm-session-direct.c (setup_session_environment), (gdm_session_direct_close): * daemon/gdm-session-worker.c (open_ck_session), (register_ck_session), (session_worker_child_watch), (gdm_session_worker_start_user_session): Move ConsoleKit registration into the worker so that ConsoleKit can probe the caller (ie. session leader) correctly. svn path=/trunk/; revision=6339
* Add a keyboard chooserMatthias Clasen2008-05-051-0/+93
| | | | svn path=/trunk/; revision=6212
* Fallback to *any* session desktop file if we can't find a better oneRay Strode2008-04-081-123/+180
| | | | | | | | | | | | | 2008-04-07 Ray Strode <rstrode@redhat.com> * daemon/gdm-session-direct.c (get_system_session_dirs), (get_fallback_session_name), (get_default_session_name): Fallback to *any* session desktop file if we can't find a better one svn path=/trunk/; revision=6132
* Plug tiny leakRay Strode2008-04-081-0/+1
| | | | | | | | | | 2008-04-07 Ray Strode <rstrode@redhat.com> * gui/simple-greeter/gdm-session-direct.c (get_session_command_for_name): Plug tiny leak svn path=/trunk/; revision=6130
* Make PATH setup consistent between two fileRay Strode2008-03-191-1/+10
| | | | | | | | | | | | 2008-03-19 Ray Strode <rstrode@redhat.com> * daemon/gdm-session-worker.c (gdm_session_worker_accredit_user): * daemon/gdm-session-direct.c (setup_session_environment): Make PATH setup consistent between two file svn path=/trunk/; revision=6043
* Add preliminary support to the state machine for session unlocking.William Jon McCann2008-03-151-0/+12
| | | | | | | | | | | | | | | 2008-03-15 William Jon McCann <jmccann@redhat.com> * daemon/gdm-session-direct.c: (session_worker_message): * daemon/gdm-session-worker.c: (on_reauthenticate), (on_reauthorize), (on_refresh_credentials), (worker_dbus_handle_message): * daemon/gdm-session-worker.h: Add preliminary support to the state machine for session unlocking. svn path=/trunk/; revision=6019
* Refactor things a little. Rename renew to refresh. Add a pid to theWilliam Jon McCann2008-03-141-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-03-14 William Jon McCann <jmccann@redhat.com> * daemon/gdm-manager.c: (bus_name_owner_changed): * daemon/gdm-product-slave.c: (send_dbus_string_method), (send_dbus_void_method), (send_dbus_int_method), (relay_session_started), (on_session_started), (on_relay_refresh_credentials), (relay_dbus_handle_message): * daemon/gdm-session-direct.c: (gdm_session_direct_handle_session_started), (do_introspect), (gdm_session_direct_accredit): * daemon/gdm-session-private.h: * daemon/gdm-session-relay.c: (gdm_session_relay_accredit), (handle_secret_info_query), (handle_info), (handle_problem), (handle_session_started), (do_introspect), (gdm_session_iface_init): * daemon/gdm-session-worker.c: (gdm_session_worker_update_environment_from_passwd_info), (_change_user), (_lookup_passwd_info), (gdm_session_worker_accredit_user), (on_refresh_credentials), (worker_dbus_handle_message): * daemon/gdm-session.c: (gdm_session_class_init), (_gdm_session_session_started): * daemon/gdm-session.h: * daemon/gdm-simple-slave.c: (on_session_started), (gdm_simple_slave_accredit_when_ready), (on_greeter_connected): * daemon/gdm-slave.c: (gdm_slave_get_primary_session_id_for_user), (gdm_slave_switch_to_user_session): * daemon/gdm-slave.h: Refactor things a little. Rename renew to refresh. Add a pid to the session started signal. svn path=/trunk/; revision=6018
* Put the SessionDirect on the bus. Doesn't do anything yet.William Jon McCann2008-03-061-1/+127
| | | | | | | | | | | | | | | | | | | | | | | | | 2008-03-05 William Jon McCann <jmccann@redhat.com> * daemon/Makefile.am: * daemon/gdm-product-slave.c: (create_new_session): * daemon/gdm-session-direct.c: (gdm_session_direct_init), (_gdm_session_direct_set_display_id), (gdm_session_direct_set_property), (gdm_session_direct_get_property), (gdm_session_direct_dispose), (gdm_session_direct_finalize), (register_session), (gdm_session_direct_constructor), (gdm_session_direct_class_init), (gdm_session_direct_new), (gdm_session_direct_restart), (gdm_session_direct_stop), (gdm_session_direct_detach): * daemon/gdm-session-direct.h: * daemon/gdm-session-direct.xml: * daemon/gdm-simple-slave.c: (create_new_session): * daemon/gdm-slave.c: (gdm_slave_constructor): * daemon/test-session.c: (main): * data/gdm.conf: Put the SessionDirect on the bus. Doesn't do anything yet. svn path=/trunk/; revision=5938
* Don't bail if TryExec isn't set. It's optional.Ray Strode2008-02-281-13/+10
| | | | | | | | | | 2008-02-28 Ray Strode <rstrode@redhat.com> * daemon/gdm-session-direct.c (get_session_command_for_file): Don't bail if TryExec isn't set. It's optional. svn path=/trunk/; revision=5892
* Tell worker about language/session changes the user makes from the greeterRay Strode2008-02-261-0/+12
| | | | | | | | | | | | 2008-02-26 Ray Strode <rstrode@redhat.com> * daemon/gdm-session-direct.c (do_introspect), (gdm_session_direct_select_session), (gdm_session_direct_select_language): Tell worker about language/session changes the user makes from the greeter svn path=/trunk/; revision=5881
* Verify that the dmrc session is available before using it.William Jon McCann2008-02-261-110/+135
| | | | | | | | | | | | | 2008-02-25 William Jon McCann <jmccann@redhat.com> * daemon/gdm-session-direct.c: (is_prog_in_path), (get_session_command_for_file), (get_session_command_for_name), (gdm_session_direct_handle_saved_session_name_read), (get_session_name): Verify that the dmrc session is available before using it. svn path=/trunk/; revision=5875
* Change "SavedLanguageNameRead"/"SavedSessionNameRead" toRay Strode2008-02-251-12/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-02-25 Ray Strode <rstrode@redhat.com> * daemon/gdm-session-private.h: * daemon/gdm-session.h: * daemon/gdm-session.c: (gdm_session_class_init), (_gdm_session_default_language_name_changed), (_gdm_session_default_session_name_changed), (_gdm_session_default_session_name_changed), * daemon/gdm-session-direct.c: (get_default_language_name), (get_default_session_name), (gdm_session_direct_defaults_changed), (gdm_session_direct_select_user), (gdm_session_direct_handle_username_changed), (gdm_session_direct_handle_saved_language), (gdm_session_direct_setup), (gdm_session_direct_setup_for_user), (get_language_name), (get_session_name): * daemon/gdm-simple-slave: (on_default_language_name_changed): (on_default_session_name_changed): (create_new_session): * daemon/gdm-greeter-server.[ch]: (gdm_greeter_server_default_language_name_changed), (gdm_greeter_server_default_session_name_changed), (do_introspect): Change "SavedLanguageNameRead"/"SavedSessionNameRead" to "DefaultLanguageNameChanged"/"DefaultSessionNameChanged" and call it with system fallbacks whenever a new user is authenticating before ~/.dmrc is read. svn path=/trunk/; revision=5847
* remove stale TODO items from top of fileRay Strode2008-02-221-4/+0
| | | | | | | | | 2008-02-21 Ray Strode <rstrode@redhat.com> * daemon/gdm-session-direct.c: remove stale TODO items from top of file svn path=/trunk/; revision=5839
* when the .dmrc gets read remember the results (get_session_name),Ray Strode2008-02-211-15/+58
| | | | | | | | | | | | | | | | | | | | | | | 2008-02-21 Ray Strode <rstrode@redhat.com> * daemon/gdm-session-direct.c (gdm_session_direct_handle_saved_language) (gdm_session_direct_handle_saved_session): when the .dmrc gets read remember the results (get_session_name), (get_language_name): new functions to figure out which of 1) value reported from greeter 2) value saved in .dmrc 3) some fallback is the value we should actually use when logging in (get_session_command), (setup_session_environment): use the new get_{session,language}_name functions (gdm_session_direct_select_session): if the greeter tells us to use the value that are in ~/.dmrc then discard anything the greeter told us earlier and just default to fallback behavior. (gdm_session_direct_finalize): memleak fixes svn path=/trunk/; revision=5835