Validating string for FDQN

Eric eric.wong.t at gmail.com
Mon Jun 6 20:40:29 EDT 2011


Hello,

Is there a library or regex that can determine if a string is a fqdn
(fully qualified domain name)? I'm writing a script that needs to add
a defined domain to the end of a hostname if it isn't already a fqdn
and doesn't contain the defined domain.

Thanks.



More information about the Python-list mailing list