2e85bc7502
* rfc2045mkboundary.c was broken in 0.68 Changes 0.68: * rfc2045/rfc2045mkboundary.c (rfc2045_mk_boundary): truncate the hostname portion of the boundary to 30 chars. * courier/doc/courier.sgml: Remove descriptions of some configuration files that were moved to the courier-authlib package a while ago. They don't belong here any more. * courier/submit.C: Use the authenticated address, instead of the return address, for domain-based virtual configuration. * courier/libs/cfilename.c (config_has_vhost): Checks whether vhost.[ip] exists. * courier/module.esmtp/courieresmtpd.c (main): Only set a message's virtual host if vhost.[ip] exists. * courier/module.esmtp/esmtpclient.c (get_sourceaddr): Make sure the input buffer is null-terminated. * courier/submit.C (getrcpts): If there's no vhost setting from the sender's IP address (this includes local mail!) if vhost.domain exists, use [domain] as the virtual host. * Remove config_search(), which simply called config_localfilename(). Change all current callers to call config_localfilename(). * courier/libs/cfilename.c (config_set_local_vhost): saves a string that gets appended as a suffix, by config_localfilename(), and if that filename exists, that's returned as the filename, otherwise it's the original string without the suffix. config_get_local_vhost() returns the suffix string. to config_set_local_vhost(). * courier/libs/comsubmitclient.c (submit_fork): If config_get_local_vhost(), add a -vhost parameter to submit(). * courier/submit.C (cppmain): -vhost sets config_set_local_vhost(). * courier/submit2.C (closectl): New COMCTLFILE_VHOST parameter in the config file, taken from the vhost setting. * courier/libs/comctlfile.c (ctlfile_setvhost): If COMCTLFILE_VHOST is set, call ctlfile_setvhost(), return an indication if the vhost has changed. Absence of a COMCTLFILE_VHOST treated as a discrete "(null)" setting. * courier/module.esmtp/esmtpclient.c (esmtpchild): If ctlfile_setvhost() then disconnect the current socket, if one is open. * courier/module.esmtp/esmtpclient.c (get_sourceaddr): The IP address specified in ipout or ip6out overrides SOURCE_ADDRESS and SOURCE_ADDRESS_IPV6 environment variable. * courier/module.local/localmail.c (main): Call ctlfile_setvhost(). * courier/module.uucp/uucp.c (uux): Call ctlfile_setvhost(). * courier/module.dsn/dsn.c (main): Call ctlfile_setvhost(). * liblock/mail.c (dotlock_exists): Quell a compiler warning. * courier/courierd.dist.in SOURCE_ADDRESS: Add a note that this setting is deprecated.
68 lines
2.3 KiB
Makefile
68 lines
2.3 KiB
Makefile
# $NetBSD: pkginstall.mk,v 1.8 2012/06/09 11:45:38 adam Exp $
|
|
|
|
# Convenience definition used below for a file or directory owned by the
|
|
# courier user and group.
|
|
#
|
|
COURIER_OWNED= ${COURIER_USER} ${COURIER_GROUP}
|
|
|
|
REQD_DIRS+= ${DATADIR} ${DOCDIR} ${EGDIR} \
|
|
${LIBEXECDIR} ${LIBEXECDIR}/modules
|
|
REQD_DIRS_PERMS+= ${LIBEXECDIR}/webmail \
|
|
${REAL_ROOT_USER} ${REAL_ROOT_GROUP} 0700
|
|
MAKE_DIRS+= ${COURIER_STATEDIR}
|
|
MAKE_DIRS_PERMS+= ${COURIER_STATEDIR}/tmp ${COURIER_OWNED} 0770
|
|
|
|
###
|
|
### Courier filter directories
|
|
###
|
|
OWN_DIRS_PERMS+= ${PKG_SYSCONFDIR}/filters ${COURIER_OWNED} 0750
|
|
OWN_DIRS_PERMS+= ${PKG_SYSCONFDIR}/filters/active \
|
|
${COURIER_OWNED} 0750
|
|
OWN_DIRS_PERMS+= ${COURIER_STATEDIR}/allfilters ${COURIER_OWNED} 0750
|
|
OWN_DIRS_PERMS+= ${COURIER_STATEDIR}/filters ${COURIER_OWNED} 0750
|
|
|
|
###
|
|
### Courier mail submission directories
|
|
###
|
|
OWN_DIRS_PERMS+= ${COURIER_STATEDIR}/msgq ${COURIER_OWNED} 0750
|
|
OWN_DIRS_PERMS+= ${COURIER_STATEDIR}/msgs ${COURIER_OWNED} 0750
|
|
OWN_DIRS_PERMS+= ${COURIER_STATEDIR}/track ${COURIER_OWNED} 0755
|
|
|
|
###
|
|
### Courier webadmin directories
|
|
###
|
|
OWN_DIRS_PERMS+= ${PKG_SYSCONFDIR}/webadmin ${COURIER_OWNED} 0700
|
|
OWN_DIRS_PERMS+= ${PKG_SYSCONFDIR}/webadmin/added \
|
|
${COURIER_OWNED} 0700
|
|
OWN_DIRS_PERMS+= ${PKG_SYSCONFDIR}/webadmin/removed \
|
|
${COURIER_OWNED} 0700
|
|
|
|
###
|
|
### Courier setuid and setgid binaries
|
|
###
|
|
SPECIAL_PERMS+= bin/cancelmsg ${COURIER_OWNED} 6555
|
|
SPECIAL_PERMS+= bin/mailq ${COURIER_OWNED} 2555
|
|
SPECIAL_PERMS+= bin/sendmail ${SETUID_ROOT_PERMS}
|
|
SPECIAL_PERMS+= libexec/courier/webmail/webadmin \
|
|
${SETUID_ROOT_PERMS}
|
|
SPECIAL_PERMS+= libexec/courier/submitmkdir ${COURIER_OWNED} 4550
|
|
|
|
###
|
|
### Courier delivery configuration directories
|
|
###
|
|
OWN_DIRS_PERMS+= ${PKG_SYSCONFDIR}/aliasdir ${COURIER_OWNED} 0755
|
|
OWN_DIRS_PERMS+= ${PKG_SYSCONFDIR}/aliases ${COURIER_OWNED} 0750
|
|
OWN_DIRS_PERMS+= ${PKG_SYSCONFDIR}/smtpaccess ${COURIER_OWNED} 0755
|
|
|
|
.for _file_ in aliases/system
|
|
CONF_FILES_PERMS+= ${EGDIR}/${_file_} ${PKG_SYSCONFDIR}/${_file_} \
|
|
${COURIER_OWNED} 0640
|
|
.endfor
|
|
.for _file_ in courierd.dist enablefiltering locallowercase maildrop \
|
|
maildropfilter smtpaccess/default webmlmrc.dist
|
|
CONF_FILES_PERMS+= ${EGDIR}/${_file_} \
|
|
${PKG_SYSCONFDIR}/${_file_:S/.dist$//} \
|
|
${COURIER_FILE_PERMS}
|
|
.endfor
|
|
|
|
RCD_SCRIPTS+= courier courierd courierfilter webmlm
|