sslcertificates: Crashes when subject contains non-ascii characters
moschlar opened this issue · 1 comments
moschlar commented
Crash Report
Exception
JSONDecodeError (Invalid \escape: line 1 column 260 (char 259))
Traceback
File "/omd/sites/zdv/lib/python3/cmk/base/agent_based/data_provider.py", line 106, in _parse_raw_data
return parse_function(list(raw_data))
File "/omd/sites/zdv/local/lib/python3/cmk/base/plugins/agent_based/sslcertificates.py", line 28, in parse_sslcertificates
data = json.loads(line[0])
File "/omd/sites/zdv/lib/python3.11/json/__init__.py", line 346, in loads
return _default_decoder.decode(s)
File "/omd/sites/zdv/lib/python3.11/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/omd/sites/zdv/lib/python3.11/json/decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
Local Variables
{'idx': 0,
's': '{"file": '
'"/etc/ssl/certs/*.pages.gitlab.rlp.net_certificate-with-chain.pem", '
'"starts": 1698105600, "expires": 1729727999, "algosign": '
'"sha384WithRSAEncryption", "issuer_hash": "08ab1bf8", "subj": "C = DE, '
'ST = Rheinland-Pfalz, O = Johannes Gutenberg-Universit\\C3\\A4t Mainz, '
'CN = pages.gitlab.rlp.net"}',
'self': <json.decoder.JSONDecoder object at 0x7f882a4902d0>}
gurubert commented
has been fixed for 2.2