[exim] Extracting the registrar part of the hostname

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Marc Perkel
Date:  
À: exim-users
Sujet: [exim] Extracting the registrar part of the hostname
Making some progress extracting the registrar part (there should be a
term for this) from a host name. I created a DNS list the servers about
1400 TLDs using MyDNS (yes - I know they aren't really top level.)

Why do this? Working on tracking web sites mostly for white listing by
the main part of the sender host name. Here's code that seems to work.

warn    dnslists = rb.junkemailfilter.com=127.0.0.1/$sender_host_name
    set acl_c_sender_host_domain = 
${sg{$sender_host_name}{(\N^.*)\.(.*\..*)$\N}{\$2}}
    message = X-Sender-Domain: $acl_c_sender_host_domain


warn    dnslists = rb.junkemailfilter.com=127.0.0.2/$sender_host_name
    set acl_c_sender_host_domain = 
${sg{$sender_host_name}{(\N^.*)\.(.*\..*\..*)$\N}{\$2}}
    message = X-Sender-Domain: $acl_c_sender_host_domain


warn    dnslists = rb.junkemailfilter.com=127.0.0.3/$sender_host_name
    set acl_c_sender_host_domain = 
${sg{$sender_host_name}{(\N^.*)\.(.*\..*\..*\..*)$\N}{\$2}}
    message = X-Sender-Domain: $acl_c_sender_host_domain