Function: textsec-local-address-suspicious-p
textsec-local-address-suspicious-p is a byte-compiled function defined
in textsec.el.gz.
Signature
(textsec-local-address-suspicious-p LOCAL)
Documentation
Say whether LOCAL part of an email address looks suspicious.
LOCAL is the part before "@" in an email address, a string.
If it isn't suspicious, return nil. If it is, return a string explaining the potential problem.
Email addresses are considered suspicious if they use characters that can look similar to other characters when displayed, or use certain other unusual mixtures of characters.
Source Code
;; Defined in /usr/src/emacs/lisp/international/textsec.el.gz
(defun textsec-local-address-suspicious-p (local)
"Say whether LOCAL part of an email address looks suspicious.
LOCAL is the part before \"@\" in an email address, a string.
If it isn't suspicious, return nil. If it is, return a string explaining
the potential problem.
Email addresses are considered suspicious if they use characters
that can look similar to other characters when displayed, or use
certain other unusual mixtures of characters."
(cond
((not (equal local (ucs-normalize-NFKC-string local)))
(format "`%s' is not in normalized form `%s', its display might deceive"
local (ucs-normalize-NFKC-string local)))
((textsec-mixed-numbers-p local)
(format "`%s' contains numbers from different number systems" local))
((eq (textsec-restriction-level local) 'unrestricted)
(format "`%s' uses characters from too many unusual scripts" local))
((string-match-p "\\`\\.\\|\\.\\'\\|\\.\\." local)
(format "`%s' contains invalid dot characters" local))))