error msg
[oweals/gnunet.git] / src / transport / Makefile.am
index 6fb27f067bf46323793453eee530446633c87ac9..5f65dff604c2ce1b5f6089a38f09b137a77fc9b5 100644 (file)
@@ -4,6 +4,8 @@ plugindir = $(libdir)/gnunet
 
 pkgcfgdir= $(pkgdatadir)/config.d/
 
+libexecdir= $(pkglibdir)/libexec/
+
 pkgcfg_DATA = \
   transport.conf
 
@@ -12,7 +14,6 @@ if HAVE_MHD
  GN_LIBMHD = -lmicrohttpd
  HTTP_SERVER_PLUGIN_LA = libgnunet_plugin_transport_http_server.la
  HTTPS_SERVER_PLUGIN_LA = libgnunet_plugin_transport_https_server.la
  HTTP_SERVER_PLUGIN_TEST = test_plugin_http_server
  HTTPS_SERVER_PLUGIN_TEST = test_plugin_https_server
 endif
@@ -27,27 +28,18 @@ endif
 if HAVE_MHD 
 if HAVE_LIBCURL
  HTTP_API_TEST = test_transport_api_http
-endif
-endif 
-
-if FALSE 
- HTTP_API_TEST = test_transport_api_http
- HTTP_NAT_API_TEST = test_transport_api_http_nat
+ HTTP_REVERSE_API_TEST = test_transport_api_http_reverse
  HTTP_API_TIMEOUT_TEST = test_transport_api_timeout_http
  HTTP_REL_TEST = test_transport_api_reliability_http
- HTTP_NAT_REL_TEST = test_transport_api_reliability_http_nat
  HTTP_QUOTA_TEST = test_quota_compliance_http \
                   test_quota_compliance_http_asymmetric
-
  HTTPS_API_TEST = test_transport_api_https
- HTTPS_NAT_API_TEST = test_transport_api_https_nat
  HTTPS_API_TIMEOUT_TEST = test_transport_api_timeout_https
  HTTPS_REL_TEST = test_transport_api_reliability_https
- HTTPS_NAT_REL_TEST = test_transport_api_reliability_https_nat
  HTTPS_QUOTA_TEST = test_quota_compliance_https \
-               test_quota_compliance_https_asymmetric
+               test_quota_compliance_https_asymmetric 
 endif
-
+endif 
 
 if USE_COVERAGE
   AM_CFLAGS = --coverage -O0
@@ -57,6 +49,7 @@ if LINUX
  WLAN_BIN = gnunet-helper-transport-wlan
  WLAN_BIN_DUMMY = gnunet-helper-transport-wlan-dummy
  WLAN_BIN_SENDER = gnunet-transport-wlan-sender
+ WLAN_BIN_RECEIVER = gnunet-transport-wlan-receiver
  WLAN_PLUGIN_LA = libgnunet_plugin_transport_wlan.la
  WLAN_PLUGIN_TEST = test_plugin_wlan
  WLAN_API_TEST = test_transport_api_wlan
@@ -69,7 +62,7 @@ endif
 
 if LINUX
 install-exec-hook:
-       $(top_srcdir)/src/transport/install-wlan-helper.sh $(bindir) $(SUDO_BINARY) || true
+       $(top_srcdir)/src/transport/install-wlan-helper.sh $(libexecdir) $(SUDO_BINARY) || true
 else
 install-exec-hook:
 endif
@@ -85,7 +78,8 @@ UNIX_QUOTA_TEST = test_quota_compliance_unix \
 endif
 
 noinst_PROGRAMS = \
- $(WLAN_BIN_SENDER)
+ $(WLAN_BIN_SENDER) \
+ $(WLAN_BIN_RECEIVER)
 
 lib_LTLIBRARIES = \
   libgnunettransport.la \
@@ -115,13 +109,15 @@ libgnunettransport_la_LIBADD = \
   $(GN_LIBINTL) 
 libgnunettransport_la_LDFLAGS = \
   $(GN_LIB_LDFLAGS) $(WINFLAGS) \
-  -version-info 1:0:0
+  -version-info 3:0:1
 
