wireguard-tools/contrib/extract-keys
Greg Kroah-Hartman 01d00bc035 global: add SPDX tags to all files
It's good to have SPDX identifiers in all files as the Linux kernel
developers are working to add these identifiers to all files.

Update all files with the correct SPDX license identifier based on the license
text of the project or based on the license in the file itself.  The SPDX
identifier is a legally binding shorthand, which can be used instead of the
full boiler plate text.

Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Modified-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
2017-12-09 22:29:28 +01:00
..
.gitignore git: organize ignore files 2016-09-29 19:31:22 +02:00
Makefile extract-keys: respect compat directives 2017-02-20 21:55:44 +01:00
README examples: add key extractor 2016-08-26 04:52:50 +02:00
config.c global: add SPDX tags to all files 2017-12-09 22:29:28 +01:00
extract-keys.c global: add SPDX tags to all files 2017-12-09 22:29:28 +01:00

README

Key Extractor
=============

This will extract the symmetric ChaCha20Poly1305 session keys from the kernel
for a WireGuard interface, for use in making packet dissectors.


Build:
    $ make

Run (as root):
    # ./extract-keys INTERFACE

Output:
    REMOTE_KEY_ID SENDING_KEY
    LOCAL_KEY_ID RECEIVING_KEY

Example:
    # ./extract-keys wg0
    0x57b56068 tMTSEOJpEYFAQV2UviDiYooX0A1AD/ONqrzoQVHa1rQ=
    0xa182fd19 xvQSkQ5HTX5RUeJ74eAAb/xfNhdrDThxG91GXZIPKmY=
    0x01662508 LbMc84JULzXJiHotSkdSOPZ0bHh6IDwOrbxWLfwosTs=
    0xbd819021 4VA8lZ3I1HjnJcWTmhEzBdC92W1Aag9Lnyy2GkroOYI=