User authentication to services

Havoc Pennington hp at redhat.com
Thu Jun 17 18:15:07 PDT 2004


Hi,

Thanks for the patch, looks good overall. Some small comments:

- D-BUS code generally avoids assignment and declaration at once, 
  i.e.:
   char *service;
   service = NULL;
  is preferred.

- I'd probably capitalize all of "UID"

- the BaseName property replicates the functionality of 
  the GetServiceOwner, so we need to decide between these two.

- bus_connection_get_name() should not be able to return NULL for
  a connection that owns a service, and we know this one does.
  So you should _dbus_assert (base_name != NULL) rather than 
  setting an error in that case I'm pretty sure.

- the name "GetServiceProperty" isn't a bit funny; it's a 
  property of the connection, not the service. 
  Suggest just "GetProperty"

- dbus_bus_get_service_uid() should be consistent with 
  dbus_connection_get_unix_user() (in naming, and 
  in dbus_uint32_t vs. unsigned long)

- though I'm not sure we'll keep all of dbus-bus.[ch]
  in the long run, this seems fine for now

- can't return -1 to uint32 without a cast; just use 
  DBUS_UID_UNSET probably

Thanks,
Havoc





More information about the dbus mailing list