dradis-openvas 3.6.0 → 3.7.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4302834824dbe88f400dbd45446400ce13c38b45
4
- data.tar.gz: fed650cc7a5a5aace7a927237b60b2e98683dce0
3
+ metadata.gz: 692a9769414b9089795e601f5ee3e235a20fe4f9
4
+ data.tar.gz: 67093fd6da54d6169841a5d11be58261f410dccd
5
5
  SHA512:
6
- metadata.gz: 9d75ad8bcf20192be8f99d652808bd88d13c1e6a9c57904bd635eaebed99aec9e6ff8a7937242563b20690f7c13c6347e965858e63e29953e2a71814e079cf90
7
- data.tar.gz: 3c8927eb4d20e7fcdb99dac2166f16a592eeae31bb0e9649674c1ebd6826a57929c51aa2c4a1803ad78c36aa21f1310e5546b6f6bc976dbd99351dcd43b4fc3d
6
+ metadata.gz: 46576f1f9f587c4a9ce00b0da66e2c0e1da615d0695f36262ce916efd669803127ca00b97e58184305c904f53da4fd721295a0c42ad33cbba884c08635efc739
7
+ data.tar.gz: 8821f29fbe8e79a1a6c6ea97678ed462226d4046c8d4edac271ecea744a3287729d8d5cc899a273c9b3577799fcebf517310ac609c838cb956765370c7eee653
data/.gitignore CHANGED
@@ -6,3 +6,5 @@ Gemfile.lock
6
6
 
7
7
  # Gem artifacts
8
8
  /pkg/
9
+
10
+ .DS_Store
data/CHANGELOG.md CHANGED
@@ -1,3 +1,8 @@
1
- ## Dradis Framework 3.6 (March XX, 2017) ##
1
+ ## Dradis Framework 3.7 (Jul, 2017) ##
2
+ * Add Evidence template.
3
+ * Add :cvss_base_vector to Result template.
4
+
5
+
6
+ ## Dradis Framework 3.6 (Apr 6, 2017) ##
2
7
 
3
8
  * No changes.
@@ -8,7 +8,7 @@ module Dradis
8
8
 
9
9
  module VERSION
10
10
  MAJOR = 3
11
- MINOR = 6
11
+ MINOR = 7
12
12
  TINY = 0
13
13
  PRE = nil
14
14
 
@@ -51,9 +51,6 @@ module Dradis::Plugins::OpenVAS
51
51
  # instance-specific evidence though.
52
52
  logger.info{ "\t\t => Adding reference to this host" }
53
53
 
54
- port_info = xml_result.at_xpath('./port').text
55
- evidence_content = "\n#[Port]#\n#{port_info}\n\n"
56
-
57
54
  # There is no way of knowing where OpenVAS is going to place the evidence
58
55
  # for each issue. For example:
59
56
  #
@@ -91,9 +88,8 @@ module Dradis::Plugins::OpenVAS
91
88
  # doesn't provide any per-instance information.
92
89
  #
93
90
  # Best thing to do is to include the full <description> field and let the user deal with it.
94
- description = xml_result.at_xpath('./description').text()
95
- evidence_content << "\n#[Description]#\n#{description}\n\n"
96
-
91
+
92
+ evidence_content = template_service.process_template(template: 'evidence', data: xml_result)
97
93
  content_service.create_evidence(issue: issue, node: host_node, content: evidence_content)
98
94
  end
99
95
 
@@ -22,13 +22,13 @@ module OpenVAS
22
22
  # NONE
23
23
 
24
24
  # simple tags
25
- :threat, :description, :original_threat, :notes, :overrides,
25
+ :port, :threat, :description, :original_threat, :notes, :overrides,
26
26
 
27
27
  # nested tags
28
28
  :name, :cvss_base, :risk_factor, :cve, :bid, :xref,
29
29
 
30
- # fields inside :description
31
- :summary, :info_gathered, :insight, :impact, :impact_level, :affected_software, :solution
30
+ # fields inside :tags
31
+ :summary, :info_gathered, :cvss_base_vector, :insight, :impact, :impact_level, :affected_software, :solution
32
32
  ]
33
33
  end
34
34
 
@@ -16,7 +16,7 @@ module OpenVAS::V7
16
16
  if @tag_fields.nil?
