Class: Inspec::Resources::PortsInfo

Inherits:
Object
  • Object
show all
Defined in:
lib/resources/port.rb

Overview

implements an info method and returns all ip adresses and protocols for each port [{ 'port' => 22, 'address' => '0.0.0.0' 'protocol' => 'tcp' }, { 'port' => 22, 'address' => '::' 'protocol' => 'tcp6' }]

Direct Known Subclasses

FreeBsdPorts, LinuxPorts, LsofPorts, WindowsPorts

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(inspec) ⇒ PortsInfo

Returns a new instance of PortsInfo.



103
104
105
# File 'lib/resources/port.rb', line 103

def initialize(inspec)
  @inspec = inspec
end

Instance Attribute Details

#inspecObject (readonly)

Returns the value of attribute inspec.



102
103
104
# File 'lib/resources/port.rb', line 102

def inspec
  @inspec
end