Make error on extract-handshakes

Adrian Popa adrian.popa.gh at gmail.com
Tue Jun 27 12:02:15 UTC 2023


Hello everyone!
This is the 4th time I'm trying to post this to the list - the other
messages got held up.

I'm trying to do packet capturing of wireguard traffic and have it
decrypted by Wireshark (for educational purposes), so I'm trying to
compile extract-handshakes with the following commands:

$  git clone https://git.zx2c4.com/WireGuard
$  cd WireGuard/contrib/examples/extract-handshakes
$  make
make -C /lib/modules/6.0.8-060008-generic/build
M=/home/adrianp/temp/extract/WireGuard/contrib/examples/extract-handshakes
offset-finder.o
make[1]: Entering directory '/usr/src/linux-headers-6.0.8-060008-generic'
warning: the compiler differs from the one used to build the kernel
  The kernel was built by: x86_64-linux-gnu-gcc-12 (Ubuntu
12.2.0-9ubuntu1) 12.2.0
  You are using:           gcc (Ubuntu 11.3.0-1ubuntu1~22.04.1) 11.3.0
make[3]: *** No rule to make target
'/home/adrianp/temp/extract/WireGuard/contrib/examples/extract-handshakes/offset-finder.o'.
Stop.
make[2]: *** [scripts/Makefile.build:440: __build] Error 2
make[1]: *** [Makefile:1858:
/home/adrianp/temp/extract/WireGuard/contrib/examples/extract-handshakes]
Error 2
make[1]: Leaving directory '/usr/src/linux-headers-6.0.8-060008-generic'
make: *** [Makefile:14: offset-finder.o] Error 2

Any ideas what I'm doing wrong? Is this the correct repository for
extract-handshakes? Do I need other steps before make?

My build environment looks ok as far as I can tell:
$  ls -l /lib/modules/6.0.8-060008-generic/build
lrwxrwxrwx 1 root root 43 Nov 10  2022
/lib/modules/6.0.8-060008-generic/build ->
/usr/src/linux-headers-6.0.8-060008-generic

Thanks for your input!


More information about the WireGuard mailing list