Spam assassin custom rule to block PDF files having Urls.

Indunil Jayasooriya indunil75 at gmail.com
Fri Jul 1 17:06:45 CEST 2022


Hi,

I wrote the rule below.

uri SPAM_1Jul2022_uri_1 /https?\:\/\/t.ly\/8R_H/i
describe SPAM_1Jul2022_uri_1 Email containing above words
score SPAM_1Jul2022_uri_1 11.0

It can NOT detect this url inside the PDF file.

But, if I just write it to the mail body, It can detect it.

I need a rule that can detect urls inside a PDF file. Can you guide me?

Hope to hear from you.







On Fri, Jul 1, 2022 at 6:17 PM Indunil Jayasooriya <indunil75 at gmail.com>
wrote:

> Dear List,
>
> We get some PDF files. When we open them there is a link inside the PDF
> file. We don't need these since these urls may be harmful.
>
> Here's one Url that the PDF file contained.
>
> https://t.ly/8R_H
>
> Can we block these with Spam Assassin?
>
> If so, how to write a custom rule for it?
>
> Below Url has some instructions.
>
> https://cwiki.apache.org/confluence/display/SPAMASSASSIN/writingrules
>
>
>
>
>
>
>
>
> --
> cat /etc/motd
>
> Thank you
> Indunil Jayasooriya
> http://www.theravadanet.net/
>
>

-- 
cat /etc/motd

Thank you
Indunil Jayasooriya
http://www.theravadanet.net/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.amavis.org/pipermail/amavis-users/attachments/20220701/e2209a6f/attachment.htm>


More information about the amavis-users mailing list