On 9/22/2018 9:55 AM, RW wrote:
  /^v=spf1 .+(\?|\+)all$/

I believe [?+] would do the same easy to read, parse and maybe even to
process (I have no idea how perl RE optimizer works)

.+ should be .* or it wont match

  'v=spf1 +all'

I would remove the '$' as it doesn't appear do anything useful and could
prevent matches on weird spf records.

It may be worth splitting them into two rules for '?' and '+', there's
no dns overhead and they seem like significantly different cases.

hypotetically - masschecks should prove that.

On 22.09.18 09:57, Kevin A. McGrail wrote:
# SPF THAT DOESN'T REALLY CARE IF EMAIL IS A FORGERY -
ifplugin Mail::SpamAssassin::Plugin::AskDNS
  askdns   JMQ_SPF_NEUTRAL _SENDERDOMAIN_ TXT /^v=spf1 .*?\?all/
  describe JMQ_SPF_NEUTRAL SPF set to ?all
  score    JMQ_SPF_NEUTRAL 0.5

  askdns   JMQ_SPF_ALL _SENDERDOMAIN_ TXT /^v=spf1 .*?\+all/
  describe JMQ_SPF_ALL SPF set to +all!
  score    JMQ_SPF_ALL 0.5
endif

remove those ?'s:

/^v=spf1 .*\?all/
and
/^v=spf1 .*\+all/

--
Matus UHLAR - fantomas, uh...@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Windows found: (R)emove, (E)rase, (D)elete

Reply via email to