git.schokokeks.org
Repositories
Help
Report an Issue
keks-overlay.git
Code
Commits
Branches
Tags
Suche
Strukturansicht:
7013f95
Branches
Tags
master
keks-overlay.git
mail-mta
courier
files
set-mime
Wir brauchen Courier >= 0.65.1 und das ist noch nicht im Tree. Daher hier im Overlay.
Bernd Wurst
commited
7013f95
at 2010-12-08 06:40:37
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