error msg
[oweals/gnunet.git] / src / transport / gnunet-service-transport_hello.c
index 3838c511a5a5475999813d15464a02f330104e56..c04d2e1ddadb81f5ca8ae643adbe4503c33d0efb 100644 (file)
  */
 #define HELLO_REFRESH_PERIOD GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_HOURS, 6)
 
+/**
+ * Hello address expiration
+ */
+extern struct GNUNET_TIME_Relative hello_expiration;
+
 
 /**
  * Entry in linked list of network addresses for ourselves.  Also
@@ -69,7 +74,7 @@ struct OwnAddressList
   /**
    * Signature for a 'struct TransportPongMessage' for this address.
    */
-  struct GNUNET_CRYPTO_RsaSignature pong_signature;
+  struct GNUNET_CRYPTO_EccSignature pong_signature;
 
 };
 
@@ -159,20 +164,14 @@ refresh_hello_task (void *cls, const struct GNUNET_SCHEDULER_TaskContext *tc)
 
   hello_task = GNUNET_SCHEDULER_NO_TASK;
   gc.addr_pos = oal_head;
-  gc.expiration =
-      GNUNET_TIME_relative_to_absolute
-      (GNUNET_CONSTANTS_HELLO_ADDRESS_EXPIRATION);
+  gc.expiration = GNUNET_TIME_relative_to_absolute (hello_expiration);
 
   GNUNET_free (our_hello);
   our_hello = GNUNET_HELLO_create (&GST_my_public_key, &address_generator, &gc);
   GNUNET_assert (NULL != our_hello);
-
-#if DEBUG_TRANSPORT
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK,
               "Refreshed my `%s', new size is %d\n", "HELLO",
               GNUNET_HELLO_size (our_hello));
-#endif
-
   GNUNET_STATISTICS_update (GST_stats, gettext_noop ("# refreshed my HELLO"), 1,
                             GNUNET_NO);
   if (NULL != hello_cb)
@@ -260,13 +259,11 @@ GST_hello_modify_addresses (int addremove,
 {
   struct OwnAddressList *al;
 
-#if DEBUG_TRANSPORT
   GNUNET_log (GNUNET_ERROR_TYPE_DEBUG,
-              (add_remove ==
-               GNUNET_YES) ? "Adding `%s':%s to the set of our addresses\n" :
-              "Removing `%s':%s from the set of our addresses\n",
-              GST_plugins_a2s (address), p->short_name);
-#endif
+              (addremove ==
+               GNUNET_YES) ? "Adding `%s' to the set of our addresses\n" :
+              "Removing `%s' from the set of our addresses\n",
+              GST_plugins_a2s (address));
   GNUNET_assert (address != NULL);
   if (GNUNET_NO == addremove)
   {
@@ -302,7 +299,7 @@ GST_hello_modify_addresses (int addremove,
  */
 int
 GST_hello_test_address (const struct GNUNET_HELLO_Address *address,
-                        struct GNUNET_CRYPTO_RsaSignature **sig,
+                        struct GNUNET_CRYPTO_EccSignature **sig,
                         struct GNUNET_TIME_Absolute **sig_expiration)
 {
   struct OwnAddressList *al;