mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-14 16:44:39 +00:00
certificates: don't overwrite previous errors
This commit is contained in:
parent
af6ae47d15
commit
36a069a06f
@ -364,8 +364,8 @@ if ($_POST) {
|
||||
'emailAddress' => $pconfig['dn_email'],
|
||||
'commonName' => $pconfig['dn_commonname']);
|
||||
if (!ca_create($ca, $pconfig['keylen'], $pconfig['lifetime'], $dn, $pconfig['digest_alg'])) {
|
||||
$input_errors = array();
|
||||
while ($ssl_err = openssl_error_string()) {
|
||||
$input_errors = array();
|
||||
array_push($input_errors, "openssl library returns: " . $ssl_err);
|
||||
}
|
||||
}
|
||||
@ -378,8 +378,8 @@ if ($_POST) {
|
||||
'emailAddress' => $pconfig['dn_email'],
|
||||
'commonName' => $pconfig['dn_commonname']);
|
||||
if (!ca_inter_create($ca, $pconfig['keylen'], $pconfig['lifetime'], $dn, $pconfig['caref'], $pconfig['digest_alg'])) {
|
||||
$input_errors = array();
|
||||
while ($ssl_err = openssl_error_string()) {
|
||||
$input_errors = array();
|
||||
array_push($input_errors, "openssl library returns: " . $ssl_err);
|
||||
}
|
||||
}
|
||||
|
||||
@ -430,8 +430,8 @@ if ($_POST) {
|
||||
$dn,
|
||||
$pconfig['digest_alg']
|
||||
)) {
|
||||
$input_errors = array();
|
||||
while ($ssl_err = openssl_error_string()) {
|
||||
$input_errors = array();
|
||||
array_push($input_errors, "openssl library returns: " . $ssl_err);
|
||||
}
|
||||
}
|
||||
@ -453,8 +453,8 @@ if ($_POST) {
|
||||
$dn['subjectAltName'] = implode(",", $altnames_tmp);
|
||||
}
|
||||
if (!csr_generate($cert, $pconfig['csr_keylen'], $dn, $pconfig['csr_digest_alg'])) {
|
||||
$input_errors = array();
|
||||
while ($ssl_err = openssl_error_string()) {
|
||||
$input_errors = array();
|
||||
array_push($input_errors, "openssl library returns: " . $ssl_err);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user