Class: SSLScan::Commands::Host
- Defined in:
- lib/ssl_scan/commands/host.rb
Instance Attribute Summary collapse
-
#hostname ⇒ Object
Returns the value of attribute hostname.
-
#options ⇒ Object
Returns the value of attribute options.
Attributes inherited from Command
Instance Method Summary collapse
- #execute ⇒ Object
-
#initialize(hostname, options) ⇒ Host
constructor
A new instance of Host.
Methods inherited from Command
#display_ciphers, #display_header
Constructor Details
#initialize(hostname, options) ⇒ Host
Returns a new instance of Host.
6 7 8 9 10 |
# File 'lib/ssl_scan/commands/host.rb', line 6 def initialize(hostname, ) super() @hostname = hostname @options = end |
Instance Attribute Details
#hostname ⇒ Object
Returns the value of attribute hostname.
4 5 6 |
# File 'lib/ssl_scan/commands/host.rb', line 4 def hostname @hostname end |
#options ⇒ Object
Returns the value of attribute options.
4 5 6 |
# File 'lib/ssl_scan/commands/host.rb', line 4 def @options end |
Instance Method Details
#execute ⇒ Object
12 13 14 15 16 17 18 19 20 21 22 23 |
# File 'lib/ssl_scan/commands/host.rb', line 12 def execute parts = hostname.split(":") if parts.length == 2 display_header(parts[0], parts[1]) scanner = SSLScan::Scanner.new(parts[0], parts[1].to_i) else display_header(parts[0]) scanner = SSLScan::Scanner.new(parts[0]) end display_ciphers(scanner) @results << scanner.results end |