zxcvbn 0.1.10 → 0.1.11
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/CHANGELOG.md +6 -0
 - data/lib/zxcvbn/frequency_lists/english_wikipedia.txt +30000 -0
 - data/lib/zxcvbn/frequency_lists/female_names.txt +3712 -0
 - data/lib/zxcvbn/frequency_lists/male_names.txt +983 -0
 - data/lib/zxcvbn/frequency_lists/passwords.txt +30000 -0
 - data/lib/zxcvbn/frequency_lists/surnames.txt +10000 -0
 - data/lib/zxcvbn/frequency_lists/us_tv_and_film.txt +19160 -0
 - data/lib/zxcvbn/frequency_lists.rb +17 -9
 - data/lib/zxcvbn/matching.rb +1 -1
 - data/lib/zxcvbn/scoring.rb +1 -1
 - data/lib/zxcvbn/version.rb +1 -1
 - metadata +9 -3
 
    
        data/lib/zxcvbn/matching.rb
    CHANGED
    
    
    
        data/lib/zxcvbn/scoring.rb
    CHANGED
    
    | 
         @@ -6,7 +6,7 @@ module Zxcvbn 
     | 
|
| 
       6 
6 
     | 
    
         
             
                # this calculates the average over all keys.
         
     | 
| 
       7 
7 
     | 
    
         
             
                def self.calc_average_degree(graph)
         
     | 
| 
       8 
8 
     | 
    
         
             
                  average = 0
         
     | 
| 
       9 
     | 
    
         
            -
                  graph. 
     | 
| 
      
 9 
     | 
    
         
            +
                  graph.each_value do |neighbors|
         
     | 
| 
       10 
10 
     | 
    
         
             
                    average += neighbors.count { |n| n }.to_f
         
     | 
| 
       11 
11 
     | 
    
         
             
                  end
         
     | 
| 
       12 
12 
     | 
    
         
             
                  average /= graph.keys.size.to_f
         
     | 
    
        data/lib/zxcvbn/version.rb
    CHANGED
    
    
    
        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.11
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
7 
     | 
    
         
             
            - Rafael Santos
         
     | 
| 
       8 
8 
     | 
    
         
             
            autorequire:
         
     | 
| 
       9 
9 
     | 
    
         
             
            bindir: exe
         
     | 
| 
       10 
10 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
     | 
    
         
            -
            date:  
     | 
| 
      
 11 
     | 
    
         
            +
            date: 2024-08-25 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:
         
     | 
| 
         @@ -24,6 +24,12 @@ files: 
     | 
|
| 
       24 
24 
     | 
    
         
             
            - lib/zxcvbn/adjacency_graphs.rb
         
     | 
| 
       25 
25 
     | 
    
         
             
            - lib/zxcvbn/feedback.rb
         
     | 
| 
       26 
26 
     | 
    
         
             
            - lib/zxcvbn/frequency_lists.rb
         
     | 
| 
      
 27 
     | 
    
         
            +
            - lib/zxcvbn/frequency_lists/english_wikipedia.txt
         
     | 
| 
      
 28 
     | 
    
         
            +
            - lib/zxcvbn/frequency_lists/female_names.txt
         
     | 
| 
      
 29 
     | 
    
         
            +
            - lib/zxcvbn/frequency_lists/male_names.txt
         
     | 
| 
      
 30 
     | 
    
         
            +
            - lib/zxcvbn/frequency_lists/passwords.txt
         
     | 
| 
      
 31 
     | 
    
         
            +
            - lib/zxcvbn/frequency_lists/surnames.txt
         
     | 
| 
      
 32 
     | 
    
         
            +
            - lib/zxcvbn/frequency_lists/us_tv_and_film.txt
         
     | 
| 
       27 
33 
     | 
    
         
             
            - lib/zxcvbn/matching.rb
         
     | 
| 
       28 
34 
     | 
    
         
             
            - lib/zxcvbn/scoring.rb
         
     | 
| 
       29 
35 
     | 
    
         
             
            - lib/zxcvbn/time_estimates.rb
         
     | 
| 
         @@ -52,7 +58,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement 
     | 
|
| 
       52 
58 
     | 
    
         
             
                - !ruby/object:Gem::Version
         
     | 
| 
       53 
59 
     | 
    
         
             
                  version: '0'
         
     | 
| 
       54 
60 
     | 
    
         
             
            requirements: []
         
     | 
| 
       55 
     | 
    
         
            -
            rubygems_version: 3. 
     | 
| 
      
 61 
     | 
    
         
            +
            rubygems_version: 3.5.11
         
     | 
| 
       56 
62 
     | 
    
         
             
            signing_key:
         
     | 
| 
       57 
63 
     | 
    
         
             
            specification_version: 4
         
     | 
| 
       58 
64 
     | 
    
         
             
            summary: ''
         
     |