-bin_PROGRAMS = \
- gnunet-transport \
+libexec_PROGRAMS = \
  $(WLAN_BIN) \
  $(WLAN_BIN_DUMMY) \
- gnunet-service-transport \
+ gnunet-service-transport 
+
+bin_PROGRAMS = \
+ gnunet-transport \
  gnunet-transport-certificate-creation
 
 #bin_SCRIPTS = \
@@ -145,6 +141,11 @@ gnunet_transport_wlan_sender_SOURCES = \
 gnunet_transport_wlan_sender_LDADD = \
   $(top_builddir)/src/util/libgnunetutil.la 
 
+gnunet_transport_wlan_receiver_SOURCES = \
+ gnunet-transport-wlan-receiver.c
+gnunet_transport_wlan_receiver_LDADD = \
+  $(top_builddir)/src/util/libgnunetutil.la 
+
 gnunet_transport_SOURCES = \
  gnunet-transport.c         
 gnunet_transport_LDADD = \
@@ -163,7 +164,8 @@ gnunet_service_transport_SOURCES = \
  gnunet-service-transport_hello.h gnunet-service-transport_hello.c \
  gnunet-service-transport_neighbours.h gnunet-service-transport_neighbours.c \
  gnunet-service-transport_plugins.h gnunet-service-transport_plugins.c \
- gnunet-service-transport_validation.h gnunet-service-transport_validation.c 
+ gnunet-service-transport_validation.h gnunet-service-transport_validation.c \
+ gnunet-service-transport_manipulation.h gnunet-service-transport_manipulation.c 
 gnunet_service_transport_LDADD = \
   $(top_builddir)/src/ats/libgnunetats.la \
   $(top_builddir)/src/hello/libgnunethello.la \
@@ -172,6 +174,9 @@ gnunet_service_transport_LDADD = \
   $(top_builddir)/src/util/libgnunetutil.la \
   $(GN_GLPK) \
   $(GN_LIBINTL)
+gnunet_service_transport_CFLAGS = \
+  $(CFLAGS)
+# -DANALYZE
 
 plugin_LTLIBRARIES = \
   libgnunet_plugin_transport_tcp.la \
@@ -239,10 +244,10 @@ libgnunet_plugin_transport_unix_la_LIBADD = \
   $(LTLIBINTL)
 libgnunet_plugin_transport_unix_la_LDFLAGS = \
  $(GN_PLUGIN_LDFLAGS)
+
+
 libgnunet_plugin_transport_http_client_la_SOURCES = \
-  plugin_transport_http_client.c plugin_transport_http_common.c
+  plugin_transport_http_client.c plugin_transport_http_common.c plugin_transport_http_common.h
 libgnunet_plugin_transport_http_client_la_LIBADD = \
   $(top_builddir)/src/hello/libgnunethello.la \
   $(top_builddir)/src/statistics/libgnunetstatistics.la \
@@ -256,10 +261,10 @@ libgnunet_plugin_transport_http_client_la_CFLAGS = \
  $(CFLAGS) 
 libgnunet_plugin_transport_http_client_la_CPPFLAGS = \
  @LIBCURL_CPPFLAGS@
+
+
 libgnunet_plugin_transport_http_server_la_SOURCES = \
-  plugin_transport_http_server.c plugin_transport_http_common.c
+  plugin_transport_http_server.c plugin_transport_http_common.c 
 libgnunet_plugin_transport_http_server_la_LIBADD = \
   $(top_builddir)/src/hello/libgnunethello.la \
   $(top_builddir)/src/statistics/libgnunetstatistics.la \
@@ -281,14 +286,14 @@ libgnunet_plugin_transport_https_client_la_LIBADD = \
   @LIBCURL@ \
   $(top_builddir)/src/nat/libgnunetnat.la \
   $(top_builddir)/src/util/libgnunetutil.la 
-libgnunet_plugin_transport_https_client_laLDFLAGS = \
+libgnunet_plugin_transport_https_client_la_LDFLAGS = \
  $(GN_PLUGIN_LDFLAGS)
 libgnunet_plugin_transport_https_client_la_CFLAGS = \
  $(CFLAGS) -DBUILD_HTTPS 
 libgnunet_plugin_transport_https_client_la_CPPFLAGS = \
  @LIBCURL_CPPFLAGS@
