UJP - SpamAssasinにホワイトリスト設定

Life is fun and easy!

不正IP報告数

Okan Sensor
 
メイン
ログイン
ブログ カテゴリ一覧

ブログ - SpamAssasinにホワイトリスト設定

SpamAssasinにホワイトリスト設定

カテゴリ : 
Apple » MacBook » 2008 13inch 1
ブロガー : 
ujpblog 2021/1/27 12:21
 当サイトへの不正ログインモニタリングの通知メールが,SpamAssasinによってスパム扱いを受けるようになった.



 スパムヘッダはこれ.

X-Spam-Flag: YES
X-Spam-Score: 7.269
X-Spam-Level: *******
X-Spam-Status: Yes, score=7.269 tagged_above=2 required=6
	tests=[BITCOIN_SPAM_07=3.499, BITCOIN_XPRIO=0.001,
	FORGED_SPF_HELO=2.297, NORMAL_HTTP_TO_IP=0.001,
	NUMERIC_HTTP_ADDR=0.001, PDS_BTC_ID=0.498, SPF_HELO_PASS=-0.001,
	SPF_SOFTFAIL=0.972, URIBL_BLOCKED=0.001]
	autolearn=no autolearn_force=no
 不正ログイン通知の検知本文情報によるのかなぁ.
 設定ファイルは以下の通り.
$ locate spamassassin|grep local.cf🆑
/Applications/Server.app/Contents/ServerRoot/private/etc/mail/spamassassin/local.cf.default
/Library/Server/Mail/Config/spamassassin/local.cf
/Library/Server/Mail/Config/spamassassin/local.cf.default
/Library/Server/Mail/Data/scanner/spamassassin/3.004001/updates_spamassassin_org/local.cf
$
 どれだ?!
 タイムスタンプを確認.
$ ls -la /Library/Server/Mail/Config/spamassassin/local.cf🆑
-rw-r--r-- 1 root wheel 2725  5 16  2020 /Library/Server/Mail/Config/spamassassin/local.cf
$ ls -la /Library/Server/Mail/Config/spamassassin/local.cf.default
-rw-r--r-- 1 root wheel 2706  9 13  2018 /Library/Server/Mail/Config/spamassassin/local.cf.default
$
 差分を確認.
$ diff /Library/Server/Mail/Config/spamassassin/local.cf.default /Library/Server/Mail/Config/spamassassin/local.cf🆑
99a100,101
>
> required_hits 6.0
$
 macOS Serverの管理画面を確認.


 サーバの設定を見ると,スコアが6.0なので一致.

 ホワイトリストを設定するため,まずは現在設定をコピー.
$ sudo cp -p /Library/Server/Mail/Config/spamassassin/local.cf /Library/Server/Mail/Config/spamassassin/local.cf.20210127🆑
$ ls -la /Library/Server/Mail/Config/spamassassin/local.cf*
-rw-r--r-- 1 root wheel 2725  5 16  2020 /Library/Server/Mail/Config/spamassassin/local.cf
-rw-r--r-- 1 root wheel 2725  5 16  2020 /Library/Server/Mail/Config/spamassassin/local.cf.20210127🈁
-rw-r--r-- 1 root wheel 2706  9 13  2018 /Library/Server/Mail/Config/spamassassin/local.cf.default
$
 ホワイトリストにしたいメアドやドメインを登録.
$ tail /Library/Server/Mail/Config/spamassassin/local.cf
# shortcircuit BAYES_00                ham

endif # Mail::SpamAssassin::Plugin::Shortcircuit


required_hits 6.0

whitelist_from *@xxxxx.or.jp🈁
whitelist_from *@yyy.jp🈁
whitelist_from *@mail.xxx.jp🈁
$
 保存したら文法チェック.
sh-3.2# spamassassin --lint🆑
sh-3.2#

 これで様子見かな.

トラックバック


広告スペース
Google