Example #1
0
    if ($direct->id != $directive_id) {
        echo "<center><span style='color:red'>" . _("The directive {$directive_id} doesn't exist in {$XML_FILE}") . "</span></center>";
        exit;
    }
    $_SESSION['directive'] = serialize($direct);
    if ($XML_FILE != '/etc/ossim/server/directives.xml') {
        release_file($XML_FILE);
    }
    if (!empty($directive_id)) {
        $direct->printDirective($level, $directive_xml);
    }
    ?>
</table>
<?php 
    $directive_name = Plugin_sid::get_name_by_idsid($conn, "1505", $directive_id);
    list($properties, $num_properties) = Compliance::get_category($conn, "AND category.sid={$directive_id}");
    $iso_groups = ISO27001::get_groups($conn, "WHERE SIDSS_Ref LIKE '{$directive_id}' OR SIDSS_Ref LIKE '{$directive_id},%' OR SIDSS_Ref LIKE '%,{$directive_id}' OR SIDSS_Ref LIKE '%,{$directive_id},%'");
    $pci_groups = PCI::get_groups($conn, "WHERE SIDSS_ref LIKE '{$directive_id}' OR SIDSS_ref LIKE '{$directive_id},%' OR SIDSS_ref LIKE '%,{$directive_id}' OR SIDSS_ref LIKE '%,{$directive_id},%'");
    list($alarms, $num_alarms) = Alarm::get_list3($conn, "", "", 0, "", null, null, null, null, "", $directive_id);
    $kdocs = Repository::get_linked_by_directive($conn, $directive_id);
    ?>
<table class="transparent" height="100%" width="100%">
	<tr>
		<td class="nobborder" valign="top">
			<table height="100%" width="100%">
				<tr><th colspan="2" height="15"><?php 
    echo _("Properties");
    ?>
</th></tr>
				<?php 
    if (count($properties) < 1) {
Example #2
0
	<link rel="stylesheet" type="text/css" href="../style/style.css"/>
</head>
<body>

<?php 
require_once 'ossim_db.inc';
require_once 'classes/Security.inc';
require_once 'classes/Compliance.inc';
$sid = GET('sid');
ossim_valid($sid, OSS_DIGIT, 'illegal:' . _("sid"));
if (ossim_error()) {
    die(ossim_error());
}
$db = new ossim_db();
$conn = $db->connect();
if (list($category_list, $total) = Compliance::get_category($conn, "AND plugin_sid.sid = {$sid}")) {
    $cat = $category_list[0];
}
include "../hmenu.php";
?>

<form method="post" action="modifygeneral.php">
	<input type="hidden" name="insert" value="insert"/>
	
	<table align="center">
		<tr>
			<th> <?php 
echo gettext("SID");
?>
 (*)</th>
			<td class="left"><input type="text" name="sid" value="<?php 
Example #3
0
    ?>
 </a>
      &nbsp;&nbsp;&nbsp;<a href="general.php">
      <?php 
    echo gettext("No");
    ?>
 </a>
    </p>
<?php 
    exit;
}
require_once 'ossim_db.inc';
require_once 'classes/Compliance.inc';
$db = new ossim_db();
$conn = $db->connect();
Compliance::delete($conn, $sid);
$db->close($conn);
?>

    <p> <?php 
echo gettext("Category deleted");
?>
 </p>
    <p><a href="general.php">
    <?php 
echo gettext("Back");
?>
 </a></p>
<?php 
// update indicators on top frame
$OssimWebIndicator->update_display();
Example #4
0
ossim_valid($order, OSS_ALPHA, OSS_SPACE, OSS_SCORE, OSS_NULLABLE, 'illegal:' . _("order"));
ossim_valid($page, OSS_DIGIT, OSS_NULLABLE, 'illegal:' . _("page"));
ossim_valid($rp, OSS_DIGIT, OSS_NULLABLE, 'illegal:' . _("rp"));
if (ossim_error()) {
    die(ossim_error());
}
if (empty($order)) {
    $order = "sid";
}
//if ($order == "ip") $order = "INET_ATON(ip)"; // Numeric ORDER for IP
$start = ($page - 1) * $rp;
$limit = "LIMIT {$start}, {$rp}";
$db = new ossim_db();
$conn = $db->connect();
$xml = "";
list($category_list, $total) = Compliance::get_category($conn, "", "ORDER BY {$order} {$limit}");
$xml .= "<rows>\n";
$xml .= "<page>{$page}</page>\n";
$xml .= "<total>{$total}</total>\n";
//var_dump($category_list);
foreach ($category_list as $cat) {
    $sid = $cat->get_sid();
    $xml .= "<row id='{$sid}'>";
    $xml .= "<cell><![CDATA[" . $sid . "]]></cell>";
    $xml .= "<cell><![CDATA[" . trim(str_replace("directive_event:", "", $cat->get_plugin_name())) . "]]></cell>";
    $xml .= "<cell><![CDATA[" . ($cat->get_targeted() ? "<img src='../pixmaps/tables/tick-small-circle.png'>" : "<img src='../pixmaps/tables/cross-small-circle.png'>") . "]]></cell>";
    $xml .= "<cell><![CDATA[" . ($cat->get_untargeted() ? "<img src='../pixmaps/tables/tick-small-circle.png'>" : "<img src='../pixmaps/tables/cross-small-circle.png'>") . "]]></cell>";
    $xml .= "<cell><![CDATA[" . ($cat->get_approach() ? "<img src='../pixmaps/tables/tick-small-circle.png'>" : "<img src='../pixmaps/tables/cross-small-circle.png'>") . "]]></cell>";
    $xml .= "<cell><![CDATA[" . ($cat->get_exploration() ? "<img src='../pixmaps/tables/tick-small-circle.png'>" : "<img src='../pixmaps/tables/cross-small-circle.png'>") . "]]></cell>";
    $xml .= "<cell><![CDATA[" . ($cat->get_penetration() ? "<img src='../pixmaps/tables/tick-small-circle.png'>" : "<img src='../pixmaps/tables/cross-small-circle.png'>") . "]]></cell>";
    $xml .= "<cell><![CDATA[" . ($cat->get_generalmalware() ? "<img src='../pixmaps/tables/tick-small-circle.png'>" : "<img src='../pixmaps/tables/cross-small-circle.png'>") . "]]></cell>";
Example #5
0
ossim_valid($imp_image, OSS_DIGIT, 'illegal:' . _("imp_image"));
ossim_valid($imp_financial, OSS_DIGIT, 'illegal:' . _("imp_financial"));
ossim_valid($D, OSS_DIGIT, 'illegal:' . _("D"));
ossim_valid($I, OSS_DIGIT, 'illegal:' . _("I"));
ossim_valid($C, OSS_DIGIT, 'illegal:' . _("C"));
ossim_valid($net_anomaly, OSS_DIGIT, 'illegal:' . _("net_anomaly"));
if (ossim_error()) {
    die(ossim_error());
}
if (!empty($insert)) {
    require_once 'ossim_db.inc';
    require_once 'classes/Compliance.inc';
    $db = new ossim_db();
    $conn = $db->connect();
    $descr = "";
    Compliance::update($conn, $descr, $sid, $targeted, $untargeted, $approach, $exploration, $penetration, $generalmalware, $imp_qos, $imp_infleak, $imp_lawful, $imp_image, $imp_financial, $D, $I, $C, $net_anomaly);
    $db->close($conn);
}
?>
    <p><?php 
echo _("Category succesfully updated");
?>
</p>
    <script>document.location.href="general.php"</script>
<?php 
// update indicators on top frame
$OssimWebIndicator->update_display();
?>

</body>
</html>