sitecore_scan 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,7 @@
1
1
  ---
2
- !binary "U0hBMQ==":
3
- metadata.gz: !binary |-
4
- OGExOWRjNzc1NjRiNWYzZmQ5NjYyMGZjOTk4MmQ4ZDRjY2YyNWRkMw==
5
- data.tar.gz: !binary |-
6
- NDU2NWU1ZTc0MWNhZDEyNmY3NzMwNDdkNmFlZWM4YjU3NDZlNjE2MQ==
2
+ SHA256:
3
+ metadata.gz: bd30c3c23e866d2f966d0b69cf5ebc3d23a6008661ad2b127f186fa6944e3917
4
+ data.tar.gz: 4d4f9c8c9acf5be5ec3171e417a104a9a6c1408bf28962882f567f07218c99ce
7
5
  SHA512:
8
- metadata.gz: !binary |-
9
- Y2Q2NGU2MjMzNjJlODlhNmM5OGQxM2ZiMWJiOWE3ZGUzOTlmZDgyNGE3OTc0
10
- Zjk2N2YyODJlN2Y1YzhjYjBkYTVhMmQ4MzhhNGYxYWZiZDliODUwNzVmMDQ5
11
- MmMyYWE3OTE0Y2ZmYWRkNTUxZGNkNmRlNzYwMzBhMGRkM2EyNzA=
12
- data.tar.gz: !binary |-
13
- MDFiM2QyYmZmZGY0NWNiNjNhNzJjMWE3NGY1ODRiNmE4MDk1ZGQxMTlhN2E4
14
- MDJkNGRmMzZmMDJhYzJlMDI5NDg3OTk0ZmRjODYwYmE3M2QzZDkyMmY0NTM3
15
- MzQ3MjQxYWI3ZmVmZTVkOWJlZjEyNjYyNGVhZmYyZTE2NDFhNjM=
6
+ metadata.gz: bd74227b8846e8168fad58a01f392fb36dc0b1fb0c482a3763518e8f9256e3beadca1634fbb3d1519c0f5d757a8f4689ce07b2029d1a9ce9e5f118f9947450cc
7
+ data.tar.gz: 30462814098889ac8b478435d469f86c34e4a05b4cb824d83ffb8b94331a22193edabce3bd6af5d5c793c07fb3e49a73e9301acec2de6f5e17baa9a498d5bd8a
data/bin/sitecore-scan CHANGED
@@ -16,7 +16,7 @@ def banner
16
16
  \\___ \\| | __/ _ \\/ __/ _ \\| '__/ _ \\\\___ \\ / __/ _` | '_ \\
17
17
  ____) | | || __/ (_| (_) | | | __/____) | (_| (_| | | | |
18
18
  |_____/|_|\\__\\___|\\___\\___/|_| \\___|_____/ \\___\\__,_|_| |_|
19
- version 0.0.2"
19
+ version #{SitecoreScan::VERSION}"
20
20
  puts
21
21
  puts '-' * 60
22
22
  end
data/lib/sitecore_scan.rb CHANGED
@@ -8,9 +8,10 @@ require 'cgi'
8
8
  require 'logger'
9
9
  require 'net/http'
10
10
  require 'openssl'
11
+ require 'stringio'
11
12
 
12
13
  class SitecoreScan
13
- VERSION = '0.0.2'.freeze
14
+ VERSION = '0.0.3'.freeze
14
15
 
15
16
  def self.logger
16
17
  @logger
@@ -65,7 +66,11 @@ class SitecoreScan
65
66
 
66
67
  return version if version
67
68
 
68
- res.body.to_s.scan(%r{<iframe src="https://sdn.sitecore.net/startpage.aspx\?[^"]+v=([\d\.]+)"}).flatten.first
69
+ version = res.body.to_s.scan(%r{<iframe src="https://sdn.sitecore.net/startpage.aspx\?[^"]+v=([\d.]+)"}).flatten.first
70
+
71
+ return version if version
72
+
73
+ nil
69
74
  end
70
75
 
71
76
  #
@@ -99,7 +104,7 @@ class SitecoreScan
99
104
 
100
105
  return false unless res
101
106
  return false unless res.code.to_i == 200
102
- return false unless res.body.to_s.include? 'Visual Sitecore Service Web Service'
107
+ return false unless res.body.to_s.include?('Visual Sitecore Service Web Service')
103
108
 
104
109
  true
105
110
  end
metadata CHANGED
@@ -1,27 +1,27 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sitecore_scan
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brendan Coles
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-11-07 00:00:00.000000000 Z
11
+ date: 2023-02-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: logger
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ~>
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.4'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ~>
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.4'
27
27
  description: A simple remote scanner for Sitecore CMS
@@ -43,19 +43,17 @@ require_paths:
43
43
  - lib
44
44
  required_ruby_version: !ruby/object:Gem::Requirement
45
45
  requirements:
46
- - - ! '>='
46
+ - - ">="
47
47
  - !ruby/object:Gem::Version
48
48
  version: 2.0.0
49
49
  required_rubygems_version: !ruby/object:Gem::Requirement
50
50
  requirements:
51
- - - ! '>='
51
+ - - ">="
52
52
  - !ruby/object:Gem::Version
53
53
  version: '0'
54
54
  requirements: []
55
- rubyforge_project:
56
- rubygems_version: 2.2.2
55
+ rubygems_version: 3.3.7
57
56
  signing_key:
58
57
  specification_version: 4
59
58
  summary: Sitecore scanner
60
59
  test_files: []
61
- has_rdoc: