[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r28121 - gnunet/src/include
From: |
gnunet |
Subject: |
[GNUnet-SVN] r28121 - gnunet/src/include |
Date: |
Wed, 17 Jul 2013 15:43:51 +0200 |
Author: tg
Date: 2013-07-17 15:43:51 +0200 (Wed, 17 Jul 2013)
New Revision: 28121
Modified:
gnunet/src/include/gnunet_multicast_service.h
gnunet/src/include/gnunet_psyc_service.h
gnunet/src/include/gnunet_social_service.h
Log:
PSYC/multicast: message parameters for join/part requests
Modified: gnunet/src/include/gnunet_multicast_service.h
===================================================================
--- gnunet/src/include/gnunet_multicast_service.h 2013-07-17 13:38:43 UTC
(rev 28120)
+++ gnunet/src/include/gnunet_multicast_service.h 2013-07-17 13:43:51 UTC
(rev 28121)
@@ -222,19 +222,21 @@
/**
* Header of a request from a member to the origin.
*
- * This format is public as the replay mechanism must replay message fragments
using the
- * same format. This is needed as we want to integrity-check message
fragments within
- * the multicast layer to avoid multicasting mal-formed messages.
+ * FIXME: this is going to be internal.
*/
struct GNUNET_MULTICAST_RequestHeader
{
-
/**
* Header for all requests from a member to the origin.
*/
struct GNUNET_MessageHeader header;
/**
+ * Public key of the group.
+ */
+ struct GNUNET_CRYPTO_ECCPublicKey pub_key;
+
+ /**
* Flags for this request.
*/
enum GNUNET_MULTICAST_MessageFlags flags GNUNET_PACKED;
@@ -389,10 +391,12 @@
* @param cls Closure (set from GNUNET_MULTICAST_origin_start).
* @param sender Identity of the sender.
* @param req Request to the origin.
+ * @param flags Flags for the request.
*/
typedef void (*GNUNET_MULTICAST_RequestCallback) (void *cls,
const struct
GNUNET_PeerIdentity *sender,
- const struct
GNUNET_MULTICAST_RequestHeader *req);
+ const struct
GNUNET_MessageHeader *req,
+ enum
GNUNET_MULTICAST_MessageFlags flags);
/**
@@ -649,9 +653,11 @@
* Part a multicast group.
*
* @param member Membership handle.
+ * @param part_req Application-dependent part request to send to the origin.
*/
void
-GNUNET_MULTICAST_member_part (struct GNUNET_MULTICAST_Member *member);
+GNUNET_MULTICAST_member_part (struct GNUNET_MULTICAST_Member *member,
+ const struct GNUNET_MessageHeader *part_req);
/**
Modified: gnunet/src/include/gnunet_psyc_service.h
===================================================================
--- gnunet/src/include/gnunet_psyc_service.h 2013-07-17 13:38:43 UTC (rev
28120)
+++ gnunet/src/include/gnunet_psyc_service.h 2013-07-17 13:43:51 UTC (rev
28121)
@@ -118,7 +118,7 @@
/**
* Historic message, retrieved from PSYCstore.
*/
- GNUNET_PSYC_MESSAGE_HISTORIC = 1 << 2
+ GNUNET_PSYC_MESSAGE_HISTORIC = 1 << 30
};
@@ -385,6 +385,10 @@
* @param method Function to invoke on messages received from the channel,
* typically at least contains functions for @e join and @e
part.
* @param method_cls Closure for @a method.
+ * @param method_name Method name for the join request.
+ * @param env Environment containing transient variables for the request, or
NULL.
+ * @param data_size Number of bytes in @a data.
+ * @param data Payload for the join message.
* @return Handle for the slave, NULL on error.
*/
struct GNUNET_PSYC_Slave *
@@ -392,7 +396,11 @@
const struct GNUNET_CRYPTO_EccPublicKey *pub_key,
const struct GNUNET_PeerIdentity *origin,
GNUNET_PSYC_Method method,
- void *method_cls);
+ void *method_cls,
+ const char *method_name,
+ const struct GNUNET_ENV_Environment *env,
+ size_t data_size,
+ const void *data);
/**
@@ -402,9 +410,17 @@
* first explicitly send a @e part request (via GNUNET_PSYC_slave_to_master()).
*
* @param slave Slave handle.
+ * @param method_name Method name for the part request.
+ * @param env Environment containing transient variables for the request, or
NULL.
+ * @param data_size Number of bytes in @a data.
+ * @param data Payload for the part message.
*/
void
-GNUNET_PSYC_slave_part (struct GNUNET_PSYC_Slave *slave);
+GNUNET_PSYC_slave_part (struct GNUNET_PSYC_Slave *slave,
+ const char *method_name,
+ const struct GNUNET_ENV_Environment *env,
+ size_t data_size,
+ const void *data);
/**
Modified: gnunet/src/include/gnunet_social_service.h
===================================================================
--- gnunet/src/include/gnunet_social_service.h 2013-07-17 13:38:43 UTC (rev
28120)
+++ gnunet/src/include/gnunet_social_service.h 2013-07-17 13:43:51 UTC (rev
28121)
@@ -189,15 +189,15 @@
* @param nym Handle for the user who wants to enter.
* @param header_length Number of modifiers in header.
* @param header Modifiers present in the message.
- * @param msg_size Number of bytes in @a msg.
- * @param msg Payload given on enter (e.g. a password).
+ * @param data_size Number of bytes in @a data.
+ * @param data Payload given on enter (e.g. a password).
*/
typedef void (*GNUNET_SOCIAL_AnswerDoorCallback)(void *cls,
struct GNUNET_SOCIAL_Nym *nym,
size_t header_length,
GNUNET_PSYC_Modifier *header,
- size_t msg_size,
- const void *msg);
+ size_t data_size,
+ const void *data);
/**
@@ -283,16 +283,16 @@
* @param nym Handle for the entity that wanted to enter.
* @param method_name Method name for the rejection message.
* @param env Environment containing variables for the message, or NULL.
- * @param msg_size Number of bytes in @a message for method.
- * @param msg Rejection message to send back.
+ * @param data_size Number of bytes in @a data for method.
+ * @param data Data for the rejection message to send back.
*/
void
GNUNET_SOCIAL_home_reject_entry (struct GNUNET_SOCIAL_Home *home,
struct GNUNET_SOCIAL_Nym *nym,
const char *method_name,
const struct GNUNET_ENV_Environment *env,
- size_t msg_size,
- const void *msg);
+ size_t data_size,
+ const void *data);
/**
@@ -411,8 +411,8 @@
* 'PLACE' record in the GADS zone with the public key 'HEX', and can be
* used to request entry to a pseudonym's place directly.
* @param env Environment containing variables for the message, or NULL.
- * @param msg_size Number of bytes in @a msg.
- * @param msg Message to give to the enter callback.
+ * @param data_size Number of bytes in @a data.
+ * @param data Payload for the message to give to the enter callback.
* @param slicer Slicer to use for processing incoming requests from guests.
* @return NULL on errors, otherwise handle to the place.
*/
@@ -421,8 +421,8 @@
struct GNUNET_SOCIAL_Ego *ego,
char *address,
const struct GNUNET_ENV_Environment *env,
- size_t msg_size,
- const void *msg,
+ size_t data_size,
+ const void *data,
struct GNUNET_SOCIAL_Slicer *slicer);
/**
@@ -434,8 +434,8 @@
* @param peer Peer to send request to.
* @param slicer Slicer to use for processing incoming requests from guests.
* @param env Environment containing variables for the message, or NULL.
- * @param msg_size Number of bytes in @a msg.
- * @param msg Message to give to the enter callback.
+ * @param data_size Number of bytes in @a data.
+ * @param data Payload for the message to give to the enter callback.
* @return NULL on errors, otherwise handle to the place.
*/
struct GNUNET_SOCIAL_Place *
@@ -445,8 +445,8 @@
struct GNUNET_PeerIdentity *peer,
struct GNUNET_SOCIAL_Slicer *slicer,
const struct GNUNET_ENV_Environment *env,
- size_t msg_size,
- const void *msg);
+ size_t data_size,
+ const void *data);
struct GNUNET_SOCIAL_WatchHandle;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r28121 - gnunet/src/include,
gnunet <=