[sendmail/f13/master] - fixed m4 ldap routing macro, backported from 8.14.5.Alpha0, (#650366) - fixed MAXHOSTNAMELEN (#485

Jaroslav Škarvada jskarvad at fedoraproject.org
Mon Nov 8 14:18:28 UTC 2010


commit bdb15b035da759f48acff350553cb6494ec9d2a8
Author: Jaroslav Škarvada <jskarvad at redhat.com>
Date:   Mon Nov 8 15:18:22 2010 +0100

    - fixed m4 ldap routing macro, backported from 8.14.5.Alpha0, (#650366)
    - fixed MAXHOSTNAMELEN (#485380)
    - updated sendmail.nm-dispatcher script to handle VPN connections (#577540)
    - added comments about purpose of files and patches

 sendmail-8.14.4-m4-ldap-routing.patch |   45 ++++++++++++++++++++++++++++
 sendmail.nm-dispatcher                |    8 +++--
 sendmail.spec                         |   52 ++++++++++++++++++++++++++++----
 3 files changed, 95 insertions(+), 10 deletions(-)
---
diff --git a/sendmail-8.14.4-m4-ldap-routing.patch b/sendmail-8.14.4-m4-ldap-routing.patch
new file mode 100644
index 0000000..70d425d
--- /dev/null
+++ b/sendmail-8.14.4-m4-ldap-routing.patch
@@ -0,0 +1,45 @@
+--- sendmail-bak/cf/feature/ldap_routing.m4	2009-06-26 23:11:08.000000000 +0200
++++ sendmail/cf/feature/ldap_routing.m4	2010-01-05 01:57:27.000000000 +0100
+@@ -35,40 +35,12 @@
+        _ARG6_, `tempfail', `define(`_LDAP_ROUTE_MAPTEMP_', `_TEMPFAIL_')',
+        _ARG6_, `queue', `define(`_LDAP_ROUTE_MAPTEMP_', `_QUEUE_')')
+ 
+-define(`_ATMPF_', `<TMPF>')dnl
+-dnl check whether arg contains -T`'_ATMPF_
+-dnl unless it is a sequence map or just LDAP
+-dnl note: this does not work if ARG1 begins with space(s), however, as
+-dnl we issue a warning, hopefully the user will fix it...
+-ifelse(defn(`_ARG1_'), `', `',
+-  defn(`_ARG1_'), `LDAP', `',
+-  `ifelse(index(_ARG1_, `sequence '), `0', `',
+-    `ifelse(index(_ARG1_, _ATMPF_), `-1',
+-      `errprint(`*** WARNING: missing -T'_ATMPF_` in first argument of FEATURE(`ldap_routing')
+-')
+-      define(`_ABP_', index(_ARG1_, ` '))
+-      define(`_NARG1_', `substr(_ARG1_, 0, _ABP_) -T'_ATMPF_` substr(_ARG1_, _ABP_)')
+-      ')
+-    ')
+-  ')
+-ifelse(defn(`_ARG2_'), `', `',
+-  defn(`_ARG2_'), `LDAP', `',
+-  `ifelse(index(_ARG2_, `sequence '), `0', `',
+-    `ifelse(index(_ARG2_, _ATMPF_), `-1',
+-      `errprint(`*** WARNING: missing -T'_ATMPF_` in second argument of FEATURE(`ldap_routing')
+-')
+-      define(`_ABP_', index(_ARG2_, ` '))
+-      define(`_NARG2_', `substr(_ARG2_, 0, _ABP_) -T'_ATMPF_` substr(_ARG2_, _ABP_)')
+-      ')
+-    ')
+-  ')
+-
+ LOCAL_CONFIG
+ # LDAP routing maps
+ Kldapmh ifelse(len(X`'_ARG1_), `1',
+ 	       `ldap -1 -T<TMPF> -v mailHost -k (&(objectClass=inetLocalMailRecipient)(mailLocalAddress=%0))',
+-	       defn(`_NARG1_'), `', `_ARG1_', `_NARG1_')
++	       `_ARG1_')
+ 
+ Kldapmra ifelse(len(X`'_ARG2_), `1',
+ 		`ldap -1 -T<TMPF> -v mailRoutingAddress -k (&(objectClass=inetLocalMailRecipient)(mailLocalAddress=%0))',
+-		defn(`_NARG2_'), `', `_ARG2_', `_NARG2_')
++		`_ARG2_')
diff --git a/sendmail.nm-dispatcher b/sendmail.nm-dispatcher
index 5d30871..75dceb9 100644
--- a/sendmail.nm-dispatcher
+++ b/sendmail.nm-dispatcher
@@ -1,5 +1,7 @@
 #!/bin/sh
 
-if [ "$2" = "up" ] || [ "$2" = "down" ]; then
-	/sbin/service sendmail reload || :
-fi
+case "$2" in
+	up|down|vpn-up|vpn-down)
+		/sbin/service sendmail reload || :
+		;;
+esac
diff --git a/sendmail.spec b/sendmail.spec
index 73695e4..d2bc480 100644
--- a/sendmail.spec
+++ b/sendmail.spec
@@ -14,41 +14,72 @@
 Summary: A widely used Mail Transport Agent (MTA)
 Name: sendmail
 Version: 8.14.4
-Release: 5%{?dist}
+Release: 6%{?dist}
 License: Sendmail
 Group: System Environment/Daemons
 URL: http://www.sendmail.org/
 Source0: ftp://ftp.sendmail.org/pub/sendmail/sendmail.%{version}.tar.gz
+# init script
 Source1: sendmail.init
+# NetworkManager dispatch script
 Source2: sendmail.nm-dispatcher
+# script to generate db and cf files
 Source3: sendmail.etc-mail-make
+# default sysconfig file
 Source4: sendmail.sysconfig
+# default /etc/mail/Makefile
 Source5: sendmail.etc-mail-Makefile
+# default sendmail.mc
 Source6: sendmail-redhat.mc
+# pam config
 Source8: sendmail.pam
 Source9: sendmail-8.12.5-newconfig.readme
+# sasl2 config
 Source11: Sendmail-sasl2.conf
+# default /etc/mail/access
 Source12: sendmail-etc-mail-access
+# default /etc/mail/domaintable
 Source13: sendmail-etc-mail-domaintable
+# default /etc/mail/local-host-names
 Source14: sendmail-etc-mail-local-host-names
+# default /etc/mail/mailertable
 Source15: sendmail-etc-mail-mailertable
+# default /etc/mail/trusted-users
 Source16: sendmail-etc-mail-trusted-users
+# default /etc/mail/virtusertable
 Source17: sendmail-etc-mail-virtusertable
+# fix man path and makemap man page
 Patch3: sendmail-8.14.4-makemapman.patch
+# fix smrsh paths
 Patch4: sendmail-8.14.3-smrsh_paths.patch
+# fix sm-client.pid path
 Patch7: sendmail-8.13.7-pid.patch
+# do not reject all numeric login names if hesiod support is compiled in, #80060
 Patch9: sendmail-8.12.7-hesiod.patch
+# fix sendmail man page
 Patch10: sendmail-8.12.7-manpage.patch
+# compile with -fpie
 Patch11: sendmail-8.14.4-dynamic.patch
+# fix cyrus path
 Patch12: sendmail-8.13.0-cyrus.patch
+# fix aliases.db path
 Patch13: sendmail-8.14.4-aliases_dir.patch
+# fix vacation Makefile
 Patch14: sendmail-8.13.7-vacation.patch
+# remove version information from sendmail helpfile
 Patch15: sendmail-8.14.1-noversion.patch
+# do not accept localhost.localdomain as valid address from smtp
 Patch16: sendmail-8.13.1-localdomain.patch
+# build libmilter as DSO
 Patch17: sendmail-8.14.3-sharedmilter.patch
+# skip colon separator when parsing service name in ServiceSwitchFile
 Patch18: sendmail-8.14.4-switchfile.patch
+# fix milter file descriptors leaks, #485426
 Patch20: sendmail-8.14.3-milterfdleaks.patch
+# handle IPv6:::1 in block_bad_helo.m4 like 127.0.0.1, #549217
 Patch21: sendmail-8.14.3-ipv6-bad-helo.patch
+# fix m4 ldap routing macro, #650366
+Patch24: sendmail-8.14.4-m4-ldap-routing.patch
 Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 BuildRequires: tcp_wrappers-devel
 BuildRequires: db4-devel
@@ -161,6 +192,7 @@ cp devtools/M4/UNIX/{,shared}library.m4
 %patch18 -p1 -b .switchfile
 %patch20 -p1 -b .milterfdleaks
 %patch21 -p1 -b .ipv6-bad-helo
+%patch24 -p1 -b .m4-ldap-routing
 
 for f in RELEASE_NOTES contrib/etrn.0; do
 	iconv -f iso8859-1 -t utf8 -o ${f}{_,} &&
@@ -172,7 +204,7 @@ done
 cat > redhat.config.m4 << EOF
 define(\`confMAPDEF', \`-DNEWDB -DNIS -DHESIOD -DMAP_REGEX -DSOCKETMAP -DNAMED_BIND=1')
 define(\`confOPTIMIZE', \`\`\`\`${RPM_OPT_FLAGS}'''')
-define(\`confENVDEF', \`-I%{_includedir}/db -I/usr/kerberos/include -Wall -DXDEBUG=0 -DTCPWRAPPERS -DNETINET6 -DHES_GETMAILHOST -DUSE_VENDOR_CF_PATH=1 -D_FFR_TLS_1')
+define(\`confENVDEF', \`-I%{_includedir}/libdb -I/usr/kerberos/include -Wall -DXDEBUG=0 -DTCPWRAPPERS -DNETINET6 -DHES_GETMAILHOST -DUSE_VENDOR_CF_PATH=1 -D_FFR_TLS_1 -D_FFR_LINUX_MHNL')
 define(\`confLIBDIRS', \`-L/usr/kerberos/%{_lib}')
 define(\`confLIBS', \`-lnsl -lwrap -lhesiod -lcrypt -ldb -lresolv')
 define(\`confMANOWN', \`root')
@@ -457,7 +489,7 @@ exit 0
 %postun milter -p /sbin/ldconfig
 
 %files
-%defattr(-,root,root)
+%defattr(-,root,root,-)
 %dir %{_docdir}/sendmail-%{version}
 %doc %{_docdir}/sendmail-%{version}/FAQ
 %doc %{_docdir}/sendmail-%{version}/KNOWNBUGS
@@ -522,7 +554,7 @@ exit 0
 %config %{_libdir}/sasl*/Sendmail*.conf
 
 %files cf
-%defattr(-,root,root)
+%defattr(-,root,root,-)
 %doc %{sendmailcf}/README
 %dir %{sendmailcf}
 %{sendmailcf}/cf
@@ -537,19 +569,19 @@ exit 0
 %{sendmailcf}/siteconfig
 
 %files devel
-%defattr(-,root,root)
+%defattr(-,root,root,-)
 %doc libmilter/docs/*
 %dir %{_includedir}/libmilter
 %{_includedir}/libmilter/*.h
 %{_libdir}/libmilter.so
 
 %files milter
-%defattr(-,root,root)
+%defattr(-,root,root,-)
 %{_libdir}/libmilter.so.[0-9].[0-9]
 %{_libdir}/libmilter.so.[0-9].[0-9].[0-9]
 
 %files doc
-%defattr(-,root,root)
+%defattr(-,root,root,-)
 %{_docdir}/sendmail-%{version}/README.cf
 %{_docdir}/sendmail-%{version}/README.libmilter
 %{_docdir}/sendmail-%{version}/README.redhat
@@ -562,6 +594,12 @@ exit 0
 
 
 %changelog
+* Mon Nov 08 2010 Jaroslav Škarvada <jskarvad at redhat.com> - 8.14.4-6
+- fixed m4 ldap routing macro, backported from 8.14.5.Alpha0, (#650366)
+- fixed MAXHOSTNAMELEN (#485380)
+- updated sendmail.nm-dispatcher script to handle VPN connections (#577540)
+- added comments about purpose of files and patches
+
 * Tue Sep 14 2010 Jaroslav Škarvada <jskarvad at redhat.com> - 8.14.4-5
 - rebuilt with db4-4.8.30 (#633269)
 


More information about the scm-commits mailing list