本文整理汇总了PHP中Av_sensor::get_all方法的典型用法代码示例。如果您正苦于以下问题:PHP Av_sensor::get_all方法的具体用法?PHP Av_sensor::get_all怎么用?PHP Av_sensor::get_all使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Av_sensor
的用法示例。
在下文中一共展示了Av_sensor::get_all方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: while
$res = $conn->query("SELECT id,name,value FROM acl_perm WHERE type='MENU'");
while ($rw = $res->fetchRow()) {
$ret[$rw['name']][$rw['value']] = $rw['id'];
}
return $ret;
}
ini_set("include_path", ".:/usr/share/ossim/include:/usr/share/phpgacl");
$force_gacl = true;
require_once 'av_init.php';
$gacl = $GLOBALS['ACL'];
/* connect to db */
$db = new ossim_db();
$conn = $db->connect();
try {
$net_list = Asset_net::get_all($conn);
$sensor_list = Av_sensor::get_all($conn);
} catch (Exception $e) {
print $e->getMessage();
exit;
}
$permids = get_permids($conn);
$users = Session::get_list($conn);
foreach ($users as $user) {
$nets = "";
$sensors = "";
$perms = array();
$login = $user->get_login();
if ($user->get_is_admin() || $login == ACL_DEFAULT_OSSIM_ADMIN) {
continue;
}
// Skip admin user
示例2: ossim_db
$dbo = new ossim_db(true);
// Multiple Database Server selector
$conn = $dbo->connect();
$database_servers = Databases::get_list($conn);
$dbo->close();
//
if (is_array($_SESSION["server"]) && $_SESSION["server"][0] != "") {
$dbo->enable_cache();
$conn = $dbo->custom_connect($_SESSION["server"][0], $_SESSION["server"][2], $_SESSION["server"][3]);
} else {
$dbo->enable_cache();
$conn = $dbo->connect();
}
include_once "{$BASE_path}/base_common.php";
$sensors = $hosts = $ossim_servers = $sensor_names = array();
$sensors = Av_sensor::get_all($conn, TRUE);
foreach ($sensors as $_sensor) {
$sensor_names[$_sensor['ip']] = $_sensor['name'];
}
list($hosts, $host_ids) = Asset_host::get_basic_list($conn, array(), TRUE);
$entities = Session::get_all_entities($conn);
$rep_activities = Reputation::get_reputation_activities($conn, "ORDER BY descr", $db_memcache);
$rep_severities = array("High" => "High Severity", "Medium" => "Medium Severity", "Low" => "Low Severity");
//
// added default home host/lan to SESSION[ip_addr]
//
if ($_GET["addhomeips"] == "src" || $_GET["addhomeips"] == "dst") {
$_nets = Asset_net::get_all($conn, TRUE);
// adding all not external lans
$local_ips = array();
$total_ips = 0;