pwned 2.0.0 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.travis.yml +2 -4
- data/CHANGELOG.md +8 -1
- data/lib/pwned/not_pwned_validator.rb +3 -3
- data/lib/pwned/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b7e2d94dbe8ca81e5e0d8024cb614d2039a4b8cbd835a805131a9d98c8215327
|
4
|
+
data.tar.gz: 73d6a46ff19e904ba94590de3526709183e43956152d048352263c0b4a0246c3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9fc9f07b450fddcc3dff391640bbce98589de8779254d470413111d5198b50ace2c71264f7dd6f81c06caec4262a7be360bb5b6e2dd9699262be72fa0905726f
|
7
|
+
data.tar.gz: f03aec89ab299234ef7823097c4ffd943576019381249aaf097c38e74651ad5b4da1a66136320257729a9442b8a6c68a516b71fae3c2c12c9431ac56c90162c5
|
data/.travis.yml
CHANGED
@@ -10,10 +10,10 @@ env:
|
|
10
10
|
- RAILS_VERSION=6.0.0
|
11
11
|
|
12
12
|
rvm:
|
13
|
+
- 2.7
|
13
14
|
- 2.6
|
14
15
|
- 2.5
|
15
16
|
- 2.4
|
16
|
-
- 2.3
|
17
17
|
- jruby
|
18
18
|
- ruby-head
|
19
19
|
|
@@ -24,6 +24,4 @@ matrix:
|
|
24
24
|
- rvm: ruby-head
|
25
25
|
exclude:
|
26
26
|
- rvm: 2.4
|
27
|
-
env: RAILS_VERSION=6.0.0
|
28
|
-
- rvm: 2.3
|
29
|
-
env: RAILS_VERSION=6.0.0
|
27
|
+
env: RAILS_VERSION=6.0.0
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,13 @@
|
|
1
1
|
# Changelog for `Pwned`
|
2
2
|
|
3
|
-
## Ongoing [☰](https://github.com/philnash/pwned/compare/
|
3
|
+
## Ongoing [☰](https://github.com/philnash/pwned/compare/v2.0.1...master)
|
4
|
+
|
5
|
+
## 2.0.1 (January 14, 2019) [☰](https://github.com/philnash/pwned/compare/v2.0.0...v2.0.1)
|
6
|
+
|
7
|
+
- Minor updates
|
8
|
+
|
9
|
+
- Adds double-splat to ActiveModel::Errors#add calls with options to make Ruby 2.7 happy.
|
10
|
+
- Detects presence of Net::HTTPClientException in tests to remove deprecation warning.
|
4
11
|
|
5
12
|
## 2.0.0 (October 1, 2019) [☰](https://github.com/philnash/pwned/compare/v1.2.1...v2.0.0)
|
6
13
|
|
@@ -79,12 +79,12 @@ class NotPwnedValidator < ActiveModel::EachValidator
|
|
79
79
|
begin
|
80
80
|
pwned_check = Pwned::Password.new(value, request_options)
|
81
81
|
if pwned_check.pwned_count > threshold
|
82
|
-
record.errors.add(attribute, :not_pwned, options.merge(count: pwned_check.pwned_count))
|
82
|
+
record.errors.add(attribute, :not_pwned, **options.merge(count: pwned_check.pwned_count))
|
83
83
|
end
|
84
84
|
rescue Pwned::Error => error
|
85
85
|
case on_error
|
86
86
|
when :invalid
|
87
|
-
record.errors.add(attribute, :pwned_error, options.merge(message: options[:error_message]))
|
87
|
+
record.errors.add(attribute, :pwned_error, **options.merge(message: options[:error_message]))
|
88
88
|
when :valid
|
89
89
|
# Do nothing, consider the record valid
|
90
90
|
when Proc
|
@@ -129,4 +129,4 @@ end
|
|
129
129
|
#
|
130
130
|
# @since 1.1.0
|
131
131
|
class PwnedValidator < NotPwnedValidator
|
132
|
-
end
|
132
|
+
end
|
data/lib/pwned/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pwned
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Phil Nash
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-01-13 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -159,7 +159,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
159
159
|
version: '0'
|
160
160
|
requirements: []
|
161
161
|
rubyforge_project:
|
162
|
-
rubygems_version: 2.7.6
|
162
|
+
rubygems_version: 2.7.6
|
163
163
|
signing_key:
|
164
164
|
specification_version: 4
|
165
165
|
summary: Tools to use the Pwned Passwords API.
|