gnu: rpcbind, libtirpc: Fix CVE-2017-8779.
[jackhill/guix/guix.git] / gnu / packages / onc-rpc.scm
CommitLineData
3e424f25 1;;; GNU Guix --- Functional package management for GNU
89e34644 2;;; Copyright © 2014, 2017 Ludovic Courtès <ludo@gnu.org>
7e348e6c 3;;; Copyright © 2016 John Darrington <jmd@gnu.org>
65df7d4f 4;;; Copyright © 2017 Leo Famulari <leo@famulari.name>
3e424f25
LC
5;;;
6;;; This file is part of GNU Guix.
7;;;
8;;; GNU Guix is free software; you can redistribute it and/or modify it
9;;; under the terms of the GNU General Public License as published by
10;;; the Free Software Foundation; either version 3 of the License, or (at
11;;; your option) any later version.
12;;;
13;;; GNU Guix is distributed in the hope that it will be useful, but
14;;; WITHOUT ANY WARRANTY; without even the implied warranty of
15;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16;;; GNU General Public License for more details.
17;;;
18;;; You should have received a copy of the GNU General Public License
19;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
20
21(define-module (gnu packages onc-rpc)
22 #:use-module (guix licenses)
23 #:use-module (guix packages)
24 #:use-module (guix download)
c39a54f4 25 #:use-module (gnu packages)
89e34644 26 #:use-module (gnu packages kerberos)
7e348e6c 27 #:use-module (gnu packages pkg-config)
3e424f25
LC
28 #:use-module (guix build-system gnu))
29
30(define-public libtirpc
31 (package
32 (name "libtirpc")
2beb879b 33 (version "1.0.1")
3e424f25
LC
34 (source (origin
35 (method url-fetch)
de67e922 36 (uri (string-append "mirror://sourceforge/libtirpc/libtirpc/"
3e424f25
LC
37 version "/libtirpc-"
38 version ".tar.bz2"))
c39a54f4 39 (patches (search-patches "libtirpc-CVE-2017-8779.patch"))
3e424f25
LC
40 (sha256
41 (base32
2beb879b 42 "17mqrdgsgp9m92pmq7bvr119svdg753prqqxmg4cnz5y657rfmji"))))
3e424f25
LC
43 (build-system gnu-build-system)
44 (arguments
1da82dbb
JD
45 `(#:phases
46 (modify-phases %standard-phases
47 (add-after 'unpack 'remote-dangling-symlink
48 (lambda _
7b706a49
JD
49 (substitute* '("man/netconfig.5"
50 "man/getnetconfig.3t"
51 "man/getnetpath.3t"
52 "man/rpc.3t"
53 "src/getnetconfig.c"
54 "tirpc/netconfig.h")
55 (("/etc/netconfig") (string-append %output "/etc/netconfig")))
56
1da82dbb
JD
57 ;; Remove the dangling symlinks since it breaks the
58 ;; 'patch-source-shebangs' file tree traversal.
59 (delete-file "INSTALL"))))))
13bef904 60 (inputs `(("mit-krb5" ,mit-krb5)))
3b3b60d0 61 (home-page "https://sourceforge.net/projects/libtirpc/")
3e424f25
LC
62 (synopsis "Transport-independent Sun/ONC RPC implementation")
63 (description
64 "This package provides a library that implements the Sun/ONC RPC (remote
65procedure calls) protocol in a transport-independent manner. It supports both
66IPv4 and IPv6. ONC RPC is notably used by the network file system (NFS).")
67 (license bsd-3)))
7e348e6c
JD
68
69(define-public rpcbind
70 (package
71 (name "rpcbind")
65df7d4f 72 (version "0.2.4")
7e348e6c
JD
73 (source
74 (origin
75 (method url-fetch)
76 (uri (string-append "mirror://sourceforge/" name "/" name "/"
77 version "/"
78 name "-" version ".tar.bz2"))
c39a54f4 79 (patches (search-patches "rpcbind-CVE-2017-8779.patch"))
7e348e6c
JD
80 (sha256
81 (base32
65df7d4f 82 "0rjc867mdacag4yqvs827wqhkh27135rp9asj06ixhf71m9rljh7"))))
7e348e6c
JD
83 (build-system gnu-build-system)
84 (arguments
85 `(#:configure-flags
db8b5f52 86 `("--with-systemdsystemunitdir=no" "--enable-warmstarts")))
7e348e6c
JD
87 (inputs
88 `(("libtirpc" ,libtirpc)))
89 (native-inputs
90 `(("pkg-config" ,pkg-config)))
91 (home-page "http://rpcbind.sourceforge.net/")
92 (synopsis "Server to convert RPC program numbers into universal addresses")
93 (description
94 "@command{Rpcbind} is a server that converts RPC program numbers into
95universal addresses.")
96 (license bsd-3)))
97