summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjim-p <jimp@pfsense.org>2010-09-01 15:18:44 -0400
committerjim-p <jimp@pfsense.org>2010-09-01 15:18:44 -0400
commit4e990e1e207366ed78fecc8c865df5074ad2cfdd (patch)
tree7c53245e6a501b0f8c3f9a1a7fc3614fc27503a5
parent1e332e981ca27a8a04abcd2c609661b869044354 (diff)
downloadpfsense-4e990e1e207366ed78fecc8c865df5074ad2cfdd.zip
pfsense-4e990e1e207366ed78fecc8c865df5074ad2cfdd.tar.gz
CA/CERT Move
-rwxr-xr-xusr/local/www/wizard.php4
-rw-r--r--usr/local/www/wizards/openvpn_wizard.inc26
2 files changed, 15 insertions, 15 deletions
diff --git a/usr/local/www/wizard.php b/usr/local/www/wizard.php
index d4a2b02..d255725 100755
--- a/usr/local/www/wizard.php
+++ b/usr/local/www/wizard.php
@@ -508,7 +508,7 @@ function showchange() {
if($field['add_to_certca_selection'] == $value) $SELECTED = " SELECTED";
echo "<option value='" . $field['add_to_certca_selection'] . "'" . $SELECTED . ">" . $field['add_to_certca_selection'] . "</option>\n";
}
- foreach($config['system']['ca'] as $ca) {
+ foreach($config['ca'] as $ca) {
$name = htmlspecialchars($ca['name']);
$SELECTED = "";
if ($value == $name) $SELECTED = " SELECTED";
@@ -546,7 +546,7 @@ function showchange() {
if($field['add_to_cert_selection'] == $value) $SELECTED = " SELECTED";
echo "<option value='" . $field['add_to_cert_selection'] . "'" . $SELECTED . ">" . $field['add_to_cert_selection'] . "</option>\n";
}
- foreach($config['system']['cert'] as $ca) {
+ foreach($config['cert'] as $ca) {
if (stristr($ca['name'], "webconf"))
continue;
$name = htmlspecialchars($ca['name']);
diff --git a/usr/local/www/wizards/openvpn_wizard.inc b/usr/local/www/wizards/openvpn_wizard.inc
index ff8175c..fc7d0c4 100644
--- a/usr/local/www/wizards/openvpn_wizard.inc
+++ b/usr/local/www/wizards/openvpn_wizard.inc
@@ -163,7 +163,7 @@ function step5_submitphpaction() {
function step6_stepbeforeformdisplay() {
global $stepid, $config;
- if (count($config['system']['ca']) < 1) {
+ if (count($config['ca']) < 1) {
$stepid++;
}
}
@@ -185,8 +185,8 @@ function step7_submitphpaction() {
$canames = array();
$cacns = array();
- if (is_array($config['system']['ca'])) {
- foreach($config['system']['ca'] as $ca) {
+ if (is_array($config['ca'])) {
+ foreach($config['ca'] as $ca) {
$canames[] = $ca['name'];
$cainfo = cert_get_subject_hash($ca['crt']);
$cacns[] = $cainfo["CN"];
@@ -213,8 +213,8 @@ function step7_submitphpaction() {
function step8_stepbeforeformdisplay() {
global $stepid, $config;
- if (count($config['system']['cert']) < 1 ||
- (count($config['system']['cert']) == 1 && stristr($config['system']['cert'][0]['name'], "webconf"))) {
+ if (count($config['cert']) < 1 ||
+ (count($config['cert']) == 1 && stristr($config['cert'][0]['name'], "webconf"))) {
$stepid++;
}
}
@@ -271,8 +271,8 @@ function step9_submitphpaction() {
$certnames = array();
$certcns = array();
- if (is_array($config['system']['cert'])) {
- foreach($config['system']['cert'] as $cert) {
+ if (is_array($config['cert'])) {
+ foreach($config['cert'] as $cert) {
$certnames[] = $cert['name'];
$certinfo = cert_get_subject_hash($cert['crt']);
$certcns[] = $certinfo["CN"];
@@ -450,10 +450,10 @@ function step12_submitphpaction() {
'commonName' => $pconfig['step6']['certca']);
ca_create($ca, $pconfig['step6']['keylength'], $pconfig['step6']['lifetime'], $dn);
- if (!is_array($config['system']['ca']))
- $config['system']['ca'] = array();
+ if (!is_array($config['ca']))
+ $config['ca'] = array();
- $config['system']['ca'][] = $ca;
+ $config['ca'][] = $ca;
} else if (!isset($pconfig['step6']['uselist']) && empty($pconfig['step6']['authcertca'])) {
$message = "Please choose a Certificate Authority.";
header("Location:wizard.php?xml=openvpn_wizard.xml&stepid=5&message={$message}");
@@ -477,10 +477,10 @@ function step12_submitphpaction() {
'commonName' => $pconfig['step9']['certname']);
cert_create($cert, $ca['refid'], $pconfig['step9']['keylength'], $pconfig['step9']['lifetime'], $dn);
- if (!is_array($config['system']['cert']))
- $config['system']['cert'] = array();
+ if (!is_array($config['cert']))
+ $config['cert'] = array();
- $config['system']['cert'][] = $cert;
+ $config['cert'][] = $cert;
} else if (!isset($pconfig['step6']['uselist']) && empty($pconfig['step9']['authcertname'])) {
$message = "Please choose a Certificate.";
header("Location:wizard.php?xml=openvpn_wizard.xml&stepid=7&message={$message}");
OpenPOWER on IntegriCloud