--> -->
 
 
<class 'ssl.CertificateError'>
Python 2.7.12: /usr/bin/python
Tue Aug 4 15:54:45 2020

A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred.

 /var/www/formular.se/index.cgi in ()
     46         #Ping check does not work since router does not answer to pings :(
     47         #delay = ping.do_one('ssl.formular.se', timeout=1)
=>   48         response = urllib.urlopen(chkUrl)
     49 
     50         parser = make_parser()
response undefined, urllib = <module 'urllib' from '/usr/lib/python2.7/urllib.pyc'>, urllib.urlopen = <function urlopen>, chkUrl = u'https://ssl.formular.se/formular/index.py?transformOutput=False'
 /usr/lib/python2.7/urllib.py in urlopen(url=u'https://ssl.formular.se/formular/index.py?transformOutput=False', data=None, proxies=None, context=None)
     85         opener = _urlopener
     86     if data is None:
=>   87         return opener.open(url)
     88     else:
     89         return opener.open(url, data)
opener = <urllib.FancyURLopener instance>, opener.open = <bound method FancyURLopener.open of <urllib.FancyURLopener instance>>, url = u'https://ssl.formular.se/formular/index.py?transformOutput=False'
 /usr/lib/python2.7/urllib.py in open(self=<urllib.FancyURLopener instance>, fullurl='https://ssl.formular.se/formular/index.py?transformOutput=False', data=None)
    211         try:
    212             if data is None:
=>  213                 return getattr(self, name)(url)
    214             else:
    215                 return getattr(self, name)(url, data)
builtin getattr = <built-in function getattr>, self = <urllib.FancyURLopener instance>, name = 'open_https', url = '//ssl.formular.se/formular/index.py?transformOutput=False'
 /usr/lib/python2.7/urllib.py in open_https(self=<urllib.FancyURLopener instance>, url='//ssl.formular.se/formular/index.py?transformOutput=False', data=None)
    441             if realhost: h.putheader('Host', realhost)
    442             for args in self.addheaders: h.putheader(*args)
=>  443             h.endheaders(data)
    444             errcode, errmsg, headers = h.getreply()
    445             fp = h.getfile()
h = <httplib.HTTPS instance>, h.endheaders = <bound method HTTPSConnection.endheaders of <httplib.HTTPSConnection instance>>, data = None
 /usr/lib/python2.7/httplib.py in endheaders(self=<httplib.HTTPSConnection instance>, message_body=None)
   1051         else:
   1052             raise CannotSendHeader()
=> 1053         self._send_output(message_body)
   1054 
   1055     def request(self, method, url, body=None, headers={}):
self = <httplib.HTTPSConnection instance>, self._send_output = <bound method HTTPSConnection._send_output of <httplib.HTTPSConnection instance>>, message_body = None
 /usr/lib/python2.7/httplib.py in _send_output(self=<httplib.HTTPSConnection instance>, message_body=None)
    895             msg += message_body
    896             message_body = None
=>  897         self.send(msg)
    898         if message_body is not None:
    899             #message_body was not a string (i.e. it is a file) and
self = <httplib.HTTPSConnection instance>, self.send = <bound method HTTPSConnection.send of <httplib.HTTPSConnection instance>>, msg = 'GET /formular/index.py?transformOutput=False HTT...l.formular.se\r\nUser-Agent: Python-urllib/1.17\r\n\r\n'
 /usr/lib/python2.7/httplib.py in send(self=<httplib.HTTPSConnection instance>, data='GET /formular/index.py?transformOutput=False HTT...l.formular.se\r\nUser-Agent: Python-urllib/1.17\r\n\r\n')
    857         if self.sock is None:
    858             if self.auto_open:
=>  859                 self.connect()
    860             else:
    861                 raise NotConnected()
self = <httplib.HTTPSConnection instance>, self.connect = <bound method HTTPSConnection.connect of <httplib.HTTPSConnection instance>>
 /usr/lib/python2.7/httplib.py in connect(self=<httplib.HTTPSConnection instance>)
   1276 
   1277             self.sock = self._context.wrap_socket(self.sock,
=> 1278                                                   server_hostname=server_hostname)
   1279 
   1280     __all__.append("HTTPSConnection")
server_hostname = 'ssl.formular.se'
 /usr/lib/python2.7/ssl.py in wrap_socket(self=<ssl.SSLContext object>, sock=<socket._socketobject object>, server_side=False, do_handshake_on_connect=True, suppress_ragged_eofs=True, server_hostname='ssl.formular.se')
    351                          suppress_ragged_eofs=suppress_ragged_eofs,
    352                          server_hostname=server_hostname,
=>  353                          _context=self)
    354 
    355     def set_npn_protocols(self, npn_protocols):
_context undefined, self = <ssl.SSLContext object>
 /usr/lib/python2.7/ssl.py in __init__(self=<ssl.SSLSocket object>, sock=<socket._socketobject object>, keyfile=None, certfile=None, server_side=False, cert_reqs=0, ssl_version=2, ca_certs=None, do_handshake_on_connect=True, family=2, type=1, proto=0, fileno=None, suppress_ragged_eofs=True, npn_protocols=None, ciphers=None, server_hostname='ssl.formular.se', _context=<ssl.SSLContext object>)
    599                         # non-blocking
    600                         raise ValueError("do_handshake_on_connect should not be specified for non-blocking sockets")
=>  601                     self.do_handshake()
    602 
    603             except (OSError, ValueError):
self = <ssl.SSLSocket object>, self.do_handshake = <bound method SSLSocket.do_handshake of <ssl.SSLSocket object>>
 /usr/lib/python2.7/ssl.py in do_handshake(self=<ssl.SSLSocket object>, block=False)
    836                 raise ValueError("check_hostname needs server_hostname "
    837                                  "argument")
=>  838             match_hostname(self.getpeercert(), self.server_hostname)
    839 
    840     def _real_connect(self, addr, connect_ex):
global match_hostname = <function match_hostname>, self = <ssl.SSLSocket object>, self.getpeercert = <bound method SSLSocket.getpeercert of <ssl.SSLSocket object>>, self.server_hostname = 'ssl.formular.se'
 /usr/lib/python2.7/ssl.py in match_hostname(cert={'OCSP': (u'http://ocsp.int-x3.letsencrypt.org',), 'caIssuers': (u'http://cert.int-x3.letsencrypt.org/',), 'issuer': ((('countryName', u'US'),), (('organizationName', u"Let's Encrypt"),), (('commonName', u"Let's Encrypt Authority X3"),)), 'notAfter': 'Oct 21 18:57:24 2020 GMT', 'notBefore': u'Jul 23 18:57:24 2020 GMT', 'serialNumber': u'0333187A26A3D65BA192D1EB9D2DD72235C5', 'subject': ((('commonName', u'kunskapsresursen.se'),),), 'subjectAltName': (('DNS', 'kunskapsresursen.se'),), 'version': 3L}, hostname='ssl.formular.se')
    274         raise CertificateError("hostname %r "
    275             "doesn't match %r"
=>  276             % (hostname, dnsnames[0]))
    277     else:
    278         raise CertificateError("no appropriate commonName or "
hostname = 'ssl.formular.se', dnsnames = ['kunskapsresursen.se']

<class 'ssl.CertificateError'>: hostname 'ssl.formular.se' doesn't match 'kunskapsresursen.se'
      args = ("hostname 'ssl.formular.se' doesn't match 'kunskapsresursen.se'",)
      message = "hostname 'ssl.formular.se' doesn't match 'kunskapsresursen.se'"