Class: Saint::Evidence
Instance Method Summary collapse
Methods inherited from Base
#initialize, #method_missing, #respond_to?
Constructor Details
This class inherits a constructor from Saint::Base
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Saint::Base
Instance Method Details
#process_field_value(method) ⇒ Object
7 8 9 10 11 12 13 14 15 16 |
# File 'lib/saint/evidence.rb', line 7 def process_field_value(method) # We cannot send the message 'class' to the saint_object because it # evaluates to the object's Ruby class. We temporarily rename the # field to 'vuln_class' and switch it back later when needed. if method == :vuln_class method = :class end @xml.xpath("./#{method.to_s}").first.try(:text) end |
#supported_tags ⇒ Object
3 4 5 |
# File 'lib/saint/evidence.rb', line 3 def [ :port, :severity, :vuln_class, :cve, :cvss_base_score ] end |