zxcvbn 0.1.11 → 0.1.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/lib/zxcvbn/version.rb +1 -1
- data/lib/zxcvbn.rb +13 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3abba874325220873de3e16bf2213afe1e51c468e6c5059ee793641563bbd123
|
4
|
+
data.tar.gz: e555337f55746d9fc2b2339797e287fb1a16c292d2d2b4aa54fdcfa0c7fbe370
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ec032e5e93416aef8ea9526cc4ff39e90a381228965c718f50f0311f900c8c1029d1ad13b7efd88f79c3fa890e5fd0b6c61d3252131430e7f19b383e55e62767
|
7
|
+
data.tar.gz: 5174f7aa4a0a65beefc790ea0f252abc749a203022b05d6b9ce33a6771599d6c41a33c2b341cda009eb0aad9d4d9df6da5b7cd308c2d3fb566657aafcecd0fab
|
data/CHANGELOG.md
CHANGED
data/lib/zxcvbn/version.rb
CHANGED
data/lib/zxcvbn.rb
CHANGED
@@ -10,6 +10,18 @@ require_relative "zxcvbn/version"
|
|
10
10
|
|
11
11
|
module Zxcvbn
|
12
12
|
class Error < StandardError; end
|
13
|
+
Result = Struct.new(
|
14
|
+
:password,
|
15
|
+
:guesses,
|
16
|
+
:guesses_log10,
|
17
|
+
:sequence,
|
18
|
+
:calc_time,
|
19
|
+
:crack_times_seconds,
|
20
|
+
:crack_times_display,
|
21
|
+
:score,
|
22
|
+
:feedback,
|
23
|
+
keyword_init: true
|
24
|
+
)
|
13
25
|
|
14
26
|
def self.zxcvbn(password, user_inputs = [])
|
15
27
|
start = (Time.now.to_f * 1000).to_i
|
@@ -25,7 +37,7 @@ module Zxcvbn
|
|
25
37
|
end
|
26
38
|
|
27
39
|
def self.test(password, user_inputs = [])
|
28
|
-
|
40
|
+
Result.new(Zxcvbn.zxcvbn(password, user_inputs))
|
29
41
|
end
|
30
42
|
|
31
43
|
class Tester
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: zxcvbn
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rafael Santos
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-10-29 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: 100% native Ruby 100% compatible port of Dropbox's zxcvbn.js
|
14
14
|
email:
|