diff options
author | Chris Rees <crees@FreeBSD.org> | 2013-05-15 17:29:33 +0000 |
---|---|---|
committer | Chris Rees <crees@FreeBSD.org> | 2013-05-15 17:29:33 +0000 |
commit | ef6baa35965adc8e867d48f995b10b1229875370 (patch) | |
tree | cdd4643238bb17905d3fee0cf5dc9805a4fe85e6 /security/cfs/files | |
parent | - Update GNU Awk to 4.1.0 (diff) |
security/cfs: Resurrect and maintain CFS.
The referenced security issues have been fixed in this version (1.5.0 beta), and
some small bugs have been found too, with many fixes from Debian's Gerrit Pape.
Obtained from: Debian (parts)
Security: CVE-2002-0351
Security: CVE-2006-3123
Notes
Notes:
svn path=/head/; revision=318250
Diffstat (limited to 'security/cfs/files')
-rw-r--r-- | security/cfs/files/cfsd.in | 49 | ||||
-rw-r--r-- | security/cfs/files/pkg-message.in | 22 |
2 files changed, 71 insertions, 0 deletions
diff --git a/security/cfs/files/cfsd.in b/security/cfs/files/cfsd.in new file mode 100644 index 000000000000..065f0daeaa1e --- /dev/null +++ b/security/cfs/files/cfsd.in @@ -0,0 +1,49 @@ +#!/bin/sh +# +# $FreeBSD$ +# +# PROVIDE: cfsd +# REQUIRE: mountd +# +# Add the following line to /etc/rc.conf to enable cfsd: +# +# cfsd_enable=YES +# +# Additional options: +# +# cfsd_port=3049 # the port to listen to +# cfsd_mountpoint=/crypt # the CFS mountpoint +# + +. /etc/rc.subr + +name=cfsd +rcvar=cfsd_enable + +load_rc_config $name + +: ${cfsd_enable=no} +: ${cfsd_port=3049} +: ${cfsd_mountpoint=/crypt} + +command=%%PREFIX%%/sbin/cfsd +command_args="$cfsd_port > /dev/null 2>&1" +required_dirs="%%CFSD_BOOTSTRAP%% $cfsd_mountpoint" +start_postcmd=cfsd_poststart +stop_precmd=cfsd_prestop + +cfsd_poststart() +{ + if [ -n "$cfsd_mountpoint" ]; then + mount -o port="$cfsd_port",mntudp,nfsv2 localhost:%%CFSD_BOOTSTRAP%% "$cfsd_mountpoint" + fi +} + +cfsd_prestop() +{ + if [ -n "$cfsd_mountpoint" ]; then + umount "$cfsd_mountpoint" + fi +} + +run_rc_command $1 diff --git a/security/cfs/files/pkg-message.in b/security/cfs/files/pkg-message.in new file mode 100644 index 000000000000..31217fe7c7e7 --- /dev/null +++ b/security/cfs/files/pkg-message.in @@ -0,0 +1,22 @@ +=============================================================================== +Quick start instructions: + + - add the following entry to /etc/exports: + + %%CFSD_BOOTSTRAP%% localhost + + - create the default CFS mountpoint (if you want to use a different + mountpoint, set the cfsd_mountpoint variable in /etc/rc.conf): + + # mkdir /crypt + + - enable rpcbind, mountd and cfsd in /etc/rc.conf: + + cfsd_enable="YES" + mountd_enable="YES" + + - start mountd and cfsd, or restart: + + # service mountd start + # service cfsd start +=============================================================================== |