summaryrefslogtreecommitdiff
path: root/ext/openssl/tests
diff options
context:
space:
mode:
authorMáté Kocsis <kocsismate@woohoolabs.com>2020-08-20 16:03:34 +0200
committerMáté Kocsis <kocsismate@woohoolabs.com>2020-09-12 22:08:41 +0200
commite8e4ddce778c7f0919b3fd09187ab330adfe884b (patch)
treecdca280c98c1b582181a19c9aec8f291b41b1f76 /ext/openssl/tests
parent3053f6f2fa20499a6a35049a043e1acd02a77ca5 (diff)
downloadphp-git-e8e4ddce778c7f0919b3fd09187ab330adfe884b.tar.gz
Improve parameter handling in ext/openssl
Closes GH-6025
Diffstat (limited to 'ext/openssl/tests')
-rw-r--r--ext/openssl/tests/bug38261.phpt4
-rw-r--r--ext/openssl/tests/bug60632.phpt2
-rw-r--r--ext/openssl/tests/bug68912.phpt2
-rw-r--r--ext/openssl/tests/bug70438.phpt4
-rw-r--r--ext/openssl/tests/openssl_csr_sign_basic.phpt2
-rw-r--r--ext/openssl/tests/openssl_encrypt_error.phpt2
-rw-r--r--ext/openssl/tests/openssl_pkcs12_export_basic.phpt2
-rw-r--r--ext/openssl/tests/openssl_pkcs12_export_to_file_basic.phpt2
-rw-r--r--ext/openssl/tests/openssl_seal_basic.phpt4
-rw-r--r--ext/openssl/tests/openssl_x509_export_basic.phpt2
-rw-r--r--ext/openssl/tests/openssl_x509_export_to_file_basic.phpt2
-rw-r--r--ext/openssl/tests/openssl_x509_fingerprint_basic.phpt2
-rw-r--r--ext/openssl/tests/openssl_x509_read_basic.phpt4
13 files changed, 17 insertions, 17 deletions
diff --git a/ext/openssl/tests/bug38261.phpt b/ext/openssl/tests/bug38261.phpt
index 827f3aca75..9cb16e3e8f 100644
--- a/ext/openssl/tests/bug38261.phpt
+++ b/ext/openssl/tests/bug38261.phpt
@@ -40,6 +40,6 @@ try {
--EXPECT--
bool(false)
bool(false)
-openssl_x509_parse(): Argument #1 ($x509) must be of type OpenSSLCertificate|string, array given
+openssl_x509_parse(): Argument #1 ($certificate) must be of type OpenSSLCertificate|string, array given
bool(false)
-openssl_x509_parse(): Argument #1 ($x509) must be of type OpenSSLCertificate|string, stdClass given
+openssl_x509_parse(): Argument #1 ($certificate) must be of type OpenSSLCertificate|string, stdClass given
diff --git a/ext/openssl/tests/bug60632.phpt b/ext/openssl/tests/bug60632.phpt
index 3f2b0f0197..f51189a50e 100644
--- a/ext/openssl/tests/bug60632.phpt
+++ b/ext/openssl/tests/bug60632.phpt
@@ -27,4 +27,4 @@ try {
}
?>
--EXPECT--
-openssl_seal(): Argument #6 ($iv) must provide an IV for chosen cipher algorithm
+openssl_seal(): Argument #6 ($initialization_vector) cannot be null for the chosen cipher algorithm
diff --git a/ext/openssl/tests/bug68912.phpt b/ext/openssl/tests/bug68912.phpt
index 64d1a9b60a..97e75df545 100644
--- a/ext/openssl/tests/bug68912.phpt
+++ b/ext/openssl/tests/bug68912.phpt
@@ -19,4 +19,4 @@ try {
}
?>
--EXPECT--
-openssl_spki_new(): Argument #1 ($privkey) must be of type OpenSSLAsymmetricKey, resource given
+openssl_spki_new(): Argument #1 ($private_key) must be of type OpenSSLAsymmetricKey, resource given
diff --git a/ext/openssl/tests/bug70438.phpt b/ext/openssl/tests/bug70438.phpt
index 173f0a0066..dd74e272be 100644
--- a/ext/openssl/tests/bug70438.phpt
+++ b/ext/openssl/tests/bug70438.phpt
@@ -26,7 +26,7 @@ openssl_open($sealed, $decrypted, $ekeys[0], $priv_key, $cipher, $iv);
echo $decrypted;
?>
--EXPECTF--
-openssl_seal(): Argument #6 ($iv) must provide an IV for chosen cipher algorithm
+openssl_seal(): Argument #6 ($initialization_vector) cannot be null for the chosen cipher algorithm
-Warning: openssl_seal(): Unknown signature algorithm in %s on line %d
+Warning: openssl_seal(): Unknown digest algorithm in %s on line %d
openssl_seal() test
diff --git a/ext/openssl/tests/openssl_csr_sign_basic.phpt b/ext/openssl/tests/openssl_csr_sign_basic.phpt
index 8d32ad1943..7d856b71bf 100644
--- a/ext/openssl/tests/openssl_csr_sign_basic.phpt
+++ b/ext/openssl/tests/openssl_csr_sign_basic.phpt
@@ -76,7 +76,7 @@ bool(false)
Warning: openssl_csr_sign(): X.509 Certificate Signing Request cannot be retrieved in %s on line %d
bool(false)
openssl_csr_sign(): Argument #1 ($csr) must be of type OpenSSLCertificateSigningRequest|string, array given
-openssl_csr_sign(): Argument #2 ($cacert) must be of type OpenSSLCertificate|string|null, array given
+openssl_csr_sign(): Argument #2 ($ca_certificate) must be of type OpenSSLCertificate|string|null, array given
Key array must be of the form array(0 => key, 1 => phrase)
object(OpenSSLCertificate)#%d (0) {
}
diff --git a/ext/openssl/tests/openssl_encrypt_error.phpt b/ext/openssl/tests/openssl_encrypt_error.phpt
index 53bc371f46..0b1bc662f7 100644
--- a/ext/openssl/tests/openssl_encrypt_error.phpt
+++ b/ext/openssl/tests/openssl_encrypt_error.phpt
@@ -28,5 +28,5 @@ bool(false)
Warning: openssl_encrypt(): The authenticated tag cannot be provided for cipher that doesn not support AEAD in %s on line %d
string(44) "iPR4HulskuaP5Z6me5uImk6BqVyJG73+63tkPauVZYk="
-Warning: openssl_encrypt(): Key length cannot be set for the cipher method in %s on line %d
+Warning: openssl_encrypt(): Key length cannot be set for the cipher algorithm in %s on line %d
bool(false)
diff --git a/ext/openssl/tests/openssl_pkcs12_export_basic.phpt b/ext/openssl/tests/openssl_pkcs12_export_basic.phpt
index fc8a146c0c..03947f3a49 100644
--- a/ext/openssl/tests/openssl_pkcs12_export_basic.phpt
+++ b/ext/openssl/tests/openssl_pkcs12_export_basic.phpt
@@ -53,4 +53,4 @@ bool(false)
Warning: openssl_pkcs12_export(): X.509 Certificate cannot be retrieved in %s on line %d
bool(false)
-openssl_pkcs12_export(): Argument #1 ($x509) must be of type OpenSSLCertificate|string, OpenSSLAsymmetricKey given
+openssl_pkcs12_export(): Argument #1 ($certificate) must be of type OpenSSLCertificate|string, OpenSSLAsymmetricKey given
diff --git a/ext/openssl/tests/openssl_pkcs12_export_to_file_basic.phpt b/ext/openssl/tests/openssl_pkcs12_export_to_file_basic.phpt
index 69363fe34f..43d51753a0 100644
--- a/ext/openssl/tests/openssl_pkcs12_export_to_file_basic.phpt
+++ b/ext/openssl/tests/openssl_pkcs12_export_to_file_basic.phpt
@@ -58,4 +58,4 @@ bool(false)
Warning: openssl_pkcs12_export_to_file(): X.509 Certificate cannot be retrieved in %s on line %d
bool(false)
-openssl_pkcs12_export_to_file(): Argument #1 ($x509cert) must be of type OpenSSLCertificate|string, OpenSSLAsymmetricKey given
+openssl_pkcs12_export_to_file(): Argument #1 ($certificate) must be of type OpenSSLCertificate|string, OpenSSLAsymmetricKey given
diff --git a/ext/openssl/tests/openssl_seal_basic.phpt b/ext/openssl/tests/openssl_seal_basic.phpt
index bdbbd01208..16efb05a66 100644
--- a/ext/openssl/tests/openssl_seal_basic.phpt
+++ b/ext/openssl/tests/openssl_seal_basic.phpt
@@ -40,13 +40,13 @@ var_dump(openssl_seal($data, $sealed, $ekeys, array($wrong), $method));
--EXPECTF--
Warning: openssl_seal(): Not a public key (1th member of pubkeys) in %s on line %d
bool(false)
-openssl_seal(): Argument #4 ($pubkeys) cannot be empty
+openssl_seal(): Argument #4 ($public_key) cannot be empty
int(19)
int(19)
Warning: openssl_seal(): Not a public key (2th member of pubkeys) in %s on line %d
bool(false)
-openssl_seal(): Argument #4 ($pubkeys) cannot be empty
+openssl_seal(): Argument #4 ($public_key) cannot be empty
Warning: openssl_seal(): Not a public key (1th member of pubkeys) in %s on line %d
bool(false)
diff --git a/ext/openssl/tests/openssl_x509_export_basic.phpt b/ext/openssl/tests/openssl_x509_export_basic.phpt
index 43dc843b70..2f87296019 100644
--- a/ext/openssl/tests/openssl_x509_export_basic.phpt
+++ b/ext/openssl/tests/openssl_x509_export_basic.phpt
@@ -40,7 +40,7 @@ bool(true)
Warning: openssl_x509_export(): X.509 Certificate cannot be retrieved in %s on line %d
bool(false)
bool(true)
-openssl_x509_export(): Argument #1 ($x509) must be of type OpenSSLCertificate|string, array given
+openssl_x509_export(): Argument #1 ($certificate) must be of type OpenSSLCertificate|string, array given
int(0)
int(0)
int(%d)
diff --git a/ext/openssl/tests/openssl_x509_export_to_file_basic.phpt b/ext/openssl/tests/openssl_x509_export_to_file_basic.phpt
index 71a494f401..60cbd480c3 100644
--- a/ext/openssl/tests/openssl_x509_export_to_file_basic.phpt
+++ b/ext/openssl/tests/openssl_x509_export_to_file_basic.phpt
@@ -39,6 +39,6 @@ bool(true)
Warning: openssl_x509_export_to_file(): X.509 Certificate cannot be retrieved in %s on line %d
bool(false)
bool(true)
-openssl_x509_export_to_file(): Argument #1 ($x509) must be of type OpenSSLCertificate|string, array given
+openssl_x509_export_to_file(): Argument #1 ($certificate) must be of type OpenSSLCertificate|string, array given
---
bool(true)
diff --git a/ext/openssl/tests/openssl_x509_fingerprint_basic.phpt b/ext/openssl/tests/openssl_x509_fingerprint_basic.phpt
index c4524ada0b..456049edf9 100644
--- a/ext/openssl/tests/openssl_x509_fingerprint_basic.phpt
+++ b/ext/openssl/tests/openssl_x509_fingerprint_basic.phpt
@@ -40,5 +40,5 @@ Warning: openssl_x509_fingerprint(): X.509 Certificate cannot be retrieved in %s
bool(false)
** Testing bad hash method **
-Warning: openssl_x509_fingerprint(): Unknown signature algorithm in %s on line %d
+Warning: openssl_x509_fingerprint(): Unknown digest algorithm in %s on line %d
bool(false)
diff --git a/ext/openssl/tests/openssl_x509_read_basic.phpt b/ext/openssl/tests/openssl_x509_read_basic.phpt
index e4d956b120..60d7a1eee7 100644
--- a/ext/openssl/tests/openssl_x509_read_basic.phpt
+++ b/ext/openssl/tests/openssl_x509_read_basic.phpt
@@ -42,5 +42,5 @@ Warning: openssl_x509_read(): X.509 Certificate cannot be retrieved in %s on lin
bool(false)
object(OpenSSLCertificate)#%d (0) {
}
-openssl_x509_read(): Argument #1 ($x509) must be of type OpenSSLCertificate|string, array given
-openssl_x509_read(): Argument #1 ($x509) must be of type OpenSSLCertificate|string, array given
+openssl_x509_read(): Argument #1 ($certificate) must be of type OpenSSLCertificate|string, array given
+openssl_x509_read(): Argument #1 ($certificate) must be of type OpenSSLCertificate|string, array given