diff options
author | jim-p <jimp@pfsense.org> | 2012-05-14 12:39:56 -0400 |
---|---|---|
committer | jim-p <jimp@pfsense.org> | 2012-05-14 12:39:56 -0400 |
commit | 547c56c4fb6504af27c087d49cec6662b94bea3d (patch) | |
tree | f8152751a9fb16bba7d94df861582e37ec6832d0 /usr/local | |
parent | e052047dd8145b336755206b728e61f28d7a544b (diff) | |
download | pfsense-547c56c4fb6504af27c087d49cec6662b94bea3d.zip pfsense-547c56c4fb6504af27c087d49cec6662b94bea3d.tar.gz |
Create $altnames earlier, and also fix a bracing issue with this if statement. Fixes certificate importing.
Diffstat (limited to 'usr/local')
-rw-r--r-- | usr/local/www/system_certmanager.php | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr/local/www/system_certmanager.php b/usr/local/www/system_certmanager.php index aa01209..6622b40 100644 --- a/usr/local/www/system_certmanager.php +++ b/usr/local/www/system_certmanager.php @@ -234,10 +234,10 @@ if ($_POST) { $reqdfieldsn = array(gettext("Existing Certificate Choice")); } + $altnames = array(); do_input_validation($_POST, $reqdfields, $reqdfieldsn, &$input_errors); - if ($pconfig['method'] != "import") + if ($pconfig['method'] != "import") { /* subjectAltNames */ - $altnames = array(); foreach ($_POST as $key => $value) { $entry = ''; if (!substr_compare('altname_type', $key, 0, 12)) { @@ -292,6 +292,7 @@ if ($_POST) { }else if (preg_match("/[\!\@\#\$\%\^\(\)\~\?\>\<\&\/\\\,\.\"\']/", $_POST["$reqdfields[$i]"])) array_push($input_errors, "The field '" . $reqdfieldsn[$i] . "' contains invalid characters."); } + } /* if this is an AJAX caller then handle via JSON */ if (isAjax() && is_array($input_errors)) { |