summaryrefslogtreecommitdiffstats
path: root/src/usr/local/www/system_camanager.php
diff options
context:
space:
mode:
authorSteve Beaver <sbeaver@netgate.com>2017-02-09 16:53:13 -0500
committerSteve Beaver <sbeaver@netgate.com>2017-02-09 16:53:13 -0500
commite8afd822c866e4b09ed539268186939478be8e09 (patch)
tree65e3e78d8723c02c0f77fb6e368af5f97f8ff46a /src/usr/local/www/system_camanager.php
parente04daed06563f5fb2d065d86931cd6b2684605c7 (diff)
downloadpfsense-e8afd822c866e4b09ed539268186939478be8e09.zip
pfsense-e8afd822c866e4b09ed539268186939478be8e09.tar.gz
GET/POST conversion for camanager and certmanager
Diffstat (limited to 'src/usr/local/www/system_camanager.php')
-rw-r--r--src/usr/local/www/system_camanager.php16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/usr/local/www/system_camanager.php b/src/usr/local/www/system_camanager.php
index cdee6d1..accddff 100644
--- a/src/usr/local/www/system_camanager.php
+++ b/src/usr/local/www/system_camanager.php
@@ -38,9 +38,6 @@ $ca_methods = array(
$ca_keylens = array("512", "1024", "2048", "3072", "4096", "7680", "8192", "15360", "16384");
$openssl_digest_algs = array("sha1", "sha224", "sha256", "sha384", "sha512", "whirlpool");
-if (is_numericint($_GET['id'])) {
- $id = $_GET['id'];
-}
if (isset($_POST['id']) && is_numericint($_POST['id'])) {
$id = $_POST['id'];
}
@@ -63,7 +60,6 @@ if (!is_array($config['crl'])) {
$a_crl =& $config['crl'];
-$act = $_GET['act'];
if ($_POST['act']) {
$act = $_POST['act'];
}
@@ -157,7 +153,7 @@ if ($act == "expkey") {
exit;
}
-if ($_POST) {
+if ($_POST && ($_POST['save'] == 'Save')) {
unset($input_errors);
$input_errors = array();
@@ -430,13 +426,13 @@ foreach ($a_ca as $i => $ca):
<?php endif?>
</td>
<td class="text-nowrap">
- <a class="fa fa-pencil" title="<?=gettext("Edit CA")?>" href="system_camanager.php?act=edit&amp;id=<?=$i?>"></a>
- <a class="fa fa-certificate" title="<?=gettext("Export CA")?>" href="system_camanager.php?act=exp&amp;id=<?=$i?>"></a>
+ <a class="fa fa-pencil" title="<?=gettext("Edit CA")?>" href="system_camanager.php?act=edit&amp;id=<?=$i?>" usepost></a>
+ <a class="fa fa-certificate" title="<?=gettext("Export CA")?>" href="system_camanager.php?act=exp&amp;id=<?=$i?>" usepost></a>
<?php if ($ca['prv']): ?>
- <a class="fa fa-key" title="<?=gettext("Export key")?>" href="system_camanager.php?act=expkey&amp;id=<?=$i?>"></a>
+ <a class="fa fa-key" title="<?=gettext("Export key")?>" href="system_camanager.php?act=expkey&amp;id=<?=$i?>" usepost></a>
<?php endif?>
<?php if (!ca_in_use($ca['refid'])): ?>
- <a class="fa fa-trash" title="<?=gettext("Delete CA and its CRLs")?>" href="system_camanager.php?act=del&amp;id=<?=$i?>"></a>
+ <a class="fa fa-trash" title="<?=gettext("Delete CA and its CRLs")?>" href="system_camanager.php?act=del&amp;id=<?=$i?>" usepost ></a>
<?php endif?>
</td>
</tr>
@@ -448,7 +444,7 @@ foreach ($a_ca as $i => $ca):
</div>
<nav class="action-buttons">
- <a href="?act=new" class="btn btn-success btn-sm">
+ <a href="?act=new" class="btn btn-success btn-sm" usepost>
<i class="fa fa-plus icon-embed-btn"></i>
<?=gettext("Add")?>
</a>
OpenPOWER on IntegriCloud