openc2lib.types.targets.idn_email_addr
1from openc2lib.types.targets.email_addr import EmailAddr 2from openc2lib.core.target import target 3 4@target('idn_email_addr') 5class IDNEmailAddr(EmailAddr): 6 """ OpenC2 IDNEmailAddr 7 8 Implements the `idn_email_addr` target (Section 3.4.1.8). 9 A single internationalized email address. 10 """ 11 12 def set(self, email): 13 """ Allows IDN email (RFC6531): there is a dedicated class for this (`IDNEmailAddr`). """ 14 emailinfo = email_validator.validate_email(email, check_deliverability=False,allow_smtputf8=True) 15 self._emailaddr = emailinfo.normalized
5@target('idn_email_addr') 6class IDNEmailAddr(EmailAddr): 7 """ OpenC2 IDNEmailAddr 8 9 Implements the `idn_email_addr` target (Section 3.4.1.8). 10 A single internationalized email address. 11 """ 12 13 def set(self, email): 14 """ Allows IDN email (RFC6531): there is a dedicated class for this (`IDNEmailAddr`). """ 15 emailinfo = email_validator.validate_email(email, check_deliverability=False,allow_smtputf8=True) 16 self._emailaddr = emailinfo.normalized
OpenC2 IDNEmailAddr
Implements the idn_email_addr target (Section 3.4.1.8).
A single internationalized email address.
def
set(self, email):
13 def set(self, email): 14 """ Allows IDN email (RFC6531): there is a dedicated class for this (`IDNEmailAddr`). """ 15 emailinfo = email_validator.validate_email(email, check_deliverability=False,allow_smtputf8=True) 16 self._emailaddr = emailinfo.normalized
Allows IDN email (RFC6531): there is a dedicated class for this (IDNEmailAddr).