History log of /external/dbus/dbus/dbus-marshal-validate.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
4299eb3c0907100fe95d2986984b48d40cc52841 08-Jul-2015 Daniel Erat <derat@google.com> Incorporate upstream changes to v1.6.8.

Squash upstream commits up to and including the v1.6.8
release (upstream commit 1cad15cc).

This repository's changes from upstream are now limited to:

- addition of Android.mk, CleanSpec.mk, config.h, and NOTICE
files
- addition of dbus/dbus-arch-deps.h and removal from
dbus/.gitignore (ebae2d21, f022f55d)
- WANT_PIDFILE #ifdefs added to bus/bus.c to disable writing
dbus-daemon's PID to a file (3100d06a)
- TRACE_LOCKS set to 0 in dbus/dbus-connection.c (88a0ffe5)
- DBUS_ANDROID_LOG added to dbus/dbus-internals.c to use
logcat (7de15def)
- ANDROID_MANAGED_SOCKET added to dbus/dbus-sysdeps-unix.c
to use an SELinux-managed socket rather than a
dbus-daemon-created Unix domain socket (3100d06a)

Bug: 22328216
Change-Id: I793ebdf963d9b0740f0da28f1de593d088f08406
/external/dbus/dbus/dbus-marshal-validate.h
c11401949f29a97414887a01f0d3e6e8fe60ba40 13-Dec-2010 Havoc Pennington <hp@pobox.com> CVE 2010-4352: Reject deeply nested variants

Add DBUS_INVALID_NESTED_TOO_DEEPLY validity problem and a test that
should generate it.

Previously, we rejected deep nesting in the signature, but
variants allow dynamic message nesting, conditional only
on the depth of the message body.

The nesting limit is 64, which was also the limit in static
signatures. Empirically, dynamic nesting depth observed on my
Fedora 14 system doesn't exceed 2; 64 is really a huge limit.

https://bugs.freedesktop.org/show_bug.cgi?id=32321

Signed-Off-By: Colin Walters <walters@verbum.org>
Signed-off-by: Will Thompson <will.thompson@collabora.co.uk>
/external/dbus/dbus/dbus-marshal-validate.h
dbecdeabb20e0ce11121819c63373f0afba57c58 19-Mar-2010 Marcus Brinkmann <marcus.brinkmann@ruhr-uni-bochum.de> Consistently include <config.h> in all C source files and never in header files.
/external/dbus/dbus/dbus-marshal-validate.h
37019e9d271390fa8c62c1aae62d30bb9068adaa 16-Jul-2009 Thiago Macieira <thiago@kde.org> Merge branch 'fd-passing'

Conflicts:
dbus/dbus-connection.c
dbus/dbus-message-util.c
dbus/dbus-sysdeps-unix.c
5baf2f856a9c6625993234855b07680da1c8916f 11-Jul-2009 Tobias Mueller <fdo-bugs@cryptobitch.de> Bug 21161 - Update the FSF address

No comment.

Signed-off-by: Colin Walters <walters@verbum.org>
/external/dbus/dbus/dbus-marshal-validate.h
a0cc21f8bb6752ffe0ee5f4f5b575dc50d6d46ae 22-Apr-2009 Lennart Poettering <lennart@poettering.net> unix-fd: add message encoding/decoding for unix fds

When appending unix fds to the message a new entry in the fd array will
be allocated and the index to it will be written to the message payload.

When parsing unix fds from the message the index will be read from the
payload and then looked up in the fd array.

When we read fds we put them in a queue first. Since each message knows
how many fds are attached to it we will then pop enough fds from this
queue each time we decode a message from the stream.

This should make sending and receiving more portable since we don't make
any strong requirements on the exact semantics of the SCM_RIGHTS
implementation: as long as fds are recieved in order, none or lost and
the arrive at the same time as at least one byte from the actual message
dat we should be able to handle them correctly.
/external/dbus/dbus/dbus-marshal-validate.h
3801b6de7878074a8e77445bad2a2d093889a3af 22-Apr-2009 Lennart Poettering <lennart@poettering.net> build-system: get rid of config.h inclusion checks

These header files include config.h explicitly anyway. These checks are
hence pointless.

Of course one could argue that including config.h from header files
sucks, but D-Bus generally seems not to have a problem with that, so
let's unify this.
/external/dbus/dbus/dbus-marshal-validate.h
099b5e59ea84d72bfe29a17e0934f6b2f492ddf3 18-Mar-2009 Federico Mena Quintero <federico@novell.com> bfo20738 - Translate DBusValidity into error message

Signed-off-by: Federico Mena Quintero <federico@novell.com>
/external/dbus/dbus/dbus-marshal-validate.h
d012387afef0ba02185ebe27bc6bb15551912e92 14-Jul-2007 Havoc Pennington <hp@redhat.com> 2007-07-13 Havoc Pennington <hp@redhat.com>

