Coder Social home page Coder Social logo

libparistraceroute / libparistraceroute Goto Github PK

View Code? Open in Web Editor NEW
96.0 96.0 31.0 2.29 MB

libparistraceroute is a library written in C dedicated to active network measurements. Some example are also provided, such as paris-ping and the new implementation of paris-traceroute.

License: GNU Lesser General Public License v3.0

Makefile 1.98% Shell 0.14% M4 1.25% C 95.69% C++ 0.28% Python 0.66%

libparistraceroute's Introduction

libparistraceroute

libparistraceroute is a library written in C dedicated to active network measurements. Some example are also provided, such as paris-ping and the new implementation of paris-traceroute.

Installation

Installation steps are detailed here:

https://github.com/libparistraceroute/libparistraceroute/wiki/Installation

We recommend that you use the installation with git to use the last version of libparistraceroute.

Documentation

For further details about libparistraceroute, we refer the reader to the wiki:

https://github.com/libparistraceroute/libparistraceroute/wiki/

libparistraceroute's People

Contributors

akram17 avatar drt24 avatar ibgp2 avatar jordanauge avatar kvermeul avatar nescio007 avatar rlenglet avatar sawassermann avatar tdelacour avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

libparistraceroute's Issues

Cannot create libparistraceroute loopUnknown error: Permission denied on WSL

root@DUB-LAP-128:~# whoami
root
root@DUB-LAP-128:~# paris-traceroute 8.8.8.8
Cannot create a raw socket (are you root?): Permission denied
E: Cannot create libparistraceroute loopUnknown error: Permission denied
root@DUB-LAP-128:~# uname -a
Linux DUB-LAP-128 4.4.0-18362-Microsoft #476-Microsoft Fri Nov 01 16:53:00 PST 2019 x86_64 x86_64 x86_64 GNU/Linux

Bounds error whois.c BUFFER_SIZE

whois.c:88:25: error: writing 1 byte into a region of size 0 [-Werror=stringop-overflow=]
   88 |     buffer[BUFFER_SIZE] = '\0';
      |     ~~~~~~~~~~~~~~~~~~~~^~~~~~
whois.c:77:12: note: at offset 1000 to an object with size 1000 declared here
   77 |     char   buffer[BUFFER_SIZE];
      |            ^~~~~~

Enclosed is my proposal to fix it.

0000-whois.c-BUFFER_SIZE-overflow.patch.zip

Please make a release

I'd like to update the Debian package.

Please tag a release that I can base the new Debian package on.

The current version in Debian is 0.92-dev so the version number of your release should be higher than that.

Reading off the end of a buffer in probe_wrap_packet

Running paris-traceroute under valgrind I got:

==13399== Invalid read of size 1
==13399==    at 0x4E549B0: tcp_get_header_size (tcp.c:107)
==13399==    by 0x4E52D2C: probe_wrap_packet (probe.c:502)
==13399==    by 0x4E4F4DC: network_process_recvq (network.c:667)
==13399==    by 0x4E557B7: pt_loop (pt_loop.c:337)
==13399==    by 0x401E7C: main (paris-traceroute.c:451)
==13399==  Address 0x5744c0c is 4 bytes after a block of size 56 alloc'd
==13399==    at 0x4C2FB55: calloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==13399==    by 0x4E4B66C: buffer_resize (buffer.c:61)
==13399==    by 0x4E4B6DA: buffer_write_bytes (buffer.c:81)
==13399==    by 0x4E519A6: packet_create_from_bytes (packet.c:40)
==13399==    by 0x4E55FCD: sniffer_process_packets (sniffer.c:357)
==13399==    by 0x4E5582C: pt_loop (pt_loop.c:345)
==13399==    by 0x401E7C: main (paris-traceroute.c:451)

