Why is my installation failing at [ansible.automation_platform_installer.certificate_authority : Get AAP CA certificate info]
Issue
Installation failing due to "CryptographyDeprecationWarning: Properties that return a naïve datetime object have been deprecated. Please switch to not_valid_before_utc."
TASK [ansible.automation_platform_installer.certificate_authority : Get AAP CA certificate info] ***
fatal: [example.controller.com]: FAILED! => {"changed": false, "module_stderr": "/tmp/ansible_community.crypto.x509_certificate_info_payload_6093ctdw/ansible_community.crypto.x509_certificate_info_payload.zip/ansible_collections/community/crypto/plugins/module_utils/crypto/module_backends/certificate_info.py:346: CryptographyDeprecationWarning: Properties that return a naïve datetime object have been deprecated. Please switch to not_valid_before_utc.\n return self.cert.not_valid_before\n/tmp/ansible_community.crypto.x509_certificate_info_payload_6093ctdw/ansible_community.crypto.x509_certificate_info_payload.zip/ansible_collections/community/crypto/plugins/module_utils/crypto/module_backends/certificate_info.py:349: CryptographyDeprecationWarning: Properties that return a naïve datetime object have been deprecated. Please switch to not_valid_after_utc.\n return self.cert.not_valid_after\nTraceback (most recent call last):\n File \"/root/.ansible/tmp/ansible-tmp-1714667154.6547134-1164745-230878101437512/AnsiballZ_x509_certificate_info.py\", line 107, in <module>\n _ansiballz_main()\n File \"/root/.ansible/tmp/ansible-tmp-1714667154.6547134-1164745-230878101437512/AnsiballZ_x509_certificate_info.py\", line 99, in _ansiballz_main\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\n File \"/root/.ansible/tmp/ansible-tmp-1714667154.6547134-1164745-230878101437512/AnsiballZ_x509_certificate_info.py\", line 47, in invoke_module\n runpy.run_module(mod_name='ansible_collections.community.crypto.plugins.modules.x509_certificate_info', init_globals=dict(_module_fqn='ansible_collections.community.crypto.plugins.modules.x509_certificate_info', _modlib_path=modlib_path),\n File \"/usr/lib64/python3.9/runpy.py\", line 225, in run_module\n return _run_module_code(code, init_globals, run_name, mod_spec)\n File \"/usr/lib64/python3.9/runpy.py\", line 97, in _run_module_code\n _run_code(code, mod_globals, init_globals,\n File \"/usr/lib64/python3.9/runpy.py\", line 87, in _run_code\n exec(code, run_globals)\n File \"/tmp/ansible_community.crypto.x509_certificate_info_payload_6093ctdw/ansible_community.crypto.x509_certificate_info_payload.zip/ansible_collections/community/crypto/plugins/modules/x509_certificate_info.py\", line 452, in <module>\n File \"/tmp/ansible_community.crypto.x509_certificate_info_payload_6093ctdw/ansible_community.crypto.x509_certificate_info_payload.zip/ansible_collections/community/crypto/plugins/modules/x509_certificate_info.py\", line 436, in main\n File \"/tmp/ansible_community.crypto.x509_certificate_info_payload_6093ctdw/ansible_community.crypto.x509_certificate_info_payload.zip/ansible_collections/community/crypto/plugins/module_utils/crypto/module_backends/certificate_info.py\", line 228, in get_info\n File \"/tmp/ansible_community.crypto.x509_certificate_info_payload_6093ctdw/ansible_community.crypto.x509_certificate_info_payload.zip/ansible_collections/community/crypto/plugins/module_utils/crypto/module_backends/certificate_info.py\", line 381, in _get_all_extensions\n File \"/tmp/ansible_community.crypto.x509_certificate_info_payload_6093ctdw/ansible_community.crypto.x509_certificate_info_payload.zip/ansible_collections/community/crypto/plugins/module_utils/crypto/cryptography_support.py\", line 82, in cryptography_get_extensions_from_cert\nAttributeError: 'cryptography.hazmat.bindings._rust.x509.Certificat' object has no attribute '_x509'\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}
Environment
Ansible Automation Platform 2.4 or later.
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.