From 7020303391731ebfdc80da9edaff5b6c2732f024 Mon Sep 17 00:00:00 2001 From: Ralf Habacker Date: Thu, 14 Jun 2007 17:37:27 +0000 Subject: * dbus/dbus-sysdeps-win.c: disabled DBusUserInfo related code (_dbus_append_desired_identity,_dbus_windows_user_is_process_owner): new win32 functions as counterpart of unix related (_dbus_send_credentials_socket,_dbus_read_credentials_socket): renamed from ..._unix_socket (_dbus_send_credentials_unix_socket): removed obsolate function * dbus/dbus-sysdeps-win-util.c: disabled DBusGroupInfo related code (_dbus_verify_daemon_user,_dbus_change_to_daemon_user): new win32 functions as counterpart of unix related --- dbus/dbus-sysdeps-util-win.c | 38 +++++++++++++++++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) (limited to 'dbus/dbus-sysdeps-util-win.c') diff --git a/dbus/dbus-sysdeps-util-win.c b/dbus/dbus-sysdeps-util-win.c index 3b308f8c..2d11fb8c 100644 --- a/dbus/dbus-sysdeps-util-win.c +++ b/dbus/dbus-sysdeps-util-win.c @@ -22,6 +22,15 @@ * */ +/* #define ENABLE_DBUSGROUPINFO */ + +#ifdef ENABLE_DBUSGROUPINFO +typedef struct { + int gid; + char *groupname; +} DBusGroupInfo; +#endif + #undef open #define STRSAFE_NO_DEPRECATE @@ -209,6 +218,32 @@ _dbus_write_pid_file (const DBusString *filename, return TRUE; } +/** + * Verify that after the fork we can successfully change to this user. + * + * @param user the username given in the daemon configuration + * @returns #TRUE if username is valid + */ +dbus_bool_t +_dbus_verify_daemon_user (const char *user) +{ + return TRUE; +} + +/** + * Changes the user and group the bus is running as. + * + * @param user the user to become + * @param error return location for errors + * @returns #FALSE on failure + */ +dbus_bool_t +_dbus_change_to_daemon_user (const char *user, + DBusError *error) +{ + return TRUE; +} + /** * Changes the user and group the bus is running as. * @@ -755,7 +790,7 @@ _dbus_path_is_absolute (const DBusString *filename) return FALSE; } - +#ifdef ENABLE_DBUSGROPINFO static dbus_bool_t fill_group_info(DBusGroupInfo *info, dbus_gid_t gid, @@ -866,6 +901,7 @@ _dbus_group_info_fill (DBusGroupInfo *info, return fill_group_info (info, DBUS_GID_UNSET, groupname, error); } +#endif /** @} */ /* End of DBusInternalsUtils functions */ -- cgit