+
+
 libgnunet_plugin_transport_https_server_la_SOURCES = \
   plugin_transport_http_server.c plugin_transport_http_common.c
 libgnunet_plugin_transport_https_server_la_LIBADD = \
@@ -312,6 +317,7 @@ check_PROGRAMS = \
  test_plugin_udp \
  $(UNIX_TEST) \
  $(WLAN_PLUGIN_TEST) \
+ test_http_common \
  $(HTTP_CLIENT_PLUGIN_TEST) \
  $(HTTPS_CLIENT_PLUGIN_TEST) \
  $(HTTP_SERVER_PLUGIN_TEST) \
@@ -331,22 +337,21 @@ check_PROGRAMS = \
  $(UNIX_PLUGIN_TIMEOUT_TEST) \
  test_transport_api_udp_nat \
  $(HTTP_API_TEST) \
- $(HTTP_NAT_API_TEST) \
+ $(HTTP_REVERSE_API_TEST) \
  $(HTTP_API_TIMEOUT_TEST) \
  $(HTTPS_API_TEST) \
- $(HTTPS_NAT_API_TEST) \
  $(HTTPS_API_TIMEOUT_TEST) \
  $(WLAN_API_TEST) \
  test_transport_api_multi \
+ test_transport_api_manipulation_send_tcp \
+ test_transport_api_manipulation_recv_tcp \
  test_transport_api_reliability_tcp \
  test_transport_api_reliability_tcp_nat \
  test_transport_api_unreliability_udp \
  test_transport_api_unreliability_constant_udp \
  $(UNIX_REL_TEST) \
  $(HTTP_REL_TEST) \
- $(HTTP_NAT_REL_TEST) \
  $(HTTPS_REL_TEST) \
- $(HTTPS_NAT_REL_TEST) \
  $(WLAN_REL_TEST) \
  $(WLAN_UREL_TEST) \
  test_quota_compliance_tcp \
@@ -381,24 +386,21 @@ TESTS = \
  $(UNIX_PLUGIN_TEST) \
  $(UNIX_PLUGIN_TIMEOUT_TEST) \
  test_transport_api_udp_nat \
- test_transport_api_http \
  $(HTTP_API_TEST) \
- $(HTTP_NAT_API_TEST) \
  $(HTTP_API_TIMEOUT_TEST) \
  $(HTTPS_API_TEST) \
- $(HTTPS_NAT_API_TEST) \
  $(HTTPS_API_TIMEOUT_TEST) \
  $(WLAN_API_TEST) \
  test_transport_api_multi \
+ test_transport_api_manipulation_send_tcp \
+ test_transport_api_manipulation_recv_tcp \
  test_transport_api_reliability_tcp \
  test_transport_api_reliability_tcp_nat \
  test_transport_api_unreliability_udp \
  test_transport_api_unreliability_constant_udp \
  $(UNIX_REL_TEST) \
  $(HTTP_REL_TEST) \
- $(HTTP_NAT_REL_TEST) \
  $(HTTPS_REL_TEST) \
- $(HTTPS_NAT_REL_TEST) \
  $(WLAN_REL_TEST) \
  $(WLAN_UREL_TEST) \
  test_quota_compliance_tcp \
@@ -433,7 +435,6 @@ test_transport_testing_LDADD = \
  $(top_builddir)/src/hello/libgnunethello.la \
  $(top_builddir)/src/transport/libgnunettransporttesting.la 
 
-
 test_transport_api_blacklisting_SOURCES = \
  test_transport_api_blacklisting.c
 test_transport_api_blacklisting_LDADD = \
@@ -497,6 +498,16 @@ test_plugin_wlan_LDADD = \
  $(top_builddir)/src/util/libgnunetutil.la  \
  $(top_builddir)/src/transport/libgnunettransporttesting.la 
 
