-
Notifications
You must be signed in to change notification settings - Fork 20
Description
Running the OpenNSA (master) docker with TLS, I always get a fatal error on twisted.
opennsa_1 | 2021-08-10 21:20:14Z [-] Loading opennsa.tac...
opennsa_1 | 2021-08-10 21:20:14Z [-] Loaded.
opennsa_1 | 2021-08-10 21:20:14Z [-] twistd 21.7.0 (/usr/bin/python3 3.7.3) starting up.
opennsa_1 | 2021-08-10 21:20:14Z [-] reactor class: twisted.internet.epollreactor.EPollReactor.
opennsa_1 | 2021-08-10 21:20:14Z [-] OpenNSA service initializing
opennsa_1 | 2021-08-10 21:20:14Z [opennsaTlsContext] Loaded CA certificate commonName b'OISTE WISeKey Global Root GB CA'
opennsa_1 | 2021-08-10 21:20:14Z [opennsaTlsContext] Loaded CA certificate commonName b'Baltimore CyberTrust Root'
opennsa_1 | 2021-08-10 21:20:14Z [opennsaTlsContext] Loaded CA certificate commonName b'Certum Trusted Network CA 2'
opennsa_1 | 2021-08-10 21:20:14Z [-] Traceback (most recent call last):
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/internet/_sslverify.py", line 324, in getattr
opennsa_1 | 2021-08-10 21:20:14Z [-] return self[_x509names[attr]]
opennsa_1 | 2021-08-10 21:20:14Z [-] KeyError: 'commonName'
opennsa_1 | 2021-08-10 21:20:14Z [-]
opennsa_1 | 2021-08-10 21:20:14Z [-] During handling of the above exception, another exception occurred:
opennsa_1 | 2021-08-10 21:20:14Z [-]
opennsa_1 | 2021-08-10 21:20:14Z [-] Traceback (most recent call last):
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/bin/twistd", line 10, in
opennsa_1 | 2021-08-10 21:20:14Z [-] sys.exit(run())
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/scripts/twistd.py", line 36, in run
opennsa_1 | 2021-08-10 21:20:14Z [-] app.run(runApp, ServerOptions)
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/application/app.py", line 676, in run
opennsa_1 | 2021-08-10 21:20:14Z [-] runApp(config)
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/scripts/twistd.py", line 30, in runApp
opennsa_1 | 2021-08-10 21:20:14Z [-] runner.run()
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/application/app.py", line 376, in run
opennsa_1 | 2021-08-10 21:20:14Z [-] self.postApplication()
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/scripts/_twistd_unix.py", line 255, in postApplication
opennsa_1 | 2021-08-10 21:20:14Z [-] self.startApplication(self.application)
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/scripts/_twistd_unix.py", line 456, in startApplication
opennsa_1 | 2021-08-10 21:20:14Z [-] app.startApplication(application, not self.config["no_save"])
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/application/app.py", line 691, in startApplication
opennsa_1 | 2021-08-10 21:20:14Z [-] service.IService(application).startService()
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/application/service.py", line 276, in startService
opennsa_1 | 2021-08-10 21:20:14Z [-] service.startService()
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/home/opennsa/opennsa/opennsa/setup.py", line 331, in startService
opennsa_1 | 2021-08-10 21:20:14Z [-] factory, ctx_factory = self.setupServiceFactory()
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/home/opennsa/opennsa/opennsa/setup.py", line 184, in setupServiceFactory
opennsa_1 | 2021-08-10 21:20:14Z [-] ctx_factory = setupTLSContext(vc) # May be None
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/home/opennsa/opennsa/opennsa/setup.py", line 107, in setupTLSContext
opennsa_1 | 2021-08-10 21:20:14Z [-] ctx_factory = opennsa2WayTlsContext(vc[config.KEY], vc[config.CERTIFICATE], vc[config.CERTIFICATE_DIR], vc[config.VERIFY_CERT])
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/home/opennsa/opennsa/opennsa/opennsaTlsContext.py", line 116, in init
opennsa_1 | 2021-08-10 21:20:14Z [-] opennsaTlsContext.init(self, certificate_dir, verify)
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/home/opennsa/opennsa/opennsa/opennsaTlsContext.py", line 30, in init
opennsa_1 | 2021-08-10 21:20:14Z [-] self._trustRoot = self._createTrustRootFromCADirectory(certificate_dir)
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/home/opennsa/opennsa/opennsa/opennsaTlsContext.py", line 49, in _createTrustRootFromCADirectory
opennsa_1 | 2021-08-10 21:20:14Z [-] log.msg('Loaded CA certificate commonName %s' % (str(CACertificates[-1].getSubject().commonName)), system = LOG_SYSTEM)
opennsa_1 | 2021-08-10 21:20:14Z [-] File "/usr/local/lib/python3.7/dist-packages/twisted/internet/_sslverify.py", line 326, in getattr
opennsa_1 | 2021-08-10 21:20:14Z [-] raise AttributeError(attr)
opennsa_1 | 2021-08-10 21:20:14Z [-] AttributeError: commonName