dradis-nmap 3.15.0 → 3.16.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
  SHA256:
3
- metadata.gz: 8483ae7b858089caafea606939af8a707bb49ac6387c5a75a61bee27ca1b3047
4
- data.tar.gz: cc910317146439cb1c1ff76ed16341ce45943754d8185b6f416ae6af8505f2be
3
+ metadata.gz: a110471150b27489da28e66a2823c61c9390194bef78e0adec44d96221c905e7
4
+ data.tar.gz: 760067acfb3c386063b17d8bb86f219d733a9ece916de394e9ac504de8c9fe99
5
5
  SHA512:
6
- metadata.gz: ab3b7fd6354711c98340eaa47141d22603def36e238e2a5939c2ec6850ebea189006f025c4e8cfe6dd62d572cd3bbcea1cd29d4c6b38a6ba9c37ca1dc8403633
7
- data.tar.gz: 5333cb33a15e4a382777440ace13289d4809d67d7a79bd374ab1849e510591e800f298eb20f3c0c7b5fc85744f896b3612acf32db530ad1dcb79cf18bea8d979
6
+ metadata.gz: 1c04804b0b7b458ef50c0c229545048b43518bb2aaf68821cc5dfa6a40d4190177e027237d00aa46618a0b3c6d183fb4275b3be3fbbfafd709b2b5f7251acc4e
7
+ data.tar.gz: 44b141ebf8e55c74882004375ed743a88e7c4a940f27f89b47fba47d6d2ea16b9d24adaca50aa0c72124e0c4c4ff68115d26da301cb5a2c72dbb41a4a404d947
@@ -1,3 +1,7 @@
1
+ ## Dradis Framework 3.16 (February, 2020) ##
2
+
3
+ * No changes.
4
+
1
5
  ## Dradis Framework 3.15 (November, 2019) ##
2
6
 
3
7
  * No changes.
@@ -27,7 +27,7 @@ Gem::Specification.new do |spec|
27
27
  spec.add_dependency 'dradis-plugins', '~> 3.6'
28
28
  spec.add_dependency 'ruby-nmap', '~> 0.7'
29
29
 
30
- spec.add_development_dependency 'bundler', '~> 1.6'
30
+ spec.add_development_dependency 'bundler'
31
31
  spec.add_development_dependency 'rake', '~> 10.0'
32
32
  spec.add_development_dependency 'rspec-rails'
33
33
  spec.add_development_dependency 'combustion', '~> 0.5.2'
@@ -8,7 +8,7 @@ module Dradis
8
8
 
9
9
  module VERSION
10
10
  MAJOR = 3
11
- MINOR = 15
11
+ MINOR = 16
12
12
  TINY = 0
13
13
  PRE = nil
14
14
 
@@ -12,34 +12,11 @@ describe 'Nmap upload plugin' do
12
12
  # Init services
13
13
  plugin = Dradis::Plugins::Nmap
14
14
 
15
- @content_service = Dradis::Plugins::ContentService.new(plugin: plugin)
16
- template_service = Dradis::Plugins::TemplateService.new(plugin: plugin)
15
+ @content_service = Dradis::Plugins::ContentService::Base.new(plugin: plugin)
17
16
 
18
17
  @importer = plugin::Importer.new(
19
- content_service: @content_service,
20
- template_service: template_service
18
+ content_service: @content_service
21
19
  )
22
-
23
- # Stub dradis-plugins methods
24
- #
25
- # They return their argument hashes as objects mimicking
26
- # Nodes, Issues, etc
27
- allow(@content_service).to receive(:create_node) do |args|
28
- # puts "create_node: #{ args.inspect }"
29
- OpenStruct.new(args)
30
- end
31
- allow(@content_service).to receive(:create_note) do |args|
32
- # puts "create_note: #{ args.inspect }"
33
- OpenStruct.new(args)
34
- end
35
- allow(@content_service).to receive(:create_issue) do |args|
36
- # puts "create_issue: #{ args.inspect }"
37
- OpenStruct.new(args)
38
- end
39
- allow(@content_service).to receive(:create_evidence) do |args|
40
- # puts "create_evidence: #{ args.inspect }"
41
- OpenStruct.new(args)
42
- end
43
20
  end
44
21
 
45
22
  it "creates an error note when the xml is not valid" do
@@ -47,16 +24,20 @@ describe 'Nmap upload plugin' do
47
24
  expect(args[:text]).to include("#[Title]#\nInvalid file format")
48
25
  OpenStruct.new(args)
49
26
  end.once
27
+
50
28
  # Run the import
51
29
  @importer.import(file: 'spec/fixtures/files/invalid.xml')
52
30
  end
53
31
 
54
32
  it "creates nodes, issues, notes and an evidences as needed" do
55
33
  expect(@content_service).to receive(:create_node) do |args|
56
- # puts "create_node: #{ args.inspect }"
34
+ puts "create_node: #{ args.inspect }"
57
35
  expect(args[:label]).to eq('74.207.244.221')
58
36
  expect(args[:type]).to eq(:host)
59
- OpenStruct.new(args)
37
+ obj = OpenStruct.new(args)
38
+ obj.define_singleton_method(:set_property) { |*| }
39
+ obj.define_singleton_method(:set_service) { |*| }
40
+ obj
60
41
  end.once
61
42
  expect(@content_service).to receive(:create_note) do |args|
62
43
  puts "create_note: #{ args.inspect }"
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dradis-nmap
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.15.0
4
+ version: 3.16.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: 2019-12-11 00:00:00.000000000 Z
11
+ date: 2020-02-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dradis-plugins
@@ -42,16 +42,16 @@ dependencies:
42
42
  name: bundler
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - "~>"
45
+ - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: '1.6'
47
+ version: '0'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - "~>"
52
+ - - ">="
53
53
  - !ruby/object:Gem::Version
54
- version: '1.6'
54
+ version: '0'
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: rake
57
57
  requirement: !ruby/object:Gem::Requirement