+
+test_http_common_SOURCES = \
+ test_http_common.c plugin_transport_http_common.c
+test_http_common_LDADD = \
+ $(top_builddir)/src/transport/libgnunettransport.la \
+ $(top_builddir)/src/statistics/libgnunetstatistics.la \
+ $(top_builddir)/src/hello/libgnunethello.la \
+ $(top_builddir)/src/util/libgnunetutil.la  \
+ $(top_builddir)/src/transport/libgnunettransporttesting.la 
+
 test_plugin_http_server_SOURCES = \
  test_plugin_transport.c
 test_plugin_http_server_LDADD = \
@@ -505,7 +516,7 @@ test_plugin_http_server_LDADD = \
  $(top_builddir)/src/hello/libgnunethello.la \
  $(top_builddir)/src/util/libgnunetutil.la  \
  $(top_builddir)/src/transport/libgnunettransporttesting.la 
+
 test_plugin_https_server_SOURCES = \
  test_plugin_transport.c
 test_plugin_https_server_LDADD = \
@@ -514,7 +525,7 @@ test_plugin_https_server_LDADD = \
  $(top_builddir)/src/hello/libgnunethello.la \
  $(top_builddir)/src/util/libgnunetutil.la  \
  $(top_builddir)/src/transport/libgnunettransporttesting.la
+
 test_plugin_http_client_SOURCES = \
  test_plugin_transport.c
 test_plugin_http_client_LDADD = \
@@ -523,7 +534,7 @@ test_plugin_http_client_LDADD = \
  $(top_builddir)/src/hello/libgnunethello.la \
  $(top_builddir)/src/util/libgnunetutil.la  \
  $(top_builddir)/src/transport/libgnunettransporttesting.la 
+
 test_plugin_https_client_SOURCES = \
  test_plugin_transport.c
 test_plugin_https_client_LDADD = \
@@ -583,6 +594,23 @@ test_transport_api_tcp_nat_LDADD = \
  $(top_builddir)/src/util/libgnunetutil.la \
  $(top_builddir)/src/transport/libgnunettransporttesting.la 
 
+test_transport_api_manipulation_send_tcp_SOURCES = \
+ test_transport_api_manipulation_send_tcp.c
+test_transport_api_manipulation_send_tcp_LDADD = \
+ $(top_builddir)/src/transport/libgnunettransport.la \
+ $(top_builddir)/src/hello/libgnunethello.la \
+ $(top_builddir)/src/util/libgnunetutil.la \
+ $(top_builddir)/src/transport/libgnunettransporttesting.la 
+
+test_transport_api_manipulation_recv_tcp_SOURCES = \
+ test_transport_api_manipulation_recv_tcp.c
+test_transport_api_manipulation_recv_tcp_LDADD = \
+ $(top_builddir)/src/transport/libgnunettransport.la \
+ $(top_builddir)/src/hello/libgnunethello.la \
+ $(top_builddir)/src/util/libgnunetutil.la \
+ $(top_builddir)/src/transport/libgnunettransporttesting.la 
+
+
 test_transport_api_reliability_tcp_SOURCES = \
  test_transport_api_reliability.c
 test_transport_api_reliability_tcp_LDADD = \
@@ -663,41 +691,30 @@ test_transport_api_unix_LDADD = \
  $(top_builddir)/src/util/libgnunetutil.la \
  $(top_builddir)/src/transport/libgnunettransporttesting.la 
 
-# HTTP/S tests
-
+# HTTP tests
 test_transport_api_http_SOURCES = \
  test_transport_api.c
 test_transport_api_http_LDADD = \
  $(top_builddir)/src/transport/libgnunettransport.la \
  $(top_builddir)/src/hello/libgnunethello.la \
  $(top_builddir)/src/util/libgnunetutil.la \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
-
-if FALSE
+ $(top_builddir)/src/transport/libgnunettransporttesting.la
 
-test_transport_api_timeout_http_SOURCES = \
- test_transport_api_timeout.c
-test_transport_api_timeout_http_LDADD = \
+test_transport_api_http_reverse_SOURCES = \
+ test_transport_api.c
+test_transport_api_http_reverse_LDADD = \
  $(top_builddir)/src/transport/libgnunettransport.la \
  $(top_builddir)/src/hello/libgnunethello.la \
  $(top_builddir)/src/util/libgnunetutil.la \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
