Class: Mihari::Analyzers::VirusTotal
- Includes:
- Mixins::Refang
- Defined in:
- lib/mihari/analyzers/virustotal.rb
Constant Summary
Constants included from Mixins::Retriable
Instance Attribute Summary collapse
- #api_key ⇒ String? readonly
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Attributes inherited from Base
Instance Method Summary collapse
- #artifacts ⇒ Object
-
#initialize(*args, **kwargs) ⇒ VirusTotal
constructor
A new instance of VirusTotal.
Methods included from Mixins::Refang
Methods inherited from Base
inherited, #normalized_artifacts, #run, #run_emitter, #source
Methods included from Mixins::Retriable
Methods included from Mixins::Configurable
#configuration_values, #configured?
Methods included from Mixins::AutonomousSystem
Constructor Details
#initialize(*args, **kwargs) ⇒ VirusTotal
Returns a new instance of VirusTotal.
17 18 19 20 21 22 23 24 |
# File 'lib/mihari/analyzers/virustotal.rb', line 17 def initialize(*args, **kwargs) super(*args, **kwargs) @query = refang(query) @type = TypeChecker.type(query) @api_key = kwargs[:api_key] || Mihari.config.virustotal_api_key end |
Instance Attribute Details
#api_key ⇒ String? (readonly)
15 16 17 |
# File 'lib/mihari/analyzers/virustotal.rb', line 15 def api_key @api_key end |
#type ⇒ Object (readonly)
Returns the value of attribute type.
12 13 14 |
# File 'lib/mihari/analyzers/virustotal.rb', line 12 def type @type end |
Instance Method Details
#artifacts ⇒ Object
26 27 28 |
# File 'lib/mihari/analyzers/virustotal.rb', line 26 def artifacts search || [] end |