Skip to content

Test a mail server against blacklists.

License

Notifications You must be signed in to change notification settings

teqneers/blcheck

 
 

Repository files navigation

blcheck

A powerful script for testing a domain or an IP against mailing block and allow lists. Script will use dig if it is found. If dig is not found script will use host.

Features

  • More then 300 block lists already included!
  • Automatic distinction between domain or IP
  • Performs PTR validation (only if domain is supplied, does not work for IP)
  • 3 verbose (-v) levels and a quiet (-q) mode
  • The result of script is the number of services which blocklisted the domain, so it can be used for any kind of automated scripts or cronjobs
  • Informative and pleasant output

Requirements

  • Any Unix/Linux or macOS with BASH.
  • Either dig or host command available.
  • GNU parallel command available.

Usage

blcheck [options] <domain\_or\_IP>

Supplied domain must be full qualified domain name.
If the IP is supplied, the PTR check cannot be executed and will be skipped.

<pre>
-d dnshost  Use host as DNS server to make lookups
-l file     Load lists from file with one entry per line
-c          Warn if the top level domain of the list has expired
-v          Verbose mode, can be used multiple times (up to -vvv)
-q          Quiet mode with absolutely no output (useful for scripts)
-p          Plain text output (no coloring, no interactive status)
-t          Thread numbers (4) or percentage (75%) of cores to use
-h          The help you are just reading
</pre>

Result of the script is the number of blocklisted entries. So if the supplied
IP is not blocklisted on any of the servers the return code is 0.

TODO

  1. Handle domains with multiple DNS entries.

Licence

blcheck is distributed under the terms of the MIT license. See license file for details.

Credits

Script has been written by the Intellex team. Additional contributors:

About

Test a mail server against blacklists.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 51.5%
  • Shell 44.7%
  • Makefile 3.8%