查看domain的whois信息
python3 亲试可行
1、pip install python-whois
2、
def is_registered(domain_name): """ A function that returns a boolean indicating whether a `domain_name` is registered """ try: w = whois.whois(domain_name) except Exception: return False else: return bool(w.domain_name)