diff options
-rw-r--r-- | TODO | 6 | ||||
-rw-r--r-- | configure.ac | 3 | ||||
-rw-r--r-- | src/Makefile.am | 3 | ||||
-rw-r--r-- | src/vpn/Makefile | 660 | ||||
-rw-r--r-- | src/vpn/packet.h | 14 | ||||
-rw-r--r-- | src/vpn/pretty-print.c | 6 |
6 files changed, 661 insertions, 31 deletions
@@ -111,13 +111,7 @@ | |||
111 | * DATASTORE: | 111 | * DATASTORE: |
112 | - GNUNET_DATASTORE_cancel method not tested | 112 | - GNUNET_DATASTORE_cancel method not tested |
113 | * TESTING: [Nate] | 113 | * TESTING: [Nate] |
114 | - modify configuration to allow controlling connections for non-local starts | ||
115 | - testbed creation with topology (needs working F2F topology) | ||
116 | - testbed with churn | ||
117 | - implement testcases for distributed testing | ||
118 | - test basic peer re-configure | 114 | - test basic peer re-configure |
119 | - test topology creation | ||
120 | - test churn generation | ||
121 | - consider changing API for peer-group termination to | 115 | - consider changing API for peer-group termination to |
122 | call continuation when done | 116 | call continuation when done |
123 | * NAT/UPNP: [MW] | 117 | * NAT/UPNP: [MW] |
diff --git a/configure.ac b/configure.ac index 0abacd253..0f1a7c91d 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -662,6 +662,7 @@ src/hello/Makefile | |||
662 | src/include/Makefile | 662 | src/include/Makefile |
663 | src/include/gnunet_directories.h | 663 | src/include/gnunet_directories.h |
664 | src/hostlist/Makefile | 664 | src/hostlist/Makefile |
665 | src/monkey/Makefile | ||
665 | src/nat/Makefile | 666 | src/nat/Makefile |
666 | src/nat/libnatpmp/Makefile | 667 | src/nat/libnatpmp/Makefile |
667 | src/nat/miniupnp/Makefile | 668 | src/nat/miniupnp/Makefile |
@@ -673,7 +674,7 @@ src/testing/Makefile | |||
673 | src/topology/Makefile | 674 | src/topology/Makefile |
674 | src/transport/Makefile | 675 | src/transport/Makefile |
675 | src/util/Makefile | 676 | src/util/Makefile |
676 | src/monkey/Makefile | 677 | src/vpn/Makefile |
677 | ]) | 678 | ]) |
678 | AC_OUTPUT | 679 | AC_OUTPUT |
679 | 680 | ||
diff --git a/src/Makefile.am b/src/Makefile.am index cdab96621..aa68c8537 100644 --- a/src/Makefile.am +++ b/src/Makefile.am | |||
@@ -30,4 +30,5 @@ SUBDIRS = \ | |||
30 | hostlist \ | 30 | hostlist \ |
31 | topology \ | 31 | topology \ |
32 | $(NAT_DIR) \ | 32 | $(NAT_DIR) \ |
33 | fs | 33 | fs \ |
34 | vpn | ||
diff --git a/src/vpn/Makefile b/src/vpn/Makefile index d2d4342bb..6f34b70d8 100644 --- a/src/vpn/Makefile +++ b/src/vpn/Makefile | |||
@@ -1,22 +1,654 @@ | |||
1 | CFLAGS=-Wall -pedantic --std=c99 -g | 1 | # Makefile.in generated by automake 1.11.1 from Makefile.am. |
2 | CXXFLAGS = ${CFLAGS} | 2 | # src/vpn/Makefile. Generated from Makefile.in by configure. |
3 | 3 | ||
4 | LDFLAGS = | 4 | # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, |
5 | # 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, | ||
6 | # Inc. | ||
7 | # This Makefile.in is free software; the Free Software Foundation | ||
8 | # gives unlimited permission to copy and/or distribute it, | ||
9 | # with or without modifications, as long as this notice is preserved. | ||
5 | 10 | ||
6 | .PHONY: .dependencies | 11 | # This program is distributed in the hope that it will be useful, |
12 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without | ||
13 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A | ||
14 | # PARTICULAR PURPOSE. | ||
7 | 15 | ||
8 | all: default | ||
9 | 16 | ||
10 | default: .dependencies test | ||
11 | 17 | ||
12 | test: test.o tun.o packet.o debug.o pretty-print.o tcp.o | ||
13 | 18 | ||
14 | .dependencies: | 19 | pkgdatadir = $(datadir)/gnunet |
15 | echo > .dependencies | 20 | pkgincludedir = $(includedir)/gnunet |
16 | gcc -M *.c >> .dependencies | 21 | pkglibdir = $(libdir)/gnunet |
22 | pkglibexecdir = $(libexecdir)/gnunet | ||
23 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd | ||
24 | install_sh_DATA = $(install_sh) -c -m 644 | ||
25 | install_sh_PROGRAM = $(install_sh) -c | ||
26 | install_sh_SCRIPT = $(install_sh) -c | ||
27 | INSTALL_HEADER = $(INSTALL_DATA) | ||
28 | transform = $(program_transform_name) | ||
29 | NORMAL_INSTALL = : | ||
30 | PRE_INSTALL = : | ||
31 | POST_INSTALL = : | ||
32 | NORMAL_UNINSTALL = : | ||
33 | PRE_UNINSTALL = : | ||
34 | POST_UNINSTALL = : | ||
35 | build_triplet = x86_64-unknown-linux-gnu | ||
36 | host_triplet = x86_64-unknown-linux-gnu | ||
37 | bin_PROGRAMS = gnunet-daemon-vpn$(EXEEXT) $(am__EXEEXT_1) | ||
38 | subdir = src/vpn | ||
39 | DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in | ||
40 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 | ||
41 | am__aclocal_m4_deps = $(top_srcdir)/m4/align.m4 \ | ||
42 | $(top_srcdir)/m4/argz.m4 $(top_srcdir)/m4/gettext.m4 \ | ||
43 | $(top_srcdir)/m4/iconv.m4 $(top_srcdir)/m4/lib-ld.m4 \ | ||
44 | $(top_srcdir)/m4/lib-link.m4 $(top_srcdir)/m4/lib-prefix.m4 \ | ||
45 | $(top_srcdir)/m4/libcurl.m4 $(top_srcdir)/m4/libgcrypt.m4 \ | ||
46 | $(top_srcdir)/m4/libtool.m4 $(top_srcdir)/m4/ltdl.m4 \ | ||
47 | $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \ | ||
48 | $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \ | ||
49 | $(top_srcdir)/m4/nls.m4 $(top_srcdir)/m4/po.m4 \ | ||
50 | $(top_srcdir)/m4/progtest.m4 $(top_srcdir)/acinclude.m4 \ | ||
51 | $(top_srcdir)/configure.ac | ||
52 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ | ||
53 | $(ACLOCAL_M4) | ||
54 | mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs | ||
55 | CONFIG_HEADER = $(top_builddir)/gnunet_config.h | ||
56 | CONFIG_CLEAN_FILES = | ||
57 | CONFIG_CLEAN_VPATH_FILES = | ||
58 | am__EXEEXT_1 = gnunet-vpn-helper$(EXEEXT) | ||
59 | am__installdirs = "$(DESTDIR)$(bindir)" | ||
60 | PROGRAMS = $(bin_PROGRAMS) | ||
61 | am_gnunet_daemon_vpn_OBJECTS = gnunet-daemon-vpn.$(OBJEXT) | ||
62 | gnunet_daemon_vpn_OBJECTS = $(am_gnunet_daemon_vpn_OBJECTS) | ||
63 | am__DEPENDENCIES_1 = | ||
64 | gnunet_daemon_vpn_DEPENDENCIES = \ | ||
65 | $(top_builddir)/src/core/libgnunetcore.la \ | ||
66 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | ||
67 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
68 | $(am__DEPENDENCIES_1) | ||
69 | am_gnunet_vpn_helper_OBJECTS = debug.$(OBJEXT) packet.$(OBJEXT) \ | ||
70 | pretty-print.$(OBJEXT) tcp.$(OBJEXT) test.$(OBJEXT) \ | ||
71 | tun.$(OBJEXT) | ||
72 | gnunet_vpn_helper_OBJECTS = $(am_gnunet_vpn_helper_OBJECTS) | ||
73 | gnunet_vpn_helper_LDADD = $(LDADD) | ||
74 | DEFAULT_INCLUDES = -I. -I$(top_builddir) | ||
75 | depcomp = $(SHELL) $(top_srcdir)/depcomp | ||
76 | am__depfiles_maybe = depfiles | ||
77 | am__mv = mv -f | ||
78 | COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ | ||
79 | $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) | ||
80 | LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ | ||
81 | --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \ | ||
82 | $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) | ||
83 | CCLD = $(CC) | ||
84 | LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \ | ||
85 | --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \ | ||
86 | $(LDFLAGS) -o $@ | ||
87 | SOURCES = $(gnunet_daemon_vpn_SOURCES) $(gnunet_vpn_helper_SOURCES) | ||
88 | DIST_SOURCES = $(gnunet_daemon_vpn_SOURCES) \ | ||
89 | $(gnunet_vpn_helper_SOURCES) | ||
90 | ETAGS = etags | ||
91 | CTAGS = ctags | ||
92 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) | ||
93 | ACLOCAL = ${SHELL} /home/grothoff/svn/gnunet/missing --run aclocal-1.11 | ||
94 | AMTAR = ${SHELL} /home/grothoff/svn/gnunet/missing --run tar | ||
95 | AR = ar | ||
96 | ARGZ_H = | ||
97 | AS = as | ||
98 | AUTOCONF = ${SHELL} /home/grothoff/svn/gnunet/missing --run autoconf | ||
99 | AUTOHEADER = ${SHELL} /home/grothoff/svn/gnunet/missing --run autoheader | ||
100 | AUTOMAKE = ${SHELL} /home/grothoff/svn/gnunet/missing --run automake-1.11 | ||
101 | AWK = gawk | ||
102 | CC = gcc | ||
103 | CCDEPMODE = depmode=gcc3 | ||
104 | CFLAGS = -fno-strict-aliasing -Wall -g -O0 -Wall -Werror | ||
105 | CPP = gcc -E | ||
106 | CPPFLAGS = -I/home/grothoff/gn9//include | ||
107 | CXX = g++ | ||
108 | CXXCPP = g++ -E | ||
109 | CXXDEPMODE = depmode=gcc3 | ||
110 | CXXFLAGS = -g -O0 -Wall -Werror | ||
111 | CYGPATH_W = echo | ||
112 | DEFAULT_INTERFACE = "eth0" | ||
113 | DEFS = -DHAVE_CONFIG_H | ||
114 | DEPDIR = .deps | ||
115 | DLLDIR = lib | ||
116 | DLLTOOL = dlltool | ||
117 | DSYMUTIL = | ||
118 | DUMPBIN = | ||
119 | ECHO_C = | ||
120 | ECHO_N = -n | ||
121 | ECHO_T = | ||
122 | EGREP = /bin/grep -E | ||
123 | EXEEXT = | ||
124 | EXT_LIBS = | ||
125 | EXT_LIB_PATH = -L/home/grothoff/gn9//lib | ||
126 | FGREP = /bin/grep -F | ||
127 | GMSGFMT = /usr/bin/msgfmt | ||
128 | GMSGFMT_015 = /usr/bin/msgfmt | ||
129 | GN_DAEMON_CONFIG_DIR = /etc | ||
130 | GN_DAEMON_HOME_DIR = /var/lib/gnunet | ||
131 | GN_INTLINCL = | ||
132 | GN_LIBINTL = | ||
133 | GN_LIB_LDFLAGS = -export-dynamic -no-undefined | ||
134 | GN_PLUGIN_LDFLAGS = -export-dynamic -avoid-version -module -no-undefined | ||
135 | GN_USER_HOME_DIR = ~/.gnunet | ||
136 | GREP = /bin/grep | ||
137 | INCLTDL = | ||
138 | INSTALL = /usr/bin/install -c | ||
139 | INSTALL_DATA = ${INSTALL} -m 644 | ||
140 | INSTALL_PROGRAM = ${INSTALL} | ||
141 | INSTALL_SCRIPT = ${INSTALL} | ||
142 | INSTALL_STRIP_PROGRAM = $(install_sh) -c -s | ||
143 | INTLLIBS = | ||
144 | INTL_MACOSX_LIBS = | ||
145 | LD = /usr/bin/ld -m elf_x86_64 | ||
146 | LDFLAGS = -L/home/grothoff/gn9//lib | ||
147 | LIBADD_DL = -ldl | ||
148 | LIBADD_DLD_LINK = | ||
149 | LIBADD_DLOPEN = -ldl | ||
150 | LIBADD_SHL_LOAD = | ||
151 | LIBCURL = -lcurl | ||
152 | LIBCURL_CPPFLAGS = | ||
153 | LIBGCRYPT_CFLAGS = | ||
154 | LIBGCRYPT_CONFIG = /usr/bin/libgcrypt-config | ||
155 | LIBGCRYPT_LIBS = -lgcrypt | ||
156 | LIBICONV = | ||
157 | LIBINTL = | ||
158 | LIBLTDL = -lltdl | ||
159 | LIBOBJS = | ||
160 | LIBPREFIX = | ||
161 | LIBS = -ldl | ||
162 | LIBTOOL = $(SHELL) $(top_builddir)/libtool | ||
163 | LIPO = | ||
164 | LN_S = ln -s | ||
165 | LTDLDEPS = | ||
166 | LTDLINCL = | ||
167 | LTDLOPEN = libltdl | ||
168 | LTLIBICONV = | ||
169 | LTLIBINTL = | ||
170 | LTLIBOBJS = | ||
171 | LT_CONFIG_H = gnunet_config.h | ||
172 | LT_DLLOADERS = libltdl/dlopen.la | ||
173 | LT_DLPREOPEN = -dlpreopen libltdl/dlopen.la | ||
174 | MAKEINFO = ${SHELL} /home/grothoff/svn/gnunet/missing --run makeinfo | ||
175 | MKDIR_P = /bin/mkdir -p | ||
176 | MSGFMT = /usr/bin/msgfmt | ||
177 | MSGFMT_015 = /usr/bin/msgfmt | ||
178 | MSGMERGE = /usr/bin/msgmerge | ||
179 | MYSQL_CPPFLAGS = | ||
180 | MYSQL_LDFLAGS = | ||
181 | NM = /usr/bin/nm -B | ||
182 | NMEDIT = | ||
183 | OBJC = gcc | ||
184 | OBJCDEPMODE = depmode=gcc3 | ||
185 | OBJCFLAGS = | ||
186 | OBJDUMP = objdump | ||
187 | OBJEXT = o | ||
188 | OTOOL = | ||
189 | OTOOL64 = | ||
190 | PACKAGE = gnunet | ||
191 | PACKAGE_BUGREPORT = bug-gnunet@gnu.org | ||
192 | PACKAGE_NAME = gnunet | ||
193 | PACKAGE_STRING = gnunet 0.9.0pre0 | ||
194 | PACKAGE_TARNAME = gnunet | ||
195 | PACKAGE_URL = | ||
196 | PACKAGE_VERSION = 0.9.0pre0 | ||
197 | PATH_SEPARATOR = : | ||
198 | POSTGRES_CPPFLAGS = | ||
199 | POSTGRES_LDFLAGS = | ||
200 | POSUB = po | ||
201 | PYTHON = /usr/bin/python | ||
202 | PYTHON_EXEC_PREFIX = ${exec_prefix} | ||
203 | PYTHON_PLATFORM = linux2 | ||
204 | PYTHON_PREFIX = ${prefix} | ||
205 | PYTHON_VERSION = 2.5 | ||
206 | RANLIB = ranlib | ||
207 | SED = /bin/sed | ||
208 | SET_MAKE = | ||
209 | SHELL = /bin/bash | ||
210 | SQLITE_CPPFLAGS = | ||
211 | SQLITE_LDFLAGS = | ||
212 | STRIP = strip | ||
213 | USE_NLS = yes | ||
214 | VERSION = 0.9.0pre0 | ||
215 | XGETTEXT = /usr/bin/xgettext | ||
216 | XGETTEXT_015 = /usr/bin/xgettext | ||
217 | XMKMF = | ||
218 | X_CFLAGS = | ||
219 | X_EXTRA_LIBS = | ||
220 | X_LIBS = | ||
221 | X_PRE_LIBS = -lSM -lICE | ||
222 | _libcurl_config = | ||
223 | abs_builddir = /home/grothoff/svn/gnunet/src/vpn | ||
224 | abs_srcdir = /home/grothoff/svn/gnunet/src/vpn | ||
225 | abs_top_builddir = /home/grothoff/svn/gnunet | ||
226 | abs_top_srcdir = /home/grothoff/svn/gnunet | ||
227 | ac_ct_CC = gcc | ||
228 | ac_ct_CXX = g++ | ||
229 | ac_ct_DUMPBIN = | ||
230 | ac_ct_OBJC = gcc | ||
231 | am__include = include | ||
232 | am__leading_dot = . | ||
233 | am__quote = | ||
234 | am__tar = ${AMTAR} chof - "$$tardir" | ||
235 | am__untar = ${AMTAR} xf - | ||
236 | bindir = ${exec_prefix}/bin | ||
237 | build = x86_64-unknown-linux-gnu | ||
238 | build_alias = | ||
239 | build_cpu = x86_64 | ||
240 | build_os = linux-gnu | ||
241 | build_target = linux | ||
242 | build_vendor = unknown | ||
243 | builddir = . | ||
244 | datadir = ${datarootdir} | ||
245 | datarootdir = ${prefix}/share | ||
246 | docdir = ${datarootdir}/doc/${PACKAGE_TARNAME} | ||
247 | dvidir = ${docdir} | ||
248 | exec_prefix = ${prefix} | ||
249 | host = x86_64-unknown-linux-gnu | ||
250 | host_alias = | ||
251 | host_cpu = x86_64 | ||
252 | host_os = linux-gnu | ||
253 | host_vendor = unknown | ||
254 | htmldir = ${docdir} | ||
255 | includedir = ${prefix}/include | ||
256 | infodir = ${datarootdir}/info | ||
257 | install_sh = ${SHELL} /home/grothoff/svn/gnunet/install-sh | ||
258 | libdir = ${exec_prefix}/lib | ||
259 | libexecdir = ${exec_prefix}/libexec | ||
260 | localedir = ${datarootdir}/locale | ||
261 | localstatedir = ${prefix}/var | ||
262 | lt_ECHO = echo | ||
263 | ltdl_LIBOBJS = lt__strl.o | ||
264 | ltdl_LTLIBOBJS = lt__strl.lo | ||
265 | mandir = ${datarootdir}/man | ||
266 | mkdir_p = /bin/mkdir -p | ||
267 | oldincludedir = /usr/include | ||
268 | pdfdir = ${docdir} | ||
269 | pkgpyexecdir = ${pyexecdir}/gnunet | ||
270 | pkgpythondir = ${pythondir}/gnunet | ||
271 | prefix = /home/grothoff/gn9 | ||
272 | program_transform_name = s,x,x, | ||
273 | psdir = ${docdir} | ||
274 | pyexecdir = ${exec_prefix}/lib/python2.5/site-packages | ||
275 | pythondir = ${prefix}/lib/python2.5/site-packages | ||
276 | sbindir = ${exec_prefix}/sbin | ||
277 | sharedstatedir = ${prefix}/com | ||
278 | srcdir = . | ||
279 | subdirs = libltdl | ||
280 | sys_symbol_underscore = no | ||
281 | sysconfdir = ${prefix}/etc | ||
282 | target_alias = | ||
283 | top_build_prefix = ../../ | ||
284 | top_builddir = ../.. | ||
285 | top_srcdir = ../.. | ||
286 | INCLUDES = -I$(top_srcdir)/src/include | ||
287 | #WINFLAGS = -Wl,--no-undefined -Wl,--export-all-symbols | ||
288 | #AM_CFLAGS = --coverage -O0 | ||
289 | VPNBIN = gnunet-vpn-helper | ||
290 | gnunet_vpn_helper_SOURCES = \ | ||
291 | debug.c debug.h \ | ||
292 | packet.h packet.c \ | ||
293 | pretty-print.c pretty-print.h \ | ||
294 | tcp.c tcp.h \ | ||
295 | test.c \ | ||
296 | tun.c tun.h | ||
17 | 297 | ||
18 | -include .dependencies | 298 | gnunet_daemon_vpn_SOURCES = \ |
299 | gnunet-daemon-vpn.c | ||
19 | 300 | ||
20 | clean: | 301 | gnunet_daemon_vpn_LDADD = \ |
21 | rm -f *.o | 302 | $(top_builddir)/src/core/libgnunetcore.la \ |
22 | rm -f test | 303 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
304 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
305 | $(GN_LIBINTL) | ||
306 | |||
307 | all: all-am | ||
308 | |||
309 | .SUFFIXES: | ||
310 | .SUFFIXES: .c .lo .o .obj | ||
311 | $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) | ||
312 | @for dep in $?; do \ | ||
313 | case '$(am__configure_deps)' in \ | ||
314 | *$$dep*) \ | ||
315 | ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ | ||
316 | && { if test -f $@; then exit 0; else break; fi; }; \ | ||
317 | exit 1;; \ | ||
318 | esac; \ | ||
319 | done; \ | ||
320 | echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/vpn/Makefile'; \ | ||
321 | $(am__cd) $(top_srcdir) && \ | ||
322 | $(AUTOMAKE) --gnu src/vpn/Makefile | ||
323 | .PRECIOUS: Makefile | ||
324 | Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status | ||
325 | @case '$?' in \ | ||
326 | *config.status*) \ | ||
327 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ | ||
328 | *) \ | ||
329 | echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ | ||
330 | cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ | ||
331 | esac; | ||
332 | |||
333 | $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) | ||
334 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh | ||
335 | |||
336 | $(top_srcdir)/configure: $(am__configure_deps) | ||
337 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh | ||
338 | $(ACLOCAL_M4): $(am__aclocal_m4_deps) | ||
339 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh | ||
340 | $(am__aclocal_m4_deps): | ||
341 | install-binPROGRAMS: $(bin_PROGRAMS) | ||
342 | @$(NORMAL_INSTALL) | ||
343 | test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" | ||
344 | @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ | ||
345 | for p in $$list; do echo "$$p $$p"; done | \ | ||
346 | sed 's/$(EXEEXT)$$//' | \ | ||
347 | while read p p1; do if test -f $$p || test -f $$p1; \ | ||
348 | then echo "$$p"; echo "$$p"; else :; fi; \ | ||
349 | done | \ | ||
350 | sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ | ||
351 | -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ | ||
352 | sed 'N;N;N;s,\n, ,g' | \ | ||
353 | $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ | ||
354 | { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ | ||
355 | if ($$2 == $$4) files[d] = files[d] " " $$1; \ | ||
356 | else { print "f", $$3 "/" $$4, $$1; } } \ | ||
357 | END { for (d in files) print "f", d, files[d] }' | \ | ||
358 | while read type dir files; do \ | ||
359 | if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ | ||
360 | test -z "$$files" || { \ | ||
361 | echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ | ||
362 | $(INSTALL_PROGRAM_ENV) $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ | ||
363 | } \ | ||
364 | ; done | ||
365 | |||
366 | uninstall-binPROGRAMS: | ||
367 | @$(NORMAL_UNINSTALL) | ||
368 | @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ | ||
369 | files=`for p in $$list; do echo "$$p"; done | \ | ||
370 | sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ | ||
371 | -e 's/$$/$(EXEEXT)/' `; \ | ||
372 | test -n "$$list" || exit 0; \ | ||
373 | echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ | ||
374 | cd "$(DESTDIR)$(bindir)" && rm -f $$files | ||
375 | |||
376 | clean-binPROGRAMS: | ||
377 | @list='$(bin_PROGRAMS)'; test -n "$$list" || exit 0; \ | ||
378 | echo " rm -f" $$list; \ | ||
379 | rm -f $$list || exit $$?; \ | ||
380 | test -n "$(EXEEXT)" || exit 0; \ | ||
381 | list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \ | ||
382 | echo " rm -f" $$list; \ | ||
383 | rm -f $$list | ||
384 | gnunet-daemon-vpn$(EXEEXT): $(gnunet_daemon_vpn_OBJECTS) $(gnunet_daemon_vpn_DEPENDENCIES) | ||
385 | @rm -f gnunet-daemon-vpn$(EXEEXT) | ||
386 | $(LINK) $(gnunet_daemon_vpn_OBJECTS) $(gnunet_daemon_vpn_LDADD) $(LIBS) | ||
387 | gnunet-vpn-helper$(EXEEXT): $(gnunet_vpn_helper_OBJECTS) $(gnunet_vpn_helper_DEPENDENCIES) | ||
388 | @rm -f gnunet-vpn-helper$(EXEEXT) | ||
389 | $(LINK) $(gnunet_vpn_helper_OBJECTS) $(gnunet_vpn_helper_LDADD) $(LIBS) | ||
390 | |||
391 | mostlyclean-compile: | ||
392 | -rm -f *.$(OBJEXT) | ||
393 | |||
394 | distclean-compile: | ||
395 | -rm -f *.tab.c | ||
396 | |||
397 | include ./$(DEPDIR)/debug.Po | ||
398 | include ./$(DEPDIR)/gnunet-daemon-vpn.Po | ||
399 | include ./$(DEPDIR)/packet.Po | ||
400 | include ./$(DEPDIR)/pretty-print.Po | ||
401 | include ./$(DEPDIR)/tcp.Po | ||
402 | include ./$(DEPDIR)/test.Po | ||
403 | include ./$(DEPDIR)/tun.Po | ||
404 | |||
405 | .c.o: | ||
406 | $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< | ||
407 | $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po | ||
408 | # source='$<' object='$@' libtool=no \ | ||
409 | # DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \ | ||
410 | # $(COMPILE) -c $< | ||
411 | |||
412 | .c.obj: | ||
413 | $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` | ||
414 | $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po | ||
415 | # source='$<' object='$@' libtool=no \ | ||
416 | # DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \ | ||
417 | # $(COMPILE) -c `$(CYGPATH_W) '$<'` | ||
418 | |||
419 | .c.lo: | ||
420 | $(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< | ||
421 | $(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo | ||
422 | # source='$<' object='$@' libtool=yes \ | ||
423 | # DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \ | ||
424 | # $(LTCOMPILE) -c -o $@ $< | ||
425 | |||
426 | mostlyclean-libtool: | ||
427 | -rm -f *.lo | ||
428 | |||
429 | clean-libtool: | ||
430 | -rm -rf .libs _libs | ||
431 | |||
432 | ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) | ||
433 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ | ||
434 | unique=`for i in $$list; do \ | ||
435 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ | ||
436 | done | \ | ||
437 | $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ | ||
438 | END { if (nonempty) { for (i in files) print i; }; }'`; \ | ||
439 | mkid -fID $$unique | ||
440 | tags: TAGS | ||
441 | |||
442 | TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ | ||
443 | $(TAGS_FILES) $(LISP) | ||
444 | set x; \ | ||
445 | here=`pwd`; \ | ||
446 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ | ||
447 | unique=`for i in $$list; do \ | ||
448 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ | ||
449 | done | \ | ||
450 | $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ | ||
451 | END { if (nonempty) { for (i in files) print i; }; }'`; \ | ||
452 | shift; \ | ||
453 | if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ | ||
454 | test -n "$$unique" || unique=$$empty_fix; \ | ||
455 | if test $$# -gt 0; then \ | ||
456 | $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ | ||
457 | "$$@" $$unique; \ | ||
458 | else \ | ||
459 | $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ | ||
460 | $$unique; \ | ||
461 | fi; \ | ||
462 | fi | ||
463 | ctags: CTAGS | ||
464 | CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ | ||
465 | $(TAGS_FILES) $(LISP) | ||
466 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ | ||
467 | unique=`for i in $$list; do \ | ||
468 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ | ||
469 | done | \ | ||
470 | $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ | ||
471 | END { if (nonempty) { for (i in files) print i; }; }'`; \ | ||
472 | test -z "$(CTAGS_ARGS)$$unique" \ | ||
473 | || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ | ||
474 | $$unique | ||
475 | |||
476 | GTAGS: | ||
477 | here=`$(am__cd) $(top_builddir) && pwd` \ | ||
478 | && $(am__cd) $(top_srcdir) \ | ||
479 | && gtags -i $(GTAGS_ARGS) "$$here" | ||
480 | |||
481 | distclean-tags: | ||
482 | -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags | ||
483 | |||
484 | distdir: $(DISTFILES) | ||
485 | @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ | ||
486 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ | ||
487 | list='$(DISTFILES)'; \ | ||
488 | dist_files=`for file in $$list; do echo $$file; done | \ | ||
489 | sed -e "s|^$$srcdirstrip/||;t" \ | ||
490 | -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ | ||
491 | case $$dist_files in \ | ||
492 | */*) $(MKDIR_P) `echo "$$dist_files" | \ | ||
493 | sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ | ||
494 | sort -u` ;; \ | ||
495 | esac; \ | ||
496 | for file in $$dist_files; do \ | ||
497 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ | ||
498 | if test -d $$d/$$file; then \ | ||
499 | dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ | ||
500 | if test -d "$(distdir)/$$file"; then \ | ||
501 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ | ||
502 | fi; \ | ||
503 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ | ||
504 | cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ | ||
505 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ | ||
506 | fi; \ | ||
507 | cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ | ||
508 | else \ | ||
509 | test -f "$(distdir)/$$file" \ | ||
510 | || cp -p $$d/$$file "$(distdir)/$$file" \ | ||
511 | || exit 1; \ | ||
512 | fi; \ | ||
513 | done | ||
514 | check-am: all-am | ||
515 | check: check-am | ||
516 | all-am: Makefile $(PROGRAMS) | ||
517 | installdirs: | ||
518 | for dir in "$(DESTDIR)$(bindir)"; do \ | ||
519 | test -z "$$dir" || $(MKDIR_P) "$$dir"; \ | ||
520 | done | ||
521 | install: install-am | ||
522 | install-exec: install-exec-am | ||
523 | install-data: install-data-am | ||
524 | uninstall: uninstall-am | ||
525 | |||
526 | install-am: all-am | ||
527 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am | ||
528 | |||
529 | installcheck: installcheck-am | ||
530 | install-strip: | ||
531 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ | ||
532 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ | ||
533 | `test -z '$(STRIP)' || \ | ||
534 | echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install | ||
535 | mostlyclean-generic: | ||
536 | |||
537 | clean-generic: | ||
538 | |||
539 | distclean-generic: | ||
540 | -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) | ||
541 | -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) | ||
542 | |||
543 | maintainer-clean-generic: | ||
544 | @echo "This command is intended for maintainers to use" | ||
545 | @echo "it deletes files that may require special tools to rebuild." | ||
546 | clean: clean-am | ||
547 | |||
548 | clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am | ||
549 | |||
550 | distclean: distclean-am | ||
551 | -rm -rf ./$(DEPDIR) | ||
552 | -rm -f Makefile | ||
553 | distclean-am: clean-am distclean-compile distclean-generic \ | ||
554 | distclean-tags | ||
555 | |||
556 | dvi: dvi-am | ||
557 | |||
558 | dvi-am: | ||
559 | |||
560 | html: html-am | ||
561 | |||
562 | html-am: | ||
563 | |||
564 | info: info-am | ||
565 | |||
566 | info-am: | ||
567 | |||
568 | install-data-am: | ||
569 | |||
570 | install-dvi: install-dvi-am | ||
571 | |||
572 | install-dvi-am: | ||
573 | |||
574 | install-exec-am: install-binPROGRAMS | ||
575 | @$(NORMAL_INSTALL) | ||
576 | $(MAKE) $(AM_MAKEFLAGS) install-exec-hook | ||
577 | install-html: install-html-am | ||
578 | |||
579 | install-html-am: | ||
580 | |||
581 | install-info: install-info-am | ||
582 | |||
583 | install-info-am: | ||
584 | |||
585 | install-man: | ||
586 | |||
587 | install-pdf: install-pdf-am | ||
588 | |||
589 | install-pdf-am: | ||
590 | |||
591 | install-ps: install-ps-am | ||
592 | |||
593 | install-ps-am: | ||
594 | |||
595 | installcheck-am: | ||
596 | |||
597 | maintainer-clean: maintainer-clean-am | ||
598 | -rm -rf ./$(DEPDIR) | ||
599 | -rm -f Makefile | ||
600 | maintainer-clean-am: distclean-am maintainer-clean-generic | ||
601 | |||
602 | mostlyclean: mostlyclean-am | ||
603 | |||
604 | mostlyclean-am: mostlyclean-compile mostlyclean-generic \ | ||
605 | mostlyclean-libtool | ||
606 | |||
607 | pdf: pdf-am | ||
608 | |||
609 | pdf-am: | ||
610 | |||
611 | ps: ps-am | ||
612 | |||
613 | ps-am: | ||
614 | |||
615 | uninstall-am: uninstall-binPROGRAMS | ||
616 | |||
617 | .MAKE: install-am install-exec-am install-strip | ||
618 | |||
619 | .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ | ||
620 | clean-generic clean-libtool ctags distclean distclean-compile \ | ||
621 | distclean-generic distclean-libtool distclean-tags distdir dvi \ | ||
622 | dvi-am html html-am info info-am install install-am \ | ||
623 | install-binPROGRAMS install-data install-data-am install-dvi \ | ||
624 | install-dvi-am install-exec install-exec-am install-exec-hook \ | ||
625 | install-html install-html-am install-info install-info-am \ | ||
626 | install-man install-pdf install-pdf-am install-ps \ | ||
627 | install-ps-am install-strip installcheck installcheck-am \ | ||
628 | installdirs maintainer-clean maintainer-clean-generic \ | ||
629 | mostlyclean mostlyclean-compile mostlyclean-generic \ | ||
630 | mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \ | ||
631 | uninstall-am uninstall-binPROGRAMS | ||
632 | |||
633 | install-exec-hook: | ||
634 | chown root $(bindir)/gnunet-vpn-helper || true | ||
635 | chmod u+s $(bindir)/gnunet-vpn-helper || true | ||
636 | #install-exec-hook: | ||
637 | |||
638 | #check_PROGRAMS = \ | ||
639 | # test_XXX | ||
640 | |||
641 | #TESTS = \ | ||
642 | # test_transport_api_tcp | ||
643 | |||
644 | #test_transport_api_tcp_SOURCES = \ | ||
645 | # test_transport_api.c | ||
646 | #test_transport_api_tcp_LDADD = \ | ||
647 | # $(top_builddir)/src/transport/libgnunettransport.la \ | ||
648 | # $(top_builddir)/src/util/libgnunetutil.la | ||
649 | |||
650 | #EXTRA_DIST = test_transport_api_data.conf | ||
651 | |||
652 | # Tell versions [3.59,3.63) of GNU make to not export all variables. | ||
653 | # Otherwise a system limit (for SysV at least) may be exceeded. | ||
654 | .NOEXPORT: | ||
diff --git a/src/vpn/packet.h b/src/vpn/packet.h index ac7cfcf51..ccf3cb7fc 100644 --- a/src/vpn/packet.h +++ b/src/vpn/packet.h | |||
@@ -79,14 +79,14 @@ struct ip6_udp { | |||
79 | struct udp_pkt data; | 79 | struct udp_pkt data; |
80 | }; | 80 | }; |
81 | 81 | ||
82 | extern void send_pkt(int fd, struct ip6_pkt* pkt); | 82 | void send_pkt(int fd, struct ip6_pkt* pkt); |
83 | extern int recv_ipv6pkt(int fd, struct pkt_tun** pkt); | 83 | int recv_ipv6pkt(int fd, struct pkt_tun** pkt); |
84 | extern int recv_pkt(int fd, struct pkt_tun** pkt); | 84 | int recv_pkt(int fd, struct pkt_tun** pkt); |
85 | extern struct ip6_pkt* parse_ip6(struct pkt_tun* pkt); | 85 | struct ip6_pkt* parse_ip6(struct pkt_tun* pkt); |
86 | 86 | ||
87 | extern struct ip6_tcp* parse_ip6_tcp(struct ip6_pkt*); | 87 | struct ip6_tcp* parse_ip6_tcp(struct ip6_pkt*); |
88 | extern struct ip6_udp* parse_ip6_udp(struct ip6_pkt*); | 88 | struct ip6_udp* parse_ip6_udp(struct ip6_pkt*); |
89 | 89 | ||
90 | extern short payload(struct ip6_hdr* pkt); | 90 | short payload(struct ip6_hdr* pkt); |
91 | 91 | ||
92 | #endif | 92 | #endif |
diff --git a/src/vpn/pretty-print.c b/src/vpn/pretty-print.c index e8f15cad6..0a80beecd 100644 --- a/src/vpn/pretty-print.c +++ b/src/vpn/pretty-print.c | |||
@@ -75,11 +75,12 @@ static void pp_ip6adr(unsigned char* adr, char* dest) {{{ | |||
75 | }}} | 75 | }}} |
76 | 76 | ||
77 | void pp_hexdump(unsigned char* data, char* dest, int max) {{{ | 77 | void pp_hexdump(unsigned char* data, char* dest, int max) {{{ |
78 | int i; | ||
78 | char tmp[3]; | 79 | char tmp[3]; |
79 | char tmp2[2]; | 80 | char tmp2[2]; |
80 | int off = 0; | 81 | int off = 0; |
81 | int to = max > 16 ? 16 : max; | 82 | int to = max > 16 ? 16 : max; |
82 | for (int i = 0; i < to; i++) { | 83 | for (i = 0; i < to; i++) { |
83 | if (i == 8) off = 1; | 84 | if (i == 8) off = 1; |
84 | sprintf(tmp, "%02x", data[i]); | 85 | sprintf(tmp, "%02x", data[i]); |
85 | memcpy(dest+(3*i)+off, tmp, 2); | 86 | memcpy(dest+(3*i)+off, tmp, 2); |
@@ -138,7 +139,8 @@ void pkt_printf(struct ip6_pkt* pkt) {{{ | |||
138 | memcpy(buf+323, tmp, 3); | 139 | memcpy(buf+323, tmp, 3); |
139 | 140 | ||
140 | int size = payload(&pkt->hdr); | 141 | int size = payload(&pkt->hdr); |
141 | for(int i = 0; i < 8; i++) { | 142 | int i; |
143 | for(i = 0; i < 8; i++) { | ||
142 | if (16*i > size) break; | 144 | if (16*i > size) break; |
143 | pp_hexdump(pkt->data + (16*i), buf + 420 + (i*70), size - 16*i); | 145 | pp_hexdump(pkt->data + (16*i), buf + 420 + (i*70), size - 16*i); |
144 | } | 146 | } |