* Add indent-tabs-mode: nil to all file headers.
/external/dbus/dbus/dbus-marshal-validate.h
bf172ce4c5856af21f5ee208960bf718a5058ad9 22-Oct-2006 Havoc Pennington <hp@redhat.com> 2006-10-21 Havoc Pennington <hp@redhat.com>

* Documentation! Whee! Doxygen now 100% silent. If you make it
angry again, you will be punished.
/external/dbus/dbus/dbus-marshal-validate.h
fed8880c6f718b9f06e589d1769494a47b395c0d 21-Oct-2006 Havoc Pennington <hp@redhat.com> 2006-10-21 Havoc Pennington <hp@redhat.com>

* Document a bunch of undocumented stuff
/external/dbus/dbus/dbus-marshal-validate.h
e19ebac55d671ecd92877af182300311afa7641a 21-Oct-2006 Havoc Pennington <hp@redhat.com> 2006-10-21 Havoc Pennington <hp@redhat.com>

* Clean up Doxygen group markers for public API so Doxygen finds
everything (not comprehensively fixed for private API).
Means all remaining Doxygen warnings are just about missing docs
and thus pretty simple to resolve.
/external/dbus/dbus/dbus-marshal-validate.h
5e389fdf499c39926c61b47fcafb5e71291ce1a2 15-Jun-2005 John (J5) Palmieri <johnp@redhat.com> * dbus/dbus-marshal-validate.h: Added a new validation
error code DBUS_VALIDITY_UNKNOWN_OOM_ERROR = -4 for
out of memory errors when validating signitures

* dbus/dbus-marshal-header.c: use DBUS_VALIDITY_UNKNOWN_OOM_ERROR
in places where we previously used DBUS_VALID and a FALSE return
value to indicate OOM

* dbus/dbus-marshal-validate.c (_dbus_validate_signature_with_reason):
Use a stack to track the number of elements inside containers. The
stack values are then used to validate that dict entries have only two
elements within them.
(validate_body_helper): check the reason for failure when validating
varients

* dbus/dbus-message.c (load_message): use
DBUS_VALIDITY_UNKNOWN_OOM_ERROR in places where we previously used
DBUS_VALID and a FALSE return value to indicate OOM

* doc/TODO: remove "- validate dict entry number of fields" as this
patch fixes it
/external/dbus/dbus/dbus-marshal-validate.h
71f3b461b371d6bf7c7bc4e92578420b78d5c0d8 11-Feb-2005 Havoc Pennington <hp@redhat.com> 2005-02-10 Havoc Pennington <hp@redhat.com>

* dbus/dbus-message-factory.c (generate_special): modify test to
avoid using a non-basic dict key

* dbus/dbus-marshal-validate-util.c: add test for the below

* doc/dbus-specification.xml: require that dict keys are a basic
type

* dbus/dbus-marshal-validate.c
(_dbus_validate_signature_with_reason): require that dict key is a
basic type
/external/dbus/dbus/dbus-marshal-validate.h
96a47516321dea8c08e1ab15ac0102ce3c3ae3f1 06-Feb-2005 Havoc Pennington <hp@redhat.com> 2005-02-06 Havoc Pennington <hp@redhat.com>

* dbus/dbus-message-factory.c (generate_special): more tests

* dbus/dbus-marshal-validate.c (validate_body_helper): detect
array length that exceeds the maximum
/external/dbus/dbus/dbus-marshal-validate.h
8f04e1e01f51fa9bef564dbaf29be59694407d21 06-Feb-2005 Havoc Pennington <hp@redhat.com> 2005-02-05 Havoc Pennington <hp@redhat.com>

* dbus/dbus-message-factory.c (generate_special): more test cases,
increasing coverage

* dbus/dbus-marshal-validate.c (validate_body_helper): return the
reason why a signature was invalid

* dbus/dbus-marshal-header.c (load_and_validate_field): fix to
skip the length of the string before we look at it in validation

* dbus/dbus-string-util.c (_dbus_string_test): add tests for
equal_substring

* dbus/dbus-message.c (_dbus_message_loader_new): default
max_message_length to DBUS_MAXIMUM_MESSAGE_LENGTH
/external/dbus/dbus/dbus-marshal-validate.h
c7816d45e82ba8dd7e1e969c2cb6c3a27577cf68 28-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-28 Havoc Pennington <hp@redhat.com>

* doc/dbus-specification.xml: update to describe 16-bit types and
dict entries

* dbus/dbus-marshal-basic.c (_dbus_unpack_uint16): fix broken
assertion

* dbus/dbus-protocol.h (DBUS_TYPE_DICT_ENTRY): add DICT_ENTRY as a
type

* dbus/dbus-marshal-recursive.c: implement
/external/dbus/dbus/dbus-marshal-validate.h
fddbc09c4a9125fcb168fb31ff300d4132919ea6 28-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-27 Havoc Pennington <hp@redhat.com>

* dbus/dbus-message.c: byteswap the message if you init an
iterator to read/write from it

