recog 1.0.15 → 1.0.16
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +1 -1
- data/README.md +3 -3
- data/bin/{recog_export.rb → recog_export} +0 -0
- data/bin/{recog_match.rb → recog_match} +0 -0
- data/bin/{recog_verify.rb → recog_verify} +0 -0
- data/features/match.feature +4 -4
- data/features/verify.feature +4 -4
- data/lib/recog/version.rb +1 -1
- metadata +8 -8
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5967636c56e64027e73963a64574380b85c6af88
|
4
|
+
data.tar.gz: a06812e81e6c16b3fc8237d50040ad61d27a7adf
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f9a3360742a7156517f2069c5e7dc12223504c0cfd935db0fde50fbe2ec5f5ce2a6c4c968f26b3b34276ee707835f53461c2e04fb0468b77d49d360ce8dc8fd6
|
7
|
+
data.tar.gz: 5e0677ff0170f1c4fbac6a0a9a9d2513f5332a652a6bec2f21fbd92a3ca8ec803c585d3415d64cd59124065655516fd04e832728e8d4869e691a17e0faa567a1
|
data/.travis.yml
CHANGED
data/README.md
CHANGED
@@ -48,13 +48,13 @@ The <example/> element should contain a successful match for the fingerprint's `
|
|
48
48
|
|
49
49
|
the <param/> elements contain a `pos` attribute, which indicates what capture field from the `pattern` should be extracted, or `0` for a static string. The `name` attribute is the key that will be reported in the case of a successful match and the `value` will either be a static string for `pos` values of `0` or missing and taken from the captured field.
|
50
50
|
|
51
|
-
Once a fingerprint has been added, the <examples/> entries can be tested by executing `bin/recog_verify
|
51
|
+
Once a fingerprint has been added, the <examples/> entries can be tested by executing `bin/recog_verify` against the fingerprint file:
|
52
52
|
|
53
|
-
$ bin/recog_verify
|
53
|
+
$ bin/recog_verify xml/ssh_banners.xml
|
54
54
|
|
55
55
|
Matches can be tested on the command-line in a similar fashion:
|
56
56
|
|
57
|
-
$ echo 'OpenSSH_6.6p1 Ubuntu-2ubuntu1' | bin/recog_match
|
57
|
+
$ echo 'OpenSSH_6.6p1 Ubuntu-2ubuntu1' | bin/recog_match xml/ssh_banners.xml -
|
58
58
|
MATCH: {"service.version"=>"6.6p1", "openssh.comment"=>"Ubuntu-2ubuntu1", "service.vendor"=>"OpenBSD", "service.family"=>"OpenSSH", "service.product"=>"OpenSSH", "data"=>"OpenSSH_6.6p1 Ubuntu-2ubuntu1"}
|
59
59
|
|
60
60
|
|
File without changes
|
File without changes
|
File without changes
|
data/features/match.feature
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
Feature: Match
|
2
2
|
Scenario: Finds matches
|
3
|
-
When I run `recog_match
|
3
|
+
When I run `recog_match matching_banners_fingerprints.xml banners.xml`
|
4
4
|
Then it should pass with:
|
5
5
|
"""
|
6
|
-
MATCH: {"pureftpd.config"=>"[privsep] [TLS] ", "service.family"=>"Pure-FTPd", "service.product"=>"Pure-FTPd", "data"=>"---------- Welcome to Pure-FTPd [privsep] [TLS] ----------"}
|
7
|
-
MATCH: {"os.vendor"=>"Sun", "os.family"=>"Solaris", "os.product"=>"Solaris", "os.device"=>"General", "host.name"=>"polaris", "os.version"=>"5.8", "data"=>"polaris FTP server (SunOS 5.8) ready."}
|
6
|
+
MATCH: {"matched"=>"Pure-FTPd Config data can be zero or more of: [privsep] [TLS]", "pureftpd.config"=>"[privsep] [TLS] ", "service.family"=>"Pure-FTPd", "service.product"=>"Pure-FTPd", "data"=>"---------- Welcome to Pure-FTPd [privsep] [TLS] ----------"}
|
7
|
+
MATCH: {"matched"=>"SunOS/Solaris", "os.vendor"=>"Sun", "os.family"=>"Solaris", "os.product"=>"Solaris", "os.device"=>"General", "host.name"=>"polaris", "os.version"=>"5.8", "data"=>"polaris FTP server (SunOS 5.8) ready."}
|
8
8
|
"""
|
9
9
|
|
10
10
|
Scenario: Fails at finding matches
|
11
|
-
When I run `recog_match
|
11
|
+
When I run `recog_match failing_banners_fingerprints.xml banners.xml`
|
12
12
|
Then it should pass with:
|
13
13
|
"""
|
14
14
|
FAIL: ---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
|
data/features/verify.feature
CHANGED
@@ -1,20 +1,20 @@
|
|
1
1
|
Feature: Verify
|
2
2
|
Scenario: No tests
|
3
|
-
When I run `recog_verify
|
3
|
+
When I run `recog_verify no_tests.xml`
|
4
4
|
Then it should pass with:
|
5
5
|
"""
|
6
6
|
SUMMARY: Test completed with 0 successful, 0 warnings, and 0 failures
|
7
7
|
"""
|
8
8
|
|
9
9
|
Scenario: Successful tests
|
10
|
-
When I run `recog_verify
|
10
|
+
When I run `recog_verify successful_tests.xml`
|
11
11
|
Then it should pass with:
|
12
12
|
"""
|
13
13
|
SUMMARY: Test completed with 4 successful, 0 warnings, and 0 failures
|
14
14
|
"""
|
15
15
|
|
16
16
|
Scenario: Tests with warnings
|
17
|
-
When I run `recog_verify
|
17
|
+
When I run `recog_verify tests_with_warnings.xml`
|
18
18
|
Then it should pass with:
|
19
19
|
"""
|
20
20
|
WARN: 'Pure-FTPd' has no test cases
|
@@ -22,7 +22,7 @@ Feature: Verify
|
|
22
22
|
"""
|
23
23
|
|
24
24
|
Scenario: Tests with failures
|
25
|
-
When I run `recog_verify
|
25
|
+
When I run `recog_verify tests_with_failures.xml`
|
26
26
|
Then it should pass with:
|
27
27
|
"""
|
28
28
|
FAIL: 'foo test' failed to match "bar" with (?-mix:^foo$)'
|
data/lib/recog/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: recog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.16
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rapid7 Research
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-02-
|
11
|
+
date: 2015-02-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|
@@ -115,9 +115,9 @@ description: Recog is a framework for identifying products, services, operating
|
|
115
115
|
email:
|
116
116
|
- research@rapid7.com
|
117
117
|
executables:
|
118
|
-
- recog_export
|
119
|
-
- recog_match
|
120
|
-
- recog_verify
|
118
|
+
- recog_export
|
119
|
+
- recog_match
|
120
|
+
- recog_verify
|
121
121
|
extensions: []
|
122
122
|
extra_rdoc_files: []
|
123
123
|
files:
|
@@ -130,9 +130,9 @@ files:
|
|
130
130
|
- LICENSE
|
131
131
|
- README.md
|
132
132
|
- Rakefile
|
133
|
-
- bin/recog_export
|
134
|
-
- bin/recog_match
|
135
|
-
- bin/recog_verify
|
133
|
+
- bin/recog_export
|
134
|
+
- bin/recog_match
|
135
|
+
- bin/recog_verify
|
136
136
|
- features/match.feature
|
137
137
|
- features/support/env.rb
|
138
138
|
- features/verify.feature
|