| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
| |
in the SELinux support.
* doc/busconfig.dtd: update DTD for SELinux support.
* bus/config-loader-libxml.c: fix error handler and parser
initialisation/cleanup. OOM test now works with libxml2 HEAD.
* configure.in: remove the warning about libxml2
* dbus/dbus-bus.c: silence doxygen warning.
|
|
|
|
|
|
|
|
| |
* bus/utils.h (BUS_SET_OOM): use dbus_error_set_const instead of
dbus_error_set.
* bus/dispatch.c (check_send_exit_to_service): fix the test case,
broken by the change in the _SET_OOM macros.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
SELinux support from Matthew Rickard <mjricka@epoch.ncsc.mil>
* bus/selinux.c, bus/selinux.h: new file encapsulating selinux
functionality
* configure.in: add --enable-selinux
* bus/policy.c (bus_policy_merge): add FIXME to a comment
* bus/main.c (main): initialize and shut down selinux
* bus/connection.c: store SELinux ID on each connection, to avoid
repeated getting of the string context and converting it into
an ID
* bus/bus.c (bus_context_get_policy): new accessor, though it
isn't used
(bus_context_check_security_policy): check whether the security
context of sender connection can send to the security context of
recipient connection
* bus/config-parser.c: add parsing for <selinux> and <associate>
* dbus/dbus-transport.c (_dbus_transport_get_unix_fd): to
implement dbus_connection_get_unix_fd()
* dbus/dbus-connection.c (dbus_connection_get_unix_fd): new
function, used by the selinux stuff
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
backend for config file loader. Doesn't work with full OOM test yet.
* configure.in: change error when selecting libxml into a warning.
* test/data/invalid-config-files: add two non-well-formed XML files.
* glib/Makefile.am: libdbus_gtool always uses expat, not libxml.
* dbus/dbus-transport-unix.c (unix_handle_watch): do not disconnect in
case of DBUS_WATCH_HANGUP, several do_reading() may be necessary to
read all the buffer. (bug #894)
* bus/activation.c (bus_activation_activate_service): fix a potential
assertion failure (bug #896). Small optimization in the case of
auto-activation messages.
* dbus/dbus-message.c (verify_test_message, _dbus_message_test): add
test case for byte-through-vararg bug (#901). patch by Kimmo
Hämäläinen.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-sysdeps.c (fill_user_info): fix inexistent label name,
breaking build on Solaris, reported by Farhad Saberi on the ML.
* dbus/dbus-message.c (dbus_message_append_args_valist): fix the
va_arg invocation to account for integer promotion in the case of
DBUS_TYPE_BYTE (unsigned char is promoted to int). (bug #901)
* bus/services.c (bus_service_remove_owner): fix bug #902, use
_dbus_list_get_first_link, not _dbus_list_get_first.
* dbus/dbus-bus.c (dbus_bus_service_exists): plug a memory leak.
* dbus/dbus-object-tree.c (free_subtree_recurse): always null
handler functions so that the asserts in _dbus_object_subtree_unref
do not fail.
* dbus/dbus-transport-unix.c (do_reading):
_dbus_transport_queue_messages return value is of type
dbus_bool_t, not DBusDispatchStatus.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-protocol.h: Add DBUS_ERROR_UNIX_PROCESS_ID_UNKNOWN
* bus/dispatch.c:
(check_get_connection_unix_user): Debug says GetProperty; but the
method is called GetConnectionUnixUser
(check_get_connection_unix_process_id): New function
(bus_dispatch_test): Actually call check_get_connection_unix_user();
also call check_get_connection_unix_process_id()
* bus/driver.c:
(bus_driver_handle_get_connection_unix_process_id): New function,
handles GetConnectionUnixProcessID on the org.freedesktop.DBus
interface
* dbus/dbus-auth.c:
(handle_server_data_external_mech): Set pid from the credentials
obtained from the socket
* dbus/dbus-connection.c:
(dbus_connection_get_unix_process_id): New function
* dbus/dbus-connection.h:
Add prototype for dbus_connection_get_unix_process_id
* dbus/dbus-transport.c:
(_dbus_transport_get_unix_process_id): New function
* dbus/dbus-transport.h:
Add prototype for _dbus_transport_get_unix_process_id
|
|
|
|
| |
<chipx86@gnupdate.org>
|
| |
|
|
|
|
|
|
|
|
| |
* dbus/bus.c (dbus_bus_get_unix_user)
* doc/dbus-specification.xml: implement GetConnectionUnixUser
method of org.freedesktop.DBus interface.
* bus/dispatch.c: test case
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-glib-error-enum.h: autogenerate the GError enum
codes from the dbus error names
* glib/dbus-glib.h: move to subdir dbus/ since it's included
as dbus/dbus-glib.h and that breakage is now visible due to
including dbus/dbus-glib.h in dbus-glib-lowlevel.h
* glib/dbus-glib.h: s/gproxy/g_proxy/
* dbus/dbus-shared.h: new header to hold stuff shared with
binding APIs
* dbus/dbus-protocol.h (DBUS_ERROR_*): move errors here rather
than dbus-errors.h
* glib/dbus-glib.h (dbus_set_g_error): move to
dbus-glib-lowlevel.h
* glib/dbus-glib.h: remove dbus/dbus.h from here; change a bunch
of stuff to enable this
* dbus/dbus-glib-lowlevel.h: put dbus/dbus.h here
* a bunch of other changes with the same basic "separate glib
bindings from dbus.h" theme
|
|
|
|
|
| |
* bus/driver.c, dbus/dbus-bus.c: use BOOLEAN instead of UINT32 for
the reply value of the ServiceExists message.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-message-builder.c (_dbus_message_data_load): append
random signature when using REQUIRED_FIELDS (this hack won't work
in the long term)
* dbus/dbus-message.c: change the signature to be a header field,
instead of message->signature special-case string. Incremental
step forward. Then we can fix up code to send the signature in the
message, then fix up code to validate said signature, then fix up
code to not put the typecodes inline, etc.
(load_one_message): don't make up the signature after the fact
(decode_header_data): require signature field for the known
message types
* dbus/dbus-marshal.c (_dbus_marshal_string_len): new
* dbus/dbus-protocol.h: add DBUS_HEADER_FIELD_SIGNATURE
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-connection.h, dbus/dbus-connection.c: have object path
registration functions take the path argument as char* instead of
char**.
* dbus/dbus-marshal.h, dbus/dbus-marshal.c (_dbus_decompose_path):
split off the path decompostion part of
_dbus_demarshal_object_path. Some misc. fixes to silence compiler
warnings.
* glib/dbus-gobject.c, test/test-service.c: update accordingly.
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-auth.c: Rewrite auth protocol handling to use a state
machine approach. A state is implemented as a function that
handles incoming events as specified for that state.
* doc/dbus-specification.xml: Update auth protocol state machine
specification to match implementation. Remove some leftover
base64 examples.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gproxy.c, glib/dbus-gmain.c, dbus/dbus-string.c,
dbus/dbus-object-tree.c, dbus/dbus-message.c: add comments to
quiet doxygen.
* Doxyfile.in: remove deprecated options.
* dbus/dbus-message-handler.c, dbus/dbus-message-handler.h,
glib/test-thread.h, glib/test-thread-client.c,
glib/test-thread-server.c, glib/test-profile.c,
glib/test-dbus-glib.c: remove these unused files.
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-object-tree.c
(_dbus_object_tree_dispatch_and_unlock): fix dispatch for
non-fallback handlers (bug #684).
(_dbus_object_subtree_new): initialize invoke_as_fallback field.
(find_subtree_recurse): report wether the returned subtree is an
exact match or a "fallback" match higher up in the tree.
(object_tree_test_iteration): update test case.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* test/glib/test-service-glib.c (main): remove unused variable
* glib/dbus-gidl.c (base_info_ref): fix a silly compiler warning
* dbus/dbus-auth.h (enum): remove AUTHENTICATED_WITH_UNUSED_BYTES
from the enum, no longer in use.
* dbus/dbus-sysdeps.h: include config.h so DBUS_VA_COPY actually
works right.
* dbus/dbus-message.c: add various _dbus_return_val_if_fail for
whether error_name passed in is a valid error name.
|
|
|
|
|
| |
- the varargs dbus_message_get_args() needs to support OBJECT_PATH
and OBJECT_PATH_ARRAY
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gvalue.c (dbus_gvalue_marshal, dbus_gvalue_demarshal):
fix no int64 case.
* dbus/dbus-string.c (_dbus_string_parse_basic_type): impl.
* dbus/dbus-message.c (_dbus_message_iter_get_basic_type),
(_dbus_message_iter_get_basic_type_array): impl.
drastically simplify ~all relevant _get methods to use these.
(_dbus_message_iter_append_basic_array),
(dbus_message_iter_append_basic): impl
drastically simplify ~all relevant _append methods to use these.
* dbus/dbus-message-builder.c (parse_basic_type)
(parse_basic_array, lookup_basic_type): impl.
(_dbus_message_data_load): prune scads of duplicate /
cut & paste coding.
* dbus/dbus-marshal.c (_dbus_demarshal_basic_type_array)
(_dbus_demarshal_basic_type): implement,
(demarshal_and_validate_len/arg): beef up debug.
(_dbus_marshal_basic_type, _dbus_marshal_basic_type_array): impl.
|
|
|
|
|
|
| |
* dbus/dbus-message.c (dbus_message_iter_get_args_valist): Swap
operands to && so we call dbus_message_iter_next () for the last
argument also.
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-object-tree.c
(_dbus_object_tree_list_registered_unlock, lookup_subtree): return
children even if the requested path isn't registered.
(object_tree_test_iteration): test object_tree_list_registered.
* configure.in: undefine HAVE_ABSTRACT_SOCKETS instead of defining
it to 0.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
filter against auth->allowed_mechs; we only add allowed mechs in
record_mechanisms().
* dbus/dbus-auth-script.c (_dbus_auth_script_run): Add an
ALLOWED_MECHS to auth-script format so we can set the list of
allowed mechanisms.
* data/auth/client-out-of-mechanisms.auth-script: New test to
check client disconnects when it is out of mechanisms to try.
* dbus/dbus-auth.c (process_command): Remove check for lines
longer that 1 MB; we only buffer up maximum 16 kB.
* dbus/dbus-transport.c, dbus/dbus-transport-unix.c,
dbus/dbus-auth-script.c, dbus/dbus-auth.c, dbus/dbus-auth.h:
Remove auth state AUTHENTICATED_WITH_UNUSED_BYTES, instead always
assume there might be unused bytes.
* dbus/dbus-auth.c (_dbus_auth_do_work): Remove check for
client-out-of-mechs, it is handled in process_reject(). Move check
for max failures to send_rejected(), as it's a server-only thing.
|
|
|
|
|
|
| |
* dbus/dbus-auth.c: Factor out protocol reply code into functions
send_auth(), send_data(), send_rejected(), send_error(),
send_ok(), send_begin() and send_cancel().
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove base64 encoding, replace with hex encoding. Original patch
from trow@ximian.com, added error handling.
* dbus/dbus-string.c (_dbus_string_base64_encode)
(_dbus_string_base64_decode): Remove.
(_dbus_string_hex_decode): Add end_return argument so we can
distinguish between OOM and invalid hex encoding.
(_dbus_string_test): Remove base64 tests and add test case for
invalid hex.
* dbus/dbus-keyring.c, dbus/dbus-auth-script.c, dbus/dbus-auth.c:
Replace base64 with hex.
* test/data/auth/invalid-hex-encoding.auth-script: New test case
for invalid hex encoded data in auth protocol.
|
|
|
|
|
| |
* dbus/dbus-connection.c (check_for_reply_unlocked): plug a memory
leak.
|
|
|
|
|
| |
and HEADER_FIELD_SENDER_SERVICE -> HEADER_FIELD_SENDER
for both dbus-protocol.h and in the spec
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-server-unix.c (unix_finalize): Don't unref
unix_server->watch here, it is unreffed in disconnect.
(_dbus_server_new_for_tcp_socket): convert NULL host to
"localhost" here so we don't append NULL to address.
* dbus/dbus-server.c (_dbus_server_test): Add test case for
various addresses, including tcp with no explicit host.
|
|
|
|
|
|
|
|
|
|
|
|
| |
fix incorrect setting of .name_offset in the HeaderField (it was
off by two bytes, positioned right after the name and typecode)
* bus/bus.c (bus_context_new, bus_context_unref): test before
calling dbus_server_free_data_slot and _dbus_user_database_unref
in case of an error.
* tools/Makefile.am: add $(DBUS_GLIB_TOOL_LIBS), xml libs needed
by libdbus-gtool.
|
|
|
|
|
| |
* dbus/dbus-transport-unix.c (unix_do_iteration): Rewrite to use
_dbus_poll() instead of select().
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bus/driver.c (bus_driver_handle_get_service_owner):
implement a GetServiceOwner method.
* doc/dbus-specification.xml: document it.
* dbus/dbus-errors.h: add a 'ServiceHasNoOwner' error.
* glib/dbus-gproxy.c (dbus_gproxy_new_for_service_owner):
implement, using the bus GetServiceOwner method.
* test/glib/test-dbus-glib.c:
use dbus_gproxy_new_for_service_owner so that we can receive the
signal.
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-message.c
(dbus_message_new_error_printf): impl.
* dbus/dbus-connection.c
(dbus_connection_unregister_object_path): fix warning.
* configure.in: fix no-mono-installed situation.
|
|
|
|
|
|
|
|
|
|
| |
Patch from Timo Teräs:
* tools/dbus-send.c (main): if --print-reply, assume type is
method call; support boolean type args
* dbus/dbus-connection.c (dbus_connection_send_with_reply): fix a
bunch of memleak and logic bugs
|
|
|
|
| |
for every registered object. Also added object_path functions to dbus-message.
|
|
|
|
|
|
|
|
|
|
|
|
| |
arrays
* dbus/dbus-message.h, bus/dbus-message.c (dbus_message_iter_init)
(dbus_message_iter_init_array_iterator)
(dbus_message_iter_init_dict_iterator): return a dbus_bool_t to
indicate whether the iterator is empty
* dbus/dbus-pending-call.c, dbus/dbus-server.c: silence compiler
warnings
|
|
|
|
|
| |
* dbus/dbus-message.c (dbus_message_get_auto_activation)
(dbus_message_set_auto_activation): Add doxygen docs.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bus/activation.c: (bus_activation_service_created),
(bus_activation_send_pending_auto_activation_messages),
(bus_activation_activate_service):
* bus/activation.h:
* bus/dispatch.c: (bus_dispatch),
(check_nonexistent_service_auto_activation),
(check_service_auto_activated),
(check_segfault_service_auto_activation),
(check_existent_service_auto_activation), (bus_dispatch_test):
* bus/driver.c: (bus_driver_handle_activate_service):
* bus/services.c: (bus_registry_acquire_service):
* dbus/dbus-message.c: (dbus_message_set_auto_activation),
(dbus_message_get_auto_activation):
* dbus/dbus-message.h:
* dbus/dbus-protocol.h: Implement auto-activation.
|
|
|
|
|
|
|
|
| |
* dbus/dbus-marshal.c (_dbus_marshal_get_arg_end_pos):
fix a bug with CUSTOM types.
* dbus/dbus-message.c (message_iter_test, _dbus_message_test): add
a unit test for this bug (used to fail).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bus/activation.c:
- Added service file reloading.
Each service files directory is kept in an hash table in
BusActivation and each BusActivationEntry knows what .service-file it
was read from. So when you try to activate a service the bus will
check if it's been updated, removed or if new .service-files has
been installed.
- Test code at the bottom for the service file reloading.
* bus/test-main.c: (main):
* bus/test.h:
- added service reloading test.
* dbus/dbus-sysdeps.c:
* dbus/dbus-sysdeps.h: (_dbus_delete_directory): Added.
|
|
|
|
|
| |
* dbus/dbus-connection.c (_dbus_connection_block_for_reply):
bail immediately if disconnected, to avoid busy loop.
|
|
|
|
|
| |
* dbus/dbus-message.c (dbus_message_iter_get_args_valist):
cleanup cut/paste/inefficiency.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-string.c (_dbus_string_append_printf_valist): Fix a
bug where args were used twice. This bug resulted in a segfault
on a Debian/PPC system when starting the messagebus daemon. Include
dbus-sysdeps.h for DBUS_VA_COPY
* dbus/dbus-sysdeps.h: Define DBUS_VA_COPY if neccessary. From GLib
* configure.in: Check for va_copy; define DBUS_VA_COPY to the
appropriate va_copy implementation. From GLib
|
|
|
|
|
| |
* dbus/dbus-message.c: (dbus_message_append_args_valist):
- Added case for DBUS_TYPE_BYTE, patch from Johan Hedberg.
|
|
|
|
|
| |
* Update AFL version to 2.0 throughout the source files to reflect
the update that was done a while ago.
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-message.c (dbus_message_iter_append_dict): Set
wrote_dict_key to FALSE on the iter that the dict is appended to,
just like when appending other types. Fixes a bug where a dict
couldn't be put inside a dict.
(dbus_message_iter_append_dict_key): Fix typo in warning message.
(message_iter_test, _dbus_message_test): Add test case for dict
inside dict.
|
|
|
|
|
|
| |
* bus/*.[ch]:
* dbus/*.[ch]:
* glib/*.[ch]: Made ref functions return the pointer
|
|
|
|
| |
* dbus/dbus-message.c (get_next_field): delete unused function
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-message.c (_dbus_message_test): enable and fix the
tests for set_path, set_interface, set_member, etc.
* dbus/dbus-string.c (_dbus_string_insert_bytes): allow 0 bytes
* dbus/dbus-message.c (set_string_field): always just delete and
re-append the field; accept NULL for deletion
(re_align_fields_recurse): reimplement
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-connection.c: fix docs to properly describe the
disconnected message
(_dbus_connection_notify_disconnected): remove this function;
we can't synchronously add the disconnected message, we have to
do it after we've queued any remaining real messages
(_dbus_connection_get_dispatch_status_unlocked): queue the
disconnect message only if the transport has finished queueing all
its real messages and is disconnected.
(dbus_connection_disconnect): update the dispatch status here
|
|
|
|
|
|
|
| |
* bus/bus.c (bus_context_check_security_policy): fix up assertion
* bus/connection.c (bus_transaction_send_from_driver): set the
destination to the connection's base service
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
hmm, make check is currently not passing.
* doc/dbus-specification.xml: add requirement that custom type
names follow the same rules as interface names.
* dbus/dbus-protocol.h: change some of the byte codes, to avoid
duplication and allow 'c' to be 'custom'; dict is now 'm' for
'map'
* doc/dbus-specification.xml: update type codes to match
dbus-protocol.h, using the ASCII byte values. Rename type NAMED to
CUSTOM. Add type OBJECT_PATH to the spec.
2003-10-17 Havoc Pennington <hp@redhat.com>
* bus/driver.c (create_unique_client_name): use "." as separator
in base service names instead of '-'
* dbus/dbus-string.c (_dbus_string_get_byte): allow getting nul
byte at the end of the string
* dbus/dbus-internals.h (_DBUS_LIKELY, _DBUS_UNLIKELY): add
optimization macros since string validation seems to be a slow
point.
* doc/dbus-specification.xml: restrict valid
service/interface/member/error names. Add test suite code for the
name validation.
* dbus/dbus-string.c: limit service/interface/member/error names
to [0-9][A-Z][a-z]_
* dbus/dbus-connection.c (dbus_connection_dispatch): add missing
format arg to verbose spew
* glib/dbus-gproxy.c (dbus_gproxy_call_no_reply): if not out of
memory, return instead of g_error
* test/test-service.c (path_message_func): support emitting a
signal on request
* dbus/dbus-bus.c (init_connections_unlocked): only fill in
activation bus type if DBUS_BUS_ACTIVATION was set; default to
assuming the activation bus was the session bus so that services
started manually will still register.
(init_connections_unlocked): fix so that in OOM situation we get
the same semantics when retrying the function
* test/test-service.c (main): change to use path registration, to
test those codepaths; register with DBUS_BUS_ACTIVATION rather
than DBUS_BUS_SESSION
|