+ $(top_builddir)/src/transport/libgnunettransporttesting.la
 
-test_transport_api_timeout_https_SOURCES = \
+test_transport_api_timeout_http_SOURCES = \
  test_transport_api_timeout.c
-test_transport_api_timeout_https_LDADD = \
- $(top_builddir)/src/transport/libgnunettransport.la \
- $(top_builddir)/src/hello/libgnunethello.la \
- $(top_builddir)/src/util/libgnunetutil.la \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
-
-test_transport_api_http_nat_SOURCES = \
- test_transport_api.c
-test_transport_api_http_nat_LDADD = \
+test_transport_api_timeout_http_LDADD = \
  $(top_builddir)/src/transport/libgnunettransport.la \
  $(top_builddir)/src/hello/libgnunethello.la \
  $(top_builddir)/src/util/libgnunetutil.la \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
+ $(top_builddir)/src/transport/libgnunettransporttesting.la  
 
 test_transport_api_reliability_http_SOURCES = \
  test_transport_api_reliability.c
@@ -707,46 +724,6 @@ test_transport_api_reliability_http_LDADD = \
  $(top_builddir)/src/util/libgnunetutil.la \
  $(top_builddir)/src/transport/libgnunettransporttesting.la 
 
-test_transport_api_reliability_http_nat_SOURCES = \
- test_transport_api_reliability.c
-test_transport_api_reliability_http_nat_LDADD = \
- $(top_builddir)/src/transport/libgnunettransport.la \
- $(top_builddir)/src/hello/libgnunethello.la \
- $(top_builddir)/src/util/libgnunetutil.la \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
-
-test_transport_api_https_SOURCES = \
- test_transport_api.c
-test_transport_api_https_LDADD = \
- $(top_builddir)/src/transport/libgnunettransport.la \
- $(top_builddir)/src/hello/libgnunethello.la \
- $(top_builddir)/src/util/libgnunetutil.la  \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
-
-test_transport_api_https_nat_SOURCES = \
- test_transport_api.c
-test_transport_api_https_nat_LDADD = \
- $(top_builddir)/src/transport/libgnunettransport.la \
- $(top_builddir)/src/hello/libgnunethello.la \
- $(top_builddir)/src/util/libgnunetutil.la \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
-
-test_transport_api_reliability_https_SOURCES = \
- test_transport_api_reliability.c
-test_transport_api_reliability_https_LDADD = \
- $(top_builddir)/src/transport/libgnunettransport.la \
- $(top_builddir)/src/hello/libgnunethello.la \
- $(top_builddir)/src/util/libgnunetutil.la \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
-
-test_transport_api_reliability_https_nat_SOURCES = \
- test_transport_api_reliability.c
-test_transport_api_reliability_https_nat_LDADD = \
- $(top_builddir)/src/transport/libgnunettransport.la \
- $(top_builddir)/src/hello/libgnunethello.la \
- $(top_builddir)/src/util/libgnunetutil.la \
- $(top_builddir)/src/transport/libgnunettransporttesting.la 
-
 test_quota_compliance_http_SOURCES = \
  test_quota_compliance.c
 test_quota_compliance_http_LDADD = \
@@ -779,8 +756,31 @@ test_quota_compliance_https_asymmetric_LDADD = \
  $(top_builddir)/src/util/libgnunetutil.la \
  $(top_builddir)/src/transport/libgnunettransporttesting.la
 
+# HTTPS tests
+test_transport_api_https_SOURCES = \
+ test_transport_api.c
+test_transport_api_https_LDADD = \
+ $(top_builddir)/src/transport/libgnunettransport.la \
+ $(top_builddir)/src/hello/libgnunethello.la \
+ $(top_builddir)/src/util/libgnunetutil.la  \
+ $(top_builddir)/src/transport/libgnunettransporttesting.la 
 
