syntheticpp at gmx.net
Sun May 27 06:02:55 PDT 2007
Havoc, maybe it has not become clear:
I seriously try to go your route.
I hope I'm not completely wrong.
Peter Kümmel wrote:
> I've tried to remove dbus_getuid calls from the "platform independent"
> code. The first step was to introduce _dbus_append_uid, first patch.
> Internally I still use the dummy uid, but they could be later on
> replaced by a DBusString which holds a sid.
> I've found _dbus_getuid() in a call of _dbus_user_database_get_uid
> in init_system_db. Is it right that we have to set up a database
> which handles DBusStrings?
> A other call is in
> bus_policy_allow_user (BusPolicy *policy,
> unsigned long uid)
> dbus_bool_t allowed;
> unsigned long *group_ids;
> int n_group_ids;
> Seems this makes only sens on Unix, so I've introduced
> "allow_unix_user_function" and "allow_win_user_function",
> to avoid the calling of bus_policy_allow_user, see the second patch.
> (the patches only demonstrate the changes)
> How should we fix the "plain _wrong_" patch of policy.c?
> "bus_policy_create_client_policy" also uses dbus_uid_t and
> is called by "bus_context_create_client_policy"
> which is called by "bus_connection_complete". Should we rename
> all these function to *_unix?
> But this looks like duplicating the code. Or are all these functions
> without sens on windows?.
> A other way is to call everywhere the function for unix and win and
> make one of the functions a noop when it is called on the wrong system.
> But currently the unix function will fail on windows.
More information about the dbus