pass only CadetTunnelAxolotl if it suffices, preparation for having ambiguous KX...
[oweals/gnunet.git] / src / cadet / gnunet-service-cadet_tunnel.h
index 8d65cbebd08cbb729b1a6b2a840fdcea4d75dc8a..0abdc02ce6a140e08020dd3dbb801a3b1d8659a7 100644 (file)
@@ -286,35 +286,36 @@ GCT_remove_channel (struct CadetTunnel *t, struct CadetChannel *ch);
  * Search for a channel by global ID.
  *
  * @param t Tunnel containing the channel.
- * @param chid Public channel number.
+ * @param ctn Public channel number.
  *
  * @return channel handler, NULL if doesn't exist
  */
 struct CadetChannel *
-GCT_get_channel (struct CadetTunnel *t, CADET_ChannelNumber chid);
+GCT_get_channel (struct CadetTunnel *t, struct GNUNET_CADET_ChannelTunnelNumber ctn);
 
 
 /**
- * Decrypt and demultiplex by message type. Call appropriate handler
- * for a message towards a channel of a local tunnel.
+ * Decrypt and process an encrypted message.
+ *
+ * Calls the appropriate handler for a message in a channel of a local tunnel.
  *
  * @param t Tunnel this message came on.
  * @param msg Message header.
  */
 void
 GCT_handle_encrypted (struct CadetTunnel *t,
-                      const struct GNUNET_MessageHeader *msg);
+                      const struct GNUNET_CADET_TunnelEncryptedMessage *msg);
 
 
 /**
- * Demultiplex an encapsulated KX message by message type.
+ * Handle a Key eXchange message.
  *
  * @param t Tunnel on which the message came.
- * @param message KX message itself.
+ * @param msg KX message itself.
  */
 void
 GCT_handle_kx (struct CadetTunnel *t,
-               const struct GNUNET_MessageHeader *message);
+               const struct GNUNET_CADET_TunnelKeyExchangeMessage *msg);
 
 
 /**
@@ -426,8 +427,8 @@ GCT_get_destination (struct CadetTunnel *t);
  *
  * @return ID of a channel free to use.
  */
-CADET_ChannelNumber
-GCT_get_next_chid (struct CadetTunnel *t);
+struct GNUNET_CADET_ChannelTunnelNumber
+GCT_get_next_ctn (struct CadetTunnel *t);
 
 
 /**
@@ -494,13 +495,13 @@ GCT_send_prebuilt_message (const struct GNUNET_MessageHeader *message,
 
 
 /**
- * Send an Axolotl KX message.
+ * Send a KX message.
  *
  * @param t Tunnel on which to send it.
  * @param force_reply Force the other peer to reply with a KX message.
  */
 void
-GCT_send_ax_kx (struct CadetTunnel *t, int force_reply);
+GCT_send_kx (struct CadetTunnel *t, int force_reply);
 
 
 /**