Commit e0a3c565 authored by Ray Strode's avatar Ray Strode

daemon: Add an interface for communicating with GDM via D-Bus

One goal for GNOME 3.6, is to replace the screen locking functionality
provided by gnome-screensaver with redesigned functionality provided
by gnome-shell.

At the same time, it makes sense to consolidate the yucky PAM
authentication code to one place (GDM).

Right now only greeters can talk to GDM.  At the time the greeter is
started, the slave sets up a private communication channel which the
greeter then connects to for initiating communication.

This commit adds a new method to the org.gnome.DisplayManager.Manager
interface that allows opening a private connection to the slave that
is associated with the currently running session.  That slave exports
the session object over the bus that greeters can interact with the
session as appropriate.  This interface replaces the
GDM_GREETER_DBUS_ADDRESS environment variable that used to to be used
for connecting the greeter to the slave.

This commit also drops gdm-greeter-server and gdm-chooser-server which
don't fit the new model, and are really just thin middle men that don't do
anything important.

Furthermore, this commit splits GdmSession interfaces 3 orthogonal parts
up into 3 separate interfaces on the session object.

A future commit will make this interface work for screensavers/reauthentication.

Based on work by Giovanni Campagna <gcampagna@src.gnome.org>

https://bugzilla.gnome.org/show_bug.cgi?id=676381
parent 5d319617
......@@ -33,13 +33,20 @@ BUILT_SOURCES = \
gdm-xdmcp-chooser-slave-glue.h \
gdm-display-glue.h \
gdm-xdmcp-display-glue.h \
gdm-manager-glue.h \
gdm-static-display-glue.h \
gdm-transient-display-glue.h \
gdm-local-display-factory-glue.h \
gdm-greeter-glue.h \
gdm-session-glue.h \
gdm-session-enum-types.h \
$(NULL)
gdm-session-enum-types.h: gdm-session-enum-types.h.in gdm-session.h
$(AM_V_GEN) glib-mkenums --template $^ > $@
gdm-session-enum-types.c: gdm-session-enum-types.c.in gdm-session.h
$(AM_V_GEN) glib-mkenums --template $^ > $@
gdm-display-glue.c gdm-display-glue.h: gdm-display.xml Makefile.am
$(AM_V_GEN)gdbus-codegen \
--c-namespace=GdmDBus \
......@@ -75,19 +82,19 @@ gdm-local-display-factory-glue.c gdm-local-display-factory-glue.h : gdm-local-di
--generate-c-code=gdm-local-display-factory-glue \
$(srcdir)/gdm-local-display-factory.xml
gdm-session-glue.c gdm-session-glue.h : gdm-session.xml Makefile.am
gdm-manager-glue.c gdm-manager-glue.h : gdm-manager.xml Makefile.am
$(AM_V_GEN)gdbus-codegen \
--c-namespace=GdmDBus \
--interface-prefix=org.gnome.DisplayManager \
--generate-c-code=gdm-session-glue \
$(srcdir)/gdm-session.xml
--generate-c-code=gdm-manager-glue \
$(srcdir)/gdm-manager.xml
gdm-greeter-glue.c gdm-greeter-glue.h : gdm-greeter-server.xml Makefile.am
gdm-session-glue.c gdm-session-glue.h : gdm-session.xml Makefile.am
$(AM_V_GEN)gdbus-codegen \
--c-namespace=GdmDBus \
--interface-prefix=org.gnome.DisplayManager \
--generate-c-code=gdm-greeter-glue \
$(srcdir)/gdm-greeter-server.xml
--generate-c-code=gdm-session-glue \
$(srcdir)/gdm-session.xml
gdm-slave-glue.c gdm-slave-glue.h: gdm-slave.xml Makefile.am
$(AM_V_GEN)gdbus-codegen \
......@@ -104,32 +111,6 @@ gdm-xdmcp-chooser-slave-glue.c gdm-xdmcp-chooser-slave-glue.h: gdm-xdmcp-chooser
$(srcdir)/gdm-xdmcp-chooser-slave.xml
noinst_PROGRAMS = \
test-session \
$(NULL)
test_session_SOURCES = \
test-session.c \
gdm-session.c \
gdm-session.h \
gdm-session-record.c \
gdm-session-record.h \
gdm-session-worker-job.c\
gdm-dbus-util.c \
gdm-dbus-util.h \
$(NULL)
nodist_test_session_SOURCES = \
gdm-session-glue.c \
gdm-session-glue.h \
$(NULL)
test_session_LDADD = \
$(top_builddir)/common/libgdmcommon.la \
$(XLIB_LIBS) \
$(EXTRA_DAEMON_LIBS) \
$(DAEMON_LIBS) \
$(PAM_LIBS) \
$(LIBXKLAVIER_LIBS) \
$(NULL)
libexec_PROGRAMS = \
......@@ -145,8 +126,6 @@ endif
gdm_simple_slave_SOURCES = \
simple-slave-main.c \
gdm-greeter-server.c \
gdm-greeter-server.h \
gdm-welcome-session.c \
gdm-welcome-session.h \
gdm-greeter-session.c \
......@@ -174,6 +153,8 @@ nodist_gdm_simple_slave_SOURCES = \
gdm-greeter-glue.h \
gdm-display-glue.c \
gdm-display-glue.h \
gdm-session-enum-types.c \
gdm-session-enum-types.h \
gdm-session-glue.c \
gdm-session-glue.h \
gdm-slave-glue.c \
......@@ -195,8 +176,6 @@ gdm_simple_slave_LDADD = \
gdm_xdmcp_chooser_slave_SOURCES = \
xdmcp-chooser-slave-main.c \
gdm-chooser-server.c \
gdm-chooser-server.h \
gdm-session.c \
gdm-session.h \
gdm-session-record.c \
......@@ -220,6 +199,8 @@ gdm_xdmcp_chooser_slave_SOURCES = \
nodist_gdm_xdmcp_chooser_slave_SOURCES = \
gdm-session-glue.c \
gdm-session-glue.h \
gdm-session-enum-types.c \
gdm-session-enum-types.h \
gdm-display-glue.c \
gdm-display-glue.h \
gdm-slave-glue.c \
......@@ -250,6 +231,8 @@ gdm_session_worker_SOURCES = \
nodist_gdm_session_worker_SOURCES = \
gdm-session-glue.h \
gdm-session-glue.c \
gdm-session-enum-types.c \
gdm-session-enum-types.h \
$(NULL)
if HAVE_LIBAUDIT
......@@ -297,6 +280,8 @@ gdm_binary_SOURCES = \
gdm-manager.h \
gdm-slave-proxy.c \
gdm-slave-proxy.h \
gdm-dbus-util.c \
gdm-dbus-util.h \
$(NULL)
nodist_gdm_binary_SOURCES = \
......@@ -304,10 +289,14 @@ nodist_gdm_binary_SOURCES = \
gdm-display-glue.c \
gdm-local-display-factory-glue.h \
gdm-local-display-factory-glue.c \
gdm-manager-glue.h \
gdm-manager-glue.c \
gdm-transient-display-glue.h \
gdm-transient-display-glue.c \
gdm-static-display-glue.h \
gdm-static-display-glue.c \
gdm-slave-glue.h \
gdm-slave-glue.c \
$(NULL)
XDMCP_SOURCES = \
......@@ -371,8 +360,8 @@ gdm: $(srcdir)/gdm.in
CLEANFILES = \
gdm \
gdm-display-glue.c \
gdm-greeter-glue.c \
gdm-local-display-factory-glue.c \
gdm-manager-glue.c \
gdm-session-glue.c \
gdm-slave-glue.c \
gdm-static-display-glue.c \
......@@ -384,7 +373,6 @@ CLEANFILES = \
EXTRA_DIST = \
gdm.in \
gdm-greeter-server.xml \
gdm-slave.xml \
gdm-simple-slave.xml \
gdm-xdmcp-chooser-slave.xml \
......
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*-
*
* Copyright (C) 2008 William Jon McCann <jmccann@redhat.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
#include "config.h"
#include <stdlib.h>
#include <stdio.h>
#include <fcntl.h>
#include <unistd.h>
#include <string.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <errno.h>
#include <ctype.h>
#include <pwd.h>
#include <grp.h>
#if defined (_POSIX_PRIORITY_SCHEDULING) && defined (HAVE_SCHED_YIELD)
#include <sched.h>
#endif
#include <glib.h>
#include <glib/gi18n.h>
#include <glib-object.h>
#include <gio/gio.h>
#include "gdm-common.h"
#include "gdm-chooser-server.h"
#include "gdm-dbus-util.h"
#define GDM_CHOOSER_SERVER_DBUS_PATH "/org/gnome/DisplayManager/ChooserServer"
#define GDM_CHOOSER_SERVER_DBUS_INTERFACE "org.gnome.DisplayManager.ChooserServer"
#define GDM_CHOOSER_SERVER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GDM_TYPE_CHOOSER_SERVER, GdmChooserServerPrivate))
static const char* chooser_server_introspection =
"<node>"
" <interface name=\"org.gnome.DisplayManager.ChooserServer\">"
" <method name=\"SelectHostname\">"
" <arg name=\"text\" direction=\"in\" type=\"s\"/>"
" </method>"
" <method name=\"Disconnect\">"
" </method>"
" </interface>"
"</node>";
struct GdmChooserServerPrivate
{
char *user_name;
char *group_name;
char *display_id;
GDBusServer *server;
GDBusConnection *chooser_connection;
};
enum {
PROP_0,
PROP_USER_NAME,
PROP_GROUP_NAME,
PROP_DISPLAY_ID,
};
enum {
HOSTNAME_SELECTED,
CONNECTED,
DISCONNECTED,
LAST_SIGNAL
};
static guint signals [LAST_SIGNAL] = { 0, };
static void gdm_chooser_server_class_init (GdmChooserServerClass *klass);
static void gdm_chooser_server_init (GdmChooserServer *chooser_server);
G_DEFINE_TYPE (GdmChooserServer, gdm_chooser_server, G_TYPE_OBJECT)
static void
handle_select_hostname (GdmChooserServer *chooser_server,
GDBusMethodInvocation *invocation,
GVariant *parameters)
{
const char *text;
g_variant_get (parameters, "(&s)", &text);
g_debug ("ChooserServer: SelectHostname: %s", text);
g_dbus_method_invocation_return_value (invocation, NULL);
g_signal_emit (chooser_server, signals [HOSTNAME_SELECTED], 0, text);
}
static void
handle_disconnect (GdmChooserServer *chooser_server,
GDBusMethodInvocation *invocation,
GVariant *parameters)
{
g_debug ("ChooserServer: Disconnect");
g_dbus_method_invocation_return_value (invocation, NULL);
g_signal_emit (chooser_server, signals [DISCONNECTED], 0);
}
static void
chooser_handle_child_method (GDBusConnection *connection,
const char *sender,
const char *object_path,
const char *interface_name,
const char *method_name,
GVariant *parameters,
GDBusMethodInvocation *invocation,
void *user_data)
{
GdmChooserServer *chooser_server = GDM_CHOOSER_SERVER (user_data);
if (strcmp (method_name, "SelectHostname") == 0) {
return handle_select_hostname (chooser_server, invocation, parameters);
} else if (strcmp (method_name, "Disconnect") == 0) {
return handle_disconnect (chooser_server, invocation, parameters);
}
}
static void
connection_closed (GDBusConnection *connection,
GdmChooserServer *chooser_server)
{
g_clear_object (&chooser_server->priv->chooser_connection);
}
static gboolean
allow_user_function (GDBusAuthObserver *observer,
GIOStream *stream,
GCredentials *credentials,
void *data)
{
GdmChooserServer *chooser_server = GDM_CHOOSER_SERVER (data);
struct passwd *pwent;
if (chooser_server->priv->user_name == NULL) {
return FALSE;
}
gdm_get_pwent_for_name (chooser_server->priv->user_name, &pwent);
if (pwent == NULL) {
return FALSE;
}
return g_credentials_get_unix_user (credentials, NULL) == pwent->pw_uid;
}
static void
handle_connection (GDBusServer *server,
GDBusConnection *new_connection,
void *user_data)
{
GdmChooserServer *chooser_server = GDM_CHOOSER_SERVER (user_data);
g_debug ("ChooserServer: Handing new connection");
if (chooser_server->priv->chooser_connection == NULL) {
GDBusInterfaceVTable vtable = { chooser_handle_child_method };
GDBusNodeInfo *info;
chooser_server->priv->chooser_connection = g_object_ref (new_connection);
info = g_dbus_node_info_new_for_xml (chooser_server_introspection, NULL);
g_debug ("GdmChooserServer: new connection %p", new_connection);
g_dbus_connection_register_object (new_connection,
"/org/gnome/DisplayManager/ChooserServer",
info->interfaces[0],
&vtable,
NULL, NULL, NULL);
g_signal_connect (new_connection, "closed",
G_CALLBACK (connection_closed), chooser_server);
g_signal_emit (chooser_server, signals[CONNECTED], 0);
}
}
gboolean
gdm_chooser_server_start (GdmChooserServer *chooser_server)
{
GDBusAuthObserver *observer;
GError *error = NULL;
gboolean ret;
ret = FALSE;
g_debug ("ChooserServer: Creating D-Bus server for chooser");
observer = g_dbus_auth_observer_new ();
g_signal_connect (observer, "authorize-authenticated-peer",
G_CALLBACK (allow_user_function), chooser_server);
chooser_server->priv->server = gdm_dbus_setup_private_server (observer,
&error);
g_object_unref (observer);
if (chooser_server->priv->server == NULL) {
g_warning ("Cannot create D-BUS server for the chooser: %s", error->message);
/* FIXME: should probably fail if we can't create the socket */
goto out;
}
g_signal_connect (chooser_server->priv->server, "new-connection",
G_CALLBACK (handle_connection), chooser_server);
ret = TRUE;
g_debug ("ChooserServer: D-Bus server listening on %s",
g_dbus_server_get_client_address (chooser_server->priv->server));
g_dbus_server_start (chooser_server->priv->server);
out:
return ret;
}
gboolean
gdm_chooser_server_stop (GdmChooserServer *chooser_server)
{
gboolean ret;
ret = FALSE;
g_debug ("ChooserServer: Stopping chooser server...");
g_clear_object (&chooser_server->priv->server);
g_clear_object (&chooser_server->priv->chooser_connection);
return ret;
}
char *
gdm_chooser_server_get_address (GdmChooserServer *chooser_server)
{
return g_strdup (g_dbus_server_get_client_address (chooser_server->priv->server));
}
static void
_gdm_chooser_server_set_display_id (GdmChooserServer *chooser_server,
const char *display_id)
{
g_free (chooser_server->priv->display_id);
chooser_server->priv->display_id = g_strdup (display_id);
}
static void
_gdm_chooser_server_set_user_name (GdmChooserServer *chooser_server,
const char *name)
{
g_free (chooser_server->priv->user_name);
chooser_server->priv->user_name = g_strdup (name);
}
static void
_gdm_chooser_server_set_group_name (GdmChooserServer *chooser_server,
const char *name)
{
g_free (chooser_server->priv->group_name);
chooser_server->priv->group_name = g_strdup (name);
}
static void
gdm_chooser_server_set_property (GObject *object,
guint prop_id,
const GValue *value,
GParamSpec *pspec)
{
GdmChooserServer *self;
self = GDM_CHOOSER_SERVER (object);
switch (prop_id) {
case PROP_DISPLAY_ID:
_gdm_chooser_server_set_display_id (self, g_value_get_string (value));
break;
case PROP_USER_NAME:
_gdm_chooser_server_set_user_name (self, g_value_get_string (value));
break;
case PROP_GROUP_NAME:
_gdm_chooser_server_set_group_name (self, g_value_get_string (value));
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
break;
}
}
static void
gdm_chooser_server_get_property (GObject *object,
guint prop_id,
GValue *value,
GParamSpec *pspec)
{
GdmChooserServer *self;
self = GDM_CHOOSER_SERVER (object);
switch (prop_id) {
case PROP_DISPLAY_ID:
g_value_set_string (value, self->priv->display_id);
break;
case PROP_USER_NAME:
g_value_set_string (value, self->priv->user_name);
break;
case PROP_GROUP_NAME:
g_value_set_string (value, self->priv->group_name);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
break;
}
}
static void
gdm_chooser_server_class_init (GdmChooserServerClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
object_class->get_property = gdm_chooser_server_get_property;
object_class->set_property = gdm_chooser_server_set_property;
g_type_class_add_private (klass, sizeof (GdmChooserServerPrivate));
g_object_class_install_property (object_class,
PROP_DISPLAY_ID,
g_param_spec_string ("display-id",
"display id",
"display id",
NULL,
G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
g_object_class_install_property (object_class,
PROP_USER_NAME,
g_param_spec_string ("user-name",
"user name",
"user name",
GDM_USERNAME,
G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
g_object_class_install_property (object_class,
PROP_GROUP_NAME,
g_param_spec_string ("group-name",
"group name",
"group name",
GDM_GROUPNAME,
G_PARAM_READWRITE | G_PARAM_CONSTRUCT));
signals [HOSTNAME_SELECTED] =
g_signal_new ("hostname-selected",
G_OBJECT_CLASS_TYPE (object_class),
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (GdmChooserServerClass, hostname_selected),
NULL,
NULL,
g_cclosure_marshal_VOID__STRING,
G_TYPE_NONE,
1,
G_TYPE_STRING);
signals [CONNECTED] =
g_signal_new ("connected",
G_OBJECT_CLASS_TYPE (object_class),
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (GdmChooserServerClass, connected),
NULL,
NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE,
0);
signals [DISCONNECTED] =
g_signal_new ("disconnected",
G_OBJECT_CLASS_TYPE (object_class),
G_SIGNAL_RUN_FIRST,
G_STRUCT_OFFSET (GdmChooserServerClass, disconnected),
NULL,
NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE,
0);
}
static void
gdm_chooser_server_init (GdmChooserServer *chooser_server)
{
chooser_server->priv = GDM_CHOOSER_SERVER_GET_PRIVATE (chooser_server);
}
GdmChooserServer *
gdm_chooser_server_new (const char *display_id)
{
GObject *object;
object = g_object_new (GDM_TYPE_CHOOSER_SERVER,
"display-id", display_id,
NULL);
return GDM_CHOOSER_SERVER (object);
}
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*-
*
* Copyright (C) 2008 William Jon McCann <jmccann@redhat.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*
*/
#ifndef __GDM_CHOOSER_SERVER_H
#define __GDM_CHOOSER_SERVER_H
#include <glib-object.h>
G_BEGIN_DECLS
#define GDM_TYPE_CHOOSER_SERVER (gdm_chooser_server_get_type ())
#define GDM_CHOOSER_SERVER(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), GDM_TYPE_CHOOSER_SERVER, GdmChooserServer))
#define GDM_CHOOSER_SERVER_CLASS(k) (G_TYPE_CHECK_CLASS_CAST((k), GDM_TYPE_CHOOSER_SERVER, GdmChooserServerClass))
#define GDM_IS_CHOOSER_SERVER(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), GDM_TYPE_CHOOSER_SERVER))
#define GDM_IS_CHOOSER_SERVER_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), GDM_TYPE_CHOOSER_SERVER))
#define GDM_CHOOSER_SERVER_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), GDM_TYPE_CHOOSER_SERVER, GdmChooserServerClass))
typedef struct GdmChooserServerPrivate GdmChooserServerPrivate;
typedef struct
{
GObject parent;
GdmChooserServerPrivate *priv;
} GdmChooserServer;
typedef struct
{
GObjectClass parent_class;
void (* hostname_selected) (GdmChooserServer *chooser_server,
const char *hostname);
void (* connected) (GdmChooserServer *chooser_server);
void (* disconnected) (GdmChooserServer *chooser_server);
} GdmChooserServerClass;
GType gdm_chooser_server_get_type (void);
GdmChooserServer * gdm_chooser_server_new (const char *display_id);
gboolean gdm_chooser_server_start (GdmChooserServer *chooser_server);
gboolean gdm_chooser_server_stop (GdmChooserServer *chooser_server);
char * gdm_chooser_server_get_address (GdmChooserServer *chooser_server);
G_END_DECLS
#endif /* __GDM_CHOOSER_SERVER_H */
......@@ -39,6 +39,7 @@
#include "gdm-common.h"
#include "gdm-session.h"
#include "gdm-welcome-session.h"
#include "gdm-chooser-session.h"
......@@ -78,9 +79,7 @@ gdm_chooser_session_new (const char *display_name,
object = g_object_new (GDM_TYPE_CHOOSER_SESSION,
"command", LIBEXECDIR "/gdm-simple-chooser",
"server-dbus-path", GDM_CHOOSER_SERVER_DBUS_PATH,
"server-dbus-interface", GDM_CHOOSER_SERVER_DBUS_INTERFACE,
"server-env-var-name", "GDM_CHOOSER_DBUS_ADDRESS",
"verification-mode", GDM_SESSION_VERIFICATION_MODE_CHOOSER,
"x11-display-name", display_name,
"x11-display-device", display_device,
"x11-display-hostname", display_hostname,
......
......@@ -123,3 +123,43 @@ gdm_dbus_setup_private_server (GDBusAuthObserver *observer,
return server;
}
gboolean
gdm_dbus_get_pid_for_name (const char *system_bus_name,
pid_t *out_pid,
GError **error)
{
GDBusConnection *bus;
GVariant *reply;
gboolean retval = FALSE;
unsigned int v;
bus = g_bus_get_sync (G_BUS_TYPE_SYSTEM, NULL, error);
if (bus == NULL) {
return FALSE;
}
reply = g_dbus_connection_call_sync (bus,
"org.freedesktop.DBus",
"/org/freedesktop/DBus",
"org.freedesktop.DBus",
"GetConnectionUnixProcessID",
g_variant_new ("(s)", system_bus_name),
G_VARIANT_TYPE ("(u)"),
G_DBUS_CALL_FLAGS_NONE,
-1,
NULL, error);
if (reply == NULL) {
goto out;
}
g_variant_get (reply, "(u)", &v);
*out_pid = v;
g_variant_unref (reply);
retval = TRUE;
out:
g_object_unref (bus);
return retval;
}
......@@ -22,8 +22,14 @@
#define __GDM_DBUS_UTIL_H
#include <gio/gio.h>
#include <unistd.h>
#include <sys/types.h>
GDBusServer *gdm_dbus_setup_private_server (GDBusAuthObserver *observer,
GError **error);
gboolean gdm_dbus_get_pid_for_name (const char *system_bus_name,
pid_t *out_pid,
GError **error);
#endif
......@@ -41,17 +41,19 @@
#include "gdm-settings-keys.h"
#include "gdm-slave-proxy.h"
static guint32 display_serial = 1;
#include "gdm-slave-glue.h"
#include "gdm-dbus-util.h"
#define GDM_DISPLAY_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GDM_TYPE_DISPLAY, GdmDisplayPrivate))
#define GDM_SLAVE_PATH "/org/gnome/DisplayManager/Slave"
#define DEFAULT_SLAVE_COMMAND LIBEXECDIR "/gdm-simple-slave"
struct GdmDisplayPrivate
{
char *id;
char *seat_id;
char *session_id;