17
17
  delimiters = {
18
18
  # Not supported via .fields
19
- # 'cvss_base_vector='
19
+ 'cvss_base_vector=' => :cvss_base_vector,
20
20
  'impact=' => :impact,
21
21
 
22
22
  # Not supported via .fields
@@ -7,9 +7,6 @@ class OpenVASTasks < Thor
7
7
  def upload(file_path)
8
8
  require 'config/environment'
9
9
 
10
- logger = Logger.new(STDOUT)
11
- logger.level = Logger::DEBUG
12
-
13
10
  unless File.exists?(file_path)
14
11
  $stderr.puts "** the file [#{file_path}] does not exist"
15
12
  exit -1
@@ -17,10 +14,8 @@ class OpenVASTasks < Thor
17
14
 
18
15
  detect_and_set_project_scope
19
16
 
20
- importer = Dradis::Plugins::OpenVAS::Importer.new(logger: logger)
17
+ importer = Dradis::Plugins::OpenVAS::Importer.new(task_options)
21
18
  importer.import(file: file_path)
22
-
23
- logger.close
24
19
  end
25
20
 
26
21
  end
@@ -0,0 +1,2 @@
1
+ evidence.port
2
+ evidence.description
@@ -0,0 +1,48 @@
1
+ <?xml version="1.0"?>
2
+ <result id="e2ccf551-ea4e-4186-9b24-76287d6244f3">
3
+ <subnet>172.31.253.9</subnet>
4
+ <host>172.31.253.9</host>
5
+ <port>general/tcp</port>
6
+ <nvt oid="1.3.6.1.4.1.25623.1.0.802610">
7
+ <name>Oracle Java SE JRE Multiple Vulnerabilities - February 2012 (Windows - 01)</name>
8
+ <cvss_base>10.0</cvss_base>
9
+ <risk_factor>Critical</risk_factor>
10
+ <cve>CVE-2011-3563, CVE-2012-0499, CVE-2012-0502, CVE-2012-0503, CVE-2012-0505, CVE-2012-0506</cve>
11
+ <bid>52011, 52012, 52014, 52016, 52017, 52018</bid>
12
+ <xref>URL:http://secunia.com/advisories/48009, URL:http://www.pre-cert.de/advisories/PRE-SA-2012-01.txt, URL:http://www.oracle.com/technetwork/topics/security/javacpufeb2012-366318.html, URL:http://www.oracle.com/technetwork/java/javase/documentation/overview-142120.html, URL:http://www.oracle.com/technetwork/java/javase/documentation/overview-137139.html</xref>
13
+ </nvt>
14
+ <threat>High</threat>
15
+ <description>
16
+ Summary:
17
+ This host is installed with Oracle Java SE JRE and is prone to
18
+ multiple vulnerabilities.
19
+
20
+ Vulnerability Insight:
21
+ Multiple flaws are caused by unspecified errors in the following
22
+ components:
23
+ - 2D
24
+ - AWT
25
+ - Sound
26
+ - I18n
27
+ - CORBA
28
+ - Serialization
29
+
30
+ Impact:
31
+ Successful exploitation allows remote attackers to affect confidentiality,
32
+ integrity, and availability via unknown vectors.
33
+
34
+ Impact Level: System/Application
35
+
36
+ Affected Software/OS:
37
+ Oracle Java SE JRE 7 Update 2 and earlier, 6 Update 30 and earlier, 5.0 Update 33
38
+ and earlier, and 1.4.2_35 and earlier
39
+
40
+ Solution:
41
+ Upgrade to Oracle Java SE JRE versions 7 Update 3, 6 Update 31, 5.0 Update
42
+ 34, 1.4.2_36 or later. For updates refer to
43
+ http://www.oracle.com/technetwork/topics/security/javacpufeb2012-366318.html
44
+ </description>
45
+ <original_threat>High</original_threat>
46
+ <notes/>
47
+ <overrides/>
48
+ </result>
@@ -0,0 +1,6 @@
1
+ #[Port]#
2
+ %evidence.port%
3
+
4
+
5
+ #[Description]#
6
+ %evidence.description%
@@ -5,6 +5,7 @@ result.notes
5
5
  result.overrides
6
6
  result.name
7
7
  result.cvss_base
8
+ result.cvss_base_vector
8
9
  result.risk_factor
9
10
  result.cve
10
11
  result.bid
@@ -16,14 +16,10 @@
16
16
 
17
17
 
18
18
  #[References]#
19
- CVE
20
- %result.cve%
21
-
22
- BID
23
- %result.bid%
24
-
25
- Other
26
- %result.xref%
19
+ CVE: %result.cve%
20
+ CVSS Vector: %cvss_base_vector%
21
+ BID: %result.bid%
22
+ Other: %result.xref%
27
23
 
28
24
 
29
25
  #[RawDescription]#
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dradis-openvas
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.6.0
4
+ version: 3.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Martin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-04-06 00:00:00.000000000 Z
11
+ date: 2017-07-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dradis-plugins
@@ -87,6 +87,9 @@ files:
87
87
  - spec/openvas/result_spec.rb
88
88
  - spec/spec_helper.rb
89
89
  - spec/support/fixture_loader.rb
90
+ - templates/evidence.fields
91
+ - templates/evidence.sample
92
+ - templates/evidence.template
90
93
  - templates/result.fields
91
94
  - templates/result.sample
92
95
  - templates/result.template
@@ -110,7 +113,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
110
113
  version: '0'
111
114
  requirements: []
112
115
  rubyforge_project:
113
- rubygems_version: 2.4.5
116
+ rubygems_version: 2.6.8
114
117
  signing_key:
115
118
  specification_version: 4
116
119
  summary: OpenVAS add-on for the Dradis Framework.