The status report fails when the certificate expires within a month
Part of #3596034 (closed).
Problem/motivation
c2pa_sign_requirements() calls Url::fromRoute() but c2pa_sign.install does not import Drupal\Core\Url. When the signing certificate expires within a month, the status report fails instead of showing the warning.
Steps to reproduce
- Set the certificate directory to a certificate that expires in 10 days.
- Open the status report, or run
c2pa_sign_requirements('runtime'):
Error: Class "Url" not found at c2pa_sign.install:110Proposed resolution
Add use Drupal\Core\Url; to c2pa_sign.install, with a kernel test that builds a certificate expiring in 10 days.
AI Compliance
🤖 Generated with the help of an LLM, reviewed and approved by me before posting.