devise_xfactor_authentication 2.2.18

Sign up to get free protection for your applications and to get access to all the features.
Files changed (94) hide show
  1. checksums.yaml +7 -0
  2. data/.codeclimate.yml +21 -0
  3. data/.gitignore +23 -0
  4. data/.rubocop.yml +295 -0
  5. data/.travis.yml +28 -0
  6. data/CHANGELOG.md +119 -0
  7. data/Gemfile +31 -0
  8. data/LICENSE +19 -0
  9. data/README.md +405 -0
  10. data/Rakefile +14 -0
  11. data/app/controllers/devise/devise_xfactor_authentication_controller.rb +84 -0
  12. data/app/views/devise/devise_xfactor_authentication/max_login_attempts_reached.html.erb +3 -0
  13. data/app/views/devise/devise_xfactor_authentication/show.html.erb +19 -0
  14. data/config/locales/de.yml +8 -0
  15. data/config/locales/en.yml +8 -0
  16. data/config/locales/es.yml +8 -0
  17. data/config/locales/fr.yml +8 -0
  18. data/config/locales/ru.yml +8 -0
  19. data/devise_xfactor_authentication.gemspec +39 -0
  20. data/lib/devise_xfactor_authentication/controllers/helpers.rb +49 -0
  21. data/lib/devise_xfactor_authentication/hooks/devise_xfactor_authenticatable.rb +17 -0
  22. data/lib/devise_xfactor_authentication/models/devise_xfactor_authenticatable.rb +203 -0
  23. data/lib/devise_xfactor_authentication/orm/active_record.rb +14 -0
  24. data/lib/devise_xfactor_authentication/rails.rb +7 -0
  25. data/lib/devise_xfactor_authentication/routes.rb +11 -0
  26. data/lib/devise_xfactor_authentication/schema.rb +31 -0
  27. data/lib/devise_xfactor_authentication/version.rb +3 -0
  28. data/lib/devise_xfactor_authentication.rb +52 -0
  29. data/lib/generators/active_record/devise_xfactor_authentication_generator.rb +14 -0
  30. data/lib/generators/active_record/templates/migration.rb +14 -0
  31. data/lib/generators/devise_xfactor_authentication/devise_xfactor_authentication_generator.rb +17 -0
  32. data/spec/controllers/devise_xfactor_authentication_controller_spec.rb +41 -0
  33. data/spec/features/devise_xfactor_authenticatable_spec.rb +237 -0
  34. data/spec/generators/active_record/devise_xfactor_authentication_generator_spec.rb +36 -0
  35. data/spec/lib/devise_xfactor_authentication/models/devise_xfactor_authenticatable_spec.rb +326 -0
  36. data/spec/rails_app/.gitignore +3 -0
  37. data/spec/rails_app/README.md +3 -0
  38. data/spec/rails_app/Rakefile +7 -0
  39. data/spec/rails_app/app/assets/javascripts/application.js +1 -0
  40. data/spec/rails_app/app/assets/stylesheets/application.css +4 -0
  41. data/spec/rails_app/app/controllers/application_controller.rb +3 -0
  42. data/spec/rails_app/app/controllers/home_controller.rb +10 -0
  43. data/spec/rails_app/app/helpers/application_helper.rb +8 -0
  44. data/spec/rails_app/app/mailers/.gitkeep +0 -0
  45. data/spec/rails_app/app/models/.gitkeep +0 -0
  46. data/spec/rails_app/app/models/admin.rb +6 -0
  47. data/spec/rails_app/app/models/encrypted_user.rb +15 -0
  48. data/spec/rails_app/app/models/guest_user.rb +17 -0
  49. data/spec/rails_app/app/models/user.rb +14 -0
  50. data/spec/rails_app/app/views/home/dashboard.html.erb +11 -0
  51. data/spec/rails_app/app/views/home/index.html.erb +3 -0
  52. data/spec/rails_app/app/views/layouts/application.html.erb +20 -0
  53. data/spec/rails_app/config/application.rb +63 -0
  54. data/spec/rails_app/config/boot.rb +10 -0
  55. data/spec/rails_app/config/database.yml +19 -0
  56. data/spec/rails_app/config/environment.rb +5 -0
  57. data/spec/rails_app/config/environments/development.rb +28 -0
  58. data/spec/rails_app/config/environments/production.rb +68 -0
  59. data/spec/rails_app/config/environments/test.rb +41 -0
  60. data/spec/rails_app/config/initializers/backtrace_silencers.rb +7 -0
  61. data/spec/rails_app/config/initializers/cookies_serializer.rb +3 -0
  62. data/spec/rails_app/config/initializers/devise.rb +258 -0
  63. data/spec/rails_app/config/initializers/inflections.rb +15 -0
  64. data/spec/rails_app/config/initializers/mime_types.rb +5 -0
  65. data/spec/rails_app/config/initializers/secret_token.rb +7 -0
  66. data/spec/rails_app/config/initializers/session_store.rb +8 -0
  67. data/spec/rails_app/config/initializers/wrap_parameters.rb +14 -0
  68. data/spec/rails_app/config/locales/devise.en.yml +59 -0
  69. data/spec/rails_app/config/locales/en.yml +5 -0
  70. data/spec/rails_app/config/routes.rb +65 -0
  71. data/spec/rails_app/config.ru +4 -0
  72. data/spec/rails_app/db/migrate/20140403184646_devise_create_users.rb +42 -0
  73. data/spec/rails_app/db/migrate/20140407172619_devise_xfactor_authentication_add_to_users.rb +15 -0
  74. data/spec/rails_app/db/migrate/20140407215513_add_nickanme_to_users.rb +7 -0
  75. data/spec/rails_app/db/migrate/20151224171231_add_encrypted_columns_to_user.rb +9 -0
  76. data/spec/rails_app/db/migrate/20151224180310_populate_otp_column.rb +19 -0
  77. data/spec/rails_app/db/migrate/20151228230340_remove_otp_secret_key_from_user.rb +5 -0
  78. data/spec/rails_app/db/migrate/20160209032439_devise_create_admins.rb +42 -0
  79. data/spec/rails_app/db/schema.rb +55 -0
  80. data/spec/rails_app/lib/assets/.gitkeep +0 -0
  81. data/spec/rails_app/lib/sms_provider.rb +17 -0
  82. data/spec/rails_app/public/404.html +26 -0
  83. data/spec/rails_app/public/422.html +26 -0
  84. data/spec/rails_app/public/500.html +25 -0
  85. data/spec/rails_app/public/favicon.ico +0 -0
  86. data/spec/rails_app/script/rails +6 -0
  87. data/spec/spec_helper.rb +26 -0
  88. data/spec/support/authenticated_model_helper.rb +59 -0
  89. data/spec/support/capybara.rb +3 -0
  90. data/spec/support/controller_helper.rb +16 -0
  91. data/spec/support/features_spec_helper.rb +42 -0
  92. data/spec/support/sms_provider.rb +5 -0
  93. data/spec/support/totp_helper.rb +11 -0
  94. metadata +293 -0
