I'm referring to the port Makefile with FreeBSD Id:
$FreeBSD: ports/net-mgmt/net-snmp4/Makefile,v 1.105 2007/06/21 06:59:36 rafan Exp $
Line 139 of the Makefile installs files/snmpd.sh.sample into /usr/local/etc/rc.d/snmpd.sh.
This is *not* a FreeBSD-style rc script. It simply switches on "$1" for the word start or stop and performs that action. It does *not* use /etc/rc.subr to determine whether snmpd has been enabled.
As a result, snmpd will be started during boot on any machine where the port net-mgmt/net-snmp4 is installed. Some would consider this to be a security problem.
Fix: I've included a patch that creates a FreeBSD-style rc script in files and updates the port to install it.
Patch attached with submission follows:
I'll take it.
rafan 2007-07-27 11:59:29 UTC
FreeBSD ports repository
net-mgmt/net-snmp4 Makefile pkg-plist
- Convert to rc.d style script
- Bump PORTREVISION
Note that I changed few places of the patch to match Porter's Handbook.
Submitted by: Chris Cowart <ccowart at rescomp.berkeley.edu>
Revision Changes Path
1.106 +2 -6 ports/net-mgmt/net-snmp4/Makefile
1.1 +26 -0 ports/net-mgmt/net-snmp4/files/snmpd.in (new)
1.2 +0 -20 ports/net-mgmt/net-snmp4/files/snmpd.sh.sample (dead)
1.24 +0 -1 ports/net-mgmt/net-snmp4/pkg-plist
email@example.com mailing list
To unsubscribe, send any mail to "firstname.lastname@example.org"
Committed with changes. Thanks.