Class: Controls::Asset

Inherits:
Dish::Plate
  • Object
show all
Defined in:
lib/controls/objects/asset.rb

Overview

A representation of the Asset resource

Instance Method Summary collapse

Instance Method Details

#findingsArray<SecurityControlFindings>

Retreives the security control and configuration findings for this Controls::Asset instance by UUID

Returns:

  • (Array<SecurityControlFindings>)


10
11
12
# File 'lib/controls/objects/asset.rb', line 10

def findings
  @findings ||= Controls.client.findings_by_asset_uuid(uuid)
end

#to_sString

Returns the hostname, IP, and OS of the asset

Examples:

"jdoe.local (192.168.1.23) - Windows 7 Professional Edition"

Returns:

  • (String)


20
21
22
# File 'lib/controls/objects/asset.rb', line 20

def to_s
  %(#{host_name} (#{ipaddress}) - #{operating_system})
end