nfs-kernel-server: use portmap, drop rpcbind
This commit is contained in:
parent
eca82ce3db
commit
54928eb69d
|
@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk
|
||||||
|
|
||||||
PKG_NAME:=nfs-kernel-server
|
PKG_NAME:=nfs-kernel-server
|
||||||
PKG_VERSION:=2.3.3
|
PKG_VERSION:=2.3.3
|
||||||
PKG_RELEASE:=2
|
PKG_RELEASE:=3
|
||||||
PKG_HASH:=3c8c63611c7e78b7a3b2f8a28b9928a5b5e66d5e9ad09a1e54681508884320a4
|
PKG_HASH:=3c8c63611c7e78b7a3b2f8a28b9928a5b5e66d5e9ad09a1e54681508884320a4
|
||||||
|
|
||||||
PKG_SOURCE_URL:=@SF/nfs
|
PKG_SOURCE_URL:=@SF/nfs
|
||||||
|
@ -37,7 +37,7 @@ endef
|
||||||
define Package/nfs-kernel-server
|
define Package/nfs-kernel-server
|
||||||
$(call Package/nfs-kernel-server/Default)
|
$(call Package/nfs-kernel-server/Default)
|
||||||
TITLE:=Kernel NFS server support
|
TITLE:=Kernel NFS server support
|
||||||
DEPENDS+= +kmod-fs-nfsd +kmod-fs-nfs +rpcbind
|
DEPENDS+= +kmod-fs-nfsd +kmod-fs-nfs +portmap
|
||||||
endef
|
endef
|
||||||
|
|
||||||
define Package/nfs-kernel-server/description
|
define Package/nfs-kernel-server/description
|
||||||
|
|
|
@ -1,69 +0,0 @@
|
||||||
include $(TOPDIR)/rules.mk
|
|
||||||
|
|
||||||
PKG_NAME:=rpcbind
|
|
||||||
PKG_VERSION:=1.2.5
|
|
||||||
PKG_RELEASE:=2
|
|
||||||
|
|
||||||
PKG_SOURCE_URL:=@SF/rpcbind
|
|
||||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
|
||||||
PKG_HASH:=2ce360683963b35c19c43f0ee2c7f18aa5b81ef41c3fdbd15ffcb00b8bffda7a
|
|
||||||
|
|
||||||
PKG_MAINTAINER:=Andy Walsh <andy.walsh44+github@gmail.com>
|
|
||||||
PKG_LICENSE:=BSD-3-Clause
|
|
||||||
PKG_CPE_ID:=cpe:/a:rpcbind_project:rpcbind
|
|
||||||
|
|
||||||
PKG_FIXUP:=autoreconf
|
|
||||||
PKG_REMOVE_FILES:=autogen.sh aclocal.m4
|
|
||||||
PKG_INSTALL:=1
|
|
||||||
|
|
||||||
PKG_CONFIG_DEPENDS:= \
|
|
||||||
CONFIG_RPCBIND_LIBWRAP
|
|
||||||
|
|
||||||
include $(INCLUDE_DIR)/package.mk
|
|
||||||
|
|
||||||
define Package/rpcbind
|
|
||||||
SECTION:=net
|
|
||||||
CATEGORY:=Network
|
|
||||||
DEPENDS:=+libtirpc +RPCBIND_LIBWRAP:libwrap
|
|
||||||
TITLE:=Universal addresses to RPC mapper
|
|
||||||
URL:=http://rpcbind.sourceforge.net/
|
|
||||||
USERID:=rpc=65533:rpc=65533
|
|
||||||
endef
|
|
||||||
|
|
||||||
define Package/rpcbind/description
|
|
||||||
The rpcbind utility is a server that converts RPC program numbers into universal addresses.
|
|
||||||
It must be running on the host to be able to make RPC calls on a server on that machine.
|
|
||||||
|
|
||||||
Rpcbind replaces portmap for NFS v2/v3. It has more features, like ipv6 support.
|
|
||||||
Note: Nfs4 only configurations can run without it.
|
|
||||||
endef
|
|
||||||
|
|
||||||
define Package/rpcbind/config
|
|
||||||
if PACKAGE_rpcbind
|
|
||||||
config RPCBIND_LIBWRAP
|
|
||||||
bool "Enable libwrap (TCP wrappers) support."
|
|
||||||
default y
|
|
||||||
endif
|
|
||||||
endef
|
|
||||||
|
|
||||||
CONFIGURE_ARGS += \
|
|
||||||
--with-rpcuser=rpc \
|
|
||||||
--without-systemdsystemunitdir \
|
|
||||||
--enable-warmstarts
|
|
||||||
|
|
||||||
ifeq ($(CONFIG_RPCBIND_LIBWRAP),y)
|
|
||||||
CONFIGURE_ARGS += --enable-libwrap
|
|
||||||
else
|
|
||||||
CONFIGURE_ARGS += --disable-libwrap
|
|
||||||
endif
|
|
||||||
|
|
||||||
define Package/rpcbind/install
|
|
||||||
$(INSTALL_DIR) $(1)/usr/bin
|
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/rpcinfo $(1)/usr/bin/
|
|
||||||
$(INSTALL_DIR) $(1)/usr/sbin
|
|
||||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/rpcbind $(1)/usr/sbin/
|
|
||||||
$(INSTALL_DIR) $(1)/etc/init.d
|
|
||||||
$(INSTALL_BIN) ./files/rpcbind.init $(1)/etc/init.d/rpcbind
|
|
||||||
endef
|
|
||||||
|
|
||||||
$(eval $(call BuildPackage,rpcbind))
|
|
|
@ -1,13 +0,0 @@
|
||||||
#!/bin/sh /etc/rc.common
|
|
||||||
|
|
||||||
START=19
|
|
||||||
STOP=19
|
|
||||||
|
|
||||||
USE_PROCD=1
|
|
||||||
|
|
||||||
start_service() {
|
|
||||||
procd_open_instance
|
|
||||||
procd_set_param command /usr/sbin/rpcbind -f -w
|
|
||||||
procd_set_param respawn
|
|
||||||
procd_close_instance
|
|
||||||
}
|
|
|
@ -1,29 +0,0 @@
|
||||||
Submitted By: Ken Moffat <ken at linuxfromscratch dot org>
|
|
||||||
Date: 2017-05-29
|
|
||||||
Initial Package Version: 0.2.4 (also affects earlier versions)
|
|
||||||
Upstream Status: Unknown
|
|
||||||
Origin: Guido Vranken
|
|
||||||
Description: Fixes CVE-2017-8779 (DOS by remote attackers - memory consumption
|
|
||||||
without subsequent free).
|
|
||||||
|
|
||||||
diff --git a/src/rpcb_svc_com.c b/src/rpcb_svc_com.c
|
|
||||||
index 5862c26..e11f61b 100644
|
|
||||||
--- a/src/rpcb_svc_com.c
|
|
||||||
+++ b/src/rpcb_svc_com.c
|
|
||||||
@@ -48,6 +48,7 @@
|
|
||||||
#include <rpc/rpc.h>
|
|
||||||
#include <rpc/rpcb_prot.h>
|
|
||||||
#include <rpc/svc_dg.h>
|
|
||||||
+#include <rpc/rpc_com.h>
|
|
||||||
#include <netconfig.h>
|
|
||||||
#include <errno.h>
|
|
||||||
#include <syslog.h>
|
|
||||||
@@ -432,7 +433,7 @@ rpcbproc_taddr2uaddr_com(void *arg, struct svc_req *rqstp /*__unused*/,
|
|
||||||
static bool_t
|
|
||||||
xdr_encap_parms(XDR *xdrs, struct encap_parms *epp)
|
|
||||||
{
|
|
||||||
- return (xdr_bytes(xdrs, &(epp->args), (u_int *) &(epp->arglen), ~0));
|
|
||||||
+ return (xdr_bytes(xdrs, &(epp->args), (u_int *) &(epp->arglen), RPC_MAXDATASIZE));
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
Loading…
Reference in New Issue