git.schokokeks.org
Repositories
Help
Report an Issue
keks-overlay.git
Code
Commits
Branches
Tags
Suche
Strukturansicht:
278bcfc
Branches
Tags
master
keks-overlay.git
mail-mta
courier
files
set-mime
Version bump to current versions
Bernd Wurst
commited
278bcfc
at 2008-03-05 21:09:58
set-mime
Blame
History
Raw
#!/bin/sh # this has to be called with a list of configuration files to apply the # changes # example: ./set-mime /etc/courier/esmtpd /etc/courier/esmtpd-ssl files=$* chk_badmime='##NAME: BOFHBADMIME:0' pos_badmime='##NAME: NOADDMSGID:0' ins_badmime='\ ##NAME: BOFHBADMIME:0\ #\ # set BOFHBADMIME\ # to \"reject\" to return mail with invalid MIME header\ # to \"wrap\" to wrap mail with invalid MIME header in an attachmant\ # to \"accept\" to pass mail with invalid MIME header untouched\ \ BOFHBADMIME=accept\ ' for f in ${files} do if ! grep -q "${chk_badmime}" "${f}" then echo "adding parameter ${chk_badmime} to ${f}" cat ${f} | sed -e"/${pos_badmime}/ i ${ins_badmime}" > "${f}.tmp" && mv -f "${f}.tmp" "${f}" fi done