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