当前位置: 首页>>代码示例>>PHP>>正文


PHP Software::get_hardware_vendors方法代码示例

本文整理汇总了PHP中Software::get_hardware_vendors方法的典型用法代码示例。如果您正苦于以下问题:PHP Software::get_hardware_vendors方法的具体用法?PHP Software::get_hardware_vendors怎么用?PHP Software::get_hardware_vendors使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Software的用法示例。


在下文中一共展示了Software::get_hardware_vendors方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: get_vendor_list

function get_vendor_list($conn)
{
    $response = array();
    $items = Software::get_hardware_vendors($conn, TRUE);
    $response['error'] = FALSE;
    $response['data']['items'] = $items;
    return $response;
}
开发者ID:AntBean,项目名称:alienvault-ossim,代码行数:8,代码来源:plugin_ajax.php

示例2: get_vendor_list

function get_vendor_list($data)
{
    $response = array();
    $sensor = $data['sensor'];
    ossim_valid($sensor, OSS_ALPHA, OSS_HEX, 'illegal:' . _("Sensor"));
    check_ossim_error();
    $items = Software::get_hardware_vendors($sensor);
    $response['error'] = FALSE;
    $response['data']['items'] = $items;
    return $response;
}
开发者ID:jackpf,项目名称:ossim-arc,代码行数:11,代码来源:plugin_ajax.php

示例3: GET

* Otherwise you can read it here: http://www.gnu.org/licenses/gpl-2.0.txt
*
*/
require_once 'av_init.php';
$init_error = FALSE;
$sensor = GET('sensor') != '' ? GET('sensor') : 'local';
ossim_valid($sensor, OSS_ALPHA, OSS_HEX, OSS_NULLABLE, 'illegal:' . _('Sensor'));
if (ossim_error()) {
    die(ossim_error());
}
/*
 * For performance and synchronicity, the Vendors list must be static.
 * Note that it must be reloaded when the sensor is manually changed.
 */
try {
    $_vendor_list = Software::get_hardware_vendors($sensor);
} catch (Exception $e) {
    $_vendor_list = array();
    $init_error = $e->getMessage();
}
?>

// Global variables
/* Note: presaved_data is used by asset_plugin_list.js.php dataTable object
 *       Must be global to store the changes in all dataTable pages
 *       And be able to use externally from edit_plugins.php
 */
var presaved_data = {};

function AVplugin_select()
{
开发者ID:jackpf,项目名称:ossim-arc,代码行数:31,代码来源:av_plugin_select.js.php

示例4: array

}
$system_list = Av_center::get_avc_list($conn);
$admin_ip = @$system_list['data'][strtolower(Util::get_system_uuid())]['admin_ip'];
$table = ', host_types ht, host_ip hip';
$f = array();
$f['where'] = " host.id=ht.host_id AND ht.type=4 AND hip.host_id=host.id AND hip.ip!=inet6_aton('{$admin_ip}')";
try {
    list($hosts, $total) = Asset_host::get_list($conn, $table, $f, FALSE);
    $active_plugins = Plugin::get_plugins_by_assets();
} catch (Exception $e) {
    $total = 0;
    Av_exception::write_log(Av_exception::USER_ERROR, $e->getMessage());
}
if ($total > 0) {
    try {
        $vendors = Software::get_hardware_vendors();
    } catch (Exception $e) {
        $vendors = array();
        Av_exception::write_log(Av_exception::USER_ERROR, $e->getMessage());
    }
    $device_list = array();
    foreach ($hosts as $asset_id => $host) {
        $plugin_list = array();
        $asset_id_canonical = Util::uuid_format($asset_id);
        if (count($active_plugins[$asset_id_canonical]) < 1) {
            $plugin_list[$asset_id][] = array('vendor' => '', 'model' => '', 'version' => '', 'model_list' => array(), 'version_list' => array());
        } else {
            foreach ($active_plugins[$asset_id_canonical] as $pdata) {
                $models = array();
                $versions = array();
                if ($pdata['vendor'] != '') {
开发者ID:jackpf,项目名称:ossim-arc,代码行数:31,代码来源:step_4.php

示例5: GET

    $nt->show();
    die;
}
$asset_id = GET('asset_id');
$sensor_id = GET('sensor_id');
ossim_valid($asset_id, OSS_HEX, 'illegal:' . _('Asset ID'));
ossim_valid($sensor_id, OSS_HEX, OSS_NULLABLE, 'illegal:' . _('Sensor ID'));
if (ossim_error()) {
    die(ossim_error());
}
// Database Object
$db = new ossim_db();
$conn = $db->connect();
//Getting the vendors
try {
    $vendors = Software::get_hardware_vendors($conn, TRUE);
} catch (Exception $e) {
    $vendors = array();
    Av_exception::write_log(Av_exception::USER_ERROR, $e->getMessage());
}
$plugin_list = array();
try {
    $related_sensors = Asset_host_sensors::get_sensors_by_id($conn, $asset_id);
    $selected_sensor = $sensor_id != '' ? $sensor_id : key($related_sensors);
    $active_plugins = Plugin::get_plugins_by_device(Util::uuid_format($selected_sensor));
    $asset_plugins = is_array($active_plugins[$asset_id]) ? $active_plugins[$asset_id] : array();
    foreach ($asset_plugins as $pdata) {
        $model_list = array();
        $version_list = array();
        list($vendor, $model, $version) = Plugin::translate_cpe_to_software($pdata['cpe']);
        if ($vendor != '') {
开发者ID:AntBean,项目名称:alienvault-ossim,代码行数:31,代码来源:enable_plugin.php


注:本文中的Software::get_hardware_vendors方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。