I think that this is occurring because libparistraceroute is not verifying that there is enough space left in the packet for the whole TCP header before reading data out from the header. Hence truncated packets can cause the reading of uninitialised memory. This is problematic and possibly means that it is possible to exploit libparistraceroute by returning invalid packets (I can't see any obvious problems of that nature though).

I think that the fix for this particular problem in probe_wrap_packet would be to add a check at the beginning of the for loop before segment_size = protocol->get_header_size(segment); that checks that remaining_size is big enough for protocol->get_header_size to operate safely. possibly protocol->write_default_header(NULL) could be used for that as, at least in the case of TCP, that returns the minimal header size which is what we need.
However, I may have fundamentally misunderstood something.

Consider fixing some warnings with GCC 12 while `-Werror` is on by default.

When compiling with GCC 12, the following warnings are generated:

algorithms/mda/interface.c:185:44: warning: argument 1 of type 'const mda_interface_t *[2]' with mismatched bound [-Warray-parameter=]
  185 | void mda_link_dump(const mda_interface_t * link[2], bool do_resolv)
      |                    ~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
In file included from algorithms/mda/interface.c:1:
algorithms/mda/interface.h:114:45: note: previously declared as 'const mda_interface_t **'
  114 | void mda_link_dump(const mda_interface_t ** link, bool do_resolv);
      |                    ~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
whois.c: In function 'whois_query':
whois.c:94:25: warning: writing 1 byte into a region of size 0 [-Wstringop-overflow=]
   94 |     buffer[BUFFER_SIZE] = '\0';
      |     ~~~~~~~~~~~~~~~~~~~~^~~~~~
whois.c:79:12: note: at offset 1000 into destination object 'buffer' of size 1000
   79 |     char   buffer[BUFFER_SIZE];
      |            ^~~~~~

Failed to build: `error: argument 1 of type 'const mda_interface_t *[2]' with mismatched bound [-Werror=array-parameter=] 185 | void mda_link_dump(const mda_interface_t * link[2], bool do_resolv)`

$ mkdir m4
$ ./autogen.sh 
libtoolize: putting auxiliary files in '.'.
libtoolize: copying file './ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
configure.ac:28: installing './compile'
configure.ac:93: installing './config.guess'
configure.ac:93: installing './config.sub'
configure.ac:26: installing './install-sh'
configure.ac:26: installing './missing'
libparistraceroute/Makefile.am: installing './depcomp'
configure.ac:28: warning: The macro `AC_GNU_SOURCE' is obsolete.
configure.ac:28: You should run autoupdate.
./lib/autoconf/specific.m4:312: AC_GNU_SOURCE is expanded from...
configure.ac:28: the top level
configure.ac:33: warning: The macro `AC_CONFIG_HEADER' is obsolete.
configure.ac:33: You should run autoupdate.
./lib/autoconf/status.m4:719: AC_CONFIG_HEADER is expanded from...
configure.ac:33: the top level
configure.ac:54: warning: The macro `AC_HELP_STRING' is obsolete.
configure.ac:54: You should run autoupdate.
./lib/autoconf/general.m4:204: AC_HELP_STRING is expanded from...
configure.ac:54: the top level
configure.ac:57: warning: The macro `AC_HELP_STRING' is obsolete.
configure.ac:57: You should run autoupdate.
./lib/autoconf/general.m4:204: AC_HELP_STRING is expanded from...
configure.ac:57: the top level
configure.ac:91: warning: The macro `AC_LANG_C' is obsolete.
configure.ac:91: You should run autoupdate.
./lib/autoconf/c.m4:72: AC_LANG_C is expanded from...
configure.ac:91: the top level
configure.ac:134: warning: The macro `AC_HEADER_STDC' is obsolete.
configure.ac:134: You should run autoupdate.
./lib/autoconf/headers.m4:704: AC_HEADER_STDC is expanded from...
configure.ac:134: the top level
configure.ac:157: warning: The macro `AC_HEADER_TIME' is obsolete.
configure.ac:157: You should run autoupdate.
./lib/autoconf/headers.m4:743: AC_HEADER_TIME is expanded from...
configure.ac:157: the top level
$ ./configure 
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a race-free mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether make supports the include directive... yes (GNU style)
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables... 
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether the compiler supports GNU C... yes
checking whether gcc accepts -g... yes
checking for gcc option to enable C11 features... none needed
checking whether gcc understands -c and -o together... yes
checking dependency style of gcc... gcc3
checking for stdio.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for strings.h... yes
checking for sys/stat.h... yes
checking for sys/types.h... yes
checking for unistd.h... yes
checking for wchar.h... yes
checking for minix/config.h... no
checking for sys/time.h... yes
checking whether it is safe to define __EXTENSIONS__... yes
checking whether _XOPEN_SOURCE should be defined... no
checking whether byte ordering is bigendian... no
checking for gcc... (cached) gcc
checking whether the compiler supports GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gcc option to enable C11 features... (cached) none needed
checking whether gcc understands -c and -o together... (cached) yes
checking dependency style of gcc... (cached) gcc3
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /usr/bin/ld option to reload object files... -r
checking for file... file
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for sysroot... no
checking for a working dd... /usr/bin/dd
checking how to truncate binary pipes... /usr/bin/dd bs=4096 count=1
checking for mt... no
checking if : is a manifest tool... no
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for egrep... (cached) /usr/bin/grep -E
checking for arpa/inet.h... yes
checking for netinet/in.h... yes
checking for netinet/ip.h... yes
checking for sys/socket.h... yes
checking for winsock2.h... no
checking for netlink/netlink.h... no
checking for net/rtnetlink.h... no
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for unistd.h... (cached) yes
checking for error_at_line... yes
checking for GNU libc compatible malloc... yes
checking for inet_ntoa... yes
checking for memset... no
checking for socket... yes
checking for strdup... no
checking for strerror... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating libparistraceroute/libparistraceroute-0.9.pc
config.status: creating libparistraceroute/Makefile
config.status: creating paris-traceroute/Makefile
config.status: creating paris-ping/Makefile
config.status: creating traceroute/Makefile
config.status: creating man/Makefile
config.status: creating doc/Makefile
config.status: creating libparistraceroute/config.h
config.status: executing depfiles commands
config.status: executing libtool commands
   Results
   ~~~~~~~
Probe sender:     
Network sniffer:  
Route impl.:      
Protocol:         IPv4
Transport:        
Debug code:       yes
Debug level:      1
Endianess:        little-endian
OS:               unix
CFLAGS:           -g -O2 -Wall -Werror
LDFLAGS:          
$ make 
Making all in libparistraceroute
make[1]: Entering directory '/home/marek/Downloads/libparistraceroute/libparistraceroute'
make  all-am
make[2]: Entering directory '/home/marek/Downloads/libparistraceroute/libparistraceroute'
depbase=`echo address.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.     -g -O2 -Wall -Werror -MT address.lo -MD -MP -MF $depbase.Tpo -c -o address.lo address.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT address.lo -MD -MP -MF .deps/address.Tpo -c address.c  -fPIC -DPIC -o .libs/address.o
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT address.lo -MD -MP -MF .deps/address.Tpo -c address.c -o address.o >/dev/null 2>&1
depbase=`echo algorithm.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.     -g -O2 -Wall -Werror -MT algorithm.lo -MD -MP -MF $depbase.Tpo -c -o algorithm.lo algorithm.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithm.lo -MD -MP -MF .deps/algorithm.Tpo -c algorithm.c  -fPIC -DPIC -o .libs/algorithm.o
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithm.lo -MD -MP -MF .deps/algorithm.Tpo -c algorithm.c -o algorithm.o >/dev/null 2>&1
depbase=`echo algorithms/mda.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.     -g -O2 -Wall -Werror -MT algorithms/mda.lo -MD -MP -MF $depbase.Tpo -c -o algorithms/mda.lo algorithms/mda.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda.lo -MD -MP -MF algorithms/.deps/mda.Tpo -c algorithms/mda.c  -fPIC -DPIC -o algorithms/.libs/mda.o
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda.lo -MD -MP -MF algorithms/.deps/mda.Tpo -c algorithms/mda.c -o algorithms/mda.o >/dev/null 2>&1
depbase=`echo algorithms/mda/bound.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.     -g -O2 -Wall -Werror -MT algorithms/mda/bound.lo -MD -MP -MF $depbase.Tpo -c -o algorithms/mda/bound.lo algorithms/mda/bound.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda/bound.lo -MD -MP -MF algorithms/mda/.deps/bound.Tpo -c algorithms/mda/bound.c  -fPIC -DPIC -o algorithms/mda/.libs/bound.o
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda/bound.lo -MD -MP -MF algorithms/mda/.deps/bound.Tpo -c algorithms/mda/bound.c -o algorithms/mda/bound.o >/dev/null 2>&1
depbase=`echo algorithms/mda/data.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.     -g -O2 -Wall -Werror -MT algorithms/mda/data.lo -MD -MP -MF $depbase.Tpo -c -o algorithms/mda/data.lo algorithms/mda/data.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda/data.lo -MD -MP -MF algorithms/mda/.deps/data.Tpo -c algorithms/mda/data.c  -fPIC -DPIC -o algorithms/mda/.libs/data.o
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda/data.lo -MD -MP -MF algorithms/mda/.deps/data.Tpo -c algorithms/mda/data.c -o algorithms/mda/data.o >/dev/null 2>&1
depbase=`echo algorithms/mda/flow.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.     -g -O2 -Wall -Werror -MT algorithms/mda/flow.lo -MD -MP -MF $depbase.Tpo -c -o algorithms/mda/flow.lo algorithms/mda/flow.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda/flow.lo -MD -MP -MF algorithms/mda/.deps/flow.Tpo -c algorithms/mda/flow.c  -fPIC -DPIC -o algorithms/mda/.libs/flow.o
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda/flow.lo -MD -MP -MF algorithms/mda/.deps/flow.Tpo -c algorithms/mda/flow.c -o algorithms/mda/flow.o >/dev/null 2>&1
depbase=`echo algorithms/mda/interface.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/sh ../libtool  --tag=CC   --mode=compile gcc -DHAVE_CONFIG_H -I.     -g -O2 -Wall -Werror -MT algorithms/mda/interface.lo -MD -MP -MF $depbase.Tpo -c -o algorithms/mda/interface.lo algorithms/mda/interface.c &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -g -O2 -Wall -Werror -MT algorithms/mda/interface.lo -MD -MP -MF algorithms/mda/.deps/interface.Tpo -c algorithms/mda/interface.c  -fPIC -DPIC -o algorithms/mda/.libs/interface.o
algorithms/mda/interface.c:185:44: error: argument 1 of type 'const mda_interface_t *[2]' with mismatched bound [-Werror=array-parameter=]
  185 | void mda_link_dump(const mda_interface_t * link[2], bool do_resolv)
      |                    ~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~
In file included from algorithms/mda/interface.c:1:
algorithms/mda/interface.h:114:45: note: previously declared as 'const mda_interface_t **'
  114 | void mda_link_dump(const mda_interface_t ** link, bool do_resolv);
      |                    ~~~~~~~~~~~~~~~~~~~~~~~~~^~~~
cc1: all warnings being treated as errors
make[2]: *** [Makefile:827: algorithms/mda/interface.lo] Error 1
make[2]: Leaving directory '/home/marek/Downloads/libparistraceroute/libparistraceroute'
make[1]: *** [Makefile:544: all] Error 2
make[1]: Leaving directory '/home/marek/Downloads/libparistraceroute/libparistraceroute'
make: *** [Makefile:402: all-recursive] Error 1

Invalid source address

sudo paris-traceroute 139.133.204.173
terminate called after throwing an instance of 'TrException'
Exception : [ERROR](IP4Header.cc, 239)Invalid source address : 
                                                               V[1]    5758 abort      sudo paris-traceroute 139.133.204.173

There does not seem to be an option for setting the source address/interface. This may be related to the fact that my active interface has index 2, with index 1 being a wired interface that is not connected.

Build issue

The build doesn't pass on Fedora anymore, seem to be related to a new gcc release.

Also, it's now required to use -fcommon among other flags.

Would be nice if one could look into this. Thanks.

update_timer passed negative delays

When running paris-traceroute I get error messages like:

update_timer: invalid delay (delay = -0.014287)
Error while updating timeout

In network.c update_timer expects a positive value for delay. It is called by network_update_next_timeout which calculates the delay to pass to update_timer using network_get_probe_timeout. network_get_probe_timeout's documentation says "\return The timeout of the probe. This value may be negative. If so, it means that this probe has already expired and a PROBE_TIMEOUT should be raised."

I am not sure what the fix for this is (hence no patch) should network_update_next_timeout have a line like pt_throw(NULL, probe->caller, event_create(PROBE_TIMEOUT, probe, NULL, NULL)); in network_drop_expired_flying_probe which is the other user of network_get_probe_timeout or should something be happening in network_get_matching_probe (which calls network_update_next_timeout) to ensure this can't happen?

sniffer.c registers to receive hopopts but does not process them

In sniffer.c in create_icmpv6_socket the line:

    ||  (setsockopt(sniffer->icmpv6_sockfd, IPPROTO_IPV6, IPV6_RECVHOPOPTS,  &on, sizeof(on)) == -1) // struct ip6_hbh

registers for the receiving of ip6_hbh data as per https://www.ietf.org/rfc/rfc3542.txt
However in rebuild_ipv6_header only IPV6_PKTINFO, IPV6_HOPLIMIT and IPV6_TCLASS are handled. IPV6_HOPOPTS (which has the value 54 on my system) is not handled.

This results in the following error messages when I run paris-traceroute:

Unhandled cmsg of type 54
recv_ipv6_header: error in rebuild_ipv6_header

Please implement support for kqueue as an alternative to epoll

The Debian package for paris-traceroute was affected by bug Debian#748788 where attempting to run in resulted in a seg fault on kFreeBSD. As I've updated the package to use the new libparistraceroute implementation, I was expecting this to solve the problem but I've now discovered that it will not build on FreeBSD due to the dependency on epoll which FreeBSD does not have.

The similar interface in FreeBSD is known as kqueue and is documented here:

https://www.freebsd.org/cgi/man.cgi?query=kqueue&sektion=2

please maintain

Dear paris-traceroute people,
please either maintain this tool or at least update the readme to tell interested users that this package is not maintained and/or usable any longer.
University teachers keep referring to this work.

To everybody who wants (/is supposed) to use this (for example as part as a research/university assignment), note that paris-traceroute & paris-ping (the old implementations I guess?) are usable without any (failing, see other issues) self-compilation for example from Debian stretch and buster, who might be installed within a virtual machine or a container solution (for example docker or lxc/lxd).

Contradictory LICENSE and COPYING files

In working on the Debian packaging, I have noticed contradictory LICENSE and COPYING files.

Please clarify who holds the copyright for libparistraceroute and the license that it is made available under.

Invalid read of size 2 in tcp.c

When running paris-traceroute under valgrind (searching for the cause of a segfault) I get:

==13399== Invalid read of size 2
==13399==    at 0x4C32720: memcpy@@GLIBC_2.14 (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==13399==    by 0x4E54A2F: memcpy (string3.h:53)
==13399==    by 0x4E54A2F: tcp_write_checksum (tcp.c:306)
==13399==    by 0x4E51C45: probe_update_checksum (probe.c:213)
==13399==    by 0x4E520A8: probe_update_fields (probe.c:730)
==13399==    by 0x4E52991: probe_set_fields (probe.c:841)
==13399==    by 0x401D52: main (paris-traceroute.c:398)
==13399==  Address 0x573aa38 is 0 bytes after a block of size 40 alloc'd
==13399==    at 0x4C2FB55: calloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
==13399==    by 0x4E4B66C: buffer_resize (buffer.c:61)
==13399==    by 0x4E52487: probe_set_protocols (probe.c:597)
==13399==    by 0x401C83: main (paris-traceroute.c:365)

Looking in protocols/tcp.c this results from the line:

                size_tcp   = tcp_get_header_size(tcp_segment) + 2, // hardcoded payload size 

I can't see what the + 2 is for, tcp_get_header_size appears to return the correct answer and not require adjustments. This adjustment appears to be what is upsetting valgrind.

Reverse TTL Value

I can't find the Reverse TTL functionality from the old paristraceroute Program. I hope you can implement it like in the original traceroute, by showing the difference between send TTL value and reply TTL value.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.