mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-19 02:54:38 +00:00
To fix: OpenVPN server wizard always asks to create a new CA (#3614)
This commit is contained in:
parent
732b5ff4c8
commit
2b2ae7a310
@ -194,8 +194,20 @@ function step5_submitphpaction()
|
||||
function step6_stepbeforeformdisplay()
|
||||
{
|
||||
global $stepid, $config;
|
||||
$no_internal_ca = true;
|
||||
|
||||
if (!empty($config['ca'])) {
|
||||
if (empty($config['ca'])) {
|
||||
$stepid++;
|
||||
} else {
|
||||
foreach ($config['ca'] as $ca) {
|
||||
if (!empty($ca['prv'])) {
|
||||
$no_internal_ca=false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ($no_internal_ca) {
|
||||
$stepid++;
|
||||
}
|
||||
}
|
||||
@ -447,7 +459,7 @@ function step10_submitphpaction()
|
||||
if (!isset($_POST['generatetlskey']) && isset($_POST['tlsauthentication'])) {
|
||||
if (!strstr($_POST['tlssharedkey'], "-----BEGIN OpenVPN Static key V1-----") ||
|
||||
!strstr($_POST['tlssharedkey'], "-----END OpenVPN Static key V1-----")) {
|
||||
$input_errors[] = gettext("The field 'TLS Authentication Key' does not appear to be valid.");
|
||||
$input_errors[] = gettext("The field 'TLS Authentication Key' does not appear to be valid.");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user