default_bits=1024 causes test failure with OpenSSL 3.2+
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 40.4k
- Forks
- 8.1k
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 96
Description
Description
ext/openssl/tests/gh10495.phpt test fails on systems with OpenSSL 3.2+ if the default openssl.cnf is not provided.
This is caused by the default_bits=1024 setting in ext/openssl/tests/CertificateGenerator.inc.
OpenSSL starting from 3.2 requires 2048-bit keys on the default security level 2 (https://docs.openssl.org/3.2/man3/SSL_CTX_set_security_level/#description).
PHP Version
PHP 8.4.13
Operating System
WSL with Arch Linux
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with ext/openssl/tests/CertificateGenerator.inc and inspect the default_bits=1024 setting referenced by the issue. Run ext/openssl/tests/gh10495.phpt on a system using OpenSSL 3.2+ without the default openssl.cnf. Done means the test no longer fails because the generated key is rejected at security level 2.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- security, testing-qa
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 78/100