sendmail-common-1.7/000075500000000000000000000000001205131407200144345ustar00rootroot00000000000000sendmail-common-1.7/install/000075500000000000000000000000001205131407200161025ustar00rootroot00000000000000sendmail-common-1.7/install/etc/000075500000000000000000000000001205131407200166555ustar00rootroot00000000000000sendmail-common-1.7/install/etc/ppp/000075500000000000000000000000001205131407200174545ustar00rootroot00000000000000sendmail-common-1.7/install/etc/ppp/ip-up.d/000075500000000000000000000000001205131407200207305ustar00rootroot00000000000000sendmail-common-1.7/install/etc/ppp/ip-up.d/sendmail000075500000000000000000000001431205131407200224500ustar00rootroot00000000000000#!/bin/sh SENDMAIL=/usr/sbin/sendmail [ ! -x "$SENDMAIL" ] || exec "$SENDMAIL" -q >/dev/null 2>&1 sendmail-common-1.7/install/usr/000075500000000000000000000000001205131407200167135ustar00rootroot00000000000000sendmail-common-1.7/install/usr/share/000075500000000000000000000000001205131407200200155ustar00rootroot00000000000000sendmail-common-1.7/install/usr/share/sendmail-common/000075500000000000000000000000001205131407200230775ustar00rootroot00000000000000sendmail-common-1.7/install/usr/share/sendmail-common/aliases000064400000000000000000000004221205131407200244410ustar00rootroot00000000000000# # >>>>>>>>>> The program "newaliases" must be run after # >> NOTE >> this file is updated for any changes to # >>>>>>>>>> show through to MTA. # # Basic system aliases -- these MUST be present. MAILER-DAEMON: postmaster abuse: postmaster postmaster: root sendmail-common-1.7/install/usr/share/sendmail-common/make_aliases000075500000000000000000000043161205131407200254470ustar00rootroot00000000000000#!/bin/sh -e # # Copyright (C) 2000-2003,2006,2007 Dmitry V. Levin # # make_aliases # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. # : ${ALIASES_TEMPLATE:=/usr/share/sendmail-common/aliases} exit_handler() { local rc=$? trap - EXIT [ -z "$TMPFILE" ] || rm -f -- "$TMPFILE" exit $rc } if [ -z "$1" ]; then TMPFILE="$(mktemp -t -- "aliases.XXXXXXXX")" trap exit_handler HUP PIPE INT TERM EXIT WORKFILE="$TMPFILE" else TMPFILE= WORKFILE="$1" :>"$WORKFILE" fi # Basic system aliases cat "$ALIASES_TEMPLATE" |while read alias; do if printf %s "$alias" |egrep -qs '^[^#]*:'; then name=`printf %s "$alias" |cut -d: -f1` if v=`getent aliases "$name"`; then p="$v" else p="$alias" fi else p="$alias" fi printf '%s\n' "$p" >>"$WORKFILE" done UID_MIN=`grep -s ^UID_MIN /etc/login.defs |awk '{print $2;exit}'` [ -n "$UID_MIN" ] || UID_MIN=500 printf '\n%s\n' "# Person who should get root's mail." >>"$WORKFILE" r=`getent aliases root |head -1` if [ -n "$r" ]; then p="$r" else r="$(getent passwd | awk -F: -v "u=$UID_MIN" ' BEGIN {while((getline<"/etc/shells")>0) shells[$1]=1} ($3>=u && $1!="root" && $1!="postmaster" && ($7=="" || $7 in shells)) {print $1;exit} ')" if [ -n "$r" ]; then p="root: $r" else p='#root: you' fi fi printf '%s\n' "$p" >>"$WORKFILE" printf '\n%s\n' "# Local system aliases" >>"$WORKFILE" getent aliases |tr -s '[:blank:]' ' ' |while read alias; do tr -s '[:blank:]' ' ' <"$WORKFILE" |fgrep -qsx "$alias" || printf '%s\n' "$alias" >>"$WORKFILE" done [ -z "$TMPFILE" ] || cat "$TMPFILE" sendmail-common-1.7/install/usr/share/sendmail-common/rebuild_aliases000075500000000000000000000025671205131407200261660ustar00rootroot00000000000000#!/bin/sh -e # # rebuild_aliases # # Copyright (C) 2000-2003 Dmitry V. Levin # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA # # Do not load RH compatibility interface. WITHOUT_RC_COMPAT=1 # Source function library. . /etc/init.d/functions : ${ALIASES_TEMPLATE:=/usr/share/sendmail-common/aliases} : ${ALIASES:=/etc/aliases} Fatal() { echo "${0##*/}: $*" >&2 exit 1 } [ -s "$ALIASES_TEMPLATE" ] || Fatal "$ALIASES_TEMPLATE: not available or empty alias template." [ -d "${ALIASES%/*}" ] || Fatal "${ALIASES%/*}: not a directory." if [ -s "$ALIASES" ] && ! cmp -s "$ALIASES_TEMPLATE" "$ALIASES"; then OUT="$ALIASES.rpmnew" else OUT="$ALIASES" fi action "Creating $OUT:" /usr/share/sendmail-common/make_aliases "$OUT" sendmail-common-1.7/sendmail-common.spec000064400000000000000000000044631205131407200204010ustar00rootroot00000000000000Name: sendmail-common Version: 1.7 Release: alt3 Summary: Common files for sendmail-compatible MTAs License: GPL Group: System/Base BuildArch: noarch AutoReq: yes, nosymlinks Source: %name-%version.tar Requires: mktemp >= 1:1.3.1, sed # due to %_sbindir/{mailq,newaliases} symlinks Conflicts: ssmtp-common <= 2.64-alt2 %description This package contains files common for sendmail-compatible Mail Transport Agent packages, e.g. postfix and sendmail. %prep %setup %install mkdir -p %buildroot cp -av install/* %buildroot/ mkdir -p %buildroot{%_bindir,%_sbindir,/usr/lib} for f in %_bindir/mailq %_bindir/newaliases /usr/lib/sendmail; do ln -s ../sbin/sendmail "%buildroot$f" done for f in mailq newaliases; do ln -s sendmail "%buildroot%_sbindir/$f" done %files %config %_sysconfdir/ppp/ip-up.d/* %_bindir/* %_sbindir/* /usr/lib/* %_datadir/%name %changelog * Fri Nov 16 2012 Dmitry V. Levin 1.7-alt3 - Packaged %_sbindir/{mailq,newaliases} symlinks to eliminate unwanted dependencies on ssmtp-common. * Tue Aug 14 2012 Dmitry V. Levin 1.7-alt2 - Disabled /usr/sbin/sendmail requirement. * Tue May 06 2008 Dmitry V. Levin 1.7-alt1 - make_aliases: Fixed space sensitivity (#15549). * Sun Dec 23 2007 Dmitry V. Levin 1.6-alt1 - aliases: Removed stale entries. - make_aliases: Cleaned up. * Thu Mar 29 2007 Dmitry V. Levin 1.5-alt1 - make_aliases: + Changed to skip users with shells not listed in /etc/shells. - Specfile: + Fixed build on multilib architectures. * Sun Sep 03 2006 Dmitry V. Levin 1.4-alt1 - make_aliases: Cleaned up, fixed root autoaliasing (#8132). * Sun Oct 19 2003 Dmitry V. Levin 1.3-alt1 - Cleanup default aliases. - Do not create redirections for pseudoaccounts. - Use getent instead of direct file access. * Sun Dec 08 2002 Dmitry V. Levin 1.2-alt1 - Added /etc/ppp/ip-up.d/sendmail script (#0001605). * Fri Nov 15 2002 Dmitry V. Levin 1.1-alt2 - Minor fixes. * Mon May 20 2002 Dmitry V. Levin 1.1-alt1 - Added %_datadir/%name scripts (from /usr/share/postfix/). * Wed Aug 08 2001 Dmitry V. Levin 1.0.1-alt1 - Rebuilt. * Thu Feb 22 2001 Dmitry V. Levin 1.0-ipl1 - Initial revision.