gnu: bird: Update to 2.0.10.
[jackhill/guix/guix.git] / gnu / packages / networking.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014, 2017, 2018, 2021 Ludovic Courtès <ludo@gnu.org>
3 ;;; Copyright © 2015, 2016, 2017, 2018, 2020 Ricardo Wurmus <rekado@elephly.net>
4 ;;; Copyright © 2015 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2015, 2016, 2017, 2021 Stefan Reichör <stefan@xsteve.at>
6 ;;; Copyright © 2016 Raimon Grau <raimonster@gmail.com>
7 ;;; Copyright © 2016–2022 Tobias Geerinckx-Rice <me@tobias.gr>
8 ;;; Copyright © 2016 John Darrington <jmd@gnu.org>
9 ;;; Copyright © 2016-2022 Nicolas Goaziou <mail@nicolasgoaziou.fr>
10 ;;; Copyright © 2016 Eric Bavier <bavier@member.fsf.org>
11 ;;; Copyright © 2016, 2017 Nikita <nikita@n0.is>
12 ;;; Copyright © 2016, 2017, 2018 Arun Isaac <arunisaac@systemreboot.net>
13 ;;; Copyright © 2016 Benz Schenk <benz.schenk@uzh.ch>
14 ;;; Copyright © 2016, 2017 Pjotr Prins <pjotr.guix@thebird.nl>
15 ;;; Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
16 ;;; Copyright © 2017, 2020, 2021 Leo Famulari <leo@famulari.name>
17 ;;; Copyright © 2017-2022 Efraim Flashner <efraim@flashner.co.il>
18 ;;; Copyright © 2017, 2018, 2019 Rutger Helling <rhelling@mykolab.com>
19 ;;; Copyright © 2017, 2019 Gábor Boskovits <boskovits@gmail.com>
20 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
21 ;;; Copyright © 2018 Adam Van Ymeren <adam@vany.ca>
22 ;;; Copyright © 2018 Fis Trivial <ybbs.daans@hotmail.com>
23 ;;; Copyright © 2018, 2019 Tonton <tonton@riseup.net>
24 ;;; Copyright © 2018 Clément Lassieur <clement@lassieur.org>
25 ;;; Copyright © 2018 Theodoros Foradis <theodoros@foradis.org>
26 ;;; Copyright © 2018, 2020-2022 Marius Bakke <marius@gnu.org>
27 ;;; Copyright © 2018, 2020, 2021 Oleg Pykhalov <go.wigust@gmail.com>
28 ;;; Copyright © 2018 Pierre Neidhardt <mail@ambrevar.xyz>
29 ;;; Copyright © 2019, 2020, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
30 ;;; Copyright © 2019 Vasile Dumitrascu <va511e@yahoo.com>
31 ;;; Copyright © 2019 Julien Lepiller <julien@lepiller.eu>
32 ;;; Copyright © 2019 Timotej Lazar <timotej.lazar@araneo.si>
33 ;;; Copyright © 2019, 2020, 2021 Brice Waegeneire <brice@waegenei.re>
34 ;;; Copyright © 2019, 2020 Alex Griffin <a@ajgrf.com>
35 ;;; Copyright © 2019, 2020 Jan Wielkiewicz <tona_kosmicznego_smiecia@interia.pl>
36 ;;; Copyright © 2019 Daniel Schaefer <git@danielschaefer.me>
37 ;;; Copyright © 2019 Diego N. Barbato <dnbarbato@posteo.de>
38 ;;; Copyright © 2020, 2021 Vincent Legoll <vincent.legoll@gmail.com>
39 ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net>
40 ;;; Copyright © 2020 Jesse Dowell <jessedowell@gmail.com>
41 ;;; Copyright © 2020 Hamzeh Nasajpour <h.nasajpour@pantherx.org>
42 ;;; Copyright © 2020, 2022 Michael Rohleder <mike@rohleder.de>
43 ;;; Copyright © 2021 Hartmut Goebel <h.goebel@crazy-compilers.com>
44 ;;; Copyright © 2021 Justin Veilleux <terramorpha@cock.li>
45 ;;; Copyright © 2021 Vinicius Monego <monego@posteo.net>
46 ;;; Copyright © 2021 Felix Gruber <felgru@posteo.net>
47 ;;; Copyright © 2021 Milkey Mouse <milkeymouse@meme.institute>
48 ;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net>
49 ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be>
50 ;;; Copyright © 2022 Simon South <simon@simonsouth.net>
51 ;;; Copyright © 2022 Pierre Langlois <pierre.langlois@gmx.com>
52 ;;; Copyright © 2022 Petr Hodina <phodina@protonmail.com>
53 ;;; Copyright © 2022 Manolis Fragkiskos Ragkousis <manolis837@gmail.com>
54 ;;;
55 ;;; This file is part of GNU Guix.
56 ;;;
57 ;;; GNU Guix is free software; you can redistribute it and/or modify it
58 ;;; under the terms of the GNU General Public License as published by
59 ;;; the Free Software Foundation; either version 3 of the License, or (at
60 ;;; your option) any later version.
61 ;;;
62 ;;; GNU Guix is distributed in the hope that it will be useful, but
63 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
64 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
65 ;;; GNU General Public License for more details.
66 ;;;
67 ;;; You should have received a copy of the GNU General Public License
68 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
69
70 (define-module (gnu packages networking)
71 #:use-module ((guix licenses) #:prefix license:)
72 #:use-module (guix packages)
73 #:use-module (guix download)
74 #:use-module (guix gexp)
75 #:use-module (guix git-download)
76 #:use-module (guix build-system cmake)
77 #:use-module (guix build-system glib-or-gtk)
78 #:use-module (guix build-system gnu)
79 #:use-module (guix build-system go)
80 #:use-module (guix build-system meson)
81 #:use-module (guix build-system perl)
82 #:use-module (guix build-system python)
83 #:use-module (guix build-system trivial)
84 #:use-module (guix utils)
85 #:use-module (gnu packages)
86 #:use-module (gnu packages admin)
87 #:use-module (gnu packages adns)
88 #:use-module (gnu packages algebra)
89 #:use-module (gnu packages audio)
90 #:use-module (gnu packages autogen)
91 #:use-module (gnu packages autotools)
92 #:use-module (gnu packages assembly)
93 #:use-module (gnu packages base)
94 #:use-module (gnu packages bash)
95 #:use-module (gnu packages bison)
96 #:use-module (gnu packages boost)
97 #:use-module (gnu packages check)
98 #:use-module (gnu packages code)
99 #:use-module (gnu packages compression)
100 #:use-module (gnu packages cpp)
101 #:use-module (gnu packages crypto)
102 #:use-module (gnu packages curl)
103 #:use-module (gnu packages cyrus-sasl)
104 #:use-module (gnu packages dejagnu)
105 #:use-module (gnu packages docbook)
106 #:use-module (gnu packages documentation)
107 #:use-module (gnu packages flex)
108 #:use-module (gnu packages freedesktop)
109 #:use-module (gnu packages gettext)
110 #:use-module (gnu packages glib)
111 #:use-module (gnu packages gnome)
112 #:use-module (gnu packages gnupg)
113 #:use-module (gnu packages golang)
114 #:use-module (gnu packages graphviz)
115 #:use-module (gnu packages gstreamer)
116 #:use-module (gnu packages gtk)
117 #:use-module (gnu packages image)
118 #:use-module (gnu packages libevent)
119 #:use-module (gnu packages libidn)
120 #:use-module (gnu packages libusb)
121 #:use-module (gnu packages linux)
122 #:use-module (gnu packages lua)
123 #:use-module (gnu packages kerberos)
124 #:use-module (gnu packages mpi)
125 #:use-module (gnu packages ncurses)
126 #:use-module (gnu packages nettle)
127 #:use-module (gnu packages openldap)
128 #:use-module (gnu packages onc-rpc)
129 #:use-module (gnu packages password-utils)
130 #:use-module (gnu packages pcre)
131 #:use-module (gnu packages perl)
132 #:use-module (gnu packages perl-check)
133 #:use-module (gnu packages pkg-config)
134 #:use-module (gnu packages polkit)
135 #:use-module (gnu packages pretty-print)
136 #:use-module (gnu packages protobuf)
137 #:use-module (gnu packages pulseaudio)
138 #:use-module (gnu packages python)
139 #:use-module (gnu packages python-crypto)
140 #:use-module (gnu packages python-web)
141 #:use-module (gnu packages python-xyz)
142 #:use-module (gnu packages qt)
143 #:use-module (gnu packages readline)
144 #:use-module (gnu packages ruby)
145 #:use-module (gnu packages samba)
146 #:use-module (gnu packages serialization)
147 #:use-module (gnu packages shells)
148 #:use-module (gnu packages sphinx)
149 #:use-module (gnu packages sqlite)
150 #:use-module (gnu packages ssh)
151 #:use-module (gnu packages tcl)
152 #:use-module (gnu packages textutils)
153 #:use-module (gnu packages tls)
154 #:use-module (gnu packages valgrind)
155 #:use-module (gnu packages web)
156 #:use-module (gnu packages wxwidgets)
157 #:use-module (gnu packages xml)
158 #:use-module (ice-9 match))
159
160 (define-public usrsctp
161 (package
162 (name "usrsctp")
163 (version "0.9.5.0")
164 (source
165 (origin
166 (method git-fetch)
167 (uri
168 (git-reference
169 (url "https://github.com/sctplab/usrsctp")
170 (commit version)))
171 (file-name (git-file-name name version))
172 (sha256
173 (base32 "10ndzkip8blgkw572n3dicl6mgjaa7kygwn3vls80liq92vf1sa9"))))
174 (build-system gnu-build-system)
175 (native-inputs
176 (list autoconf
177 automake
178 libtool
179 pkg-config
180 python-wrapper
181 which))
182 (home-page "https://github.com/sctplab/usrsctp/")
183 (synopsis "SCTP user-land implementation")
184 (description "UsrSCTP is a portable SCTP userland stack. SCTP is a message
185 oriented, reliable transport protocol with direct support for multihoming that
186 runs on top of IP or UDP, and supports both v4 and v6 versions.")
187 (license license:bsd-3)))
188
189 (define-public arp-scan
190 (package
191 (name "arp-scan")
192 (version "1.9.7")
193 (source
194 (origin
195 (method git-fetch)
196 (uri
197 (git-reference
198 (url "https://github.com/royhills/arp-scan/")
199 (commit version)))
200 (file-name (git-file-name name version))
201 (sha256
202 (base32 "1mf7a4f9vzvnkiavc87aqyciswggsb4fpy7j05jxnvjyyxv3l7gp"))))
203 (build-system gnu-build-system)
204 (inputs
205 (list libpcap))
206 (native-inputs
207 (list autoconf automake libtool pkg-config))
208 (propagated-inputs
209 (list perl-libwww))
210 (home-page "https://github.com/royhills/arp-scan")
211 (synopsis "Discover and fingerprint IP hosts on the local network using ARP")
212 (description "Arp-scan is a tool that uses ARP to discover and fingerprint
213 IP hosts on the local network.")
214 (license license:gpl3+)))
215
216 (define-public axel
217 (package
218 (name "axel")
219 (version "2.17.11")
220 (source
221 (origin
222 (method url-fetch)
223 (uri (string-append "https://github.com/axel-download-accelerator/axel/"
224 "releases/download/v" version "/"
225 "axel-" version ".tar.xz"))
226 (sha256
227 (base32 "1yfcsi0zv07bvhj8klgna3y1ycc4jhaija1b3rzzv0i4d4c2q2sq"))))
228 (build-system gnu-build-system)
229 (native-inputs
230 (list gettext-minimal pkg-config))
231 (inputs
232 (list libressl))
233 (home-page "https://github.com/axel-download-accelerator/axel")
234 (synopsis "Light command line download accelerator")
235 (description
236 "Axel tries to accelerate the download process by using multiple
237 connections per file, and can also balance the load between different
238 servers. It tries to be as light as possible, so it might be useful
239 on byte-critical systems. It supports HTTP, HTTPS, FTP and FTPS
240 protocols.")
241 (license license:gpl2+)))
242
243 (define-public lcrq
244 (package
245 (name "lcrq")
246 (version "0.0.1")
247 (source (origin
248 (method git-fetch)
249 (uri (git-reference
250 (url "https://codeberg.org/librecast/lcrq")
251 (commit (string-append "v" version))))
252 (file-name (git-file-name name version))
253 (sha256
254 (base32
255 "0jf7x3zcdbz5b99qz7liw4i90hn9s457zr82n0r8g9qsi81a1d8c"))))
256 (build-system gnu-build-system)
257 (arguments
258 `(#:parallel-tests? #f
259 #:make-flags (let ((target ,(%current-target-system)))
260 (list ,(string-append "CC="
261 (cc-for-target))
262 (string-append "PREFIX="
263 (assoc-ref %outputs "out"))))
264 #:test-target "test"))
265 (home-page "https://librecast.net/lcrq.html")
266 (synopsis "librecast RaptorQ library")
267 (description
268 "C library implementation of RaptorQ Forward Error Correction for
269 Librecast. RFC6330 (IETF) describes the RaptorQ proposed standard, which LCRQ
270 more-or-less follows. The primary focus has been on building a fast, simple
271 and dependency-free FEC implementation for use with Librecast, and not on
272 strict standards compliance. The code does, however, fairly closely follow
273 the RFC.")
274 (license (list license:gpl2 license:gpl3))))
275
276 (define-public lcsync
277 (package
278 (name "lcsync")
279 (version "0.0.1")
280 (source (origin
281 (method git-fetch)
282 (uri (git-reference
283 (url "https://codeberg.org/librecast/lcsync")
284 (commit (string-append "v" version))))
285 (file-name (git-file-name name version))
286 (sha256
287 (base32
288 "0s038b4xg9nlzhrganzjyfvc6n6cgd6kilnpik4axp62j2n5q11q"))))
289 (build-system gnu-build-system)
290 (arguments
291 `(#:parallel-tests? #f
292 #:make-flags (let ((target ,(%current-target-system)))
293 (list ,(string-append "CC="
294 (cc-for-target))
295 ;; avoid running setcap in the install process
296 "SETCAP_PROGRAM=true"
297 (string-append "prefix="
298 (assoc-ref %outputs "out"))))
299 #:test-target "test"
300 #:phases (modify-phases %standard-phases
301 (delete 'configure) ;no configure script
302 (add-before 'check 'remove-network-tests
303 (lambda _
304 ;; these tests require networking
305 (delete-file "./test/0000-0027.c")
306 (delete-file "./test/0000-0049.c")
307 (delete-file "./test/0000-0074.c")))
308 (add-after 'unpack 'remove-immintrin.h
309 (lambda* (#:key inputs #:allow-other-keys)
310 (substitute* "Makefile"
311 (("CFLAGS :=")
312 (string-append "CFLAGS := -I" (search-input-directory
313 inputs "include/simde"))))
314 (substitute* (find-files "src")
315 ((".*immintrin\\.h.*")
316 (string-append "#include <simde-features.h>\n"
317 "#include <x86/ssse3.h>\n"))
318 (("__m128i") "simde__m128i"))))
319 (add-before 'build 'add-library-paths
320 (lambda* (#:key inputs #:allow-other-keys)
321 (let* ((librecast (assoc-ref inputs "librecast")))
322 (substitute* (list "./src/Makefile" "./test/Makefile")
323 (("-llibrecast")
324 (string-append "-L" librecast "/lib -llibrecast")))))))))
325 (inputs (list librecast libsodium))
326 (native-inputs (list simde))
327 (home-page "https://librecast.net/lcsync.html")
328 (synopsis "librecast file and data syncing tool")
329 (description
330 "lcsync is a tool to sync files over IPv6 multicast or the
331 local filesystem. It splits the file into blocks, hashes them, and compares
332 them in order to efficiently transfer a minimal amount of data.")
333 (license (list license:gpl2 license:gpl3))))
334
335 ;; This package does not have a release yet.
336 ;; But this is required to provide a feature in PipeWire.
337 (define-public libcamera
338 (package
339 (name "libcamera")
340 (version "0.0.0-1")
341 (source
342 (origin
343 (method git-fetch)
344 (uri
345 (git-reference
346 (url "git://linuxtv.org/libcamera.git")
347 (commit "10be87fa7c3bfb097b21ca3d469c67e40c333f7e")))
348 (file-name
349 (git-file-name name version))
350 (sha256
351 (base32 "0qgirhlalmk9f9v6piwz50dr2asb64rvbb9zb1vix7y9zh7m11by"))))
352 (build-system meson-build-system)
353 (outputs '("out" "doc"))
354 (arguments
355 `(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas
356 #:configure-flags
357 (list
358 "-Dv4l2=true"
359 ;; XXX: Requires bundled pybind11.
360 "-Dpycamera=disabled")
361 #:phases
362 (modify-phases %standard-phases
363 (add-after 'unpack 'disable-failing-tests
364 (lambda _
365 (substitute* "test/meson.build"
366 (("\\['list-cameras', 'list-cameras.cpp'\\],")
367 "")
368 ;; TODO: Why do the gstreamer tests fail.
369 (("^subdir\\('gstreamer'\\)")
370 ""))))
371 (add-after 'install 'move-doc
372 (lambda* (#:key outputs #:allow-other-keys)
373 (let* ((out (assoc-ref outputs "out"))
374 (doc (assoc-ref outputs "doc")))
375 (mkdir-p (string-append doc "/share"))
376 (rename-file
377 (string-append out "/share/doc")
378 (string-append doc "/share/doc"))))))))
379 (native-inputs
380 (list graphviz ;for 'dot'
381 doxygen
382 pkg-config
383 python-wrapper
384 python-sphinx
385 python-pyyaml))
386 (inputs
387 (list boost
388 eudev
389 glib
390 gst-plugins-base
391 gnutls
392 libtiff
393 libyaml
394 openssl
395 python-jinja2
396 python-ply
397 qtbase-5))
398 (synopsis "Camera stack and framework")
399 (description "LibCamera is a complex camera support library for GNU+Linux,
400 Android, and ChromeOS.")
401 (home-page "https://libcamera.org/")
402 (license license:lgpl2.1+)))
403
404 (define-public libnice
405 ;; The latest release is old and randomly fails tests with GStreamer 1.18.5,
406 ;; such as: "test-bind: ../libnice-0.1.18/stun/tests/test-bind.c:234:
407 ;; bad_responses: Assertion `len >= 20' failed"
408 (let ((revision "0")
409 (commit "47a96334448838c43d7e72f4ef51b317befbfae1"))
410 (package
411 (name "libnice")
412 (version (git-version "0.1.18" revision commit))
413 (source
414 (origin
415 (method git-fetch)
416 (uri (git-reference
417 (url "https://gitlab.freedesktop.org/libnice/libnice")
418 (commit commit)))
419 (file-name (git-file-name name version))
420 (sha256
421 (base32
422 "19ypjazslmsb9vqs2wyyzvi72h5jbn16dbng7pxh485djdrmgcg4"))))
423 (build-system meson-build-system)
424 (outputs '("out" "doc"))
425 (arguments
426 `(#:glib-or-gtk? #t ; To wrap binaries and/or compile schemas
427 #:configure-flags
428 (list
429 "-Dgtk_doc=enabled")
430 #:phases
431 (modify-phases %standard-phases
432 (add-after 'unpack 'disable-failing-tests
433 (lambda _
434 (substitute* "tests/meson.build"
435 ;; ‘test-set-port-range.c:66:main: assertion failed:
436 ;; (nice_agent_gather_candidates (agent, stream1))’
437 (("'test-set-port-range'" all)
438 (string-append "# " all))
439 ;; The following test is disabled as it fails in a
440 ;; nondeterministic fashion (see:
441 ;; https://gitlab.freedesktop.org/libnice/libnice/-/issues/151).
442 (("'test-bsd'" all)
443 (string-append "# " all)))
444 (substitute* "stun/tests/meson.build"
445 ;; test-bind.c:234: bad_responses: Assertion `len >= 20'
446 ;; failed (see:
447 ;; https://gitlab.freedesktop.org/libnice/libnice/-/issues/150).
448 (("'bind', ")
449 ""))))
450 (add-after 'install 'move-docs
451 (lambda* (#:key outputs #:allow-other-keys)
452 (let* ((out (assoc-ref outputs "out"))
453 (doc (assoc-ref outputs "doc")))
454 (mkdir-p (string-append doc "/share"))
455 (rename-file
456 (string-append out "/share/gtk-doc")
457 (string-append doc "/share/gtk-doc"))))))))
458 (native-inputs
459 `(("glib:bin" ,glib "bin")
460 ("gobject-introspection" ,gobject-introspection)
461 ("graphviz" ,graphviz)
462 ("gtk-doc" ,gtk-doc/stable)
463 ("pkg-config" ,pkg-config)))
464 (inputs
465 (list gstreamer gst-plugins-base libnsl))
466 (propagated-inputs
467 (list glib glib-networking gnutls))
468 (synopsis "GLib ICE implementation")
469 (description "LibNice is a library that implements the Interactive
470 Connectivity Establishment (ICE) standard (RFC 5245 & RFC 8445). It provides a
471 GLib-based library, libnice, as well as GStreamer elements to use it.")
472 (home-page "https://libnice.freedesktop.org/")
473 (license
474 ;; This project is dual-licensed.
475 (list
476 license:lgpl2.1+
477 license:mpl1.1)))))
478
479 (define-public librecast
480 (package
481 (name "librecast")
482 (version "0.5.1")
483 (source (origin
484 (method git-fetch)
485 (uri (git-reference
486 (url "https://codeberg.org/librecast/librecast")
487 (commit (string-append "v" version))))
488 (file-name (git-file-name name version))
489 (sha256
490 (base32
491 "1zzdxawzsj0lxyxm8c2wdqx3b633f8ybvlg6szs4v0y42xg4a829"))))
492 (build-system gnu-build-system)
493 (arguments
494 `(#:parallel-tests? #f
495 #:make-flags (let ((target ,(%current-target-system)))
496 (list ,(string-append "CC="
497 (cc-for-target))
498 (string-append "PREFIX="
499 (assoc-ref %outputs "out"))))
500 #:test-target "test"
501 #:phases (modify-phases %standard-phases
502 (add-before 'check 'remove-network-tests
503 (lambda _
504 ;; these tests require networking
505 (delete-file "./test/0000-0010.c")
506 (delete-file "./test/0000-0012.c")
507 (delete-file "./test/0000-0013.c")
508 (delete-file "./test/0000-0014.c")
509 (delete-file "./test/0000-0015.c")
510 (delete-file "./test/0000-0016.c")
511 (delete-file "./test/0000-0018.c")
512 (delete-file "./test/0000-0019.c")
513 (delete-file "./test/0000-0021.c")
514 (delete-file "./test/0000-0028.c")
515 (delete-file "./test/0000-0036.c")
516 (delete-file "./test/0000-0037.c")
517 (delete-file "./test/0000-0038.c")
518 (delete-file "./test/0000-0039.c")
519 (delete-file "./test/0000-0040.c"))))))
520 (inputs (list libsodium lcrq))
521 (synopsis "librecast IPv6 multicast library")
522 (description "Librecast is a C library which supports IPv6 multicast
523 networking.")
524 (home-page "https://librecast.net/librecast.html")
525 (license (list license:gpl2 license:gpl3))))
526
527 (define-public rtmpdump
528 ;; There are no tags in the repository, and the project is unlikely to
529 ;; make new releases. Take a recent commit for multiple security fixes
530 ;; as well as GnuTLS compatibility.
531 (let ((commit "c5f04a58fc2aeea6296ca7c44ee4734c18401aa3")
532 (revision "0")
533 (version "2.4")) ;as mentioned in README and man pages
534 (package
535 (name "rtmpdump")
536 (version (git-version version revision commit))
537 (source
538 (origin
539 (method git-fetch)
540 (uri (git-reference
541 (url "https://git.ffmpeg.org/rtmpdump")
542 (commit commit)))
543 (file-name (git-file-name name version))
544 (sha256
545 (base32 "07ias612jgmxpam9h418kvlag32da914jsnjsfyafklpnh8gdzjb"))))
546 (build-system gnu-build-system)
547 (arguments
548 `(#:tests? #f ; no tests
549 #:make-flags
550 (list
551 ;; The ‘validate-runpath’ phase fails to find librtmp.so.0.
552 (string-append "LDFLAGS=-Wl,-rpath="
553 (assoc-ref %outputs "out") "/lib")
554 (string-append "prefix=" (assoc-ref %outputs "out")))
555 #:phases
556 (modify-phases %standard-phases
557 (add-after 'unpack 'omit-static-library
558 (lambda _
559 (substitute* "librtmp/Makefile"
560 (("cp librtmp\\.a .*") ; don't install it
561 "")
562 (("librtmp\\.a ") ; don't build it
563 ""))
564 #t))
565 (add-after 'unpack 'prefer-gnutls
566 (lambda _
567 (substitute* '("Makefile" "librtmp/Makefile")
568 (("CRYPTO=OPENSSL")
569 "#CRYPTO=OPENSSL")
570 (("#CRYPTO=GNUTLS")
571 "CRYPTO=GNUTLS"))))
572 (delete 'configure))))
573 (inputs
574 (list gnutls zlib))
575 (synopsis "Tools and library for handling RTMP streams")
576 (description "RTMPdump is a toolkit for RTMP streams. All forms of RTMP are
577 supported, including rtmp://, rtmpt://, rtmpe://, rtmpte://, and rtmps://.")
578 (home-page "https://rtmpdump.mplayerhq.hu/")
579 (license
580 (list
581 ;; Library.
582 license:lgpl2.1+
583 ;; Others.
584 license:gpl2+)))))
585
586 (define-public slurm-monitor
587 (package
588 (name "slurm-monitor")
589 (version "0.4.3")
590 (source
591 (origin
592 (method git-fetch)
593 (uri
594 (git-reference
595 (url "https://github.com/mattthias/slurm")
596 (commit (string-append "upstream/" version))))
597 (file-name (git-file-name name version))
598 (sha256
599 (base32 "1n6pgrcs8gwrcq5fch1q3yk3jipjwrf21s9a13fbjrl903g5zzv9"))))
600 (build-system cmake-build-system)
601 (arguments `(#:tests? #f)) ;no tests
602 (inputs (list ncurses))
603 (synopsis "Network load monitor")
604 (description
605 "Slurm is a network load monitor. It shows real-time traffic statistics
606 from any network device in any of three ASCII graph formats.")
607 (home-page "https://github.com/mattthias/slurm")
608 (license license:gpl2)))
609
610 (define-public srt
611 (package
612 (name "srt")
613 (version "1.4.4")
614 (source
615 (origin
616 (method git-fetch)
617 (uri
618 (git-reference
619 (url "https://github.com/Haivision/srt")
620 (commit (string-append "v" version))))
621 (file-name (git-file-name name version))
622 (sha256
623 (base32 "1zr1l9zkai7rpw9cn5j9h4zrv08hgpfmwscwyscf2j4cgwf0rxrr"))))
624 (build-system cmake-build-system)
625 (arguments
626 `(#:configure-flags
627 (list
628 (string-append "-DCMAKE_INSTALL_BINDIR="
629 (assoc-ref %outputs "out") "/bin")
630 "-DCMAKE_INSTALL_INCLUDEDIR=include"
631 "-DENABLE_STATIC=OFF"
632 "-DENABLE_UNITTESTS=ON")))
633 (native-inputs
634 (list googletest pkg-config tcl))
635 (propagated-inputs
636 (list openssl))
637 (synopsis "Secure Reliable Transport")
638 (description "SRT is a transport technology that optimizes streaming
639 performance across unpredictable networks, such as the Internet.")
640 (home-page "https://www.srtalliance.org/")
641 (license license:mpl2.0)))
642
643 (define-public lksctp-tools
644 (package
645 (name "lksctp-tools")
646 (version "1.0.19")
647 (source
648 (origin
649 (method git-fetch)
650 (uri
651 (git-reference
652 (url "https://github.com/sctp/lksctp-tools")
653 (commit (string-append "v" version))))
654 (file-name (git-file-name name version))
655 (sha256
656 (base32 "1jfq58j365mlgssavyw5wcal42n0xjkr40vmj9b8w265wgs28j20"))))
657 (build-system gnu-build-system)
658 (native-inputs
659 (list autoconf automake libtool pkg-config))
660 (synopsis
661 "@acronym{SCTP, Stream Control Transmission Protocol} helpers for Linux")
662 (description
663 "The lksctp-tools project provides a user-space library for @acronym{SCTP,
664 the Stream Control Transmission Protocol} (@file{libsctp}) and C language header
665 files (@file{netinet/sctp.h}) for accessing SCTP-specific @acronym{APIs,
666 application programming interfaces} not provided by the standard sockets.
667 It also includes some SCTP-related helper utilities.")
668 (home-page "http://lksctp.sourceforge.net/")
669 (license
670 (list
671 ;; Library.
672 license:lgpl2.1+
673 ;; Others.
674 license:gpl2+))))
675
676 (define-public python-pysctp
677 (package
678 (name "python-pysctp")
679 (version "0.6.1")
680 (source
681 (origin
682 (method url-fetch)
683 (uri (pypi-uri "pysctp" version))
684 (sha256
685 (base32 "14h2qlmfi24bizhvvqkfqfa78pzm3911ibrzy9k94i97xy1978dy"))))
686 (build-system python-build-system)
687 (inputs
688 (list lksctp-tools))
689 (arguments
690 `(#:tests? #f ;; tests require network
691 #:phases
692 (modify-phases %standard-phases
693 (add-after 'unpack 'patch-setup.py
694 (lambda _
695 (substitute* "setup.py"
696 (("include_dirs\\s*=.*")
697 (string-append "include_dirs = ['.'] + '"
698 (getenv "C_INCLUDE_PATH") "'.split(':'),"))
699 (("library_dirs\\s*=.*")
700 (string-append "library_dirs = '"
701 (getenv "LIBRARY_PATH") "'.split(':'),"))))))))
702 (home-page "https://github.com/p1sec/pysctp")
703 (synopsis "Python module for the SCTP protocol stack and library")
704 (description "@code{pysctp} implements the SCTP socket API. You need a
705 SCTP-aware kernel (most are).")
706 (license license:lgpl2.1+)))
707
708 (define-public kismet
709 (package
710 (name "kismet")
711 (version "2022-02")
712 (source (origin
713 (method git-fetch)
714 (uri (git-reference
715 (url "https://www.kismetwireless.net/git/kismet.git")
716 (commit (string-append "kismet-" version "-R1"))))
717 (file-name (git-file-name name version))
718 (patches (search-patches "kismet-unbundle-boost.patch"))
719 (modules '((guix build utils)))
720 (snippet '(begin
721 ;; Drop bundled libraries.
722 (delete-file-recursively "boost")))
723 (sha256
724 (base32
725 "01q86hrgpai433sc65dlnqy91qd26w5dwyp37adszqxfb6d2an1r"))))
726 (build-system gnu-build-system)
727 (arguments
728 (list #:tests? #f ;no test suite
729 #:phases
730 #~(modify-phases %standard-phases
731 (add-after 'unpack 'fix-install
732 (lambda* _
733 (substitute* "Makefile.in"
734 (("-o \\$\\(INSTUSR\\) -g \\$\\(SUIDGROUP\\)") "")
735 (("-o \\$\\(INSTUSR\\) -g \\$\\(INSTGRP\\)") "")))))))
736 (home-page "https://www.kismetwireless.net/")
737 (native-inputs (list perl pkg-config python python-2))
738 (inputs (list boost
739 libusb
740 libpcap
741 libwebsockets
742 openssl
743 protobuf
744 protobuf-c
745 sqlite
746 zlib))
747 (synopsis "Wireless network and device detector")
748 (description
749 "This package provides a wireless network and device detector, sniffer,
750 wardriving tool, and WIDS (wireless intrusion detection) framework. Kismet
751 works with Wi-Fi interfaces, Bluetooth interfaces, some SDR
752 (software defined radio) hardware like the RTLSDR, and other specialized
753 capture hardware")
754 (license license:gpl2+)))
755
756 (define-public knockd
757 (package
758 (name "knockd")
759 (version "0.8")
760 (source (origin
761 (method url-fetch)
762 (uri (string-append "https://www.zeroflux.org/proj/knock/files/knock-"
763 version ".tar.gz"))
764 (sha256
765 (base32
766 "1iv9h7a9l81ilbld3pi0dmzkizjss1755x1x3v5jxsi4asb8r3b9"))))
767 (build-system gnu-build-system)
768 (arguments
769 `(#:configure-flags
770 (list (string-append "--docdir=" (assoc-ref %outputs "out")
771 "/share/doc/" ,name "-" ,version))))
772 (inputs
773 (list libpcap))
774 (home-page "https://www.zeroflux.org/projects/knock")
775 (synopsis "Small port-knock daemon")
776 (description "@command{knockd} is a port-knock daemon. It listens to all traffic on
777 an ethernet or PPP interface, looking for special \"knock\" sequences of @dfn{port-hits}
778 (UDP/TCP packets sent to a server port). This port need not be open, since knockd listens
779 at the link-layer level.")
780 (license license:gpl2+)))
781
782 (define-public nng
783 (package
784 (name "nng")
785 (version "1.3.2")
786 (source
787 (origin
788 (method git-fetch)
789 (uri (git-reference
790 (url "https://github.com/nanomsg/nng")
791 (commit (string-append "v" version))))
792 (file-name (git-file-name name version))
793 (sha256
794 (base32 "0a4jg8alh2h0rw6fb4dqpvk4hgl2a7h76mq7g34fy89qh9sgg1a4"))))
795 (build-system cmake-build-system)
796 (arguments
797 `(#:configure-flags
798 (list "-DNNG_ENABLE_COVERAGE=ON"
799 "-DNNG_ENABLE_TLS=ON"
800 "-DBUILD_SHARED_LIBS=ON")
801 #:phases
802 (modify-phases %standard-phases
803 (add-after 'unpack 'disable-failing-tests
804 (lambda _
805 ;; These tests require network access.
806 (substitute* "tests/CMakeLists.txt"
807 (("add_nng_test1\\(httpclient 60 NNG_SUPP_HTTP\\)") "")
808 (("add_nng_test1\\(resolv 10 NNG_STATIC_LIB\\)") "")
809 (("add_nng_test\\(tls 60\\)") ""))
810 #t)))))
811 (native-inputs
812 `(("ksh" ,oksh)))
813 (inputs
814 `(("mbedtls" ,mbedtls-apache)))
815 (synopsis "Lightweight messaging library")
816 (description "NNG project is a rewrite of the scalability protocols library
817 known as libnanomsg, and adds significant new capabilities, while retaining
818 compatibility with the original. It is a lightweight, broker-less library,
819 offering a simple API to solve common recurring messaging problems, such as
820 publish/subscribe, RPC-style request/reply, or service discovery.")
821 (home-page "https://nng.nanomsg.org/")
822 (license license:expat)))
823
824 (define-public nanomsg
825 (package
826 (name "nanomsg")
827 (version "1.1.5")
828 (source
829 (origin
830 (method git-fetch)
831 (uri
832 (git-reference
833 (url "https://github.com/nanomsg/nanomsg")
834 (commit version)))
835 (file-name (git-file-name name version))
836 (sha256
837 (base32 "01ddfzjlkf2dgijrmm3j3j8irccsnbgfvjcnwslsfaxnrmrq5s64"))))
838 (build-system cmake-build-system)
839 (outputs '("out" "doc"))
840 (arguments
841 `(#:configure-flags
842 (list
843 "-DNN_ENABLE_COVERAGE=ON")
844 #:phases
845 (modify-phases %standard-phases
846 (add-after 'install 'move-docs
847 (lambda* (#:key outputs #:allow-other-keys)
848 (let* ((out (assoc-ref outputs "out"))
849 (doc (assoc-ref outputs "doc")))
850 (mkdir-p (string-append doc "/share/doc"))
851 (rename-file
852 (string-append out "/share/doc/nanomsg")
853 (string-append doc "/share/doc/nanomsg"))
854 #t))))))
855 (native-inputs
856 `(("asciidoctor" ,ruby-asciidoctor)
857 ("pkg-config" ,pkg-config)))
858 (synopsis "Scalable socket library")
859 (description "Nanomsg is a socket library that provides several common
860 communication patterns. It aims to make the networking layer fast, scalable,
861 and easy to use. Implemented in C, it works on a wide range of operating
862 systems with no further dependencies.")
863 (home-page "https://nanomsg.org/")
864 (license (license:non-copyleft "file:///COPYING"))))
865
866 (define-public blueman
867 (package
868 (name "blueman")
869 (version "2.2.3")
870 (source
871 (origin
872 (method url-fetch)
873 (uri (string-append "https://github.com/blueman-project/blueman/releases"
874 "/download/" version "/blueman-" version ".tar.xz"))
875 (sha256
876 (base32 "1s86w4mklzr8hvbgl3nkg8jycl6grww533dhzw8gdn5glqfpkpbf"))))
877 (build-system glib-or-gtk-build-system)
878 (arguments
879 `(#:configure-flags (list "--enable-polkit"
880 "--without-systemdsystemunitdir" ; Not required
881 "--without-systemduserunitdir") ; Not required
882 #:phases
883 (modify-phases %standard-phases
884 ;; Python references are not being patched in patch-phase of build,
885 ;; despite using python-wrapper as input. So we patch them manually.
886 (add-after 'unpack 'patch-python-references
887 (lambda* (#:key inputs #:allow-other-keys)
888 (with-directory-excursion "apps"
889 (substitute* '("blueman-adapters.in" "blueman-applet.in"
890 "blueman-manager.in" "blueman-mechanism.in"
891 "blueman-rfcomm-watcher.in" "blueman-sendto.in"
892 "blueman-services.in" "blueman-tray.in")
893 (("@PYTHON@")
894 (search-input-file inputs
895 (string-append
896 "/bin/python"
897 ,(version-major+minor
898 (package-version python)))))))))
899 ;; Fix loading of external programs.
900 (add-after 'unpack 'patch-external-programs
901 (lambda* (#:key inputs #:allow-other-keys)
902 (substitute* '("blueman/main/NetConf.py"
903 "blueman/main/PPPConnection.py")
904 (("/usr/sbin/bluetoothd")
905 (search-input-directory inputs
906 "/libexec/bluetooth/bluetoothd"))
907 (("/sbin/iptables")
908 (search-input-file inputs "/sbin/iptables"))
909 (("/usr/sbin/pppd")
910 (search-input-file inputs "/sbin/pppd")))))
911 ;; Fix loading of pulseaudio libraries.
912 (add-after 'unpack 'patch-pulseaudio-libraries
913 (lambda* (#:key inputs #:allow-other-keys)
914 (let* ((pulseaudio (assoc-ref inputs "pulseaudio"))
915 (pulse (string-append pulseaudio "/lib/libpulse.so.0"))
916 (pulse-glib (string-append pulseaudio
917 "/lib/libpulse-mainloop-glib.so.0")))
918 (with-directory-excursion "blueman/main"
919 (substitute* "PulseAudioUtils.py"
920 (("libpulse.so.0") pulse)
921 (("libpulse-mainloop-glib.so.0") pulse-glib))))))
922 ;; Fix running of blueman programs.
923 (add-after 'glib-or-gtk-wrap 'wrap-blueman-progs
924 (lambda* (#:key outputs #:allow-other-keys)
925 (let* ((out (assoc-ref outputs "out"))
926 (bin (string-append out "/bin/blueman-"))
927 (libexec (string-append out "/libexec/blueman-"))
928 (lib (string-append out "/lib/python"
929 ,(version-major+minor
930 (package-version python))
931 "/site-packages")))
932 (for-each
933 (lambda (program)
934 (wrap-program program
935 `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH") ,lib))
936 `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH")))))
937 (append
938 (map (lambda (prog) (string-append bin prog))
939 '("adapters" "applet" "manager"
940 "sendto" "services" "tray"))
941 (map (lambda (prog) (string-append libexec prog))
942 '("mechanism" "rfcomm-watcher"))))))))))
943 (native-inputs
944 `(("cython" ,python-cython)
945 ("glib:bin" ,glib "bin")
946 ("gobject-introspection" ,gobject-introspection)
947 ("gtk+:bin" ,gtk+ "bin")
948 ("intltool" ,intltool)
949 ("pkg-config" ,pkg-config)))
950 (inputs
951 `(("bluez" ,bluez)
952 ("dbus" ,dbus)
953 ("librsvg" ,librsvg)
954 ("glib" ,glib)
955 ("gtk+" ,gtk+)
956 ("iproute2" ,iproute)
957 ("iptables" ,iptables)
958 ("net-tools" ,net-tools)
959 ("pango" ,pango)
960 ("polkit" ,polkit)
961 ("ppp" ,ppp)
962 ("pulseaudio" ,pulseaudio)
963 ("pycairo" ,python-pycairo)
964 ("pygobject" ,python-pygobject)
965 ("python" ,python-wrapper)
966 ("libappindicator" ,libappindicator)
967 ("libnm" ,network-manager)))
968 (synopsis "GTK+ Bluetooth manager")
969 (description "Blueman is a Bluetooth management utility using the Bluez
970 D-Bus backend. It is designed to be easy to use for most common Bluetooth
971 tasks.")
972 (home-page "https://github.com/blueman-project/blueman")
973 (license license:gpl3+)))
974
975 ;; The gnu.org ‘home’ for this GNU project is a directory listing with 1.6.0 as
976 ;; the latest version. The author's git repository, mentioned in the 1.6.0
977 ;; README and otherwise legit-looking, contains a proper 1.7.0 release tarball
978 ;; with many OUI updates. Use it, even though it's also several years old now.
979 (define-public macchanger
980 (package
981 (name "macchanger")
982 (version "1.7.0")
983 (source
984 (origin
985 (method url-fetch)
986 (uri (string-append "https://github.com/alobbs/macchanger/"
987 "releases/download/" version "/"
988 name "-" version ".tar.gz"))
989 (sha256
990 (base32 "1gs5m0jxyprdp00w2qkbnaqm3ilkjz0q1gqdg4nzdm8g4xy73qns"))))
991 (build-system gnu-build-system)
992 (home-page "https://www.gnu.org/software/macchanger/")
993 (synopsis "Viewing and manipulating MAC addresses of network interfaces")
994 (description "GNU MAC Changer is a utility for viewing and changing MAC
995 addresses of networking devices. New addresses may be set explicitly or
996 randomly. They can include MAC addresses of the same or other hardware vendors
997 or, more generally, MAC addresses of the same category of hardware.")
998 (license license:gpl2+)))
999
1000 (define-public miredo
1001 (package
1002 (name "miredo")
1003 (version "1.2.6")
1004 (source (origin
1005 (method url-fetch)
1006 (uri (string-append "http://www.remlab.net/files/miredo/miredo-"
1007 version ".tar.xz"))
1008 (sha256
1009 (base32
1010 "0j9ilig570snbmj48230hf7ms8kvcwi2wblycqrmhh85lksd49ps"))))
1011 (build-system gnu-build-system)
1012 (arguments
1013 '(#:configure-flags
1014 (list "--localstatedir=/var")
1015 #:phases
1016 (modify-phases %standard-phases
1017 (add-after 'unpack 'do-not-create-/run
1018 (lambda _
1019 (substitute* (find-files "src" "Makefile.*")
1020 (("^.+install_sh.+/run.+$")
1021 "\ttrue"))
1022 #t))
1023 (add-after 'unpack 'patch-iproute2
1024 (lambda* (#:key inputs #:allow-other-keys)
1025 (let* ((iproute (assoc-ref inputs "iproute"))
1026 (ip (string-append iproute "/sbin/ip")))
1027 (substitute* "misc/client-hook.iproute"
1028 (("/sbin/ip") ip))
1029 #t)))
1030 ;; The checkconf test in src/ requires network access.
1031 (add-before
1032 'check 'disable-checkconf-test
1033 (lambda _
1034 (substitute* "src/Makefile"
1035 (("^TESTS = .*") "TESTS = \n"))
1036 #t)))))
1037 (inputs
1038 `(("iproute" ,iproute)))
1039 (home-page "https://www.remlab.net/miredo/")
1040 (synopsis "Teredo IPv6 tunneling software")
1041 (description
1042 "Miredo is an implementation (client, relay, server) of the Teredo
1043 specification, which provides IPv6 Internet connectivity to IPv6 enabled hosts
1044 residing in IPv4-only networks, even when they are behind a NAT device.")
1045 (license license:gpl2+)))
1046
1047 (define-public ndisc6
1048 (package
1049 (name "ndisc6")
1050 (version "1.0.6")
1051 (source (origin
1052 (method url-fetch)
1053 (uri (string-append "https://www.remlab.net/files/ndisc6/ndisc6-"
1054 version ".tar.bz2"))
1055 (sha256
1056 (base32
1057 "1yrw8maj1646d498ax8xi0jmzk80idrc5x0913x5rwg1kc7224x7"))))
1058 (build-system gnu-build-system)
1059 (home-page "https://www.remlab.net/ndisc6/")
1060 (synopsis "IPv6 diagnostic tools")
1061 (description
1062 "NDisc6 is a collection of tools for IPv6 networking diagnostics.
1063 It includes the following programs:
1064
1065 @itemize
1066 @item @command{ndisc6}: ICMPv6 Neighbor Discovery tool.
1067 @item @command{rdisc6}: ICMPv6 Router Discovery tool.
1068 @item @command{tcptraceroute6}: IPv6 traceroute over TCP.
1069 @item @command{traceroute6}: IPv6 traceroute over UDP.
1070 @item @command{rdnssd}: Recursive DNS Servers discovery daemon.
1071 @end itemize")
1072 ;; The user can choose version 2 or 3 of the GPL, not later versions.
1073 (license (list license:gpl2 license:gpl3))))
1074
1075 (define-public parprouted
1076 (package
1077 (name "parprouted")
1078 (version "0.7")
1079 (source (origin
1080 (method url-fetch)
1081 (uri (string-append "https://www.hazard.maks.net/parprouted/"
1082 "parprouted-" version ".tar.gz"))
1083 (sha256
1084 (base32
1085 "1z6yg28i0pv20jivyy82pxb38hsryj95inhj27bs6ja1bp4l6dnn"))))
1086 (build-system gnu-build-system)
1087 (arguments
1088 `(#:tests? #f ;no tests
1089 #:phases (modify-phases %standard-phases
1090 (add-after 'unpack 'insert-absolute-iproute-reference
1091 (lambda* (#:key inputs #:allow-other-keys)
1092 (let* ((iproute (assoc-ref inputs "iproute"))
1093 (ip (string-append iproute "/sbin/ip")))
1094 (substitute* "parprouted.c"
1095 (("/sbin/ip") ip))
1096 #t)))
1097 (replace 'configure
1098 (lambda* (#:key outputs #:allow-other-keys)
1099 (let* ((out (assoc-ref outputs "out"))
1100 (sbin (string-append out "/sbin"))
1101 (man8 (string-append out "/share/man/man8")))
1102 ;; No configure script; hijack the phase to make
1103 ;; the necessary arrangements.
1104 (setenv "CC" ,(cc-for-target))
1105 (for-each mkdir-p (list sbin man8))
1106 (substitute* "Makefile"
1107 (("/usr/local/sbin") sbin)
1108 (("/usr/local/man/man8") man8))
1109 #t))))))
1110 (inputs
1111 `(("iproute" ,iproute)))
1112 (home-page "https://www.hazard.maks.net/parprouted/")
1113 (synopsis "Proxy ARP requests to other interfaces")
1114 (description
1115 "@command{parprouted} is a daemon for transparent IP (Layer@tie{}3)
1116 proxy ARP bridging. Unlike standard bridging, proxy ARP bridging can bridge
1117 Ethernet networks behind wireless nodes. Normal layer@tie{}2 bridging does
1118 not work between wireless nodes because wireless does not know about MAC
1119 addresses used in the wired Ethernet networks. This daemon can also be
1120 useful for making transparent firewalls.")
1121 (license license:gpl2)))
1122
1123 (define-public pproxy
1124 (package
1125 (name "pproxy")
1126 (version "2.7.8")
1127 (source (origin
1128 (method url-fetch)
1129 (uri (pypi-uri "pproxy" version))
1130 (sha256
1131 (base32
1132 "1j4nv72i77i2j5nl9ymzpk4m98qih3naihfrqjghrc9b7g0krdzs"))))
1133 (build-system python-build-system)
1134 (arguments
1135 (list #:phases
1136 #~(modify-phases %standard-phases
1137 (replace 'check
1138 (lambda* (#:key tests? #:allow-other-keys)
1139 (when tests?
1140 (with-directory-excursion "tests"
1141 (for-each (lambda (file)
1142 (invoke "python" file))
1143 ;; XXX: The api_ tests require network access
1144 ;; so we only run the cipher tests for now.
1145 (find-files "." "^cipher_.*\\.py$")))))))))
1146 (inputs
1147 (list python-asyncssh
1148 python-daemon
1149 python-pycryptodome
1150 python-uvloop))
1151 (home-page "https://github.com/qwj/python-proxy")
1152 (synopsis "Multi-protocol network proxy")
1153 (description
1154 "@command{pproxy} is an asynchronuous proxy server implemented with
1155 Python 3 @code{asyncio}. Among the supported protocols are HTTP, SOCKS
1156 and SSH, and it can use both TCP and UDP as transport mechanisms.")
1157 (license license:expat)))
1158
1159 (define-public socat
1160 (package
1161 (name "socat")
1162 (version "1.7.4.1")
1163 (source (origin
1164 (method url-fetch)
1165 (uri (string-append
1166 "http://www.dest-unreach.org/socat/download/socat-"
1167 version ".tar.bz2"))
1168 (sha256
1169 (base32
1170 "1sbmqqvni3ss9wyay6ik5v81kxffkra80mh4ypgj74g82iba5b1z"))))
1171 (build-system gnu-build-system)
1172 (arguments '(#:tests? #f)) ; no test suite
1173 (inputs (list openssl))
1174 (home-page "http://www.dest-unreach.org/socat/")
1175 (synopsis
1176 "Open bidirectional communication channels from the command line")
1177 (description
1178 "socat is a relay for bidirectional data transfer between two independent
1179 data channels---files, pipes, devices, sockets, etc. It can create
1180 \"listening\" sockets, named pipes, and pseudo terminals.
1181
1182 socat can be used, for instance, as TCP port forwarder, as a shell interface
1183 to UNIX sockets, IPv6 relay, for redirecting TCP oriented programs to a serial
1184 line, to logically connect serial lines on different computers, or to
1185 establish a relatively secure environment (su and chroot) for running client
1186 or server shell scripts with network connections.")
1187 (license license:gpl2)))
1188
1189 (define-public mbuffer
1190 (package
1191 (name "mbuffer")
1192 (version "20220418")
1193 (source (origin
1194 (method url-fetch)
1195 (uri (string-append
1196 "http://www.maier-komor.de/software/mbuffer/mbuffer-"
1197 version ".tgz"))
1198 (sha256
1199 (base32
1200 "1iq0lcl350r7qja7yyv911aay26d0dd8n0h33mfl84gzypwh2n3f"))))
1201 (build-system gnu-build-system)
1202 (native-inputs
1203 (list which))
1204 (inputs (list openssl))
1205 (home-page "http://www.maier-komor.de/mbuffer.html")
1206 (synopsis
1207 "Swiss army knife for data stream buffering (network aware)")
1208 (description
1209 "mbuffer is a tool for buffering data streams with a large set of features:
1210
1211 @itemize
1212 @item direct support for TCP based network targets (IPv4 and IPv6)
1213 @item ability to send to multiple targets in parallel (distribution mode)
1214 @item support for multiple volumes
1215 @item I/O rate limitation
1216 @item high/low watermark based restart criteria
1217 @item configurable buffer size
1218 @item on the fly MD5 hash calculation
1219 @item highly efficient, multi-threaded implementation
1220 @end itemize")
1221 (license license:gpl3+)))
1222
1223 (define-public tcp-wrappers
1224 (package
1225 (name "tcp-wrappers")
1226 (version "7.6")
1227 (source (origin
1228 (method url-fetch)
1229 (uri (string-append
1230 "ftp://ftp.porcupine.org/pub/security/tcp_wrappers_"
1231 version ".tar.gz"))
1232 (sha256
1233 (base32
1234 "0p9ilj4v96q32klavx0phw9va21fjp8vpk11nbh6v2ppxnnxfhwm"))
1235 (modules '((guix build utils)))
1236 (snippet
1237 ;; 'sys_errlist' & co. are gone in glibc 2.33; work around it.
1238 '(substitute* "percent_m.c"
1239 (("sys_errlist\\[errno\\]")
1240 "strerror (errno)")
1241 (("errno < sys_nerr")
1242 "(1)")
1243 (("errno >= sys_nerr")
1244 "(0)")))))
1245 (build-system gnu-build-system)
1246 (arguments
1247 `(#:phases
1248 (modify-phases %standard-phases
1249 (delete 'configure) ; there is no configure script
1250 (delete 'check) ; there are no tests
1251 (replace 'build
1252 (lambda _
1253 (chmod "." #o755)
1254 ;; Upstream doesn't generate a shared library. So we have to do it.
1255 (setenv "CC" "gcc -fno-builtin -fPIC")
1256 (substitute* "Makefile"
1257 (("^(all[^\n]*)" line) (string-append line " libwrap.so\n
1258 libwrap.so: $(LIB_OBJ)\n
1259 \tgcc -shared $^ -o $@\n")))
1260 ;; Deal with some gcc breakage.
1261 (substitute* "percent_m.c"
1262 (("extern char .sys_errlist.*;") ""))
1263 (substitute* "scaffold.c"
1264 (("extern char .malloc.*;") ""))
1265 ;; This, believe it or not, is the recommended way to build!
1266 (invoke "make" "REAL_DAEMON_DIR=/etc" "linux")))
1267 ;; There is no make install stage, so we have to do it ourselves.
1268 (replace 'install
1269 (lambda _
1270 (let ((out (assoc-ref %outputs "out"))
1271 (man-pages `("hosts_access.3"
1272 "hosts_access.5"
1273 "hosts_options.5"
1274 "tcpd.8"
1275 "tcpdchk.8"
1276 "tcpdmatch.8"))
1277 (libs `("libwrap.a"
1278 "libwrap.so"))
1279 (headers `("tcpd.h"))
1280 (bins `("safe_finger"
1281 "tcpd"
1282 "tcpdchk"
1283 "tcpdmatch"
1284 "try-from")))
1285 (for-each
1286 (lambda (x)
1287 (install-file x (string-append out "/include")))
1288 headers)
1289 (for-each
1290 (lambda (x)
1291 (install-file x (string-append out "/share/man/man"
1292 (string-take-right x 1))))
1293 man-pages)
1294 (for-each
1295 (lambda (x)
1296 (install-file x (string-append out "/lib/")))
1297 libs)
1298 (for-each
1299 (lambda (x)
1300 (install-file x (string-append out "/bin/")))
1301 bins))
1302 #t)))))
1303 (home-page "http://www.porcupine.org")
1304 (synopsis "Monitor and filter incoming requests for network services")
1305 (description "With this package you can monitor and filter incoming requests for
1306 network services. It includes a library which may be used by daemons to
1307 transparently check connection attempts against an access control list.")
1308 (license (license:non-copyleft "file://DISCLAIMER"
1309 "See the file DISCLAIMER in the distribution."))))
1310
1311 (define-public zeromq
1312 (package
1313 (name "zeromq")
1314 (version "4.3.4")
1315 (source
1316 (origin
1317 (method url-fetch)
1318 (uri (string-append "https://github.com/zeromq/libzmq/releases"
1319 "/download/v" version "/zeromq-" version ".tar.gz"))
1320 (sha256
1321 (base32 "1rf3jmi36ms8jh2g5cvi253h43l6xdfq0r7mvp95va7mi4d014y5"))))
1322 (build-system gnu-build-system)
1323 (arguments '(#:configure-flags '("--disable-static"
1324 "--enable-drafts")))
1325 (home-page "https://zeromq.org")
1326 (synopsis "Library for message-based applications")
1327 (description
1328 "The 0MQ lightweight messaging kernel is a library which extends the
1329 standard socket interfaces with features traditionally provided by specialized
1330 messaging middle-ware products. 0MQ sockets provide an abstraction of
1331 asynchronous message queues, multiple messaging patterns, message
1332 filtering (subscriptions), seamless access to multiple transport protocols and
1333 more.")
1334 (license license:lgpl3+)))
1335
1336 (define-public czmq
1337 (package
1338 (name "czmq")
1339 (version "4.2.1")
1340 (source (origin
1341 (method url-fetch)
1342 (uri (string-append
1343 "https://github.com/zeromq/" name
1344 "/releases/download/v" version
1345 "/" name "-" version ".tar.gz"))
1346 (sha256
1347 (base32
1348 "0fdclvd7fcwixp0k57ccv7d159v3slasyhvndxfn8n1a9hh0lwjx"))))
1349 (build-system gnu-build-system)
1350 (arguments
1351 '(#:configure-flags '("--enable-drafts")))
1352 (inputs
1353 (list zeromq))
1354 (home-page "https://zeromq.org")
1355 (synopsis "High-level C bindings for ØMQ")
1356 (description
1357 "czmq provides bindings for the ØMQ core API that hides the differences
1358 between different versions of ØMQ.")
1359 (license license:mpl2.0)))
1360
1361 (define-public cppzmq
1362 (package
1363 (name "cppzmq")
1364 (version "4.8.1")
1365 (source (origin
1366 (method git-fetch)
1367 (uri (git-reference
1368 (url "https://github.com/zeromq/cppzmq")
1369 (commit (string-append "v" version))))
1370 (sha256
1371 (base32
1372 "0zzq20wzk5grshxfqhqgqqfwb38w3k83r821isvyaxghsglpwks3"))
1373 (file-name (git-file-name name version))))
1374 (build-system cmake-build-system)
1375 (arguments
1376 `(#:tests? ,(not (%current-target-system)))) ; run unless cross-compiling
1377 (native-inputs
1378 (list pkg-config))
1379 (inputs
1380 (list catch-framework2 zeromq))
1381 (home-page "https://zeromq.org")
1382 (synopsis "C++ bindings for the ØMQ messaging library")
1383 (description
1384 "This package provides header-only C++ bindings for ØMQ. The header
1385 files contain direct mappings of the abstractions provided by the ØMQ C API.")
1386 (license license:expat)))
1387
1388 (define-public libnatpmp
1389 (package
1390 (name "libnatpmp")
1391 (version "20150609")
1392 (source (origin
1393 (method url-fetch)
1394 (uri (string-append
1395 "http://miniupnp.free.fr/files/"
1396 name "-" version ".tar.gz"))
1397 (sha256
1398 (base32
1399 "1c1n8n7mp0amsd6vkz32n8zj3vnsckv308bb7na0dg0r8969rap1"))))
1400 (build-system gnu-build-system)
1401 (arguments
1402 `(#:phases
1403 (modify-phases %standard-phases
1404 (delete 'configure)
1405 (delete 'check)) ; no tests
1406 #:make-flags
1407 (let* ((target ,(%current-target-system))
1408 (gcc (if target
1409 (string-append target "-gcc")
1410 "gcc")))
1411 (list
1412 (string-append "CC=" gcc)
1413 (string-append "INSTALLPREFIX=" (assoc-ref %outputs "out"))
1414 (string-append "LDFLAGS=-Wl,-rpath=" %output "/lib")))))
1415 (home-page "http://miniupnp.free.fr/libnatpmp.html")
1416 (synopsis "C library implementing NAT-PMP")
1417 (description
1418 "@code{libnatpmp} is a portable and asynchronous implementation of
1419 the Network Address Translation - Port Mapping Protocol (NAT-PMP)
1420 written in the C programming language.")
1421 (license license:bsd-3)))
1422
1423 (define-public librdkafka
1424 (package
1425 (name "librdkafka")
1426 (version "1.4.2")
1427 (source (origin
1428 (method git-fetch)
1429 (uri (git-reference
1430 (url "https://github.com/edenhill/librdkafka")
1431 (commit (string-append "v" version))))
1432 (file-name (git-file-name name version))
1433 (sha256
1434 (base32
1435 "05mgrdzacn9kdpr68r5j0cvsvl54s52glnsc1ww9rcxx6p7hq1ly"))))
1436 (build-system gnu-build-system)
1437 (arguments
1438 '(#:phases
1439 (modify-phases %standard-phases
1440 (replace 'configure
1441 ;; its custom configure script doesn't understand 'CONFIG_SHELL'.
1442 (lambda* (#:key outputs #:allow-other-keys)
1443 (let ((out (assoc-ref outputs "out")))
1444 ;; librdkafka++.so lacks RUNPATH for librdkafka.so
1445 (setenv "LDFLAGS"
1446 (string-append "-Wl,-rpath=" out "/lib"))
1447 (invoke "./configure"
1448 (string-append "--prefix=" out))))))))
1449 (native-inputs
1450 `(("python" ,python-wrapper)))
1451 (propagated-inputs
1452 (list zlib)) ; in the Libs.private field of rdkafka.pc
1453 (home-page "https://github.com/edenhill/librdkafka")
1454 (synopsis "Apache Kafka C/C++ client library")
1455 (description
1456 "librdkafka is a C library implementation of the Apache Kafka protocol,
1457 containing both Producer and Consumer support.")
1458 (license license:bsd-2)))
1459
1460 (define-public libndp
1461 (package
1462 (name "libndp")
1463 (version "1.8")
1464 (source (origin
1465 (method url-fetch)
1466 (uri (string-append "https://libndp.org/files/"
1467 "libndp-" version ".tar.gz"))
1468 (sha256
1469 (base32
1470 "0ay0n0d85254zdmv8znmn399gfiqpk6ga0jwdwa7ylpbw9pbdzw8"))))
1471 (build-system gnu-build-system)
1472 (home-page "https://libndp.org/")
1473 (synopsis "Library for Neighbor Discovery Protocol")
1474 (description
1475 "libndp contains a library which provides a wrapper for IPv6 Neighbor
1476 Discovery Protocol. It also provides a tool named ndptool for sending and
1477 receiving NDP messages.")
1478 (license license:lgpl2.1+)))
1479
1480 (define-public ethtool
1481 (package
1482 (name "ethtool")
1483 (version "5.15")
1484 (source (origin
1485 (method url-fetch)
1486 (uri (string-append "mirror://kernel.org/software/network/"
1487 "ethtool/ethtool-" version ".tar.xz"))
1488 (sha256
1489 (base32
1490 "0v8i592vwjypf111w0lfvaxdwhzybp6w600g28m9rm490c8xcvv8"))))
1491 (build-system gnu-build-system)
1492 (native-inputs
1493 (list pkg-config))
1494 (inputs
1495 (list libmnl))
1496 (home-page "https://www.kernel.org/pub/software/network/ethtool/")
1497 (synopsis "Display or change Ethernet device settings")
1498 (description
1499 "ethtool can be used to query and change settings such as speed,
1500 auto-negotiation and checksum offload on many network devices, especially
1501 Ethernet devices.")
1502 (license license:gpl2)))
1503
1504 (define-public ifstatus
1505 (package
1506 (name "ifstatus")
1507 (version "1.1.0")
1508 (source (origin
1509 (method url-fetch)
1510 (uri (string-append "mirror://sourceforge/ifstatus/ifstatus/"
1511 "ifstatus%20v" version "/ifstatus-v"
1512 version ".tar.gz"))
1513 (sha256
1514 (base32
1515 "045cbsq9ps32j24v8y5hpyqxnqn9mpaf3mgvirlhgpqyb9jsia0c"))
1516 (modules '((guix build utils)))
1517 (snippet
1518 '(begin
1519 (substitute* "Main.h"
1520 (("#include <stdio.h>")
1521 "#include <stdio.h>\n#include <stdlib.h>"))
1522 #t))))
1523 (build-system gnu-build-system)
1524 (arguments
1525 '(#:tests? #f ; no "check" target
1526 #:phases
1527 (modify-phases %standard-phases
1528 (delete 'configure) ; no configure script
1529 (replace 'install
1530 (lambda* (#:key outputs #:allow-other-keys)
1531 (let* ((out (assoc-ref outputs "out"))
1532 (bin (string-append out "/bin")))
1533 (mkdir-p bin)
1534 (copy-file "ifstatus"
1535 (string-append bin "/ifstatus")))
1536 #t)))))
1537 (inputs (list ncurses))
1538 (home-page "http://ifstatus.sourceforge.net/graphic/index.html")
1539 (synopsis "Text based network interface status monitor")
1540 (description
1541 "IFStatus is a simple, easy-to-use program for displaying commonly
1542 needed/wanted real-time traffic statistics of multiple network
1543 interfaces, with a simple and efficient view on the command line. It is
1544 intended as a substitute for the PPPStatus and EthStatus projects.")
1545 (license license:gpl2+)))
1546
1547 (define-public iputils
1548 (package
1549 (name "iputils")
1550 (version "20190709")
1551 (home-page "https://github.com/iputils/iputils")
1552 (source (origin
1553 (method git-fetch)
1554 (uri (git-reference (url home-page)
1555 (commit (string-append "s" version))))
1556 (file-name (git-file-name name version))
1557 (patches (search-patches "iputils-libcap-compat.patch"))
1558 (sha256
1559 (base32
1560 "04bp4af15adp79ipxmiakfp0ij6hx5qam266flzbr94pr8z8l693"))))
1561 (build-system meson-build-system)
1562 (arguments
1563 `(#:configure-flags '("-DBUILD_RARPD=true")
1564 #:phases
1565 (modify-phases %standard-phases
1566 (add-after 'unpack 'fix-docbook-url
1567 (lambda* (#:key inputs #:allow-other-keys)
1568 (let* ((docbook-xsl (assoc-ref inputs "docbook-xsl"))
1569 (uri (string-append docbook-xsl "/xml/xsl/docbook-xsl-"
1570 ,(package-version docbook-xsl))))
1571 (for-each
1572 (lambda (file)
1573 (substitute* file
1574 (("http://docbook\\.sourceforge\\.net/release/xsl-ns/current")
1575 uri)))
1576 (cons "doc/meson.build"
1577 (find-files "doc" "\\.xsl$")))
1578 #t))))))
1579 (native-inputs
1580 `(("gettext" ,gettext-minimal)
1581 ("pkg-config" ,pkg-config)
1582 ("docbook-xsl" ,docbook-xsl)
1583 ("docbook-xml" ,docbook-xml-5)
1584 ("libxml2" ,libxml2) ;for XML_CATALOG_FILES
1585 ("xsltproc" ,libxslt)))
1586 (inputs
1587 (list libcap libidn2 openssl))
1588 (synopsis "Collection of network utilities")
1589 (description
1590 "This package contains a variety of tools for dealing with network
1591 configuration, troubleshooting, or servers. Utilities included are:
1592
1593 @itemize @bullet
1594 @item @command{arping}: Ping hosts using the @dfn{Address Resolution Protocol}.
1595 @item @command{clockdiff}: Compute time difference between network hosts
1596 using ICMP TSTAMP messages.
1597 @item @command{ninfod}: Daemon that responds to IPv6 Node Information Queries.
1598 @item @command{ping}: Use ICMP ECHO messages to measure round-trip delays
1599 and packet loss across network paths.
1600 @item @command{rarpd}: Answer RARP requests from clients.
1601 @item @command{rdisc}: Populate network routing tables with information from
1602 the ICMP router discovery protocol.
1603 @item @command{tftpd}: Trivial file transfer protocol server.
1604 @item @command{tracepath}: Trace network path to an IPv4 or IPv6 address and
1605 discover MTU along the way.
1606 @end itemize")
1607 ;; The various utilities are covered by different licenses, see LICENSE
1608 ;; for details.
1609 (license (list license:gpl2+ ;arping, rarpd, tracepath
1610 license:bsd-3 ;clockdiff, ninfod, ping, tftpd
1611 (license:non-copyleft
1612 "https://spdx.org/licenses/Rdisc.html"
1613 "Sun Microsystems license, see rdisc.c for details")))))
1614
1615 (define-public nload
1616 (package
1617 (name "nload")
1618 (version "0.7.4")
1619 (source (origin
1620 (method url-fetch)
1621 (uri (string-append "mirror://sourceforge/nload/nload/" version
1622 "/nload-" version ".tar.gz"))
1623 (sha256
1624 (base32
1625 "1rb9skch2kgqzigf19x8bzk211jdfjfdkrcvaqyj89jy2pkm3h61"))))
1626 (build-system gnu-build-system)
1627 (inputs (list ncurses))
1628 (home-page "http://www.roland-riegel.de/nload/")
1629 (synopsis "Realtime console network usage monitor")
1630 (description
1631 "Nload is a console application which monitors network traffic and
1632 bandwidth usage in real time. It visualizes the in- and outgoing traffic using
1633 two graphs, and provides additional info like total amount of transferred data
1634 and min/max network usage.")
1635 (license license:gpl2+)))
1636
1637 (define-public iodine
1638 (package
1639 (name "iodine")
1640 (version "0.7.0")
1641 (source (origin
1642 (method url-fetch)
1643 (uri (string-append "http://code.kryo.se/" name "/"
1644 name "-" version ".tar.gz"))
1645 (sha256
1646 (base32
1647 "0gh17kcxxi37k65zm4gqsvbk3aw7yphcs3c02pn1c4s2y6n40axd"))))
1648 (build-system gnu-build-system)
1649 (arguments
1650 `(#:phases
1651 (modify-phases %standard-phases
1652 (delete 'configure)
1653 (add-before 'build 'fix-ifconfig-path
1654 ;; This package works only with the net-tools version of ifconfig.
1655 (lambda* (#:key inputs #:allow-other-keys)
1656 (substitute* "src/tun.c"
1657 (("PATH=[^ ]* ")
1658 (string-append (assoc-ref inputs "net-tools") "/bin/")))
1659 #t))
1660 (add-before 'check 'delete-failing-tests
1661 ;; Avoid https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=802105.
1662 (lambda _
1663 (substitute* "tests/common.c"
1664 (("tcase_add_test\\(tc, \
1665 test_parse_format_ipv(4(|_listen_all|_mapped_ipv6)|6)\\);")
1666 ""))
1667 #t)))
1668 #:make-flags (list ,(string-append "CC=" (cc-for-target))
1669 (string-append "prefix=" (assoc-ref %outputs "out")))
1670 #:test-target "test"))
1671 (inputs (list net-tools zlib))
1672 (native-inputs (list check pkg-config))
1673 (home-page "https://code.kryo.se/iodine/")
1674 (synopsis "Tunnel IPv4 data through a DNS server")
1675 (description "Iodine tunnels IPv4 data through a DNS server. This
1676 can be useful in different situations where internet access is firewalled, but
1677 DNS queries are allowed. The bandwidth is asymmetrical, with limited upstream
1678 and up to 1 Mbit/s downstream.")
1679 ;; src/md5.[ch] is released under the zlib license
1680 (license (list license:isc license:zlib))))
1681
1682 (define-public whois
1683 (package
1684 (name "whois")
1685 (version "5.5.11")
1686 (source
1687 (origin
1688 (method git-fetch)
1689 (uri (git-reference
1690 (url "https://github.com/rfc1036/whois")
1691 (commit (string-append "v" version))))
1692 (file-name (git-file-name name version))
1693 (sha256
1694 (base32 "0wys0aixzq6mzvg7p6jb0d5rkkg23pjcgcsx86p7hjidxdvnbwzr"))))
1695 (build-system gnu-build-system)
1696 (arguments
1697 `(#:tests? #f ; no test suite
1698 #:make-flags (list (string-append "CC=" ,(cc-for-target))
1699 (string-append "PKG_CONFIG=" ,(pkg-config-for-target))
1700 (string-append "prefix=" (assoc-ref %outputs "out")))
1701 #:phases
1702 (modify-phases %standard-phases
1703 (delete 'configure) ; no configure script
1704 (add-before 'build 'setenv
1705 (lambda _
1706 (setenv "HAVE_ICONV" "1")
1707 #t)))))
1708 (inputs
1709 (list libidn2))
1710 (native-inputs
1711 `(("gettext" ,gettext-minimal)
1712 ("perl" ,perl)
1713 ("pkg-config" ,pkg-config)))
1714 (synopsis "Intelligent client for the WHOIS directory service")
1715 (description
1716 "whois searches for an object in a @dfn{WHOIS} (RFC 3912) database.
1717 It is commonly used to look up the registered users or assignees of an Internet
1718 resource, such as a domain name, an IP address block, or an autonomous system.
1719 It can automatically select the appropriate server for most queries.
1720
1721 For historical reasons, this package also includes @command{mkpasswd}, which
1722 encrypts passwords using @code{crypt(3)} and is unrelated to the Expect command
1723 of the same name.")
1724 (home-page "https://github.com/rfc1036/whois")
1725 (license license:gpl2+)))
1726
1727 (define-public wireshark
1728 (package
1729 (name "wireshark")
1730 (version "3.6.2")
1731 (source
1732 (origin
1733 (method url-fetch)
1734 (uri (string-append "https://www.wireshark.org/download/src/wireshark-"
1735 version ".tar.xz"))
1736 (sha256
1737 (base32 "03n34jh4318y3q14jclxfxi4r7b9l393w9fw9bq57ydff9aim42x"))))
1738 (build-system cmake-build-system)
1739 (arguments
1740 `(#:phases
1741 (modify-phases %standard-phases
1742 (add-after 'unpack 'remove-failing-test
1743 ;; Skip test suite failing with "Program reassemble_test is not
1744 ;; available" and alike errors. Also skip test suite failing with
1745 ;; "AssertionError: Program extcap/sdjournal is not available"
1746 ;; error.'
1747 (lambda _
1748 (substitute* "CMakeLists.txt"
1749 (("suite_unittests" all) (string-append "# " all))
1750 (("suite_extcaps" all) (string-append "# " all))))))
1751 ;; Build process chokes during `validate-runpath' phase.
1752 ;;
1753 ;; Errors are like the following:
1754 ;; "/gnu/store/...wireshark-3.0.0/lib/wireshark/plugins/3.0/epan/ethercat.so:
1755 ;; error: depends on 'libwireshark.so.12', which cannot be found in
1756 ;; RUNPATH". That is, "/gnu/store/...wireshark-3.0.0./lib" doesn't
1757 ;; belong to RUNPATH.
1758 ;;
1759 ;; That’s not a problem in practice because "ethercat.so" is a plugin,
1760 ;; so it’s dlopen’d by a process that already provides "libwireshark".
1761 ;; For now, we disable this phase.
1762 #:validate-runpath? #f))
1763 (inputs
1764 (list c-ares
1765 glib
1766 gnutls
1767 brotli
1768 libcap
1769 libgcrypt
1770 libnl
1771 libpcap
1772 libssh
1773 libxml2
1774 lz4
1775 lua-5.2 ;Lua 5.3 unsupported
1776 mit-krb5
1777 `(,nghttp2 "lib")
1778 minizip
1779 qtbase-5
1780 qtmultimedia-5
1781 qtsvg-5
1782 sbc
1783 snappy
1784 zlib
1785 `(,zstd "lib")))
1786 (native-inputs
1787 (list bison
1788 doxygen
1789 flex
1790 gettext-minimal
1791 perl
1792 pkg-config
1793 python-wrapper
1794 qttools-5))
1795 (synopsis "Network traffic analyzer")
1796 (description "Wireshark is a network protocol analyzer, or @dfn{packet
1797 sniffer}, that lets you capture and interactively browse the contents of
1798 network frames.")
1799 (home-page "https://www.wireshark.org/")
1800 (license license:gpl2+)))
1801
1802 (define-public fping
1803 (package
1804 (name "fping")
1805 (version "5.1")
1806 (source
1807 (origin
1808 (method url-fetch)
1809 (uri (string-append "https://fping.org/dist/fping-"
1810 version ".tar.gz"))
1811 (sha256
1812 (base32 "1zh9fkyn0bixgn77v9z6ayv446nqwx960hmly9m68xix0s62dr8y"))))
1813 (build-system gnu-build-system)
1814 (arguments '(#:configure-flags '("--enable-ipv6")))
1815 (home-page "https://fping.org/")
1816 (synopsis "Send ICMP ECHO_REQUEST packets to network hosts")
1817 (description
1818 "fping is a ping-like program which uses @acronym{ICMP, Internet Control
1819 Message Protocol} echo requests to determine if a target host is responding.
1820
1821 @command{fping} differs from @command{ping} in that you can specify any number
1822 of targets on the command line, or specify a file containing the lists of
1823 targets to ping. Instead of sending to one target until it times out or
1824 replies, fping will send out a ping packet and move on to the next target in a
1825 round-robin fashion.")
1826 (license license:expat)))
1827
1828 (define-public gandi.cli
1829 (package
1830 (name "gandi.cli")
1831 (version "1.6")
1832 (source
1833 (origin
1834 (method url-fetch)
1835 (uri (pypi-uri name version))
1836 (sha256
1837 (base32 "1h36jahbp7273wn3yd747kbiwjc0bm3sja67bcxdsd54ln0vyndg"))))
1838 (build-system python-build-system)
1839 (arguments
1840 `(#:phases
1841 (modify-phases %standard-phases
1842 (add-after 'unpack 'embed-store-file-names
1843 (lambda _
1844 (substitute* (list "gandi/cli/modules/cert.py"
1845 "gandi/cli/tests/commands/test_certificate.py")
1846 (("openssl") (which "openssl")))
1847 #t))
1848 (add-after 'install 'install-documentation
1849 ;; The included man page may be outdated but we install it anyway,
1850 ;; since it's mentioned in 'gandi --help' and better than nothing.
1851 (lambda* (#:key outputs #:allow-other-keys)
1852 (let* ((out (assoc-ref outputs "out"))
1853 (man1 (string-append out "/share/man/man1")))
1854 (mkdir-p man1)
1855 (with-output-to-file (string-append man1 "/gandi.1")
1856 (lambda _
1857 (invoke "rst2man.py" "gandicli.man.rst")))
1858 #t))))))
1859 (native-inputs
1860 (list python-docutils ; for rst2man.py
1861 python-pytest python-pytest-cov python-tox))
1862 (propagated-inputs
1863 (list openssh)) ; used by gandi/cli/modules/iass.py
1864 (inputs
1865 (list openssl python-click-7 python-ipy python-pyyaml python-requests))
1866 (home-page "https://cli.gandi.net")
1867 (synopsis "Command-line interface to the Gandi.net Web API")
1868 (description
1869 "This package provides a command-line client (@command{gandi}) to buy,
1870 manage, and delete Internet resources from Gandi.net such as domain names,
1871 virtual machines, and certificates.")
1872 (license license:gpl3+)))
1873
1874 (define-public go-netns
1875 (let ((commit "13995c7128ccc8e51e9a6bd2b551020a27180abd")
1876 (revision "1"))
1877 (package
1878 (name "go-netns")
1879 (version (git-version "0.0.0" revision commit))
1880 (source (origin
1881 (method git-fetch)
1882 (uri (git-reference
1883 (url "https://github.com/vishvananda/netns")
1884 (commit commit)))
1885 (file-name (git-file-name name version))
1886 (sha256
1887 (base32
1888 "1zk6w8158qi4niva5rijchbv9ixgmijsgqshh54wdaav4xrhjshn"))))
1889 (build-system go-build-system)
1890 (arguments
1891 `(#:import-path "github.com/vishvananda/netns"
1892 #:tests? #f)) ;tests require root privileges
1893 (home-page "https://github.com/vishvananda/netns")
1894 (synopsis "Simple network namespace handling for Go")
1895 (description "The netns package provides a simple interface for
1896 handling network namespaces in Go.")
1897 (license license:asl2.0))))
1898
1899 (define-public go-sctp
1900 ;; docker-libnetwork-cmd-proxy requires this exact commit.
1901 ;; This commit is mentioned in docker-libnetwork-cmd-proxy's vendor.conf.
1902 (let ((commit "f2269e66cdee387bd321445d5d300893449805be")
1903 (revision "3"))
1904 (package
1905 (name "go-sctp")
1906 (version (git-version "0.0.0" revision commit))
1907 (source (origin
1908 (method git-fetch)
1909 (uri (git-reference
1910 (url "https://github.com/ishidawataru/sctp")
1911 (commit commit)))
1912 (file-name (git-file-name name version))
1913 (sha256
1914 (base32
1915 "04463rnn9y9psp11ac5di6wrwxlhymw5h9hfhhhnxqwla90ikp0g"))))
1916 (build-system go-build-system)
1917 (arguments
1918 `(#:tests? #f ; Test suite is flakey.
1919 #:import-path "github.com/ishidawataru/sctp"))
1920 (home-page "https://github.com/ishidawataru/sctp")
1921 (synopsis "SCTP library for the Go programming language")
1922 (description "This library provides methods for using the stream control
1923 transmission protocol (SCTP) in a Go application.")
1924 (license license:asl2.0))))
1925
1926 (define-public httping
1927 (package
1928 (name "httping")
1929 (version "2.5")
1930 (source
1931 (origin
1932 (method url-fetch)
1933 (uri (string-append "https://www.vanheusden.com/httping/httping-"
1934 version ".tgz"))
1935 (sha256
1936 (base32
1937 "1y7sbgkhgadmd93x1zafqc4yp26ssiv16ni5bbi9vmvvdl55m29y"))))
1938 (build-system gnu-build-system)
1939 (native-inputs
1940 `(("gettext" ,gettext-minimal)))
1941 (inputs
1942 (list fftw ncurses openssl))
1943 (arguments
1944 `(#:make-flags (list ,(string-append "CC=" (cc-for-target))
1945 (string-append "DESTDIR=" (assoc-ref %outputs "out"))
1946 "PREFIX=")
1947 #:tests? #f)) ; no tests
1948 (home-page "https://www.vanheusden.com/httping/")
1949 (synopsis "Web server latency and throughput monitor")
1950 (description
1951 "httping measures how long it takes to connect to a web server, send an
1952 HTTP(S) request, and receive the reply headers. It is somewhat similar to
1953 @command{ping}, but can be used even in cases where ICMP traffic is blocked
1954 by firewalls or when you want to monitor the response time of the actual web
1955 application stack itself.")
1956 (license license:gpl2))) ; with permission to link with OpenSSL
1957
1958 (define-public httpstat
1959 (package
1960 (name "httpstat")
1961 (version "1.3.1")
1962 (source
1963 (origin
1964 (method git-fetch)
1965 (uri (git-reference
1966 (url "https://github.com/reorx/httpstat")
1967 (commit version)))
1968 (file-name (git-file-name name version))
1969 (sha256
1970 (base32 "0cw8299a080m42slsimz31xs0gjnh833gpbj2dsr4hkcinrn4iyd"))))
1971 (build-system python-build-system)
1972 (inputs (list curl))
1973 (arguments
1974 '(#:phases
1975 (modify-phases %standard-phases
1976 (add-before 'build 'fix-curl-path
1977 (lambda* (#:key inputs #:allow-other-keys)
1978 (substitute* "httpstat.py"
1979 (("ENV_CURL_BIN.get\\('curl'\\)")
1980 (string-append "ENV_CURL_BIN.get('"
1981 (assoc-ref inputs "curl")
1982 "/bin/curl')"))
1983 ;; "curl -w time_*" units seems to have
1984 ;; changed from seconds to nanoseconds.
1985 (("d\\[k\\] \\* 1000") "d[k] / 1000"))
1986 #t)))))
1987 (home-page "https://github.com/reorx/httpstat")
1988 (synopsis "Visualize curl statistics")
1989 (description
1990 "@command{httpstat} is a tool to visualize statistics from the
1991 @command{curl} HTTP client. It acts as a wrapper for @command{curl} and
1992 prints timing information for each step of the HTTP request (DNS lookup,
1993 TCP connection, TLS handshake and so on) in the terminal.")
1994 (license license:expat)))
1995
1996 (define-public squid
1997 (package
1998 (name "squid")
1999 (version "4.17")
2000 (source
2001 (origin
2002 (method url-fetch)
2003 (uri (string-append "http://www.squid-cache.org/Versions/v4/squid-"
2004 version ".tar.xz"))
2005 (sha256
2006 (base32 "060lwghn6q982bay11ia38c86kd8w6mjgy68n58v31kwik08m4nb"))))
2007 (build-system gnu-build-system)
2008 (arguments
2009 '(#:configure-flags
2010 ;; disable -march=native in build for reproducibility; see
2011 ;; https://wiki.squid-cache.org/KnowledgeBase/IllegalInstructionError
2012 (list "--disable-arch-native")
2013 #:phases
2014 (modify-phases %standard-phases
2015 (add-before 'build 'fix-true-path
2016 (lambda* (#:key inputs #:allow-other-keys)
2017 (substitute* "test-suite/testheaders.sh"
2018 (("/bin/true")
2019 (search-input-file inputs "/bin/true"))))))))
2020 (inputs
2021 (list perl
2022 openldap
2023 linux-pam
2024 libcap
2025 cyrus-sasl
2026 expat
2027 libxml2
2028 openssl))
2029 (native-inputs
2030 (list cppunit pkg-config))
2031 (synopsis "Web caching proxy")
2032 (description "Squid is a caching proxy for the Web supporting HTTP, HTTPS,
2033 FTP, and more. It reduces bandwidth and improves response times by caching and
2034 reusing frequently-requested web pages.")
2035 (home-page "http://www.squid-cache.org/")
2036 (license license:gpl2+)))
2037
2038 (define-public bwm-ng
2039 (package
2040 (name "bwm-ng")
2041 (version "0.6.3")
2042 (source
2043 (origin
2044 (method git-fetch)
2045 (uri (git-reference
2046 (url "https://github.com/vgropp/bwm-ng")
2047 (commit (string-append "v" version))))
2048 (file-name (git-file-name name version))
2049 (sha256
2050 (base32 "1gpp2l3w479h1w5skjra5xy0gxd24kvmk6i4psbkafnv2399la4k"))))
2051 (build-system gnu-build-system)
2052 (arguments
2053 `(#:phases
2054 (modify-phases %standard-phases
2055 (add-after 'unpack 'disable-premature-./configure
2056 (lambda _
2057 (substitute* "autogen.sh"
2058 (("\\$srcdir/configure")
2059 "true"))
2060 #t)))))
2061 (native-inputs
2062 (list autoconf automake))
2063 (inputs
2064 (list ncurses))
2065 (synopsis "Console based live network and disk I/O bandwidth monitor")
2066 (description "Bandwidth Monitor NG is a small and simple console based
2067 live network and disk I/O bandwidth monitor.")
2068 (home-page "https://www.gropp.org/?id=projects&sub=bwm-ng")
2069 (license license:gpl2)))
2070
2071 (define-public aircrack-ng
2072 (package
2073 (name "aircrack-ng")
2074 (version "1.7")
2075 (source
2076 (origin
2077 (method url-fetch)
2078 (uri (string-append "https://download.aircrack-ng.org/aircrack-ng-"
2079 version ".tar.gz"))
2080 (sha256
2081 (base32 "1hsq1gwmafka4bahs6rc8p98yi542h9a502h64bjlygpr3ih99q5"))))
2082 (build-system gnu-build-system)
2083 (native-inputs
2084 (list autoconf automake libtool pkg-config which
2085 ;; For tests.
2086 expect))
2087 (inputs
2088 (list `(,hwloc "lib") ; speed boost on SMP machines
2089 libgcrypt
2090 libnl
2091 libpcap
2092 ethtool
2093 pcre
2094 sqlite
2095 zlib))
2096 (arguments
2097 `(#:configure-flags
2098 (list "CFLAGS=-fcommon"
2099 "--with-experimental=yes" ; build wesside-ng, etc.
2100 "--with-gcrypt") ; openssl's the default
2101 #:phases (modify-phases %standard-phases
2102 (add-before 'bootstrap 'patch-evalrev
2103 (lambda _
2104 ;; Called by ./autogen.sh below, before the default
2105 ;; ‘patch-shebangs’ phase has had a chance to run.
2106 (substitute* "evalrev"
2107 (("/bin/sh")
2108 (which "sh")))))
2109 (add-after 'build 'absolutize-tools
2110 (lambda* (#:key inputs #:allow-other-keys)
2111 (let ((ethtool (search-input-file inputs
2112 "/sbin/ethtool")))
2113 (substitute* "scripts/airmon-ng"
2114 (("ethtool ")
2115 (string-append ethtool " ")))))))))
2116 (home-page "https://www.aircrack-ng.org")
2117 (synopsis "Assess WiFi network security")
2118 (description
2119 "Aircrack-ng is a complete suite of tools to assess WiFi network
2120 security. It focuses on different areas of WiFi security: monitoring,
2121 attacking, testing, and cracking. All tools are command-line driven, which
2122 allows for heavy scripting.")
2123 (license (list license:gpl2+ license:bsd-3))))
2124
2125 (define-public pixiewps
2126 (package
2127 (name "pixiewps")
2128 (version "1.4.2")
2129 (source (origin
2130 (method url-fetch)
2131 (uri (string-append
2132 "https://github.com/wiire-a/pixiewps/releases/"
2133 "download/v" version "/" name "-" version ".tar.xz"))
2134 (sha256
2135 (base32
2136 "07nym6bqml0k9v29vnj003nrgnwrywgjvnljb7cdpsvnwilhbp64"))))
2137 (build-system gnu-build-system)
2138 (arguments
2139 `(#:make-flags
2140 (list ,(string-append "CC=" (cc-for-target))
2141 (string-append "PREFIX=" (assoc-ref %outputs "out")))
2142 #:phases
2143 (modify-phases %standard-phases
2144 (delete 'configure)) ; no configure script
2145 #:tests? #f)) ; there are no tests
2146 (home-page "https://github.com/wiire-a/pixiewps/")
2147 (synopsis "Offline brute-force tool for Wi-Fi Protected Setup")
2148 (description "Pixiewps implements the pixie-dust attack to brute
2149 force the Wi-Fi Protected Setup (WPS) PIN by exploiting the low or
2150 non-existing entropy of some access points.")
2151 (license license:gpl3+)))
2152
2153 (define-public reaver
2154 (package
2155 (name "reaver")
2156 (version "1.6.6")
2157 (source (origin
2158 (method url-fetch)
2159 (uri (string-append
2160 "https://github.com/t6x/reaver-wps-fork-t6x/releases/"
2161 "download/v" version "/reaver-" version ".tar.xz"))
2162 (sha256
2163 (base32
2164 "00k7mc81ifv0wma7k4v18mj498badbw5yls6c28qin3d1gda0ag3"))))
2165 (build-system gnu-build-system)
2166 (arguments
2167 `(#:configure-flags
2168 ;; Save session files to current directory instead of /var.
2169 (list "--enable-savetocurrent"
2170 "--localstatedir=/tmp/dummy") ; prevent creating /var during install
2171 #:phases
2172 (modify-phases %standard-phases
2173 (add-before 'configure 'change-directory
2174 (lambda _
2175 (chdir "src")
2176 #t))
2177 (add-after 'install 'install-doc
2178 (lambda* (#:key outputs #:allow-other-keys)
2179 (chdir "../docs")
2180 (let* ((out (assoc-ref outputs "out"))
2181 (doc (string-append out "/share/doc/" ,name "-" ,version))
2182 (man1 (string-append out "/share/man/man1")))
2183 (for-each (lambda (file) (install-file file doc))
2184 (find-files "." "README.*"))
2185 (install-file "reaver.1" man1)
2186 #t))))
2187 #:tests? #f)) ; there are no tests
2188 (inputs
2189 (list libpcap))
2190 (propagated-inputs
2191 (list aircrack-ng pixiewps))
2192 (home-page "https://github.com/t6x/reaver-wps-fork-t6x/")
2193 (synopsis "Attack tool for Wi-Fi Protected Setup")
2194 (description "Reaver performs a brute force attack against an access
2195 point's Wi-Fi Protected Setup (WPS) PIN. Once the PIN is found, the WPA
2196 passphrase can be recovered and the AP's wireless settings can be
2197 reconfigured.")
2198 (license license:gpl2+)))
2199
2200 (define-public perl-danga-socket
2201 (package
2202 (name "perl-danga-socket")
2203 (version "1.62")
2204 (source
2205 (origin
2206 (method url-fetch)
2207 (uri (string-append "mirror://cpan/authors/id/N/NM/NML/"
2208 "Danga-Socket-" version ".tar.gz"))
2209 (sha256
2210 (base32 "0x4bvirmf0kphks19jwgva00zz73zx344218dfaiv8gigrw3yg4m"))))
2211 (build-system perl-build-system)
2212 (native-inputs
2213 (list perl-test-tcp))
2214 (propagated-inputs
2215 (list perl-sys-syscall))
2216 (home-page "https://metacpan.org/release/Danga-Socket")
2217 (synopsis "Event loop and event-driven async socket base class")
2218 (description
2219 "Danga::Socket is an abstract base class for objects backed by a socket
2220 which provides the basic framework for event-driven asynchronous IO, designed
2221 to be fast. Danga::Socket is both a base class for objects, and an event
2222 loop.")
2223 (license license:perl-license)))
2224
2225 (define-public perl-data-validate-ip
2226 (package
2227 (name "perl-data-validate-ip")
2228 (version "0.30")
2229 (source
2230 (origin
2231 (method url-fetch)
2232 (uri (string-append
2233 "mirror://cpan/authors/id/D/DR/DROLSKY/Data-Validate-IP-"
2234 version ".tar.gz"))
2235 (sha256
2236 (base32 "074adrlvkiahj1fdc9nvb95dpfyjzm2jzhi90m8xaw4bw5ipcbzy"))))
2237 (build-system perl-build-system)
2238 (native-inputs
2239 (list perl-test-requires))
2240 (propagated-inputs
2241 (list perl-netaddr-ip))
2242 (home-page "https://metacpan.org/release/Data-Validate-IP")
2243 (synopsis "IPv4 and IPv6 validation methods")
2244 (description
2245 "This module provides several IP address validation subroutines that both
2246 validate and untaint their input. This includes both basic validation
2247 (@code{is_ipv4()} and @code{is_ipv6()}) and special cases like checking whether
2248 an address belongs to a specific network or whether an address is public or
2249 private (reserved).")
2250 (license license:perl-license)))
2251
2252 (define-public perl-net-dns
2253 (package
2254 (name "perl-net-dns")
2255 (version "1.31")
2256 (source
2257 (origin
2258 (method url-fetch)
2259 (uri
2260 (list
2261 (string-append "https://www.net-dns.org/download/Net-DNS-"
2262 version ".tar.gz")
2263 (string-append "mirror://cpan/authors/id/N/NL/NLNETLABS/Net-DNS-"
2264 version ".tar.gz")))
2265 (sha256
2266 (base32 "05f6rzvvmm6xd0p100k5y9kczdzqgala09ra8bccc18n6y74l0h0"))))
2267 (build-system perl-build-system)
2268 (inputs
2269 (list perl-digest-hmac))
2270 (home-page "https://www.net-dns.org/")
2271 (synopsis
2272 "Perl Interface to the Domain Name System")
2273 (description "Net::DNS is the Perl Interface to the Domain Name System.")
2274 (license license:x11)))
2275
2276 (define-public perl-socket6
2277 (package
2278 (name "perl-socket6")
2279 (version "0.29")
2280 (source
2281 (origin
2282 (method url-fetch)
2283 (uri (string-append
2284 "mirror://cpan/authors/id/U/UM/UMEMOTO/Socket6-"
2285 version
2286 ".tar.gz"))
2287 (sha256
2288 (base32
2289 "054izici8klfxs8hr5rljib28plijpsfymy99xbzdp047bx1b2a6"))))
2290 (build-system perl-build-system)
2291 (arguments
2292 `(#:phases
2293 (modify-phases %standard-phases
2294 (replace 'configure
2295 (lambda* (#:key outputs #:allow-other-keys)
2296 (let* ((out (assoc-ref outputs "out"))
2297 (args `("Makefile.PL"
2298 ,(string-append "PREFIX=" out)
2299 "INSTALLDIRS=site")))
2300 (setenv "CONFIG_SHELL" (which "sh"))
2301 (apply invoke "perl" args)))))))
2302 (home-page "https://metacpan.org/release/Socket6")
2303 (synopsis
2304 "IPv6 related part of the C socket.h defines and structure manipulators for Perl")
2305 (description "Socket6 binds the IPv6 related part of the C socket header
2306 definitions and structure manipulators for Perl.")
2307 (license license:bsd-3)))
2308
2309 (define-public perl-net-dns-resolver-programmable
2310 (package
2311 (name "perl-net-dns-resolver-programmable")
2312 (version "0.003")
2313 (source
2314 (origin
2315 (method url-fetch)
2316 (uri (string-append
2317 "mirror://cpan/authors/id/J/JM/JMEHNLE/net-dns-resolver-programmable/"
2318 "Net-DNS-Resolver-Programmable-v" version ".tar.gz"))
2319 (sha256
2320 (base32
2321 "1v3nl2kaj4fs55n1617n53q8sa3mir06898vpy1rq98zjih24h4d"))
2322 (patches
2323 (search-patches "perl-net-dns-resolver-programmable-fix.patch"))))
2324 (build-system perl-build-system)
2325 (native-inputs
2326 (list perl-module-build))
2327 (inputs (list perl-net-dns))
2328 (home-page
2329 "https://metacpan.org/release/Net-DNS-Resolver-Programmable")
2330 (synopsis
2331 "Programmable DNS resolver class for offline emulation of DNS")
2332 (description "Net::DNS::Resolver::Programmable is a programmable DNS resolver for
2333 offline emulation of DNS.")
2334 (license license:perl-license)))
2335
2336 (define-public perl-net-dns-resolver-mock
2337 (package
2338 (name "perl-net-dns-resolver-mock")
2339 (version "1.20171219")
2340 (source (origin
2341 (method url-fetch)
2342 (uri (string-append
2343 "mirror://cpan/authors/id/M/MB/MBRADSHAW/"
2344 "Net-DNS-Resolver-Mock-" version ".tar.gz"))
2345 (sha256
2346 (base32
2347 "0m3rxpkv1b9121srvbqkrgzg4m8mnydiydqv34in1i1ixwrl6jn9"))))
2348 (build-system perl-build-system)
2349 (inputs
2350 (list perl-net-dns))
2351 (home-page "https://metacpan.org/release/Net-DNS-Resolver-Mock")
2352 (synopsis "Mock DNS Resolver object for testing")
2353 (description
2354 "Net::DNS::Resolver::Mock is a subclass of Net::DNS::Resolver, but returns
2355 static data from any provided DNS zone file instead of querying the network.
2356 It is intended primarily for use in testing.")
2357 (license license:perl-license)))
2358
2359 (define-public perl-netaddr-ip
2360 (package
2361 (name "perl-netaddr-ip")
2362 (version "4.079")
2363 (source
2364 (origin
2365 (method url-fetch)
2366 (uri (string-append
2367 "mirror://cpan/authors/id/M/MI/MIKER/NetAddr-IP-"
2368 version
2369 ".tar.gz"))
2370 (sha256
2371 (base32
2372 "1rx0dinrz9fk9qcg4rwqq5n1dm3xv2arymixpclcv2q2nzgq4npc"))))
2373 (build-system perl-build-system)
2374 (arguments
2375 `(#:phases
2376 (modify-phases %standard-phases
2377 (replace 'configure
2378 (lambda* (#:key outputs #:allow-other-keys)
2379 (let* ((out (assoc-ref outputs "out"))
2380 (args `("Makefile.PL"
2381 ,(string-append "PREFIX=" out)
2382 "INSTALLDIRS=site")))
2383 (setenv "CONFIG_SHELL" (which "sh"))
2384 (apply invoke "perl" args)))))))
2385 (home-page
2386 "https://metacpan.org/release/NetAddr-IP")
2387 (synopsis
2388 "Manages IPv4 and IPv6 addresses and subnets")
2389 (description "NetAddr::IP manages IPv4 and IPv6 addresses and subsets.")
2390 (license license:perl-license)))
2391
2392 (define-public perl-net-patricia
2393 (package
2394 (name "perl-net-patricia")
2395 (version "1.22")
2396 (source
2397 (origin
2398 (method url-fetch)
2399 (uri (string-append
2400 "mirror://cpan/authors/id/G/GR/GRUBER/Net-Patricia-"
2401 version
2402 ".tar.gz"))
2403 (sha256
2404 (base32
2405 "0ln5f57vc8388kyh9vhx2infrdzfhbpgyby74h1qsnhwds95m0vh"))))
2406 (build-system perl-build-system)
2407 (arguments
2408 '(#:phases
2409 (modify-phases %standard-phases
2410 (add-after 'unpack 'dont-link-with-nsl ; Borrowed from Debian.
2411 (lambda _
2412 (substitute* "Makefile.PL"
2413 (("-lnsl") ""))
2414 #t)))))
2415 (inputs
2416 (list perl-net-cidr-lite perl-socket6))
2417 (home-page
2418 "https://metacpan.org/release/Net-Patricia")
2419 (synopsis
2420 "Patricia Trie Perl module for fast IP address lookups")
2421 (description
2422 "Net::Patricia does IP address lookups quickly in Perl.")
2423 ;; The bindings are licensed under GPL2 or later.
2424 ;; libpatricia is licensed under 2-clause BSD.
2425 (license (list license:gpl2+ license:bsd-2))))
2426
2427 (define-public perl-net-cidr-lite
2428 (package
2429 (name "perl-net-cidr-lite")
2430 (version "0.22")
2431 (source
2432 (origin
2433 (method url-fetch)
2434 (uri (string-append
2435 "mirror://cpan/authors/id/S/ST/STIGTSP/Net-CIDR-Lite-"
2436 version
2437 ".tar.gz"))
2438 (sha256
2439 (base32 "05w57db2lx4djb4vixzdr6qgrzyzkk047nl812g7nq8s6k5xh5s3"))))
2440 (build-system perl-build-system)
2441 (home-page "https://metacpan.org/release/Net-CIDR-Lite")
2442 (synopsis "Perl extension for merging IPv4 or IPv6 CIDR addresses")
2443 (description "Net::CIDR::Lite merges IPv4 or IPv6 CIDR addresses.")
2444 (license license:gpl1+)))
2445
2446 (define-public perl-io-socket-inet6
2447 (package
2448 (name "perl-io-socket-inet6")
2449 (version "2.72")
2450 (source
2451 (origin
2452 (method url-fetch)
2453 (uri (string-append
2454 "mirror://cpan/authors/id/S/SH/SHLOMIF/IO-Socket-INET6-"
2455 version
2456 ".tar.gz"))
2457 (sha256
2458 (base32
2459 "1fqypz6qa5rw2d5y2zq7f49frwra0aln13nhq5gi514j2zx21q45"))))
2460 (build-system perl-build-system)
2461 (native-inputs
2462 (list perl-module-build perl-test-pod perl-test-pod-coverage))
2463 (propagated-inputs (list perl-socket6))
2464 (arguments `(;; Need network socket API
2465 #:tests? #f))
2466 (home-page
2467 "https://metacpan.org/release/IO-Socket-INET6")
2468 (synopsis
2469 "Perl object interface for AF_INET/AF_INET6 domain sockets")
2470 (description "IO::Socket::INET6 is an interface for AF_INET/AF_INET6 domain
2471 sockets in Perl.")
2472 (license license:perl-license)))
2473
2474 (define-public libproxy
2475 (package
2476 (name "libproxy")
2477 (version "0.4.17")
2478 (source (origin
2479 (method url-fetch)
2480 (uri (string-append "https://github.com/libproxy/libproxy/"
2481 "releases/download/" version "/libproxy-"
2482 version ".tar.xz"))
2483 (sha256
2484 (base32
2485 "01cbgz6lc3v59sldqk96l1281kp2qxnsa2qwlf2ikvjlyr1gi2dw"))))
2486 (build-system cmake-build-system)
2487 (native-inputs
2488 (list pkg-config))
2489 (inputs
2490 (list dbus zlib))
2491 (arguments
2492 `(#:phases
2493 (modify-phases %standard-phases
2494 (replace 'check
2495 (lambda* (#:key tests? #:allow-other-keys)
2496 (when tests?
2497 (invoke "ctest" "-E" "url-test")))))))
2498 (synopsis "Library providing automatic proxy configuration management")
2499 (description "Libproxy handles the details of HTTP/HTTPS proxy
2500 configuration for applications across all scenarios. Applications using
2501 libproxy only have to specify which proxy to use.")
2502 (home-page "https://libproxy.github.io/libproxy")
2503 (license license:lgpl2.1+)))
2504
2505 (define-public proxychains-ng
2506 (package
2507 (name "proxychains-ng")
2508 (version "4.16")
2509 (source
2510 (origin
2511 (method url-fetch)
2512 (uri (string-append "http://ftp.barfooze.de/pub/sabotage/tarballs/"
2513 "proxychains-ng-" version ".tar.xz"))
2514 (sha256
2515 (base32 "04k80jbv1wcr7ccsa0qyly33syw275kvkvzyihwwqmsqk4yria9p"))))
2516 (build-system gnu-build-system)
2517 (arguments
2518 `(#:tests? #f ; there are no tests
2519 #:phases
2520 (modify-phases %standard-phases
2521 (add-after 'unpack 'fix-configure-script
2522 (lambda _
2523 ;; The configure script is very intolerant to unknown arguments,
2524 ;; such as "CONFIG_SHELL".
2525 (substitute* "configure"
2526 (("\\*\\) break ;;" line)
2527 (string-append "[A-Z]*) shift ;;\n"
2528 line)))))
2529 (add-before 'configure 'set-up-environment
2530 (lambda _
2531 (setenv "CC" ,(cc-for-target)))))))
2532 (synopsis "Redirect any TCP connection through a proxy or proxy chain")
2533 (description "Proxychains-ng is a preloader which hooks calls to sockets
2534 in dynamically linked programs and redirects them through one or more SOCKS or
2535 HTTP proxies.")
2536 (home-page "https://github.com/rofl0r/proxychains-ng")
2537 (license license:gpl2+)))
2538
2539 (define-public enet
2540 (package
2541 (name "enet")
2542 (version "1.3.17")
2543 (source
2544 (origin
2545 (method url-fetch)
2546 (uri (string-append "http://enet.bespin.org/download/"
2547 "enet-" version ".tar.gz"))
2548 (sha256
2549 (base32 "1p6f9mby86af6cs7pv6h48032ip9g32c05cb7d9mimam8lchz3x3"))))
2550 (build-system gnu-build-system)
2551 (native-inputs
2552 (list pkg-config))
2553 (synopsis "Network communication layer on top of UDP")
2554 (description
2555 "ENet's purpose is to provide a relatively thin, simple and robust network
2556 communication layer on top of UDP. The primary feature it provides is optional
2557 reliable, in-order delivery of packets. ENet omits certain higher level
2558 networking features such as authentication, server discovery, encryption, or
2559 other similar tasks that are particularly application specific so that the
2560 library remains flexible, portable, and easily embeddable.")
2561 (home-page "http://enet.bespin.org")
2562 (license license:expat)))
2563
2564 (define-public sslh
2565 (package
2566 (name "sslh")
2567 (version "1.21c")
2568 (source
2569 (origin
2570 (method git-fetch)
2571 (uri (git-reference
2572 (url "https://github.com/yrutschle/sslh")
2573 (commit (string-append "v" version))))
2574 (file-name (git-file-name name version))
2575 (sha256
2576 (base32 "19h32dn0076p3s7dn35qi5yp2xvnxw9sqphppmn72vyb8caxvw1z"))))
2577 (build-system gnu-build-system)
2578 (native-inputs
2579 (list ;; Test dependencies.
2580 lcov
2581 perl
2582 perl-conf-libconfig
2583 perl-io-socket-inet6
2584 perl-socket6
2585 psmisc)) ; for ‘killall’
2586 (inputs
2587 (list libcap libconfig pcre tcp-wrappers))
2588 (arguments
2589 `(#:phases
2590 (modify-phases %standard-phases
2591 (delete 'configure) ; no configure script
2592 (add-before 'check 'fix-tests
2593 (lambda _
2594 (substitute* "./t"
2595 (("\"/tmp") "$ENV{\"TMPDIR\"} . \"")
2596 ;; The Guix build environment lacks ‘ip6-localhost’.
2597 (("ip6-localhost") "localhost"))
2598 #t))
2599 ;; Many of these files are mentioned in the man page. Install them.
2600 (add-after 'install 'install-documentation
2601 (lambda* (#:key outputs #:allow-other-keys)
2602 (let* ((out (assoc-ref outputs "out"))
2603 (doc (string-append out "/share/doc/sslh")))
2604 (install-file "README.md" doc)
2605 (for-each
2606 (lambda (file)
2607 (install-file file (string-append doc "/examples")))
2608 (append (find-files "." "\\.cfg")
2609 (find-files "scripts"))))
2610 #t)))
2611 #:make-flags (list ,(string-append "CC=" (cc-for-target))
2612 "USELIBCAP=1"
2613 "USELIBWRAP=1"
2614 (string-append "PREFIX=" (assoc-ref %outputs "out")))
2615 #:test-target "test"))
2616 (home-page "https://www.rutschle.net/tech/sslh/README.html")
2617 (synopsis "Applicative network protocol demultiplexer")
2618 (description
2619 "sslh is a network protocol demultiplexer. It acts like a switchboard,
2620 accepting connections from clients on one port and forwarding them to different
2621 servers based on the contents of the first received data packet. Detection of
2622 common protocols like HTTP(S), SSL, SSH, OpenVPN, tinc, and XMPP is already
2623 implemented, but any other protocol that matches a regular expression can be
2624 added. sslh's name comes from its original application of serving both SSH and
2625 HTTPS on port 443, allowing SSH connections from inside corporate firewalls
2626 that block port 22.")
2627 (license (list license:bsd-2 ; tls.[ch]
2628 license:gpl2+)))) ; everything else
2629
2630 (define-public iperf
2631 (package
2632 (name "iperf")
2633 (version "3.11")
2634 (source
2635 (origin
2636 (method git-fetch)
2637 (uri (git-reference
2638 (url "https://github.com/esnet/iperf")
2639 (commit version)))
2640 (file-name (git-file-name name version))
2641 (sha256
2642 (base32 "064sb8f9jxi5ii43swd73c0mm50lvk51v7awhgbj6p129c1a4nn5"))))
2643 (build-system gnu-build-system)
2644 (arguments
2645 `(#:configure-flags
2646 (list "--disable-static")))
2647 (synopsis "TCP, UDP and SCTP bandwidth measurement tool")
2648 (description
2649 "iPerf is a tool to measure achievable bandwidth on IP networks. It
2650 supports tuning of various parameters related to timing, buffers and
2651 protocols (TCP, UDP, SCTP with IPv4 and IPv6). For each test it reports
2652 the bandwidth, loss, and other parameters.")
2653 (home-page "https://software.es.net/iperf/")
2654 (license (list license:bsd-3 ; Main distribution.
2655 license:ncsa ; src/{units,iperf_locale,tcp_window_size}.c
2656 license:expat ; src/{cjson,net}.[ch]
2657 license:public-domain)))) ; src/portable_endian.h
2658
2659 (define-public nethogs
2660 (package
2661 (name "nethogs")
2662 (version "0.8.7")
2663 (source
2664 (origin
2665 (method git-fetch)
2666 (uri (git-reference
2667 (url "https://github.com/raboof/nethogs")
2668 (commit (string-append "v" version))))
2669 (hash
2670 (content-hash
2671 (base32 "10shdwvfj90lp2fxz9260342a1c2n1jbw058qy5pyq5kh3xwr9b8")
2672 sha256))
2673 (file-name (git-file-name name version))))
2674 (build-system gnu-build-system)
2675 (inputs
2676 (list libpcap ncurses))
2677 (arguments
2678 `(#:make-flags `(,,(string-append "CC=" (cc-for-target))
2679 ,(string-append "PREFIX=" %output)
2680 ,(string-append "VERSION=" ,version))
2681 #:phases
2682 (modify-phases %standard-phases
2683 (delete 'configure)))) ; no ./configure script.
2684 (home-page "https://github.com/raboof/nethogs")
2685 (synopsis "Per-process bandwidth monitor")
2686 (description "NetHogs is a small 'net top' tool for Linux. Instead of
2687 breaking the traffic down per protocol or per subnet, like most tools do, it
2688 groups bandwidth by process.
2689
2690 NetHogs does not rely on a special kernel module to be loaded. If there's
2691 suddenly a lot of network traffic, you can fire up NetHogs and immediately see
2692 which PID is causing this. This makes it easy to identify programs that have
2693 gone wild and are suddenly taking up your bandwidth.")
2694 (license license:gpl2+)))
2695
2696 (define-public nzbget
2697 (package
2698 (name "nzbget")
2699 (version "21.1")
2700 (source
2701 (origin
2702 (method url-fetch)
2703 (uri (string-append "https://github.com/nzbget/nzbget/releases"
2704 "/download/v" version
2705 "/nzbget-" version "-src.tar.gz"))
2706 (sha256
2707 (base32 "09900x1k0yf4yi2cc0k093advvadyhrkm8rnd8nszhhdp2zc33sf"))))
2708 (arguments
2709 `(#:configure-flags
2710 (list
2711 (string-append "--with-libcurses-includes="
2712 (assoc-ref %build-inputs "ncurses") "/include")
2713 (string-append "--with-libcurses-libraries="
2714 (assoc-ref %build-inputs "ncurses") "/lib")
2715 (string-append "--with-tlslib=GnuTLS"))))
2716 (build-system gnu-build-system)
2717 (inputs (list gnutls libxml2 ncurses zlib))
2718 (native-inputs (list pkg-config))
2719 (home-page "https://github.com/nzbget/nzbget")
2720 (synopsis "Usenet binary file downloader")
2721 (description
2722 "NZBGet is a binary newsgrabber, which downloads files from Usenet based
2723 on information given in @code{nzb} files. NZBGet can be used in standalone
2724 and in server/client modes. In standalone mode, you pass NZBGet @command{nzb}
2725 files as command-line parameters and it downloads them and exits. NZBGet also
2726 contains a Web interface. Its server can be controlled through remote
2727 procedure calls (RPCs).")
2728 (license license:gpl2+)))
2729
2730 (define-public openvswitch
2731 (package
2732 (name "openvswitch")
2733 (version "2.16.1")
2734 (source (origin
2735 (method url-fetch)
2736 (uri (string-append
2737 "https://www.openvswitch.org/releases/openvswitch-"
2738 version ".tar.gz"))
2739 (sha256
2740 (base32
2741 "1x0k0pw6jykrfgb8rq56bp2ghxd433d55pmr8mxy9gbzw1nc1vbi"))))
2742 (build-system gnu-build-system)
2743 (arguments
2744 '(#:configure-flags
2745 '("--enable-shared"
2746 "--disable-static" ; XXX still installs libopenvswitchavx512.a
2747 "--localstatedir=/var"
2748 "--with-dbdir=/var/lib/openvswitch")
2749 #:phases
2750 (modify-phases %standard-phases
2751 (add-after 'unpack 'use-absolute-/bin/sh
2752 (lambda* (#:key inputs #:allow-other-keys)
2753 (let* ((bash (assoc-ref inputs "bash-minimal")))
2754 (substitute* "ovsdb/ovsdb-server.c"
2755 (("/bin/sh") (string-append bash "/bin/sh"))))))
2756 (add-before 'check 'adjust-tests
2757 (lambda* (#:key inputs #:allow-other-keys)
2758 (let* ((bash (assoc-ref inputs "bash-minimal"))
2759 (/bin/sh (string-append bash "/bin/sh")))
2760 (with-fluids ((%default-port-encoding "ISO-8859-1"))
2761 (substitute* (find-files "tests" ".*(run|testsuite)$")
2762 (("#! /bin/sh")
2763 (string-append "#! " /bin/sh))
2764
2765 ;; The tests use 'kill -0' to check whether a test has
2766 ;; completed, but it does not work in the build container
2767 ;; because zombies are not reaped automatically (PID 1 is
2768 ;; the builder script). Change to something that handles
2769 ;; undead processes.
2770 (("kill -0")
2771 "kill-0")))
2772 (mkdir "/tmp/bin")
2773 (call-with-output-file "/tmp/bin/kill-0"
2774 (lambda (port)
2775 (format port "#!~a
2776 ps --no-header -p $1 -o state= | grep -qv '^Z$'"
2777 /bin/sh)))
2778 (chmod "/tmp/bin/kill-0" #o755)
2779 (setenv "PATH"
2780 (string-append "/tmp/bin:" (getenv "PATH"))))))
2781 (replace 'install
2782 (lambda _
2783 (invoke "make"
2784 ;; Don't try to create directories under /var.
2785 "RUNDIR=/tmp"
2786 "PKIDIR=/tmp"
2787 "LOGDIR=/tmp"
2788 "DBDIR=/tmp"
2789 "install"))))))
2790 (native-inputs
2791 `(("perl" ,perl)
2792 ("pkg-config" ,pkg-config)
2793 ("python" ,python-wrapper)
2794 ;; for testing
2795 ("bash" ,bash) ;for 'compgen'
2796 ("procps" ,procps)
2797 ("util-linux" ,util-linux)))
2798 (inputs
2799 (list bash-minimal libcap-ng openssl))
2800 (synopsis "Virtual network switch")
2801 (home-page "https://www.openvswitch.org/")
2802 (description
2803 "Open vSwitch is a multilayer virtual switch. It is designed to enable
2804 massive network automation through programmatic extension, while still
2805 supporting standard management interfaces and protocols (e.g. NetFlow, sFlow,
2806 IPFIX, RSPAN, CLI, LACP, 802.1ag).")
2807 (license ; see debian/copyright for detail
2808 (list license:lgpl2.1 ; xenserver and utilities/bugtool
2809 license:gpl2 ; datapath
2810 license:bsd-2 license:bsd-3
2811 license:asl2.0)))) ; all other
2812
2813 (define-public python-ipy
2814 (package
2815 (name "python-ipy")
2816 (version "1.00")
2817 (source (origin
2818 (method url-fetch)
2819 (uri (pypi-uri "IPy" version))
2820 (sha256
2821 (base32
2822 "08d6kcacj67mvh0b6y765ipccy6gi4w2ndd4v1l3im2qm1cgcarg"))))
2823 (build-system python-build-system)
2824 (home-page "https://github.com/autocracy/python-ipy/")
2825 (synopsis "Python class and tools for handling IP addresses and networks")
2826 (description "The @code{IP} class allows a comfortable parsing and
2827 handling for most notations in use for IPv4 and IPv6 addresses and
2828 networks.")
2829 (license license:bsd-3)))
2830
2831 (define-public speedtest-cli
2832 (package
2833 (name "speedtest-cli")
2834 (version "2.1.3")
2835 (source
2836 (origin
2837 (method git-fetch)
2838 (uri (git-reference
2839 (url "https://github.com/sivel/speedtest-cli")
2840 (commit (string-append "v" version))))
2841 (file-name (git-file-name name version))
2842 (sha256
2843 (base32 "10fazl4kwf41mk7pnwpfms16n0ii0kg9pf8r3mz9xwnl9y04mv9x"))))
2844 (build-system python-build-system)
2845 (home-page "https://github.com/sivel/speedtest-cli")
2846 (synopsis "Internet bandwidth tester")
2847 (description
2848 "Command line interface for testing internet bandwidth using
2849 speedtest.net.")
2850 (license license:asl2.0)))
2851
2852 (define-public tftp-hpa
2853 (package
2854 (name "tftp-hpa")
2855 (version "5.2")
2856 (source (origin
2857 (method url-fetch)
2858 (uri (string-append "mirror://kernel.org/software/"
2859 "network/tftp/tftp-hpa/tftp-hpa-" version
2860 ".tar.xz"))
2861 (sha256
2862 (base32
2863 "12vidchglhyc20znq5wdsbhi9mqg90jnl7qr9qs8hbvaz4fkdvmg"))))
2864 (build-system gnu-build-system)
2865 (arguments
2866 (list #:tests? #f ; no test target
2867 #:configure-flags
2868 #~(list "CFLAGS=-fcommon"))) ; XXX fix 5.2 build with GCC 10
2869 (synopsis "HPA's tftp client")
2870 (description
2871 "This is a tftp client derived from OpenBSD tftp with some extra options
2872 added and bugs fixed. The source includes readline support but it is not
2873 enabled due to license conflicts between the BSD advertising clause and the GPL.")
2874 (home-page "https://git.kernel.org/cgit/network/tftp/tftp-hpa.git/about/")
2875 ;; Some source files are distributed under a 3-clause BSD license, and
2876 ;; others under a 4-clause BSD license. Refer to the files in the source
2877 ;; distribution for clarification.
2878 (license (list license:bsd-3 license:bsd-4))))
2879
2880 (define-public spiped
2881 (package
2882 (name "spiped")
2883 (version "1.6.1")
2884 (source (origin
2885 (method url-fetch)
2886 (uri (string-append "https://www.tarsnap.com/spiped/spiped-"
2887 version ".tgz"))
2888 (sha256
2889 (base32
2890 "04rpnc53whfky7pp2m9h35gwzwn6788pnl6c1qd576mpknbqjw4d"))))
2891 (build-system gnu-build-system)
2892 (arguments
2893 `(#:test-target "test"
2894 #:make-flags (let* ((out (assoc-ref %outputs "out"))
2895 (bindir (string-append out "/bin"))
2896 (man1dir (string-append out "/share/man/man1")))
2897 (list ,(string-append "CC=" (cc-for-target)) ; It tries to invoke `c99`.
2898 (string-append "BINDIR=" bindir)
2899 (string-append "MAN1DIR=" man1dir)))
2900 #:phases
2901 (modify-phases %standard-phases
2902 (add-after 'unpack 'patch-command-invocations
2903 (lambda _
2904 (substitute* '("Makefile"
2905 "libcperciva/cpusupport/Build/cpusupport.sh"
2906 "libcperciva/POSIX/posix-cflags.sh"
2907 "libcperciva/POSIX/posix-l.sh")
2908 (("command -p") ""))
2909 #t))
2910 (delete 'configure) ; No ./configure script.
2911 (add-after 'install 'install-more-docs
2912 (lambda* (#:key outputs #:allow-other-keys)
2913 (let* ((out (assoc-ref %outputs "out"))
2914 (misc (string-append out "/share/doc/spiped")))
2915 (install-file "DESIGN.md" misc)
2916 #t))))))
2917 (native-inputs
2918 (list procps)) ; `ps` is used by the test suite.
2919 (inputs
2920 (list openssl))
2921 (home-page "https://www.tarsnap.com/spiped.html")
2922 (synopsis "Create secure pipes between sockets")
2923 (description "Spiped (pronounced \"ess-pipe-dee\") is a utility for creating
2924 symmetrically encrypted and authenticated pipes between socket addresses, so
2925 that one may connect to one address (e.g., a UNIX socket on localhost) and
2926 transparently have a connection established to another address (e.g., a UNIX
2927 socket on a different system). This is similar to 'ssh -L' functionality, but
2928 does not use SSH and requires a pre-shared symmetric key.")
2929 (license license:bsd-2)))
2930
2931 (define-public quagga
2932 (package
2933 (name "quagga")
2934 (version "1.2.4")
2935 (source (origin
2936 (method url-fetch)
2937 ;; Use archived sources; see <http://issues.guix.gnu.org/47123>.
2938 (uri (string-append "https://fossies.org/linux/misc/"
2939 "quagga-" version ".tar.gz"))
2940 (sha256
2941 (base32
2942 "1lsksqxij5f1llqn86pkygrf5672kvrqn1kvxghi169hqf1c0r73"))
2943 (patches
2944 (search-patches "quagga-reproducible-build.patch"))))
2945 (build-system gnu-build-system)
2946 (native-inputs (list pkg-config perl dejagnu))
2947 (inputs (list readline c-ares))
2948 (synopsis "Routing Software Suite")
2949 (description "Quagga is a routing software suite, providing implementations
2950 of OSPFv2, OSPFv3, RIP v1 and v2, RIPng and BGP-4 for Unix platforms.
2951
2952 The Quagga architecture consists of a core daemon, @command{zebra}, which
2953 acts as an abstraction layer to the underlying Unix kernel and presents the
2954 Zserv API over a Unix or TCP stream to Quagga clients. It is these Zserv
2955 clients which typically implement a routing protocol and communicate routing
2956 updates to the zebra daemon.")
2957 (home-page "https://www.nongnu.org/quagga/")
2958 (license license:gpl2+)))
2959
2960 (define-public thc-ipv6
2961 (let ((revision "0")
2962 (commit "4bb72573e0950ce6f8ca2800a10748477020029e"))
2963 (package
2964 (name "thc-ipv6")
2965 (version (git-version "3.4" revision commit))
2966 (source (origin
2967 (method git-fetch)
2968 (uri (git-reference
2969 (url "https://github.com/vanhauser-thc/thc-ipv6")
2970 (commit commit)))
2971 (file-name (git-file-name name version))
2972 (sha256
2973 (base32
2974 "1x5i6vbsddqc2yks7r1a2fw2fk16qxvd6hpzh1lykjfpkal8fdir"))))
2975 (build-system gnu-build-system)
2976 (arguments
2977 `(#:make-flags (list (string-append "PREFIX=" (assoc-ref %outputs "out")))
2978 #:tests? #f ; No test suite.
2979 #:phases
2980 (modify-phases %standard-phases
2981 (add-after 'unpack 'use-source-date-epoch-in-manpages
2982 ;; For reproducible builds
2983 (lambda _
2984 (substitute* "Makefile"
2985 (("date --iso-8601")
2986 "date --iso-8601 --utc --date=@$(SOURCE_DATE_EPOCH)"))))
2987 (delete 'configure) ; No ./configure script.
2988 (add-before 'build 'patch-paths
2989 (lambda _
2990 (substitute* "Makefile"
2991 (("/bin/echo") "echo"))
2992 #t))
2993 (add-after 'install 'install-more-docs
2994 (lambda* (#:key outputs #:allow-other-keys)
2995 (let* ((out (assoc-ref outputs "out"))
2996 (doc (string-append out "/share/thc-ipv6/doc")))
2997 (install-file "README" doc)
2998 (install-file "HOWTO-INJECT" doc)
2999 #t))))))
3000 ;; TODO Add libnetfilter-queue once packaged.
3001 (inputs
3002 (list libpcap openssl perl))
3003 (home-page "https://github.com/vanhauser-thc/thc-ipv6")
3004 (synopsis "IPv6 security research toolkit")
3005 (description "The THC IPv6 Toolkit provides command-line tools and a library
3006 for researching IPv6 implementations and deployments. It requires Linux 2.6 or
3007 newer and only works on Ethernet network interfaces.")
3008 ;; AGPL 3 with exception for linking with OpenSSL. See the 'LICENSE' file in
3009 ;; the source distribution for more information.
3010 (license license:agpl3))))
3011
3012 (define-public bmon
3013 (package
3014 (name "bmon")
3015 (version "4.0")
3016 (source
3017 (origin
3018 (method url-fetch)
3019 (uri (string-append "https://github.com/tgraf/bmon/releases/download/v"
3020 version "/bmon-" version ".tar.gz"))
3021 (sha256
3022 (base32
3023 "0ylzriv4pwh76344abzl1w219x188gshbycbna35gsyfp09c7z82"))))
3024 (build-system gnu-build-system)
3025 (inputs
3026 (list libconfuse libnl ncurses))
3027 (native-inputs
3028 (list pkg-config))
3029 (synopsis "Bandwidth monitor")
3030 (description "bmon is a monitoring and debugging tool to capture
3031 networking-related statistics and prepare them visually in a human-friendly
3032 way. It features various output methods including an interactive curses user
3033 interface and a programmable text output for scripting.")
3034 (home-page "https://github.com/tgraf/bmon")
3035 ;; README.md mentions both the 2-clause BSD and expat licenses, but all
3036 ;; the source files only have expat license headers. Upstream has been
3037 ;; contacted for clarification: https://github.com/tgraf/bmon/issues/59
3038 ;; Update the license field when upstream responds.
3039 (license (list license:bsd-2
3040 license:expat))))
3041
3042 (define-public libnet
3043 (package
3044 (name "libnet")
3045 (version "1.2")
3046 (source
3047 (origin
3048 (method url-fetch)
3049 (uri (string-append "https://github.com/libnet/libnet/releases/download"
3050 "/v" version "/libnet-" version ".tar.gz"))
3051 (sha256
3052 (base32
3053 "19ys9vxk6fg70yzzdxsphfr0rwzgxxhr9b3ykhpg7rfray0qd96a"))))
3054 (build-system gnu-build-system)
3055 (arguments
3056 `(#:phases
3057 (modify-phases %standard-phases
3058 (add-before 'build 'build-doc
3059 (lambda* (#:key make-flags #:allow-other-keys)
3060 (apply invoke "make" "-C" "doc" "doc"
3061 make-flags))))))
3062 (native-inputs
3063 (list ;; To build the documentation, Doxygen and Perl is required.
3064 doxygen perl))
3065 (home-page "https://github.com/libnet/libnet")
3066 (synopsis "Framework for low-level network packet construction")
3067 (description
3068 "Libnet provides a fairly portable framework for network packet
3069 construction and injection. It features portable packet creation interfaces
3070 at the IP layer and link layer, as well as a host of supplementary
3071 functionality. Using libnet, quick and simple packet assembly applications
3072 can be whipped up with little effort.")
3073 (license license:bsd-2)))
3074
3075 (define-public mtr
3076 (package
3077 (name "mtr")
3078 (version "0.95")
3079 (source
3080 (origin
3081 (method url-fetch)
3082 (uri (string-append "ftp://ftp.bitwizard.nl/mtr/"
3083 "mtr-" version ".tar.gz"))
3084 (sha256
3085 (base32 "0haanralbvd12pvkyihgkmx9ld74dnzm1s7mzparfandl416ibff"))))
3086 (build-system gnu-build-system)
3087 (inputs
3088 (list libcap ncurses))
3089 (arguments
3090 `(#:tests? #f)) ; tests require network access
3091 (home-page "https://www.bitwizard.nl/mtr/")
3092 (synopsis "Network diagnostic tool")
3093 (description
3094 "@acronym{mtr, My TraceRoute} combines the functionality of the
3095 @command{traceroute} and @command{ping} programs in a single network diagnostic
3096 tool. @command{mtr} can use several network protocols to detect intermediate
3097 routers (or @dfn{hops}) between the local host and a user-specified destination.
3098 It then continually measures the response time and packet loss at each hop, and
3099 displays the results in real time.")
3100 (license license:gpl2+)))
3101
3102 (define-public amule
3103 (package
3104 (name "amule")
3105 (version "2.3.3")
3106 (source (origin
3107 (method git-fetch)
3108 (uri (git-reference
3109 (url "https://github.com/amule-project/amule")
3110 (commit version)))
3111 (file-name (git-file-name name version))
3112 (sha256
3113 (base32
3114 "1nm4vxgmisn1b6l3drmz0q04x067j2i8lw5rnf0acaapwlp8qwvi"))))
3115 (build-system gnu-build-system)
3116 (arguments
3117 `(#:phases
3118 (modify-phases %standard-phases
3119 (delete 'bootstrap) ; bootstrap phase runs too early.
3120 (add-after 'patch-source-shebangs 'autogen
3121 (lambda _
3122 (invoke "sh" "autogen.sh")
3123 #t)))
3124 #:configure-flags
3125 '("--disable-rpath"
3126 "--enable-wxcas"
3127 "--enable-cas"
3128 "--enable-alc"
3129 "--enable-alcc"
3130 "--enable-xas"
3131 "--enable-amulecmd"
3132 "--enable-geoip"
3133 "--enable-ccache"
3134 "--enable-nls"
3135 "--enable-optimize"
3136 "--enable-amule-gui"
3137 "--enable-amule-daemon"
3138 "--enable-webserver"
3139 "--with-denoise-level=0")))
3140 (native-inputs
3141 (list autoconf automake gettext-minimal perl))
3142 (inputs
3143 (list zlib crypto++ libpng wxwidgets-gtk2))
3144 (home-page "https://amule.org/")
3145 (synopsis "Peer-to-peer client for the eD2K and Kademlia networks")
3146 (description
3147 "aMule is an eMule-like client for the eD2k and Kademlia peer-to-peer
3148 file sharing networks. It includes a graphical user interface (GUI), a daemon
3149 allowing you to run a client with no graphical interface, and a Web GUI for
3150 remote access. The @command{amulecmd} command allows you to control aMule
3151 remotely.")
3152 (license license:gpl2+)))
3153
3154 (define-public zyre
3155 (package
3156 (name "zyre")
3157 (version "2.0.1")
3158 (source (origin
3159 (method url-fetch)
3160 (uri
3161 (string-append "https://github.com/zeromq/zyre/releases/download/v"
3162 version "/" name "-" version ".tar.gz"))
3163 (sha256
3164 (base32
3165 "13596507ma1474cjqzxym5jlvcshvw7sjhw80rdz788gyz6kz90b"))))
3166 (build-system gnu-build-system)
3167 (inputs (list zeromq czmq libsodium))
3168 (synopsis "Framework for proximity-based peer-to-peer applications")
3169 (description "Zyre provides reliable group messaging over local area
3170 networks using zeromq. It has these key characteristics:
3171
3172 @itemize
3173 @item Zyre needs no administration or configuration.
3174 @item Peers may join and leave the network at any time.
3175 @item Peers talk to each other without any central brokers or servers.
3176 @item Peers can talk directly to each other.
3177 @item Peers can join groups, and then talk to groups.
3178 @item Zyre is reliable, and loses no messages even when the network is heavily loaded.
3179 @item Zyre is fast and has low latency, requiring no consensus protocols.
3180 @item Zyre is designed for WiFi networks, yet also works well on Ethernet networks.
3181 @end itemize")
3182 (home-page "https://github.com/zeromq/zyre")
3183 (license license:mpl2.0)))
3184
3185 (define-public libsocketcan
3186 (package
3187 (name "libsocketcan")
3188 (version "0.0.12")
3189 (source (origin
3190 (method git-fetch)
3191 (uri (git-reference
3192 (url "https://git.pengutronix.de/cgit/tools/libsocketcan")
3193 (commit (string-append "v" version))))
3194 (file-name (git-file-name name version))
3195 (sha256
3196 (base32
3197 "0nrav2yqxgb7jwnhrwirnxs9ycqqh90sqgv5a8lns837jf385jvq"))))
3198 (build-system gnu-build-system)
3199 (arguments
3200 (list #:phases
3201 #~(modify-phases %standard-phases
3202 ;; Upstream already puts (more) files in share/doc/libsocketcan.
3203 (delete 'install-license-files))))
3204 (native-inputs
3205 (list autoconf automake libtool))
3206 (home-page "https://git.pengutronix.de/cgit/tools/libsocketcan")
3207 (synopsis "SocketCAN user-space library")
3208 (description "This library allows controlling basic functions in SocketCAN
3209 from user-space. It requires a kernel built with SocketCAN support.")
3210 (license license:lgpl2.1+)))
3211
3212 (define-public can-utils
3213 (package
3214 (name "can-utils")
3215 (version "2020.02.04")
3216 (source (origin
3217 (method git-fetch)
3218 (uri (git-reference
3219 (url "https://github.com/linux-can/can-utils")
3220 (commit (string-append "v" version))))
3221 (file-name (git-file-name name version))
3222 (sha256
3223 (base32
3224 "1a3j1mmnb7pvgc8r7zzp6sdp7903in2hna6bmpraxln7cwlzn4l6"))))
3225 (build-system gnu-build-system)
3226 (arguments
3227 `(#:tests? #f ; No tests exist.
3228 #:make-flags (list ,(string-append "CC=" (cc-for-target))
3229 (string-append "PREFIX="
3230 (assoc-ref %outputs "out")))
3231 #:phases
3232 (modify-phases %standard-phases
3233 (delete 'bootstrap)
3234 (delete 'configure))))
3235 (home-page "https://github.com/linux-can/can-utils")
3236 (synopsis "CAN utilities")
3237 (description "This package provides CAN utilities in the following areas:
3238
3239 @itemize
3240 @item Basic tools to display, record, generate and replay CAN traffic
3241 @item CAN access via IP sockets
3242 @item CAN in-kernel gateway configuration
3243 @item CAN bus measurement and testing
3244 @item ISO-TP (ISO15765-2:2016 - this means messages with a body larger than
3245 eight bytes) tools
3246 @item Log file converters
3247 @item Serial Line Discipline configuration for slcan driver
3248 @end itemize")
3249 ;; Either BSD-3 or GPL-2 can be used.
3250 (license (list license:bsd-3 license:gpl2))))
3251
3252 (define-public asio
3253 (package
3254 (name "asio")
3255 (version "1.22.2")
3256 (source
3257 (origin
3258 (method url-fetch)
3259 (uri (string-append "mirror://sourceforge/asio/asio/"
3260 version " (Stable)/asio-" version ".tar.bz2"))
3261 (sha256
3262 (base32 "0v5w9j4a02j2rkc7mrdj3ms0kfpqbgq2ipkixlz2l0p8xs0vfsvp"))))
3263 (build-system gnu-build-system)
3264 (inputs
3265 (list boost openssl))
3266 (arguments
3267 `(#:configure-flags
3268 (list
3269 (string-append "--with-boost=" (assoc-ref %build-inputs "boost"))
3270 (string-append "--with-openssl=" (assoc-ref %build-inputs "openssl")))))
3271 (home-page "https://think-async.com/Asio")
3272 (synopsis "C++ library for ASynchronous network I/O")
3273 (description "Asio is a cross-platform C++ library for network and
3274 low-level I/O programming that provides developers with a consistent
3275 asynchronous model using a modern C++ approach.")
3276 (license license:boost1.0)))
3277
3278 (define-public shadowsocks
3279 (package
3280 (name "shadowsocks")
3281 (version "2.9.1")
3282 (source
3283 (origin
3284 (method git-fetch)
3285 (uri (git-reference
3286 (url "https://github.com/shadowsocks/shadowsocks")
3287 (commit version)))
3288 (sha256
3289 (base32 "02mp5905nz02d7amb4zc77rcrkxmvy8mf5rci7mvy58g24lvbw25"))
3290 (file-name (git-file-name name version))))
3291 (inputs
3292 (list openssl))
3293 (arguments
3294 '(#:phases
3295 (modify-phases %standard-phases
3296 (add-after 'unpack 'patch-crypto-paths
3297 (lambda* (#:key inputs #:allow-other-keys)
3298 (substitute* "shadowsocks/shell.py"
3299 (("config\\.get\\('libopenssl', None\\)")
3300 (format #f "config.get('libopenssl', ~s)"
3301 (string-append
3302 (assoc-ref inputs "openssl")
3303 "/lib/libssl.so")))))))))
3304 (build-system python-build-system)
3305 (home-page "https://github.com/shadowsocks/shadowsocks")
3306 (synopsis "Fast tunnel proxy that helps you bypass firewalls")
3307 (description
3308 "This package is a fast tunnel proxy that helps you bypass firewalls.
3309
3310 Features:
3311 @itemize
3312 @item TCP & UDP support
3313 @item User management API
3314 @item TCP Fast Open
3315 @item Workers and graceful restart
3316 @item Destination IP blacklist
3317 @end itemize")
3318 (license license:asl2.0)))
3319
3320 (define-public net-snmp
3321 (package
3322 (name "net-snmp")
3323 (version "5.9.3")
3324 (source (origin
3325 (method url-fetch)
3326 (uri (string-append "mirror://sourceforge/net-snmp/net-snmp/"
3327 version "/net-snmp-" version ".tar.gz"))
3328 (sha256
3329 (base32
3330 "02pgl89s8qll5zhdp61rbn6vpl084gx55bjb1cqg3wqvgsdz55r0"))
3331 (modules '((guix build utils)))
3332 (snippet
3333 '(begin
3334 ;; Drop bundled libraries.
3335 (delete-file-recursively "snmplib/openssl")))))
3336 (build-system gnu-build-system)
3337 (arguments
3338 `(#:test-target "test"
3339 ;; XXX: With parallel build enabled, Perl modules may not get linked with
3340 ;; libnetsnmp. See e.g. <https://bugzilla.novell.com/show_bug.cgi?id=819497>.
3341 #:parallel-build? #f
3342 #:configure-flags
3343 (list (string-append "LDFLAGS=-Wl,-rpath="
3344 (assoc-ref %outputs "out")
3345 "/lib")
3346 "--disable-static"
3347 "--with-logfile=/var/log/snmpd.log"
3348 (string-append "--with-openssl="
3349 (assoc-ref %build-inputs "openssl")))
3350 #:phases
3351 (modify-phases %standard-phases
3352 (add-after 'unpack 'patch-tests
3353 (lambda* (#:key inputs #:allow-other-keys)
3354 (substitute* "testing/fulltests/support/simple_TESTCONF.sh"
3355 (("NETSTAT=\"\"")
3356 (string-append "NETSTAT=\"" (which "netstat") "\"")))
3357 (substitute* '("testing/fulltests/default/T065agentextend_simple"
3358 "testing/fulltests/default/T115agentxperl_simple")
3359 (("/usr/bin/env") (which "env")))
3360 (substitute* "testing/fulltests/default/T065agentextend_sh_simple"
3361 (("/bin/sh") (which "sh")))
3362 ;; These tests require network access.
3363 (for-each delete-file
3364 '("testing/fulltests/default/T070com2sec_simple"
3365 "testing/fulltests/default/T071com2sec6_simple"))))
3366 (add-after 'unpack 'patch-Makefile.PL
3367 (lambda* (#:key outputs #:allow-other-keys)
3368 (substitute* "Makefile.in"
3369 (("Makefile.PL -NET")
3370 (string-append "Makefile.PL PREFIX="
3371 (assoc-ref outputs "out")
3372 " INSTALLDIRS=site" " NO_PERLLOCAL=1"
3373 " -NET"))))))))
3374 (inputs
3375 (list libnl ncurses ; for the ‘apps’
3376 openssl perl))
3377 (native-inputs
3378 (list pkg-config
3379 ;; For tests only.
3380 net-tools coreutils grep))
3381 (home-page "http://www.net-snmp.org/")
3382 (synopsis "Simple Network Management Protocol library and tools")
3383 (description "The @dfn{Simple Network Management Protocol} (SNMP) is a
3384 widely used protocol for monitoring the health and welfare of network
3385 equipment (e.g. routers), computer equipment and even devices like UPSs.
3386 Net-SNMP is a suite of applications used to implement SNMP v1, SNMP v2c and
3387 SNMP v3 using both IPv4 and IPv6.")
3388 ;; This only affects OpenBSD
3389 ;; https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2015-8100
3390 (properties `((lint-hidden-cve . ("CVE-2015-8100"))))
3391 (license (list license:bsd-3
3392 (license:non-copyleft
3393 "http://www.net-snmp.org/about/license.html"
3394 "CMU/UCD copyright notice")))))
3395
3396 (define-public ubridge
3397 (package
3398 (name "ubridge")
3399 (version "0.9.18")
3400 (source
3401 (origin
3402 (method git-fetch)
3403 (uri (git-reference
3404 (url "https://github.com/GNS3/ubridge")
3405 (commit (string-append "v" version))))
3406 (file-name (git-file-name name version))
3407 (sha256
3408 (base32 "0jg66jhhpv4c9340fsdp64hf9h253i8r81fknxa0gq241ripp3jn"))))
3409 (build-system gnu-build-system)
3410 (arguments
3411 `(#:tests? #f ; no tests
3412 #:make-flags
3413 (list ,(string-append "CC=" (cc-for-target)))
3414 #:phases
3415 (modify-phases %standard-phases
3416 (delete 'configure) ; no configure script
3417 (add-before 'install 'set-bindir
3418 (lambda* (#:key inputs outputs #:allow-other-keys)
3419 (let ((bin (string-append (assoc-ref outputs "out")
3420 "/bin")))
3421 (mkdir-p bin)
3422 (substitute* "Makefile"
3423 (("\\$\\(BINDIR\\)") bin)
3424 (("\tsetcap cap_net.*$") "")))
3425 #t)))))
3426 (inputs
3427 (list libpcap))
3428 (home-page "https://github.com/GNS3/ubridge/")
3429 (synopsis "Bridge for UDP tunnels, Ethernet, TAP and VMnet interfaces")
3430 (description "uBridge is a simple program to create user-land bridges
3431 between various technologies. Currently, bridging between UDP tunnels,
3432 Ethernet and TAP interfaces is supported. Packet capture is also supported.")
3433 (license license:gpl3+)))
3434
3435 (define-public hcxtools
3436 (package
3437 (name "hcxtools")
3438 (version "6.2.7")
3439 (source
3440 (origin
3441 (method git-fetch)
3442 (uri (git-reference
3443 (url "https://github.com/ZerBea/hcxtools")
3444 (commit version)))
3445 (sha256
3446 (base32 "0460dxbc04w60l3g06rk007yyb6qprgyii59y2zdki0vy7q63m8b"))
3447 (file-name (git-file-name name version))))
3448 (build-system gnu-build-system)
3449 (native-inputs (list pkg-config))
3450 (inputs (list curl libpcap openssl zlib))
3451 (arguments
3452 (list #:make-flags
3453 #~(list (string-append "CC="
3454 #$(cc-for-target)) "LDFLAGS+=-lcrypto"
3455 "LDFLAGS+=-lcurl" "LDFLAGS+=-lz"
3456 (string-append "PREFIX="
3457 #$output))
3458 #:tests? #f ;no test suite
3459 #:phases
3460 #~(modify-phases %standard-phases
3461 (delete 'configure))))
3462 (home-page "https://github.com/ZerBea/hcxtools")
3463 (synopsis "Capture wlan traffic to hashcat and John the Ripper")
3464 (description
3465 "This package contains a small set of tools to capture and convert
3466 packets from wireless devices for use with hashcat or John the Ripper.")
3467 (license license:expat)))
3468
3469 (define-public hcxdumptool
3470 (package
3471 (name "hcxdumptool")
3472 (version "6.0.6")
3473 (source
3474 (origin
3475 (method git-fetch)
3476 (uri (git-reference
3477 (url "https://github.com/ZerBea/hcxdumptool")
3478 (commit version)))
3479 (sha256
3480 (base32 "1b4d543y64ib92w9gcmiyjn5hz2vyjqmxk3f3yr1zk04fhw16gmf"))
3481 (file-name (git-file-name name version))))
3482 (build-system gnu-build-system)
3483 (arguments
3484 `(#:make-flags
3485 (list ,(string-append "CC=" (cc-for-target))
3486 (string-append "INSTALLDIR=" (assoc-ref %outputs "out") "/bin"))
3487 #:tests? #f ; no test suite
3488 #:phases
3489 (modify-phases %standard-phases
3490 (delete 'configure))))
3491 (inputs
3492 (list openssl))
3493 (home-page "https://github.com/ZerBea/hcxdumptool")
3494 (synopsis "Small tool to capture packets from wlan devices")
3495 (description
3496 "Small tool to capture packets from WLAN devices. After capturing,
3497 upload the \"uncleaned\" cap to @url{https://wpa-sec.stanev.org/?submit} to
3498 see if the access point or the client is vulnerable to a dictionary attack.
3499 Convert the cap file to hccapx format and/or to WPA-PMKID-PBKDF2
3500 hashline (16800) with @command{hcxpcaptool} from the @code{hcxtools} package
3501 and check if the WLAN key or the master key was transmitted unencrypted.")
3502 (license license:expat)))
3503
3504 (define-public dante
3505 (package
3506 (name "dante")
3507 (version "1.4.3")
3508 (source
3509 (origin
3510 (method url-fetch)
3511 (uri (string-append "https://www.inet.no/dante/files/dante-"
3512 version ".tar.gz"))
3513 (sha256
3514 (base32 "0pbahkj43rx7rmv2x40mf5p3g3x9d6i2sz7pzglarf54w5ghd2j1"))))
3515 (build-system gnu-build-system)
3516 (arguments
3517 ;; XXX: The dynamic socks library doesn't work with 'libc.so' (GNU ld
3518 ;; script). When preloading is enabled, 'sockd' failed with:
3519 ;; … Failed to open library "libc.so": …: invalid ELF header
3520 '(#:configure-flags '("--disable-preload")))
3521 (home-page "https://www.inet.no/dante/")
3522 (synopsis "SOCKS server and client")
3523 (description "Dante is a SOCKS client and server implementation. It can
3524 be installed on a machine with access to an external TCP/IP network and will
3525 allow all other machines, without direct access to that network, to be relayed
3526 through the machine the Dante server is running on. The external network will
3527 never see any machines other than the one Dante is running on.")
3528 (license (license:non-copyleft "file://LICENSE"))))
3529
3530 (define-public restbed
3531 (package
3532 (name "restbed")
3533 (version "4.8")
3534 (source
3535 (origin
3536 (method git-fetch)
3537 (uri (git-reference
3538 (url "https://github.com/Corvusoft/restbed/")
3539 (commit version)))
3540 (file-name (git-file-name name version))
3541 (sha256
3542 (base32 "15j09x36i6zj6innl0w1mfzlc56qmjwrs82my8dsagqa2ikd08ya"))))
3543 (build-system cmake-build-system)
3544 (inputs
3545 (list asio catch-framework openssl))
3546 (arguments
3547 `(#:configure-flags
3548 '("-DBUILD_SSL=NO")
3549 #:phases
3550 (modify-phases %standard-phases
3551 (add-after 'unpack 'apply-patches-and-fix-paths
3552 (lambda* (#:key inputs #:allow-other-keys)
3553 (let ((asio (assoc-ref inputs "asio"))
3554 (catch (assoc-ref inputs "catch"))
3555 (openssl (assoc-ref inputs "openssl")))
3556 (substitute* "cmake/Findasio.cmake"
3557 (("(find_path\\( asio_INCLUDE asio\\.hpp HINTS ).*$" all begin)
3558 (string-append begin " \"" asio "/include\" )")))
3559 (substitute* "cmake/Findcatch.cmake"
3560 (("(find_path\\( catch_INCLUDE catch\\.hpp HINTS ).*$" all begin)
3561 (string-append begin " \"" catch "/include\" )")))
3562 (substitute* "cmake/Findopenssl.cmake"
3563 (("(find_library\\( ssl_LIBRARY ssl ssleay32 HINTS ).*$" all begin)
3564 (string-append begin " \"" openssl "/lib\" )"))
3565 (("(find_library\\( crypto_LIBRARY crypto libeay32 HINTS ).*$" all begin)
3566 (string-append begin " \"" openssl "/lib\" )"))
3567 (("(find_path\\( ssl_INCLUDE openssl/ssl\\.h HINTS ).*$" all begin)
3568 (string-append begin " \"" openssl "/include\" )")))))))))
3569 (synopsis "Asynchronous RESTful functionality to C++11 applications")
3570 (description "Restbed is a comprehensive and consistent programming
3571 model for building applications that require seamless and secure
3572 communication over HTTP.")
3573 (home-page "https://github.com/Corvusoft/restbed")
3574 (license license:agpl3+)))
3575
3576 (define-public restinio
3577 (package
3578 (name "restinio")
3579 (version "0.6.15")
3580 (source (origin
3581 (method git-fetch)
3582 (uri (git-reference
3583 (url "https://github.com/Stiffstream/restinio")
3584 (commit (string-append "v." version))))
3585 (file-name (git-file-name name version))
3586 (sha256
3587 (base32
3588 "1f8d5nfm8jqhspzsslwb1b7j4glipz31i9vszrcnkx3clc39nj2n"))))
3589 (build-system cmake-build-system)
3590 (inputs ; TODO: Need to force-keep references on some inputs, e.g. boost.
3591 (list zlib
3592 catch-framework2
3593 openssl
3594 boost
3595 pcre
3596 pcre2
3597 sobjectizer))
3598 (propagated-inputs
3599 (list asio fmt http-parser))
3600 (arguments
3601 `(#:configure-flags '("-DRESTINIO_INSTALL=on")
3602 #:tests? #f ; TODO: The tests are called from the root CMakelist, need RESTINIO_TEST=on.
3603 #:phases
3604 (modify-phases %standard-phases
3605 (add-after 'unpack 'change-directory
3606 (lambda _
3607 (chdir "dev/restinio"))))))
3608 (home-page "https://stiffstream.com/en/products/restinio.html")
3609 (synopsis "C++14 library that gives you an embedded HTTP/Websocket server")
3610 (description "RESTinio is a header-only C++14 library that gives you an embedded
3611 HTTP/Websocket server. It is based on standalone version of ASIO
3612 and targeted primarily for asynchronous processing of HTTP-requests.")
3613 (license license:bsd-3)))
3614
3615 (define-public opendht
3616 (package
3617 (name "opendht")
3618 (version "2.4.9")
3619 (source (origin
3620 (method git-fetch)
3621 (uri (git-reference
3622 (url "https://github.com/savoirfairelinux/opendht")
3623 (commit (string-append "v" version))))
3624 (file-name (git-file-name name version))
3625 (sha256
3626 (base32
3627 "150yxlhn8ykhck7gr1i2bppbqpfyhk0cscn5z7vyn94y5fnqkxsb"))))
3628 (outputs '("out" "tools" "debug"))
3629 (build-system gnu-build-system)
3630 (arguments
3631 (list
3632 #:imported-modules `((guix build python-build-system) ;for site-packages
3633 ,@%gnu-build-system-modules)
3634 #:modules '(((guix build python-build-system) #:prefix python:)
3635 (guix build gnu-build-system)
3636 (guix build utils))
3637 #:configure-flags
3638 #~(list "--enable-tests"
3639 "--enable-proxy-server"
3640 "--enable-push-notifications"
3641 "--enable-proxy-server-identity"
3642 "--enable-proxy-client")
3643 #:phases
3644 #~(modify-phases %standard-phases
3645 (add-after 'unpack 'disable-problematic-tests
3646 (lambda _
3647 ;; The dhtrunnertester test suite includes 'testListen', which
3648 ;; is sensitive to the performance/load of the machine it runs
3649 ;; on, introducing nondeterminism (see:
3650 ;; https://github.com/savoirfairelinux/opendht/issues/626).
3651 (substitute* "tests/Makefile.am"
3652 (("\\bdhtrunnertester\\.(h|cpp)\\b")
3653 ""))))
3654 (add-after 'unpack 'fix-python-installation-prefix
3655 ;; Specify the installation prefix for the compiled Python module
3656 ;; that would otherwise attempt to installs itself to Python's own
3657 ;; site-packages directory.
3658 (lambda _
3659 (substitute* "python/Makefile.am"
3660 (("--root=\\$\\(DESTDIR)/")
3661 (string-append "--root=/ --single-version-externally-managed "
3662 "--prefix=" #$output)))))
3663 (add-after 'unpack 'specify-runpath-for-python-module
3664 (lambda _
3665 (substitute* "python/setup.py.in"
3666 (("extra_link_args=\\[(.*)\\]" _ args)
3667 (string-append "extra_link_args=[" args
3668 ", '-Wl,-rpath=" #$output "/lib']")))))
3669 (replace 'check
3670 (lambda* (#:key tests? #:allow-other-keys)
3671 (when tests?
3672 (invoke "tests/opendht_unit_tests"))))
3673 (add-after 'install 'move-and-wrap-tools
3674 (lambda* (#:key inputs outputs #:allow-other-keys)
3675 (let* ((tools (assoc-ref outputs "tools"))
3676 (dhtcluster (string-append tools "/bin/dhtcluster"))
3677 (site-packages (python:site-packages inputs outputs)))
3678 (mkdir tools)
3679 (rename-file (string-append #$output "/bin")
3680 (string-append tools "/bin"))
3681 ;; TODO: Contribute a patch to python/Makefile.am to
3682 ;; automate this.
3683 (copy-file "python/tools/dhtcluster.py" dhtcluster)
3684 (chmod dhtcluster #o555)
3685 (wrap-program dhtcluster
3686 `("GUIX_PYTHONPATH" prefix (,site-packages)))))))))
3687 (inputs (list bash-minimal fmt readline))
3688 (propagated-inputs
3689 (list msgpack ;included in several installed headers
3690 restinio ;included in opendht/http.h
3691 ;; The following are listed in the 'Requires.private' field of
3692 ;; opendht.pc:
3693 argon2
3694 gnutls
3695 jsoncpp
3696 nettle
3697 openssl)) ;required for the DHT proxy
3698 (native-inputs
3699 (list autoconf
3700 automake
3701 pkg-config
3702 python
3703 python-cython
3704 libtool
3705 cppunit))
3706 (home-page "https://github.com/savoirfairelinux/opendht/")
3707 (synopsis "Lightweight Distributed Hash Table (DHT) library")
3708 (description "OpenDHT provides an easy to use distributed in-memory data
3709 store. Every node in the network can read and write values to the store.
3710 Values are distributed over the network, with redundancy. It includes the
3711 following features:
3712 @itemize
3713 @item Lightweight and scalable, designed for large networks and small devices;
3714 @item High resilience to network disruption;
3715 @item Public key cryptography layer providing optional data signature and
3716 encryption (using GnuTLS);
3717 @item IPv4 and IPv6 support;
3718 @item Clean and powerful C++14 map API;
3719 @item Bindings for C, Rust & Python 3;
3720 @item REST API with an optional HTTP client and server with push notification
3721 support.
3722 @end itemize
3723 The following tools are also included:
3724 @table @command
3725 @item dhtnode
3726 A command line tool to run a DHT node and perform operations supported by the
3727 library (get, put, etc.) with text values.
3728 @item dhtchat
3729 A very simple IM client working over the DHT.
3730 @end table")
3731 (license license:gpl3+)))
3732
3733 (define-public frrouting
3734 (package
3735 (name "frrouting")
3736 (version "7.5.1")
3737 (source (origin
3738 (method url-fetch)
3739 (uri (string-append "https://github.com/FRRouting/frr/releases/"
3740 "download/frr-" version "/frr-" version
3741 ".tar.xz"))
3742 (sha256
3743 (base32
3744 "1r7gh5h27ii7d1d0z0x48wx7hs8vvympv3gqvy3cwzg05q5vk9xs"))))
3745 (build-system gnu-build-system)
3746 (inputs
3747 (list c-ares json-c libcap libyang readline))
3748 (native-inputs
3749 (list perl pkg-config python-wrapper python-pytest))
3750 (home-page "https://frrouting.org/")
3751 (synopsis "IP routing protocol suite")
3752 (description "FRRouting (FRR) is an IP routing protocol suite which includes
3753 protocol daemons for BGP, IS-IS, LDP, OSPF, PIM, and RIP.")
3754 (license license:gpl2+)))
3755
3756 (define-public bird
3757 (package
3758 (name "bird")
3759 (version "2.0.10")
3760 (source (origin
3761 (method url-fetch)
3762 (uri (string-append "ftp://bird.network.cz/pub/bird/bird-"
3763 version ".tar.gz"))
3764 (sha256
3765 (base32
3766 "0npx3zgbjnhm4905zmj2qkz3d13s8hakassq6sbzm1ywv3fl3lvy"))))
3767 (inputs
3768 (list libssh readline))
3769 (native-inputs
3770 (list bison flex))
3771 (arguments
3772 `(#:configure-flags '("--localstatedir=/var" "--enable-ipv6")
3773 #:phases
3774 (modify-phases %standard-phases
3775 (add-before 'configure 'dont-create-sysconfdir
3776 (lambda* (#:key outputs #:allow-other-keys)
3777 (substitute* "Makefile.in"
3778 ((" \\$\\(DESTDIR)/\\$\\(runstatedir)") "")))))))
3779 (build-system gnu-build-system)
3780 (home-page "http://bird.network.cz")
3781 (synopsis "Internet Routing Daemon")
3782 (description "BIRD is an Internet routing daemon with full support for all
3783 the major routing protocols. It allows redistribution between protocols with a
3784 powerful route filtering syntax and an easy-to-use configuration interface.")
3785 (license license:gpl2+)))
3786
3787 (define-public iwd
3788 (package
3789 (name "iwd")
3790 (version "1.24")
3791 (source (origin
3792 (method git-fetch)
3793 (uri (git-reference
3794 (url "https://git.kernel.org/pub/scm/network/wireless/iwd.git")
3795 (commit version)))
3796 (file-name (git-file-name name version))
3797 (sha256
3798 (base32
3799 "1sdi7008j5jhlg2rqpczh1pzb8zay6mc9dpnjjsmdnsmrcr3v7wi"))))
3800 (build-system gnu-build-system)
3801 (inputs
3802 (list dbus ell (package-source ell) readline))
3803 (native-inputs
3804 (list autoconf
3805 automake
3806 libtool
3807 pkg-config
3808 python
3809 python-docutils
3810 openssl))
3811 (arguments
3812 `(#:configure-flags
3813 ,#~(list "--disable-systemd-service"
3814 "--enable-external-ell"
3815 "--enable-hwsim"
3816 "--enable-tools"
3817 "--enable-wired"
3818 "--localstatedir=/var"
3819 (string-append "--with-dbus-datadir=" #$output "/share/")
3820 (string-append "--with-dbus-busdir="
3821 #$output "/share/dbus-1/system-services"))
3822 #:phases
3823 (modify-phases %standard-phases
3824 (add-after 'unpack 'copy-ell-header-files
3825 ;; Copy into the source tree two of ell's private header files that
3826 ;; it shares with iwd, as is required to build with the
3827 ;; "--enable-external-ell" configure option.
3828 ;; See the definition of "ell_shared" in iwd's Makefile.am.
3829 (lambda* (#:key inputs #:allow-other-keys)
3830 (let ((ell-header-dir (search-input-directory inputs "/ell"))
3831 (target-dir "ell"))
3832 (mkdir target-dir)
3833 (for-each
3834 (lambda (file-name)
3835 (copy-file (string-append ell-header-dir "/" file-name)
3836 (string-append target-dir "/" file-name)))
3837 '("asn1-private.h" "useful.h")))))
3838 (add-after 'configure 'patch-Makefile
3839 (lambda _
3840 (substitute* "Makefile"
3841 ;; Don't try to 'mkdir /var'.
3842 (("\\$\\(MKDIR_P\\) -m 700") "true")))))))
3843 (home-page "https://git.kernel.org/pub/scm/network/wireless/iwd.git/")
3844 (synopsis "Internet Wireless Daemon")
3845 (description "iwd is a wireless daemon for Linux that aims to replace WPA
3846 Supplicant. It optimizes resource utilization by not depending on any external
3847 libraries and instead utilizing features provided by the Linux kernel to the
3848 maximum extent possible.")
3849 (license license:lgpl2.1+)))
3850
3851 (define-public libyang
3852 (package
3853 (name "libyang")
3854 (version "1.0.215")
3855 (source (origin
3856 (method git-fetch)
3857 (uri (git-reference
3858 (url "https://github.com/CESNET/libyang")
3859 (commit (string-append "v" version))))
3860 (file-name (git-file-name name version))
3861 (sha256
3862 (base32
3863 "0mrs2ppmq77z8sbqgm2w0rl9bfgybd6bcxanakfww4chih6cy0dw"))))
3864 (build-system cmake-build-system)
3865 (arguments
3866 `(#:configure-flags
3867 (list "-DENABLE_BUILD_TESTS=ON" "-DENABLE_LYD_PRIV=ON")))
3868 (propagated-inputs (list pcre))
3869 (native-inputs (list cmocka pkg-config))
3870 (home-page "https://github.com/CESNET/libyang")
3871 (synopsis "YANG data modelling language library")
3872 (description "libyang is a YANG data modelling language parser and toolkit
3873 written (and providing API) in C. Current implementation covers YANG 1.0 (RFC
3874 6020) as well as YANG 1.1 (RFC 7950).")
3875 (license license:bsd-3)))
3876
3877 (define-public batctl
3878 (package
3879 (name "batctl")
3880 (version "2021.4")
3881 (source
3882 (origin
3883 (method url-fetch)
3884 (uri (string-append "https://downloads.open-mesh.org/batman/releases/batman-adv-"
3885 version "/batctl-" version ".tar.gz"))
3886 (sha256
3887 (base32 "1ryqz90av2p5pgmmpi1afmycd18zhpwz1i4f7r0s359jis86xndn"))))
3888 (inputs
3889 (list libnl))
3890 (native-inputs
3891 (list pkg-config))
3892 (build-system gnu-build-system)
3893 (arguments
3894 `(#:tests? #f
3895 ;; Batctl only has a makefile. Thus we disable tests and
3896 ;; configuration, passing in a few make-flags.
3897 #:phases (modify-phases %standard-phases (delete 'configure))
3898 #:make-flags
3899 (list (string-append "PREFIX=" (assoc-ref %outputs "out"))
3900 (string-append "PKG_CONFIG="
3901 (search-input-file %build-inputs
3902 "/bin/pkg-config"))
3903 ,(string-append "CC=" (cc-for-target)))))
3904 (home-page "https://www.open-mesh.org/projects/batman-adv/wiki/Wiki")
3905 (synopsis "Management tool for the mesh networking BATMAN protocol")
3906 (description "This package provides a control tool for the
3907 B.A.T.M.A.N. mesh networking routing protocol provided by the Linux kernel
3908 module @code{batman-adv}, for Layer 2.")
3909 (license license:gpl2+)))
3910
3911 (define-public pagekite
3912 (package
3913 (name "pagekite")
3914 (version "1.5.2.200725")
3915 (source
3916 (origin
3917 (method git-fetch)
3918 (uri (git-reference
3919 (url "https://github.com/pagekite/PyPagekite")
3920 (commit (string-append "v" version))))
3921 (file-name (git-file-name name version))
3922 (sha256
3923 (base32 "0lig1i42bn9isw848vnml5qhcaa04x1dr2hb075bm0a3439kv3rr"))))
3924 (build-system python-build-system)
3925 (arguments
3926 `(#:phases
3927 (modify-phases %standard-phases
3928 (add-after 'install 'install-man-page
3929 (lambda* (#:key inputs outputs #:allow-other-keys)
3930 (let* ((out (assoc-ref outputs "out"))
3931 (man (string-append out "/share/man")))
3932 (invoke "make" "doc/pagekite.1")
3933 (install-file "doc/pagekite.1" (string-append man "/man1"))))))))
3934 (inputs
3935 (list python-six python-socksipychain))
3936 (home-page "https://pagekite.net/")
3937 (synopsis "Make localhost servers publicly visible")
3938 (description
3939 "PageKite implements a tunneled reverse proxy which makes it easy to make
3940 a service (such as an HTTP or SSH server) on localhost visible to the wider
3941 Internet, even behind NAT or restrictive firewalls. A managed front-end relay
3942 service is available at @url{https://pagekite.net/}, or you can run your own.")
3943 (license license:agpl3+)))
3944
3945 (define-public ipcalc
3946 (package
3947 (name "ipcalc")
3948 (version "0.51")
3949 (source
3950 (origin
3951 (method git-fetch)
3952 (uri (git-reference
3953 ;; This is the IPv6-capable continuation of the unmaintained
3954 ;; <https://jodies.de/ipcalc-archive/>.
3955 (url "https://github.com/kjokjo/ipcalc")
3956 (commit version)))
3957 (file-name (git-file-name name version))
3958 (sha256
3959 (base32 "0cnygb69vjmp3by75jcd2z4y3ybp1s7x4nl3d32xa49h8lkhdbfv"))))
3960 (inputs `(("perl" ,perl)))
3961 (build-system trivial-build-system) ;no Makefile.PL
3962 (arguments
3963 `(#:modules ((guix build utils))
3964 #:builder
3965 (begin
3966 (use-modules (guix build utils))
3967 (use-modules (srfi srfi-1))
3968 (let* ((source (assoc-ref %build-inputs "source"))
3969 (perl (string-append (assoc-ref %build-inputs "perl")
3970 "/bin"))
3971 (out (assoc-ref %outputs "out"))
3972 (bin (string-append out "/bin"))
3973 (doc (string-append out "/share/doc/ipcalc")))
3974 (copy-recursively source "source")
3975 (chdir "source")
3976
3977 (install-file "ipcalc" bin)
3978 (patch-shebang (string-append bin "/ipcalc") (list perl))))))
3979 (synopsis "Simple IP network calculator")
3980 (description "ipcalc takes an IP address and netmask and calculates the
3981 resulting broadcast, network, Cisco wildcard mask, and host range. By giving
3982 a second netmask, you can design subnets and supernets. It is also intended
3983 to be a teaching tool and presents the subnetting results as
3984 easy-to-understand binary values.")
3985 (home-page "https://github.com/kjokjo/ipcalc")
3986 (license license:gpl2+)))
3987
3988 (define-public tunctl
3989 (package
3990 (name "tunctl")
3991 (version "1.5")
3992 (source
3993 (origin
3994 (method url-fetch)
3995 (uri (string-append "mirror://sourceforge/tunctl/tunctl/" version "/"
3996 "tunctl-" version ".tar.gz"))
3997 (sha256
3998 (base32 "1zsgn7w6l2zh2q0j6qaw8wsx981qcr536qlz1lgb3b5zqr66qama"))))
3999 (build-system gnu-build-system)
4000 (arguments
4001 `(#:phases
4002 (modify-phases %standard-phases
4003 (delete 'bootstrap) ;there is no configure.ac file
4004 (delete 'configure) ;there is no configure script
4005 (delete 'check) ;there are no tests
4006 (replace 'build
4007 (lambda _
4008 (setenv "CC" "gcc")
4009 (invoke "make" "tunctl")))
4010 ;; TODO: Requires docbook2x to generate man page from SGML.
4011 (replace 'install
4012 (lambda* (#:key outputs #:allow-other-keys)
4013 (let* ((out (assoc-ref outputs "out"))
4014 (bin (string-append out "/bin")))
4015 (install-file "tunctl" bin))
4016 #t)))))
4017 (home-page "http://tunctl.sourceforge.net")
4018 (synopsis "Utility to set up and maintain TUN/TAP network interfaces")
4019 (description "Tunctl is used to set up and maintain persistent TUN/TAP
4020 network interfaces, enabling user applications to simulate network traffic.
4021 Such interfaces are useful for VPN software, virtualization, emulation,
4022 simulation, and a number of other applications.")
4023 (license license:gpl2)))
4024
4025 (define-public wol
4026 (package
4027 (name "wol")
4028 (version "0.7.1")
4029 (source
4030 (origin
4031 (method url-fetch)
4032 (uri (string-append "mirror://sourceforge/wake-on-lan/wol/"
4033 version "/wol-" version ".tar.gz"))
4034 (sha256
4035 (base32 "08i6l5lr14mh4n3qbmx6kyx7vjqvzdnh3j9yfvgjppqik2dnq270"))))
4036 (build-system gnu-build-system)
4037 (home-page "https://sourceforge.net/projects/wake-on-lan/")
4038 (synopsis "Implements Wake On LAN functionality in a small program")
4039 (description "Tool to send a magic packet to wake another host on the
4040 network. This must be enabled on the target host, usually in the BIOS.")
4041 (license license:gpl2)))
4042
4043 (define-public traceroute
4044 (package
4045 (name "traceroute")
4046 (version "2.1.0")
4047 (source
4048 (origin
4049 (method url-fetch)
4050 (uri (string-append "mirror://sourceforge/traceroute/traceroute/"
4051 "traceroute-" version "/traceroute-"
4052 version ".tar.gz"))
4053 (sha256
4054 (base32 "1dh32vcfawkl1p9g4ral1p0camds4paqr8db1kaqxwyk6hmd4s9n"))))
4055 (build-system gnu-build-system)
4056 (arguments
4057 `(#:tests? #f ;no test suite
4058 #:make-flags
4059 (list (string-append "LIBRARY_PATH="
4060 (assoc-ref %build-inputs "libc") "/lib")
4061 (string-append "CFLAGS=-I"
4062 (assoc-ref %build-inputs "kernel-headers")
4063 "/include")
4064 "LDFLAGS=-lm -L../libsupp"
4065 (string-append "prefix=" (assoc-ref %outputs "out")))
4066 #:phases
4067 (modify-phases %standard-phases
4068 (add-after 'unpack 'patch-make
4069 (lambda _
4070 (substitute* "default.rules"
4071 ((" \\$\\(LIBDEPS\\)") "$(filter-out -l%,$(LIBDEPS))"))))
4072 (delete 'bootstrap) ;no configure.ac file
4073 (delete 'configure)))) ;no configure script
4074 (home-page "http://traceroute.sourceforge.net/")
4075 (synopsis "Tracks the route taken by packets over an IP network")
4076 (description "This package provides a modern, but Linux-specific
4077 implementation of the @command{traceroute} command that can be used to follow
4078 the route taken by packets on an IP network on their way to a given host. It
4079 utilizes the IP protocol's time to live (TTL) field and attempts to elicit an
4080 ICMP TIME_EXCEEDED response from each gateway along the path to the host.
4081 Compared to other implementations, this @command{traceroute} command allows
4082 some traces for unprivileged users.")
4083 (license (list license:gpl2+
4084 license:lgpl2.1+)))) ;for the libsupp subdirectory
4085
4086 (define-public vde2
4087 (let ((commit "8c65ebc464b2f986d5f1f4e6ae829ef4480c9d5a")
4088 (revision "0"))
4089 (package
4090 (name "vde2")
4091 (version (git-version "2.3.2" revision commit))
4092 (source
4093 (origin
4094 (method git-fetch)
4095 (uri (git-reference
4096 (url "https://github.com/virtualsquare/vde-2")
4097 (commit commit)))
4098 (file-name (git-file-name name version))
4099 (sha256
4100 (base32 "0l5xf71sv9zm5zw0wg8xgip58c0wh8zck2bazyc2a8gb67gc3s8y"))))
4101 (build-system gnu-build-system)
4102 (arguments
4103 `(#:parallel-build? #f)) ; Build fails if #t.
4104 (native-inputs
4105 (list autoconf automake libtool))
4106 (inputs
4107 (list python libpcap wolfssl))
4108 (home-page "https://github.com/virtualsquare/vde-2")
4109 (synopsis "Virtual Distributed Ethernet")
4110 (description "VDE is a set of programs to provide virtual software-defined
4111 Ethernet network interface controllers across multiple virtual or
4112 physical, local or remote devices. The VDE architecture provides
4113 virtual counterparts to hardware components such as switches and
4114 cables.")
4115 (license (list license:gpl2
4116 license:lgpl2.1 ; libvdeplug
4117 (license:non-copyleft ; slirpvde
4118 "file://COPYING.slirpvde"
4119 "See COPYING.slirpvde in the distribution."))))))
4120
4121 (define-public haproxy
4122 (package
4123 (name "haproxy")
4124 (version "2.1.7")
4125 (source (origin
4126 (method url-fetch)
4127 (uri (string-append "https://www.haproxy.org/download/"
4128 (version-major+minor version)
4129 "/src/haproxy-" version ".tar.gz"))
4130 (sha256
4131 (base32
4132 "0fd3c1znid5a9w3gcf77b85hm2a2558w9s02c4b7xzkmivqnqbir"))))
4133 (build-system gnu-build-system)
4134 (arguments
4135 `(#:make-flags
4136 (let* ((out (assoc-ref %outputs "out")))
4137 (list (string-append "PREFIX=" out)
4138 (string-append "DOCDIR=" out "/share/" ,name)
4139 "TARGET=linux-glibc"
4140 "USE_LUA=1"
4141 "USE_OPENSSL=1"
4142 "USE_ZLIB=1"
4143 "USE_PCRE_2=1"))
4144 #:tests? #f ; there are only regression tests, using varnishtest
4145 #:phases
4146 (modify-phases %standard-phases
4147 (delete 'configure))))
4148 (inputs
4149 (list lua openssl pcre2 zlib))
4150 (home-page "https://www.haproxy.org/")
4151 (synopsis "Reliable, high performance TCP/HTTP load balancer")
4152 (description "HAProxy offers @acronym{HA, high availability}, load
4153 balancing, and proxying for TCP and HTTP-based applications. It is particularly
4154 suited to Web sites crawling under very high loads while needing persistence or
4155 Layer 7 processing. Supporting tens of thousands of connections is clearly
4156 realistic with today's hardware.")
4157 (license (list license:gpl2+
4158 license:lgpl2.1
4159 license:lgpl2.1+))))
4160
4161 (define-public lldpd
4162 (package
4163 (name "lldpd")
4164 (version "1.0.14")
4165 (source
4166 (origin
4167 (method url-fetch)
4168 (uri (string-append "https://media.luffy.cx/files/lldpd/lldpd-"
4169 version ".tar.gz"))
4170 (sha256
4171 (base32 "1s0j5p0mjh1pda1aq5wm4hd41fh1m864jgbs82y5sshi9whijj57"))
4172 (modules '((guix build utils)))
4173 (snippet
4174 '(begin
4175 ;; Drop bundled library.
4176 (delete-file-recursively "libevent")))))
4177 (arguments
4178 (list #:configure-flags
4179 #~(list
4180 "--with-privsep-user=nobody"
4181 "--with-privsep-group=nogroup"
4182 "--localstatedir=/var"
4183 "--enable-pie"
4184 "--disable-static"
4185 "--without-embedded-libevent"
4186 (string-append "--with-systemdsystemunitdir="
4187 #$output "/lib/systemd/system"))))
4188 (build-system gnu-build-system)
4189 (inputs
4190 (list libevent libxml2 openssl readline))
4191 (native-inputs
4192 (list pkg-config))
4193 (home-page "https://vincentbernat.github.io/lldpd/")
4194 (synopsis "Locate neighbors of your network equipment")
4195 (description
4196 "The @dfn{Link Layer Discovery Protocol} (LLDP) is an industry standard
4197 protocol designed to supplant proprietary Link-Layer protocols such as EDP or
4198 CDP. The goal of LLDP is to provide an inter-vendor compatible mechanism to
4199 deliver Link-Layer notifications to adjacent network devices. @code{lldpd} is
4200 an implementation of LLDP. It also supports some proprietary protocols.")
4201 (license license:isc)))
4202
4203 (define-public hashcash
4204 (package
4205 (name "hashcash")
4206 (version "1.22")
4207 (source
4208 (origin
4209 (method url-fetch)
4210 (uri (string-append "http://www.hashcash.org/source/hashcash-"
4211 version ".tgz"))
4212 (sha256
4213 (base32
4214 "15kqaimwb2y8wvzpn73021bvay9mz1gqqfc40gk4hj6f84nz34h1"))))
4215 (build-system gnu-build-system)
4216 (arguments
4217 `(#:make-flags (list (string-append "CC=" ,(cc-for-target)))
4218 #:phases
4219 (modify-phases %standard-phases
4220 (delete 'configure)
4221 ;; No tests available.
4222 (delete 'check)
4223 (replace 'install
4224 (lambda* (#:key outputs #:allow-other-keys)
4225 (let* ((outdir (assoc-ref outputs "out"))
4226 (bindir (string-append outdir "/bin"))
4227 (mandir (string-append outdir "/share/man/man1"))
4228 (docdir (string-append outdir "/share/doc/hashcash-" ,version)))
4229 ;; Install manually, as we don't need the `sha1' binary
4230 (install-file "hashcash" bindir)
4231 (install-file "hashcash.1" mandir)
4232 (install-file "README" docdir)
4233 (install-file "LICENSE" docdir)
4234 (install-file "CHANGELOG" docdir)
4235 #t))))))
4236 (home-page "https://www.hashcash.org/")
4237 (synopsis "Denial-of-service countermeasure")
4238 (description "Hashcash is a proof-of-work algorithm, which has been used
4239 as a denial-of-service countermeasure technique in a number of systems.
4240
4241 A hashcash stamp constitutes a proof-of-work which takes a parametrizable
4242 amount of work to compute for the sender. The recipient can verify received
4243 hashcash stamps efficiently.
4244
4245 This package contains a command-line tool for computing and verifying hashcash
4246 stamps.")
4247 (license license:public-domain)))
4248
4249 (define-public nbd
4250 (package
4251 (name "nbd")
4252 (version "3.24")
4253 (source
4254 (origin
4255 (method url-fetch)
4256 (uri (string-append "mirror://sourceforge/nbd/nbd/" version
4257 "/nbd-" version ".tar.xz"))
4258 (sha256
4259 (base32 "036ib2d5722sx9nn7jydqfpl5ici5if2z7g8xrskzcx74dniaxv8"))))
4260 (build-system gnu-build-system)
4261 (inputs
4262 (list glib))
4263 (native-inputs
4264 (list bison pkg-config which))
4265 (home-page "https://nbd.sourceforge.io/")
4266 (synopsis "NBD client and server")
4267 (description "This package provides the NBD (Network Block Devices)
4268 client and server. It allows you to use remote block devices over a TCP/IP
4269 network.")
4270 (license license:gpl2)))
4271
4272 (define-public yggdrasil
4273 (package
4274 (name "yggdrasil")
4275 (version "0.4.3")
4276 (source
4277 (origin
4278 (method git-fetch)
4279 (uri
4280 (git-reference
4281 (url "https://github.com/yggdrasil-network/yggdrasil-go")
4282 (commit (string-append "v" version))
4283 (recursive? #t)))
4284 (file-name (git-file-name name version))
4285 (sha256
4286 (base32 "0jp6998a45xi8pbi8p84chvpm1mhhcvcxm1avi1c1gjjp4jqm3vl"))
4287 (patches (search-patches "yggdrasil-extra-config.patch"))))
4288 (build-system go-build-system)
4289 (arguments
4290 '(#:import-path "github.com/yggdrasil-network/yggdrasil-go"
4291 ;; TODO: figure out how tests are run
4292 #:tests? #f
4293 #:install-source? #f
4294 #:phases
4295 (modify-phases %standard-phases
4296 (replace 'build
4297 (lambda* (#:key import-path build-flags #:allow-other-keys)
4298 (for-each
4299 (lambda (directory)
4300 ((assoc-ref %standard-phases 'build)
4301 #:build-flags build-flags
4302 #:import-path directory))
4303 (list "github.com/yggdrasil-network/yggdrasil-go/cmd/yggdrasil"
4304 "github.com/yggdrasil-network/yggdrasil-go/cmd/yggdrasilctl"
4305 "github.com/yggdrasil-network/yggdrasil-go/cmd/genkeys"))
4306 #t)))))
4307 ;; https://github.com/kardianos/minwinsvc is windows only
4308 (propagated-inputs
4309 (list ;;("go-golang-zx2c4-com-wireguard-windows"
4310 ;; ,go-golang-zx2c4-com-wireguard-windows)
4311 go-golang-zx2c4-com-wireguard
4312 go-golang-org-x-text
4313 go-golang-org-x-sys
4314 go-golang-org-x-net
4315 go-golang-org-x-crypto
4316 go-netns
4317 go-netlink
4318 go-github-com-mitchellh-mapstructure
4319 go-github-com-mattn-go-runewidth
4320 go-github-com-mattn-go-isatty
4321 go-github-com-kardianos-minwinsvc
4322 go-github-com-hjson-hjson-go
4323 go-github-com-hashicorp-go-syslog
4324 go-github-com-gologme-log
4325 go-github-com-fatih-color
4326 go-github-com-cheggaaa-pb-v3
4327 go-github-com-vividcortex-ewma
4328 go-github-com-arceliar-phony
4329 go-github-com-arceliar-ironwood))
4330 (home-page "https://yggdrasil-network.github.io/blog.html")
4331 (synopsis
4332 "Experiment in scalable routing as an encrypted IPv6 overlay network")
4333 (description
4334 "Yggdrasil is an early-stage implementation of a fully end-to-end encrypted
4335 IPv6 network. It is lightweight, self-arranging, supported on multiple
4336 platforms and allows pretty much any IPv6-capable application to communicate
4337 securely with other Yggdrasil nodes. Yggdrasil does not require you to have
4338 IPv6 Internet connectivity - it also works over IPv4.")
4339 (license
4340 ;; As a special exception to the GNU Lesser General Public License
4341 ;; version 3 ("LGPL3"), the copyright holders of this Library give you
4342 ;; permission to convey to a third party a Combined Work that links
4343 ;; statically or dynamically to this Library without providing any Minimal
4344 ;; Corresponding Source or Minimal Application Code as set out in 4d or
4345 ;; providing the installation information set out in section 4e, provided
4346 ;; that you comply with the other provisions of LGPL3 and provided that you
4347 ;; meet, for the Application the terms and conditions of the license(s)
4348 ;; which apply to the Application. Except as stated in this special
4349 ;; exception, the provisions of LGPL3 will continue to comply in full to
4350 ;; this Library. If you modify this Library, you may apply this exception
4351 ;; to your version of this Library, but you are not obliged to do so. If
4352 ;; you do not wish to do so, delete this exception statement from your
4353 ;; version. This exception does not (and cannot) modify any license terms
4354 ;; which apply to the Application, with which you must still comply
4355 license:lgpl3)))
4356
4357 (define-public netdiscover
4358 (package
4359 (name "netdiscover")
4360 (version "0.7")
4361 (source
4362 (origin
4363 (method git-fetch)
4364 (uri (git-reference
4365 (url "https://github.com/netdiscover-scanner/netdiscover")
4366 (commit version)))
4367 (sha256
4368 (base32 "0g8w8rlg16dsibxi4dnyn7v7r8wwi5ypd51c4w59j0ps2id0w8yj"))
4369 (file-name (string-append "netdiscover-" version))))
4370 (arguments
4371 `(#:tests? #f)) ;; no tests
4372 (build-system gnu-build-system)
4373 (inputs
4374 (list libnet libpcap))
4375 (native-inputs
4376 (list autoconf automake))
4377 (synopsis "Network address discovery tool")
4378 (description "Netdiscover is a network address discovery tool developed
4379 mainly for wireless networks without a @acronym{DHCP} server. It also works
4380 on hub/switched networks. It is based on @acronym{ARP} packets, it will send
4381 @acronym{ARP} requests and sniff for replies.")
4382 (home-page "https://github.com/netdiscover-scanner/netdiscover")
4383 (license license:gpl3+)))
4384
4385 (define-public putty
4386 (package
4387 (name "putty")
4388 (version "0.77")
4389 (source
4390 (origin
4391 (method url-fetch)
4392 (uri (list (string-append "https://the.earth.li/~sgtatham/putty/"
4393 version "/putty-" version ".tar.gz")
4394 (string-append "http://www.putty.be/" version
4395 "/putty-" version ".tar.gz")))
4396 (sha256
4397 (base32 "1rgabc447a5aa9h16krpg3x78vh5jf4l6hkbqzr4bz9qabs7d6j1"))))
4398 (build-system cmake-build-system)
4399 (arguments
4400 `(#:phases
4401 (modify-phases %standard-phases
4402 (replace 'check
4403 ;; As ‘documented’ in ./Buildscr and the 0.76 Makefile.in.
4404 (lambda* (#:key tests? #:allow-other-keys)
4405 (when tests?
4406 (setenv "PUTTY_TESTCRYPT" "./testcrypt")
4407 (invoke (string-append "../putty-" ,version
4408 "/test/cryptsuite.py"))))))))
4409 (inputs
4410 (list gtk+))
4411 (native-inputs
4412 (list perl
4413 pkg-config
4414
4415 ;; For tests.
4416 python))
4417 (synopsis "Graphical @acronym{SSH, Secure SHell} and telnet client")
4418 (description "PuTTY is a graphical text terminal client. It supports
4419 @acronym{SSH, Secure SHell}, telnet, and raw socket connections with good
4420 terminal emulation. It can authenticate with public keys and Kerberos
4421 single-sign-on. It also includes command-line @acronym{SFTP, Secure File
4422 Transfer Protocol} and older @acronym{SCP, Secure Copy Protocol}
4423 implementations.")
4424 (home-page "https://www.chiark.greenend.org.uk/~sgtatham/putty/")
4425 (license license:expat)))