metasploit_data_models 4.0.0 → 4.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/app/models/mdm/api_key.rb +1 -1
- data/app/validators/ip_format_validator.rb +1 -1
- data/app/validators/parameters_validator.rb +7 -7
- data/lib/metasploit_data_models/version.rb +1 -1
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5b39228ee81c302b3a79adb5b6b7fd283609315ba4e6ba3ce54fc118975d6169
|
4
|
+
data.tar.gz: 43d50e8c9c3dd6adcb4944539f45c7cae200b2d6341b4ab37ebbe1aff19583f6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 91e81439cde4eecd56be639a8349554ec16b950f3affd58a13024ec39a55756c49f8e36683f2fea36409cb8bf27eedd44f45b67d9788c2b7dde3455292c53435
|
7
|
+
data.tar.gz: 9b6e4a077c247d81d1fa24d63e4beb212a91b711ee762e52241b673b77045b08cf0b5e77249df08e73f33ca405e9e3838809ffde2734c53f6bac6a33d0f55887
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/app/models/mdm/api_key.rb
CHANGED
@@ -53,7 +53,7 @@ class Mdm::ApiKey < ApplicationRecord
|
|
53
53
|
license = License.get
|
54
54
|
|
55
55
|
if license and not license.supports_api?
|
56
|
-
errors
|
56
|
+
errors.add :license, " - this product does not support API access"
|
57
57
|
end
|
58
58
|
end
|
59
59
|
|
@@ -6,7 +6,7 @@ class IpFormatValidator < ActiveModel::EachValidator
|
|
6
6
|
#
|
7
7
|
# @return [void]
|
8
8
|
def validate_each(object, attribute, value)
|
9
|
-
error_message_block = lambda{ object.errors
|
9
|
+
error_message_block = lambda{ object.errors.add attribute, " must be a valid IPv4 or IPv6 address" }
|
10
10
|
begin
|
11
11
|
if value.is_a? IPAddr
|
12
12
|
potential_ip = value.dup
|
@@ -33,7 +33,7 @@ class ParametersValidator < ActiveModel::EachValidator
|
|
33
33
|
:index => index
|
34
34
|
)
|
35
35
|
|
36
|
-
record.errors
|
36
|
+
record.errors.add attribute, length_error
|
37
37
|
else
|
38
38
|
parameter_name = element.first
|
39
39
|
|
@@ -44,7 +44,7 @@ class ParametersValidator < ActiveModel::EachValidator
|
|
44
44
|
:index => index,
|
45
45
|
:prefix => "has blank parameter name"
|
46
46
|
)
|
47
|
-
record.errors
|
47
|
+
record.errors.add attribute, error
|
48
48
|
end
|
49
49
|
else
|
50
50
|
error = error_at(
|
@@ -52,7 +52,7 @@ class ParametersValidator < ActiveModel::EachValidator
|
|
52
52
|
:index => index,
|
53
53
|
:prefix => "has non-String parameter name (#{parameter_name.inspect})"
|
54
54
|
)
|
55
|
-
record.errors
|
55
|
+
record.errors.add attribute, error
|
56
56
|
end
|
57
57
|
|
58
58
|
parameter_value = element.second
|
@@ -63,7 +63,7 @@ class ParametersValidator < ActiveModel::EachValidator
|
|
63
63
|
:index => index,
|
64
64
|
:prefix => "has non-String parameter value (#{parameter_value.inspect})"
|
65
65
|
)
|
66
|
-
record.errors
|
66
|
+
record.errors.add attribute, error
|
67
67
|
end
|
68
68
|
end
|
69
69
|
else
|
@@ -72,11 +72,11 @@ class ParametersValidator < ActiveModel::EachValidator
|
|
72
72
|
:index => index,
|
73
73
|
:prefix => 'has non-Array'
|
74
74
|
)
|
75
|
-
record.errors
|
75
|
+
record.errors.add attribute, error
|
76
76
|
end
|
77
77
|
end
|
78
78
|
else
|
79
|
-
record.errors
|
79
|
+
record.errors.add attribute, "is not an Array. #{TYPE_SIGNATURE_SENTENCE}"
|
80
80
|
end
|
81
81
|
end
|
82
82
|
|
@@ -126,4 +126,4 @@ class ParametersValidator < ActiveModel::EachValidator
|
|
126
126
|
|
127
127
|
clause
|
128
128
|
end
|
129
|
-
end
|
129
|
+
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metasploit_data_models
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.0.
|
4
|
+
version: 4.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Samuel Huckins
|
@@ -96,7 +96,7 @@ cert_chain:
|
|
96
96
|
JI/W23RbIRksG2pioMhd4dCXq3FLLlkOV1YfCwWixNB+iIhQPPZVaPNfgPhCn4Dt
|
97
97
|
DeGjje/qA4fkLtRmOtb9PUBq3ToRDE4=
|
98
98
|
-----END CERTIFICATE-----
|
99
|
-
date: 2020-
|
99
|
+
date: 2020-04-14 00:00:00.000000000 Z
|
100
100
|
dependencies:
|
101
101
|
- !ruby/object:Gem::Dependency
|
102
102
|
name: metasploit-yard
|
metadata.gz.sig
CHANGED
Binary file
|