Class: Contrast::Agent::Reporting::Details::XxeDetails

Inherits:
ProtectRuleDetails show all
Defined in:
lib/contrast/agent/reporting/details/xxe_details.rb

Overview

XssDetails IA result details info.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeXxeDetails

Returns a new instance of XxeDetails.



19
20
21
22
23
# File 'lib/contrast/agent/reporting/details/xxe_details.rb', line 19

def initialize
  @declared_entities = []
  @entities_resolved = []
  super
end

Instance Attribute Details

#declared_entities<Array<Contrast::Agent::Reporting::Details::XxeMatch>]

Returns <Array<Contrast::Agent::Reporting::Details::XxeMatch>].

Returns:



15
16
17
# File 'lib/contrast/agent/reporting/details/xxe_details.rb', line 15

def declared_entities
  @declared_entities
end

#entities_resolved<Array<Contrast::Agent::Reporting::Details::XxeWrapper>]

Returns <Array<Contrast::Agent::Reporting::Details::XxeWrapper>].

Returns:



17
18
19
# File 'lib/contrast/agent/reporting/details/xxe_details.rb', line 17

def entities_resolved
  @entities_resolved
end

#xmlString

Returns:



13
14
15
# File 'lib/contrast/agent/reporting/details/xxe_details.rb', line 13

def xml
  @xml
end

Instance Method Details

#to_controlled_hashObject



25
26
27
28
29
30
31
# File 'lib/contrast/agent/reporting/details/xxe_details.rb', line 25

def to_controlled_hash
  {
      xml: xml,
      declaredEntities: declared_entities&.map(&:to_controlled_hash),
      entitiesResolved: entities_resolved&.map(&:to_controlled_hash)
  }
end