* Last phase, we're done.
*/
AUTO_DONE
-
+
};
* Function to call when done.
*/
GNUNET_NAT_AutoResultCallback fin_cb;
-
+
/**
* Closure for 'fin_cb'.
*/
void *fin_cb_cls;
-
+
/**
* Handle for active 'GNUNET_NAT_mini_get_external_ipv4'-operation.
*/
ah->task = GNUNET_SCHEDULER_NO_TASK;
GNUNET_NAT_test_stop (ah->tst);
ah->tst = NULL;
- GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat",
+ GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat",
"ENABLE_ICMP_SERVER",
"NO");
next_phase (ah);
GNUNET_NAT_test_stop (ah->tst);
ah->tst = NULL;
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
- success
+ success
? _("NAT traversal with ICMP Server succeeded.\n")
: _("NAT traversal with ICMP Server failed.\n"));
- GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat", "ENABLE_ICMP_SERVER",
+ GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat", "ENABLE_ICMP_SERVER",
success ? "YES": "NO");
next_phase (ah);
}
/**
- * Determine our local IP addresses; detect internal IP & IPv6-support
+ * Determine our local IP addresses; detect internal IP & IPv6-support
*
* @param ah auto setup context
*/
{
ah->have_v6 = GNUNET_NO;
GNUNET_OS_network_interfaces_list (&nipo, ah);
- GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat", "DISABLEV6",
+ GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat", "DISABLEV6",
(GNUNET_YES == ah->have_v6) ? "NO" : "YES");
next_phase (ah);
}
/* FIXME: test if upnpc is actually working, that is, if transports
start to work once we use UPnP */
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
- (have_upnpc)
+ (have_upnpc)
? _("upnpc found, enabling its use\n")
: _("upnpc not found\n"));
- GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat", "ENABLE_UPNP",
+ GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat", "ENABLE_UPNP",
(GNUNET_YES == have_upnpc) ? "YES" : "NO");
next_phase (ah);
}
(GNUNET_YES ==
GNUNET_CONFIGURATION_get_value_yesno (ah->cfg, "nat", "BEHIND_NAT")) &&
(GNUNET_YES ==
- GNUNET_OS_check_helper_binary (binary, GNUNET_YES, NULL))); // FIXME: CF: add test-parameters
+ GNUNET_OS_check_helper_binary (binary, GNUNET_YES, "-d 127.0.0.1" ))); // use localhost as source for that one udp-port, ok for testing
GNUNET_free_non_null (tmp);
GNUNET_free (binary);
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
- (hns)
+ (hns)
? _("gnunet-helper-nat-server found, testing it\n")
: _("No working gnunet-helper-nat-server found\n"));
if (hns)
(GNUNET_YES !=
GNUNET_CONFIGURATION_get_value_yesno (ah->cfg, "nat", "BEHIND_NAT")) &&
(GNUNET_YES ==
- GNUNET_OS_check_helper_binary (binary, GNUNET_YES, NULL))); // FIXME: CF: add test-parameters
+ GNUNET_OS_check_helper_binary (binary, GNUNET_YES, "-d 127.0.0.1 127.0.0.2 42"))); // none of these parameters are actually used in privilege testing mode
GNUNET_free_non_null (tmp);
GNUNET_free (binary);
GNUNET_log (GNUNET_ERROR_TYPE_INFO,
- (hnc)
+ (hnc)
? _("gnunet-helper-nat-client found, enabling it\n")
: _("gnunet-helper-nat-client not found or behind NAT, disabling it\n"));
next_phase (ah);
ah->initial_cfg = GNUNET_CONFIGURATION_dup (cfg);
/* never use loopback addresses if user wanted autoconfiguration */
- GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat",
- "USE_LOCALADDR",
+ GNUNET_CONFIGURATION_set_value_string (ah->cfg, "nat",
+ "USE_LOCALADDR",
"NO");
next_phase (ah);
return ah;
}
-
+
/**
* Abort autoconfiguration.
*