@@ -0,0 +1,55 @@
1
+ # This file is auto-generated from the current state of the database. Instead
2
+ # of editing this file, please use the migrations feature of Active Record to
3
+ # incrementally modify your database, and then regenerate this schema definition.
4
+ #
5
+ # Note that this schema.rb definition is the authoritative source for your
6
+ # database schema. If you need to create the application database on another
7
+ # system, you should be using db:schema:load, not running all the migrations
8
+ # from scratch. The latter is a flawed and unsustainable approach (the more migrations
9
+ # you'll amass, the slower it'll run and the greater likelihood for issues).
10
+ #
11
+ # It's strongly recommended that you check this file into your version control system.
12
+
13
+ ActiveRecord::Schema.define(version: 2016_02_09_032439) do
14
+
15
+ create_table "admins", force: :cascade do |t|
16
+ t.string "email", default: "", null: false
17
+ t.string "encrypted_password", default: "", null: false
18
+ t.string "reset_password_token"
19
+ t.datetime "reset_password_sent_at"
20
+ t.datetime "remember_created_at"
21
+ t.integer "sign_in_count", default: 0, null: false
22
+ t.datetime "current_sign_in_at"
23
+ t.datetime "last_sign_in_at"
24
+ t.string "current_sign_in_ip"
25
+ t.string "last_sign_in_ip"
26
+ t.datetime "created_at", null: false
27
+ t.datetime "updated_at", null: false
28
+ t.index ["email"], name: "index_admins_on_email", unique: true
29
+ t.index ["reset_password_token"], name: "index_admins_on_reset_password_token", unique: true
30
+ end
31
+
32
+ create_table "users", force: :cascade do |t|
33
+ t.string "email", default: "", null: false
34
+ t.string "encrypted_password", default: "", null: false
35
+ t.string "reset_password_token"
36
+ t.datetime "reset_password_sent_at"
37
+ t.datetime "remember_created_at"
38
+ t.integer "sign_in_count", default: 0, null: false
39
+ t.datetime "current_sign_in_at"
40
+ t.datetime "last_sign_in_at"
41
+ t.string "current_sign_in_ip"
42
+ t.string "last_sign_in_ip"
43
+ t.datetime "created_at", null: false
44
+ t.datetime "updated_at", null: false
45
+ t.integer "second_factor_attempts_count", default: 0
46
+ t.string "nickname", limit: 64
47
+ t.string "encrypted_otp_secret_key"
48
+ t.string "encrypted_otp_secret_key_iv"
49
+ t.string "encrypted_otp_secret_key_salt"
50
+ t.index ["email"], name: "index_users_on_email", unique: true
51
+ t.index ["encrypted_otp_secret_key"], name: "index_users_on_encrypted_otp_secret_key", unique: true
52
+ t.index ["reset_password_token"], name: "index_users_on_reset_password_token", unique: true
53
+ end
54
+
55
+ end
File without changes
@@ -0,0 +1,17 @@
1
+ require 'ostruct'
2
+
3
+ class SMSProvider
4
+ Message = Class.new(OpenStruct)
5
+
6
+ class_attribute :messages
7
+ self.messages = []
8
+
9
+ def self.send_message(opts = {})
10
+ self.messages << Message.new(opts)
11
+ end
12
+
13
+ def self.last_message
14
+ self.messages.last
15
+ end
16
+
17
+ end
@@ -0,0 +1,26 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>The page you were looking for doesn't exist (404)</title>
5
+ <style type="text/css">
6
+ body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
+ div.dialog {
8
+ width: 25em;
9
+ padding: 0 4em;
10
+ margin: 4em auto 0 auto;
11
+ border: 1px solid #ccc;
12
+ border-right-color: #999;
13
+ border-bottom-color: #999;
14
+ }
15
+ h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
+ </style>
17
+ </head>
18
+
19
+ <body>
20
+ <!-- This file lives in public/404.html -->
21
+ <div class="dialog">
22
+ <h1>The page you were looking for doesn't exist.</h1>
23
+ <p>You may have mistyped the address or the page may have moved.</p>
24
+ </div>
25
+ </body>
26
+ </html>
@@ -0,0 +1,26 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>The change you wanted was rejected (422)</title>
5
+ <style type="text/css">
6
+ body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
+ div.dialog {
8
+ width: 25em;
9
+ padding: 0 4em;
10
+ margin: 4em auto 0 auto;
11
+ border: 1px solid #ccc;
12
+ border-right-color: #999;
13
+ border-bottom-color: #999;
14
+ }
15
+ h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
+ </style>
17
+ </head>
18
+
19
+ <body>
20
+ <!-- This file lives in public/422.html -->
21
+ <div class="dialog">
22
+ <h1>The change you wanted was rejected.</h1>
23
+ <p>Maybe you tried to change something you didn't have access to.</p>
24
+ </div>
25
+ </body>
26
+ </html>
@@ -0,0 +1,25 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <title>We're sorry, but something went wrong (500)</title>
5
+ <style type="text/css">
6
+ body { background-color: #fff; color: #666; text-align: center; font-family: arial, sans-serif; }
7
+ div.dialog {
8
+ width: 25em;
9
+ padding: 0 4em;
10
+ margin: 4em auto 0 auto;
11
+ border: 1px solid #ccc;
12
+ border-right-color: #999;
13
+ border-bottom-color: #999;
14
+ }
15
+ h1 { font-size: 100%; color: #f00; line-height: 1.5em; }
16
+ </style>
17
+ </head>
18
+
19
+ <body>
20
+ <!-- This file lives in public/500.html -->
21
+ <div class="dialog">
22
+ <h1>We're sorry, but something went wrong.</h1>
23
+ </div>
24
+ </body>
25
+ </html>
File without changes
@@ -0,0 +1,6 @@
1
+ #!/usr/bin/env ruby
2
+ # This command will automatically be run when you run "rails" with Rails 3 gems installed from the root of your application.
3
+
4
+ APP_PATH = File.expand_path('../../config/application', __FILE__)
5
+ require File.expand_path('../../config/boot', __FILE__)
6
+ require 'rails/commands'
@@ -0,0 +1,26 @@
1
+ ENV["RAILS_ENV"] ||= "test"
2
+ require File.expand_path("../rails_app/config/environment.rb", __FILE__)
3
+
4
+ require 'rspec/rails'
5
+ require 'timecop'
6
+ require 'rack_session_access/capybara'
7
+
8
+ # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
9
+ RSpec.configure do |config|
10
+ config.run_all_when_everything_filtered = true
11
+ config.filter_run :focus
12
+
13
+ config.use_transactional_examples = true
14
+
15
+ config.include Capybara::DSL
16
+
17
+ # Run specs in random order to surface order dependencies. If you find an
18
+ # order dependency and want to debug it, you can fix the order by providing
19
+ # the seed, which is printed after each run.
20
+ # --seed 1234
21
+ config.order = 'random'
22
+
23
+ config.after(:each) { Timecop.return }
24
+ end
25
+
26
+ Dir["#{Dir.pwd}/spec/support/**/*.rb"].each {|f| require f}
@@ -0,0 +1,59 @@
1
+ module AuthenticatedModelHelper
2
+ def build_guest_user
3
+ GuestUser.new
4
+ end
5
+
6
+ def create_user(type = 'encrypted', attributes = {})
7
+ create_table_for_nonencrypted_user if type == 'not_encrypted'
8
+
9
+ User.create!(valid_attributes(attributes))
10
+ end
11
+
12
+ def create_admin
13
+ Admin.create!(valid_attributes.except(:nickname))
14
+ end
15
+
16
+ def valid_attributes(attributes={})
17
+ {
18
+ nickname: 'Marissa',
19
+ email: generate_unique_email,
20
+ password: 'password',
21
+ password_confirmation: 'password'
22
+ }.merge(attributes)
23
+ end
24
+
25
+ def generate_unique_email
26
+ @@email_count ||= 0
27
+ @@email_count += 1
28
+ "user#{@@email_count}@example.com"
29
+ end
30
+
31
+ def create_table_for_nonencrypted_user
32
+ ActiveRecord::Migration.suppress_messages do
33
+ ActiveRecord::Schema.define(version: 1) do
34
+ create_table 'users', force: :cascade do |t|
35
+ t.string 'email', default: '', null: false
36
+ t.string 'encrypted_password', default: '', null: false
37
+ t.string 'reset_password_token'
38
+ t.datetime 'reset_password_sent_at'
39
+ t.datetime 'remember_created_at'
40
+ t.integer 'sign_in_count', default: 0, null: false
41
+ t.datetime 'current_sign_in_at'
42
+ t.datetime 'last_sign_in_at'
43
+ t.string 'current_sign_in_ip'
44
+ t.string 'last_sign_in_ip'
45
+ t.datetime 'created_at', null: false
46
+ t.datetime 'updated_at', null: false
47
+ t.integer 'second_factor_attempts_count', default: 0
48
+ t.string 'nickname', limit: 64
49
+ t.string 'otp_secret_key'
50
+ t.string 'direct_otp'
51
+ t.datetime 'direct_otp_sent_at'
52
+ t.timestamp 'totp_timestamp'
53
+ end
54
+ end
55
+ end
56
+ end
57
+ end
58
+
59
+ RSpec.configuration.send(:include, AuthenticatedModelHelper)
@@ -0,0 +1,3 @@
1
+ require 'capybara/rspec'
2
+
3
+ Capybara.app = Dummy::Application
@@ -0,0 +1,16 @@
1
+ module ControllerHelper
2
+ def sign_in(user = create_user('not_encrypted'))
3
+ allow(warden).to receive(:authenticated?).with(:user).and_return(true)
4
+ allow(controller).to receive(:current_user).and_return(user)
5
+ warden.session(:user)[DeviseXfactorAuthentication::NEED_AUTHENTICATION] = true
6
+ end
7
+ end
8
+
9
+ RSpec.configure do |config|
10
+ config.include Devise::Test::ControllerHelpers, type: :controller
11
+ config.include ControllerHelper, type: :controller
12
+
13
+ config.before(:example, type: :controller) do
14
+ @request.env['devise.mapping'] = Devise.mappings[:user]
15
+ end
16
+ end
@@ -0,0 +1,42 @@
1
+ require 'warden'
2
+
3
+ module FeaturesSpecHelper
4
+ def warden
5
+ request.env['warden']
6
+ end
7
+
8
+ def complete_sign_in_form_for(user)
9
+ fill_in "Email", with: user.email
10
+ fill_in "Password", with: 'password'
11
+ find('.actions input').click # 'Sign in' or 'Log in'
12
+ end
13
+
14
+ def set_cookie key, value
15
+ page.driver.browser.set_cookie [key, value].join('=')
16
+ end
17
+
18
+ def get_cookie key
19
+ Capybara.current_session.driver.request.cookies[key]
20
+ end
21
+
22
+ def set_tfa_cookie value
23
+ set_cookie DeviseXfactorAuthentication::REMEMBER_TFA_COOKIE_NAME, value
24
+ end
25
+
26
+ def get_tfa_cookie
27
+ get_cookie DeviseXfactorAuthentication::REMEMBER_TFA_COOKIE_NAME
28
+ end
29
+ end
30
+
31
+ RSpec.configure do |config|
32
+ config.include Warden::Test::Helpers, type: :feature
33
+ config.include FeaturesSpecHelper, type: :feature
34
+
35
+ config.before(:each) do
36
+ Warden.test_mode!
37
+ end
38
+
39
+ config.after(:each) do
40
+ Warden.test_reset!
41
+ end
42
+ end
@@ -0,0 +1,5 @@
1
+ RSpec.configure do |c|
2
+ c.before(:each) do
3
+ SMSProvider.messages.clear
4
+ end
5
+ end
@@ -0,0 +1,11 @@
1
+ # Helper class to simulate a user generating TOTP codes from a secret key
2
+ class TotpHelper
3
+ def initialize(secret_key, otp_length)
4
+ @secret_key = secret_key
5
+ @otp_length = otp_length
6
+ end
7
+
8
+ def totp_code(time = Time.now)
9
+ ROTP::TOTP.new(@secret_key, digits: @otp_length).at(time)
10
+ end
11
+ end
metadata ADDED
@@ -0,0 +1,293 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: devise_xfactor_authentication
3
+ version: !ruby/object:Gem::Version
4
+ version: 2.2.18
5
+ platform: ruby
6
+ authors:
7
+ - Jonathon Pickett
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2022-11-08 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: rails
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '5.0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '5.0'
27
+ - !ruby/object:Gem::Dependency
28
+ name: devise
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: '4'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: '4'
41
+ - !ruby/object:Gem::Dependency
42
+ name: randexp
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: '0.1'
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0.1'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rotp
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - ">="
60
+ - !ruby/object:Gem::Version
61
+ version: 6.0.0
62
+ type: :runtime
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - ">="
67
+ - !ruby/object:Gem::Version
68
+ version: 6.0.0
69
+ - !ruby/object:Gem::Dependency
70
+ name: encryptor
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - ">="
74
+ - !ruby/object:Gem::Version
75
+ version: 3.0.0
76
+ type: :runtime
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - ">="
81
+ - !ruby/object:Gem::Version
82
+ version: 3.0.0
83
+ - !ruby/object:Gem::Dependency
84
+ name: bundler
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - ">="
88
+ - !ruby/object:Gem::Version
89
+ version: '2'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ version: '2'
97
+ - !ruby/object:Gem::Dependency
98
+ name: rake
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: '13'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - ">="
109
+ - !ruby/object:Gem::Version
110
+ version: '13'
111
+ - !ruby/object:Gem::Dependency
112
+ name: rspec-rails
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ">="
116
+ - !ruby/object:Gem::Version
117
+ version: '6.0'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '6.0'
125
+ - !ruby/object:Gem::Dependency
126
+ name: capybara
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ">="
130
+ - !ruby/object:Gem::Version
131
+ version: '3'
132
+ type: :development
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ">="
137
+ - !ruby/object:Gem::Version
138
+ version: '3'
139
+ - !ruby/object:Gem::Dependency
140
+ name: pry
141
+ requirement: !ruby/object:Gem::Requirement
142
+ requirements:
143
+ - - ">="
144
+ - !ruby/object:Gem::Version
145
+ version: '0.14'
146
+ type: :development
147
+ prerelease: false
148
+ version_requirements: !ruby/object:Gem::Requirement
149
+ requirements:
150
+ - - ">="
151
+ - !ruby/object:Gem::Version
152
+ version: '0.14'
153
+ - !ruby/object:Gem::Dependency
154
+ name: timecop
155
+ requirement: !ruby/object:Gem::Requirement
156
+ requirements:
157
+ - - ">="
158
+ - !ruby/object:Gem::Version
159
+ version: '0.9'
160
+ type: :development
161
+ prerelease: false
162
+ version_requirements: !ruby/object:Gem::Requirement
163
+ requirements:
164
+ - - ">="
165
+ - !ruby/object:Gem::Version
166
+ version: '0.9'
167
+ description: |2
168
+ ### Features ###
169
+ * control sms code pattern
170
+ * configure max login attempts
171
+ * per user level control if he really need two factor authentication
172
+ * your own sms logic
173
+ email:
174
+ - jpickett76@gmail.com
175
+ executables: []
176
+ extensions: []
177
+ extra_rdoc_files: []
178
+ files:
179
+ - ".codeclimate.yml"
180
+ - ".gitignore"
181
+ - ".rubocop.yml"
182
+ - ".travis.yml"
183
+ - CHANGELOG.md
184
+ - Gemfile
185
+ - LICENSE
186
+ - README.md
187
+ - Rakefile
188
+ - app/controllers/devise/devise_xfactor_authentication_controller.rb
189
+ - app/views/devise/devise_xfactor_authentication/max_login_attempts_reached.html.erb
190
+ - app/views/devise/devise_xfactor_authentication/show.html.erb
191
+ - config/locales/de.yml
192
+ - config/locales/en.yml
193
+ - config/locales/es.yml
194
+ - config/locales/fr.yml
195
+ - config/locales/ru.yml
196
+ - devise_xfactor_authentication.gemspec
197
+ - lib/devise_xfactor_authentication.rb
198
+ - lib/devise_xfactor_authentication/controllers/helpers.rb
199
+ - lib/devise_xfactor_authentication/hooks/devise_xfactor_authenticatable.rb
200
+ - lib/devise_xfactor_authentication/models/devise_xfactor_authenticatable.rb
201
+ - lib/devise_xfactor_authentication/orm/active_record.rb
202
+ - lib/devise_xfactor_authentication/rails.rb
203
+ - lib/devise_xfactor_authentication/routes.rb
204
+ - lib/devise_xfactor_authentication/schema.rb
205
+ - lib/devise_xfactor_authentication/version.rb
206
+ - lib/generators/active_record/devise_xfactor_authentication_generator.rb
207
+ - lib/generators/active_record/templates/migration.rb
208
+ - lib/generators/devise_xfactor_authentication/devise_xfactor_authentication_generator.rb
209
+ - spec/controllers/devise_xfactor_authentication_controller_spec.rb
210
+ - spec/features/devise_xfactor_authenticatable_spec.rb
211
+ - spec/generators/active_record/devise_xfactor_authentication_generator_spec.rb
212
+ - spec/lib/devise_xfactor_authentication/models/devise_xfactor_authenticatable_spec.rb
213
+ - spec/rails_app/.gitignore
214
+ - spec/rails_app/README.md
215
+ - spec/rails_app/Rakefile
216
+ - spec/rails_app/app/assets/javascripts/application.js
217
+ - spec/rails_app/app/assets/stylesheets/application.css
218
+ - spec/rails_app/app/controllers/application_controller.rb
219
+ - spec/rails_app/app/controllers/home_controller.rb
220
+ - spec/rails_app/app/helpers/application_helper.rb
221
+ - spec/rails_app/app/mailers/.gitkeep
222
+ - spec/rails_app/app/models/.gitkeep
223
+ - spec/rails_app/app/models/admin.rb
224
+ - spec/rails_app/app/models/encrypted_user.rb
225
+ - spec/rails_app/app/models/guest_user.rb
226
+ - spec/rails_app/app/models/user.rb
227
+ - spec/rails_app/app/views/home/dashboard.html.erb
228
+ - spec/rails_app/app/views/home/index.html.erb
229
+ - spec/rails_app/app/views/layouts/application.html.erb
230
+ - spec/rails_app/config.ru
231
+ - spec/rails_app/config/application.rb
232
+ - spec/rails_app/config/boot.rb
233
+ - spec/rails_app/config/database.yml
234
+ - spec/rails_app/config/environment.rb
235
+ - spec/rails_app/config/environments/development.rb
236
+ - spec/rails_app/config/environments/production.rb
237
+ - spec/rails_app/config/environments/test.rb
238
+ - spec/rails_app/config/initializers/backtrace_silencers.rb
239
+ - spec/rails_app/config/initializers/cookies_serializer.rb
240
+ - spec/rails_app/config/initializers/devise.rb
241
+ - spec/rails_app/config/initializers/inflections.rb
242
+ - spec/rails_app/config/initializers/mime_types.rb
243
+ - spec/rails_app/config/initializers/secret_token.rb
244
+ - spec/rails_app/config/initializers/session_store.rb
245
+ - spec/rails_app/config/initializers/wrap_parameters.rb
246
+ - spec/rails_app/config/locales/devise.en.yml
247
+ - spec/rails_app/config/locales/en.yml
248
+ - spec/rails_app/config/routes.rb
249
+ - spec/rails_app/db/migrate/20140403184646_devise_create_users.rb
250
+ - spec/rails_app/db/migrate/20140407172619_devise_xfactor_authentication_add_to_users.rb
251
+ - spec/rails_app/db/migrate/20140407215513_add_nickanme_to_users.rb
252
+ - spec/rails_app/db/migrate/20151224171231_add_encrypted_columns_to_user.rb
253
+ - spec/rails_app/db/migrate/20151224180310_populate_otp_column.rb
254
+ - spec/rails_app/db/migrate/20151228230340_remove_otp_secret_key_from_user.rb
255
+ - spec/rails_app/db/migrate/20160209032439_devise_create_admins.rb
256
+ - spec/rails_app/db/schema.rb
257
+ - spec/rails_app/lib/assets/.gitkeep
258
+ - spec/rails_app/lib/sms_provider.rb
259
+ - spec/rails_app/public/404.html
260
+ - spec/rails_app/public/422.html
261
+ - spec/rails_app/public/500.html
262
+ - spec/rails_app/public/favicon.ico
263
+ - spec/rails_app/script/rails
264
+ - spec/spec_helper.rb
265
+ - spec/support/authenticated_model_helper.rb
266
+ - spec/support/capybara.rb
267
+ - spec/support/controller_helper.rb
268
+ - spec/support/features_spec_helper.rb
269
+ - spec/support/sms_provider.rb
270
+ - spec/support/totp_helper.rb
271
+ homepage: https://github.com/jpickett76/devise_xfactor_authentication
272
+ licenses: []
273
+ metadata: {}
274
+ post_install_message:
275
+ rdoc_options: []
276
+ require_paths:
277
+ - lib
278
+ required_ruby_version: !ruby/object:Gem::Requirement
279
+ requirements:
280
+ - - ">="
281
+ - !ruby/object:Gem::Version
282
+ version: '0'
283
+ required_rubygems_version: !ruby/object:Gem::Requirement
284
+ requirements:
285
+ - - ">="
286
+ - !ruby/object:Gem::Version
287
+ version: '0'
288
+ requirements: []
289
+ rubygems_version: 3.0.3
290
+ signing_key:
291
+ specification_version: 4
292
+ summary: Two factor authentication plugin for devise forked from Houdini/two_factor_authentication
293
+ test_files: []