whois/parser.py
changeset 102 e8cb8d1367c0
parent 99 67b90bfc59c7
child 103 9b79ce8f9829
equal deleted inserted replaced
101:e804426aad35 102:e8cb8d1367c0
   455 
   455 
   456 class WhoisCa(WhoisEntry):
   456 class WhoisCa(WhoisEntry):
   457     """Whois parser for .ca domains
   457     """Whois parser for .ca domains
   458     """
   458     """
   459     regex = {
   459     regex = {
   460         'registrant_name':                'Name: *(.+)',
   460         'domain_name':                    'Domain name: *(.+)',
       
   461         'registrant_name':                '(?<!Domain) Name: *(.+)',
   461         'registrant_number':              'Number: *(.+)\n',
   462         'registrant_number':              'Number: *(.+)\n',
       
   463         'domain_status':                  'Domain status: *(.+)',
       
   464         'emails':                         'Email: *(.+)',
       
   465         'updated_date':                   'Updated Date: *(.+)',
       
   466         'creation_date':                  'Creation Date: *(.+)',
       
   467         'expiration_date':                'Expiry Date: *(.+)',
       
   468         'phone':                          'Phone: *(.+)',
       
   469         'fax':                            'Fax: *(.+)',
       
   470         'dnssec':                         'dnssec: *([\S]+)'
   462     }
   471     }
   463 
   472 
   464     def __init__(self, domain, text):
   473     def __init__(self, domain, text):
   465         if 'Domain status:         available' in text:
   474         if 'Domain status:         available' in text:
   466             raise PywhoisError(text)
   475             raise PywhoisError(text)