Class: Nexpose::Device
- Inherits:
-
Object
- Object
- Nexpose::Device
- Defined in:
- lib/nexpose.rb
Overview
Description
Object that represents a single device in an NSC.
Instance Attribute Summary collapse
-
#address ⇒ Object
readonly
IP Address or Hostname of this device.
-
#id ⇒ Object
readonly
A unique device ID (assigned by the NSC).
-
#riskfactor ⇒ Object
readonly
User assigned risk multiplier.
-
#riskscore ⇒ Object
readonly
NeXpose risk score.
-
#site_id ⇒ Object
readonly
The site ID of this devices site.
Instance Method Summary collapse
-
#initialize(id, site_id, address, riskfactor = 1, riskscore = 0) ⇒ Device
constructor
A new instance of Device.
Constructor Details
#initialize(id, site_id, address, riskfactor = 1, riskscore = 0) ⇒ Device
Returns a new instance of Device.
1960 1961 1962 1963 1964 1965 1966 1967 |
# File 'lib/nexpose.rb', line 1960 def initialize(id, site_id, address, riskfactor=1, riskscore=0) @id = id @site_id = site_id @address = address @riskfactor = riskfactor @riskscore = riskscore end |
Instance Attribute Details
#address ⇒ Object (readonly)
IP Address or Hostname of this device
1954 1955 1956 |
# File 'lib/nexpose.rb', line 1954 def address @address end |
#id ⇒ Object (readonly)
A unique device ID (assigned by the NSC)
1950 1951 1952 |
# File 'lib/nexpose.rb', line 1950 def id @id end |
#riskfactor ⇒ Object (readonly)
User assigned risk multiplier
1956 1957 1958 |
# File 'lib/nexpose.rb', line 1956 def riskfactor @riskfactor end |
#riskscore ⇒ Object (readonly)
NeXpose risk score
1958 1959 1960 |
# File 'lib/nexpose.rb', line 1958 def riskscore @riskscore end |
#site_id ⇒ Object (readonly)
The site ID of this devices site
1952 1953 1954 |
# File 'lib/nexpose.rb', line 1952 def site_id @site_id end |