-endif
+test_transport_api_timeout_https_SOURCES = \
+ test_transport_api_timeout.c
+test_transport_api_timeout_https_LDADD = \
+ $(top_builddir)/src/transport/libgnunettransport.la \
+ $(top_builddir)/src/hello/libgnunethello.la \
+ $(top_builddir)/src/util/libgnunetutil.la \
+ $(top_builddir)/src/transport/libgnunettransporttesting.la  
+
+
+test_transport_api_reliability_https_SOURCES = \
+ test_transport_api_reliability.c
+test_transport_api_reliability_https_LDADD = \
+ $(top_builddir)/src/transport/libgnunettransport.la \
+ $(top_builddir)/src/hello/libgnunethello.la \
+ $(top_builddir)/src/util/libgnunetutil.la \
+ $(top_builddir)/src/transport/libgnunettransporttesting.la 
 
 test_transport_api_unreliability_unix_SOURCES = \
  test_transport_api_unreliability.c
@@ -882,7 +882,8 @@ test_transport_api_multi_LDADD = \
 
 
 EXTRA_DIST = \
-gnunet-transport-certificate-creation \
+test_plugin_hostkey \
+test_plugin_hostkey.ecc \
 template_cfg_peer1.conf\
 template_cfg_peer2.conf\
 test_plugin_transport_data.conf\
@@ -898,6 +899,8 @@ test_quota_compliance_udp_peer1.conf\
 test_quota_compliance_udp_peer2.conf\
 test_quota_compliance_unix_peer1.conf\
 test_quota_compliance_unix_peer2.conf\
+test_quota_compliance_wlan_peer1.conf\
+test_quota_compliance_wlan_peer2.conf\
 test_quota_compliance_http_asymmetric_peer1.conf\
 test_quota_compliance_http_asymmetric_peer2.conf\
 test_quota_compliance_https_asymmetric_peer1.conf\
@@ -906,6 +909,8 @@ test_quota_compliance_tcp_asymmetric_peer1.conf\
 test_quota_compliance_tcp_asymmetric_peer2.conf\
 test_quota_compliance_unix_asymmetric_peer1.conf\
 test_quota_compliance_unix_asymmetric_peer2.conf\
+test_quota_compliance_wlan_asymmetric_peer1.conf\
+test_quota_compliance_wlan_asymmetric_peer2.conf\
 test_transport_api_data.conf\
 test_transport_api_http_peer1.conf\
 test_transport_api_http_peer2.conf\
@@ -929,6 +934,10 @@ test_transport_api_reliability_wlan_peer1.conf\
 test_transport_api_reliability_wlan_peer2.conf\
 test_transport_api_bidirectional_connect_peer1.conf\
 test_transport_api_bidirectional_connect_peer2.conf\
+test_transport_api_manipulation_send_tcp_peer1.conf\
+test_transport_api_manipulation_send_tcp_peer2.conf\
+test_transport_api_manipulation_recv_tcp_peer1.conf\
+test_transport_api_manipulation_recv_tcp_peer2.conf\
 test_transport_api_tcp_nat_peer1.conf\
 test_transport_api_tcp_nat_peer2.conf\
 test_transport_api_tcp_peer1.conf\
@@ -955,18 +964,11 @@ test_transport_defaults.conf\
 test_transport_startonly.conf\
 test_transport_api_disconnect_tcp_peer1.conf\
 test_transport_api_disconnect_tcp_peer2.conf\
-test_transport_api_http_nat_peer1.conf\
-test_transport_api_http_nat_peer2.conf\
-test_transport_api_https_nat_peer1.conf\
-test_transport_api_https_nat_peer2.conf\
-test_transport_api_reliability_http_nat_peer1.conf\
-test_transport_api_reliability_http_nat_peer2.conf\
-test_transport_api_reliability_https_nat_peer1.conf\
-test_transport_api_reliability_https_nat_peer2.conf\
 test_transport_api_timeout_http_peer1.conf\
 test_transport_api_timeout_http_peer2.conf\
 test_transport_api_timeout_https_peer1.conf\
 test_transport_api_timeout_https_peer2.conf\
 test_transport_api_unreliability_constant_udp_peer1.conf\
 test_transport_api_unreliability_constant_udp_peer2.conf\
-test_transport_api_http_reverse_proxy.conf
\ No newline at end of file
+test_transport_api_http_reverse_peer1.conf \
+test_transport_api_http_reverse_peer2.conf