

def auth(self, message_data=None, peer_ip=None, message=None):
    mailfrom = Contact.create_contacts_from_message_field('from', message)[0]
    host = re.match('[^@]*@(.*)', host.email).group(1)
    result_status = spf.check(i=peer_ip, s=mailfrom.email, h=host)[0]
    if ('pass' in result_status):
        return True
    return False

dataset/ETHPy150Open bcoe/smtproutes/smtproutes/sender_auth/spf_auth.py SPFAuth.auth/VarMisuse@44/62 `mailfrom`->`host`