summaryrefslogtreecommitdiffstats
path: root/dbus/dbus-protocol.h
diff options
context:
space:
mode:
authorHavoc Pennington <hp@redhat.com>2003-04-22 19:34:33 +0000
committerHavoc Pennington <hp@redhat.com>2003-04-22 19:34:33 +0000
commitb3a3969897930eeda308113acbbb3f98069ee1ab (patch)
tree5cd99199ea35eb1f61d5d3cda9013130af488270 /dbus/dbus-protocol.h
parent983200f912f41ba75a873c011bfbcd3b0285bf4c (diff)
2003-04-22 Havoc Pennington <hp@redhat.com>
* test/data/valid-messages/opposite-endian.message: fix test to use proper type for rply field * test/data/invalid-messages: add tests for below validation * dbus/dbus-message.c (decode_header_data): validate field types, and validate that named fields are valid names (decode_name_field): consider messages in the org.freedesktop.Local. namespace to be invalid. * dbus/dbus-string.c (_dbus_string_validate_name): new
Diffstat (limited to 'dbus/dbus-protocol.h')
-rw-r--r--dbus/dbus-protocol.h12
1 files changed, 10 insertions, 2 deletions
diff --git a/dbus/dbus-protocol.h b/dbus/dbus-protocol.h
index 651969c4..314a9934 100644
--- a/dbus/dbus-protocol.h
+++ b/dbus/dbus-protocol.h
@@ -53,7 +53,10 @@ extern "C" {
#define DBUS_TYPE_DICT 10
#define DBUS_TYPE_LAST DBUS_TYPE_DICT
-
+
+/* Max length in bytes of a service or message name */
+#define DBUS_MAXIMUM_NAME_LENGTH 256
+
/* Header flags */
#define DBUS_HEADER_FLAG_ERROR 0x1
@@ -92,7 +95,12 @@ extern "C" {
#define DBUS_MESSAGE_SERVICE_DELETED "org.freedesktop.DBus.ServiceDeleted"
#define DBUS_MESSAGE_SERVICE_LOST "org.freedesktop.DBus.ServiceLost"
-#define DBUS_MESSAGE_LOCAL_DISCONNECT "org.freedesktop.Local.Disconnect"
+
+/* This namespace is reserved for locally-synthesized messages, you can't
+ * send messages that have this namespace.
+ */
+#define DBUS_NAMESPACE_LOCAL_MESSAGE "org.freedesktop.Local."
+#define DBUS_MESSAGE_LOCAL_DISCONNECT DBUS_NAMESPACE_LOCAL_MESSAGE"Disconnect"
#ifdef __cplusplus
}