GDBusMessage: Validate header fields when serializing/deserializing

The D-Bus spec mentions exactly what header fields are required for
various message types. Add tests for this as well.

Also disallow empty interfaces for signals since the D-Bus spec says
this is Verboten already.

Signed-off-by: David Zeuthen <davidz@redhat.com>
This commit is contained in:
David Zeuthen
2010-08-04 14:38:51 -04:00
parent 6f070be65b
commit 89a1b571ad
3 changed files with 268 additions and 11 deletions

View File

@@ -23,11 +23,6 @@
/*
* TODO for GDBus:
*
* - Validate all data (e.g. UTF-8) and check all the required D-Bus headers
* are present and forbidden ones aren't
* - When writing: g_dbus_message_to_blob()
* - When reading: g_dbus_message_new_from_blob()
*
* - would be nice to expose GDBusAuthMechanism and an extension point
*
* - Need to rewrite GDBusAuth and rework GDBusAuthMechanism. In particular