summaryrefslogtreecommitdiff
path: root/ext/openssl/tests/CertificateGenerator.inc
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2020-06-17 22:08:54 +0200
committerNikita Popov <nikita.ppv@gmail.com>2020-06-17 22:15:00 +0200
commit52c2f1126d762385118284cf35b99e02b7ce8afe (patch)
treeb96e315bf82c3e23f4749f19fd35cc3119d88ecd /ext/openssl/tests/CertificateGenerator.inc
parent9b3e57921f1a56ed4b3b389e4cea0b98c4b19498 (diff)
downloadphp-git-52c2f1126d762385118284cf35b99e02b7ce8afe.tar.gz
Use sha256 as digest algorithm in certificate generator
This makes the generated certificates compatible with security level 2, which is apparently the default on Ubuntu 20.04. Unfortunately this does not fix all tests, because some are using pre-generated certificates.
Diffstat (limited to 'ext/openssl/tests/CertificateGenerator.inc')
-rw-r--r--ext/openssl/tests/CertificateGenerator.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/openssl/tests/CertificateGenerator.inc b/ext/openssl/tests/CertificateGenerator.inc
index 325f975706..e915e81b8c 100644
--- a/ext/openssl/tests/CertificateGenerator.inc
+++ b/ext/openssl/tests/CertificateGenerator.inc
@@ -97,7 +97,8 @@ class CertificateGenerator
openssl_csr_new($dn, $this->lastKey, ['req_extensions' => 'v3_req']),
$this->ca,
$this->caKey,
- 2
+ /* days */ 2,
+ ['digest_alg' => 'sha256'],
);
$certText = '';