* dbus/dbus-marshal-byteswap.c: new file implementing
_dbus_marshal_byteswap()

* dbus/dbus-marshal-basic.c: add _dbus_swap_array()
/external/dbus/dbus/dbus-marshal-validate.h
9d21554dd3b560952cd5aa607c4ec07898c0b260 23-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-23 Havoc Pennington <hp@redhat.com>

* dbus/dbus-message-factory.c, dbus/dbus-message-util.c:
get this all working, not many tests in the framework yet though
/external/dbus/dbus/dbus-marshal-validate.h
606eb2106b3d7f5cd36a4f1786d281b771bb1bf7 21-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-21 Havoc Pennington <hp@redhat.com>

* dbus/dbus-bus.c: add more return_if_fail checks

* dbus/dbus-message.c (load_message): have the "no validation"
mode (have to edit the code to toggle the mode for now though)

* dbus/dbus-marshal-header.c (_dbus_header_load): have a mode that
skips all validation; I want to use this at least for benchmark
baseline, I'm not sure if it should be a publicly-available switch.
/external/dbus/dbus/dbus-marshal-validate.h
8873c90f99303f9cc308f15f8d03e637911f5b9e 18-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-18 Havoc Pennington <hp@redhat.com>

* Throughout, grand renaming to strip out the use of "service",
just say "name" instead (or "bus name" when ambiguous). Did not
change the internal code of the message bus itself, only the
programmer-facing API and messages.

* doc/dbus-specification.xml: further update the message bus section

* bus/config-parser.c (all_are_equiv): fix bug using freed string
in error case
/external/dbus/dbus/dbus-marshal-validate.h
31988af4089f3793940417535f8eabaae1ac26c8 16-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-16 Havoc Pennington <hp@redhat.com>

* Add and fix docs according to Doxygen warnings throughout
source.

* dbus/dbus-marshal-recursive.c
(_dbus_type_reader_array_is_empty): change this to just call
array_reader_get_array_len() and make it static

* dbus/dbus-message.c (dbus_message_iter_get_element_type): rename
from get_array_type
(dbus_message_iter_init_append): rename from append_iter_init

* dbus/dbus-marshal-recursive.c
(_dbus_type_reader_get_element_type): rename from
_dbus_type_reader_get_array_type
/external/dbus/dbus/dbus-marshal-validate.h
9c3d566e95c9080f6040c64531b0ccae22bd5d74 15-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-15 Havoc Pennington <hp@redhat.com>

* Land the new message args API and type system.

This patch is huge, but the public API change is not
really large. The set of D-BUS types has changed somewhat,
and the arg "getters" are more geared toward language bindings;
they don't make a copy, etc.

There are also some known issues. See these emails for details
on this huge patch:
http://lists.freedesktop.org/archives/dbus/2004-December/001836.html
http://lists.freedesktop.org/archives/dbus/2005-January/001922.html

* dbus/dbus-marshal-*: all the new stuff

* dbus/dbus-message.c: basically rewritten

* dbus/dbus-memory.c (check_guards): with "guards" enabled, init
freed blocks to be all non-nul bytes so using freed memory is less
likely to work right

* dbus/dbus-internals.c (_dbus_test_oom_handling): add
DBUS_FAIL_MALLOC=N environment variable, so you can do
DBUS_FAIL_MALLOC=0 to skip the out-of-memory checking, or
DBUS_FAIL_MALLOC=10 to make it really, really, really slow and
thorough.

* qt/message.cpp: port to the new message args API
(operator<<): use str.utf8() rather than str.unicode()
(pretty sure this is right from the Qt docs?)

* glib/dbus-gvalue.c: port to the new message args API

* bus/dispatch.c, bus/driver.c: port to the new message args API

* dbus/dbus-string.c (_dbus_string_init_const_len): initialize the
"locked" flag to TRUE and align_offset to 0; I guess we never
looked at these anyhow, but seems cleaner.

* dbus/dbus-string.h (_DBUS_STRING_ALLOCATION_PADDING):
move allocation padding macro to this header; use it to implement
(_DBUS_STRING_STATIC): ability to declare a static string.

* dbus/dbus-message.c (_dbus_message_has_type_interface_member):
change to return TRUE if the interface is not set.

* dbus/dbus-string.[hc]: move the D-BUS specific validation stuff
to dbus-marshal-validate.[hc]

* dbus/dbus-marshal-basic.c (_dbus_type_to_string): move here from
dbus-internals.c

* dbus/Makefile.am: cut over from dbus-marshal.[hc]
to dbus-marshal-*.[hc]

* dbus/dbus-object-tree.c (_dbus_decompose_path): move this
function here from dbus-marshal.c
/external/dbus/dbus/dbus-marshal-validate.h
5c486a24e50ef731b8f970060ab10e928cd0e7cd 03-Jan-2005 Havoc Pennington <hp@redhat.com> add a file to hold the validation routines
/external/dbus/dbus/dbus-marshal-validate.h