two_factor_auth 0.1.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.
Files changed (103) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +634 -0
  3. data/Rakefile +34 -0
  4. data/app/assets/javascripts/two_factor_auth/application.js +13 -0
  5. data/app/assets/stylesheets/two_factor_auth/application.css +15 -0
  6. data/app/controllers/two_factor_auth/authentications_controller.rb +32 -0
  7. data/app/controllers/two_factor_auth/registrations_controller.rb +29 -0
  8. data/app/controllers/two_factor_auth/trusted_facets_controller.rb +10 -0
  9. data/app/controllers/two_factor_auth/two_factor_auth_controller.rb +19 -0
  10. data/app/helpers/two_factor_auth/application_helper.rb +21 -0
  11. data/app/helpers/two_factor_auth/authentications_helper.rb +17 -0
  12. data/app/helpers/two_factor_auth/registrations_helper.rb +17 -0
  13. data/app/models/two_factor_auth/authentication_client_data.rb +11 -0
  14. data/app/models/two_factor_auth/authentication_request.rb +30 -0
  15. data/app/models/two_factor_auth/authentication_response.rb +49 -0
  16. data/app/models/two_factor_auth/authentication_verifier.rb +68 -0
  17. data/app/models/two_factor_auth/client_data.rb +57 -0
  18. data/app/models/two_factor_auth/registration.rb +18 -0
  19. data/app/models/two_factor_auth/registration_request.rb +33 -0
  20. data/app/models/two_factor_auth/registration_response.rb +91 -0
  21. data/app/models/two_factor_auth/registration_verifier.rb +91 -0
  22. data/app/views/layouts/two_factor_auth/application.html.erb +16 -0
  23. data/app/views/two_factor_auth/authentications/new.html.erb +30 -0
  24. data/app/views/two_factor_auth/registrations/new.html.erb +26 -0
  25. data/config/routes.rb +3 -0
  26. data/lib/generators/templates/README +6 -0
  27. data/lib/generators/templates/initializer.rb +38 -0
  28. data/lib/generators/templates/migration.rb +15 -0
  29. data/lib/generators/two_factor_auth/install_generator.rb +32 -0
  30. data/lib/tasks/two_factor_auth_tasks.rake +13 -0
  31. data/lib/two_factor_auth/authentication_hook.rb +18 -0
  32. data/lib/two_factor_auth/engine.rb +5 -0
  33. data/lib/two_factor_auth/registration_hook.rb +17 -0
  34. data/lib/two_factor_auth/version.rb +3 -0
  35. data/lib/two_factor_auth.rb +155 -0
  36. data/test/controllers/two_factor_auth/authentications_controller_test.rb +70 -0
  37. data/test/controllers/two_factor_auth/registrations_controller_test.rb +57 -0
  38. data/test/controllers/two_factor_auth/trusted_facets_controller_test.rb +17 -0
  39. data/test/dummy/README.rdoc +28 -0
  40. data/test/dummy/Rakefile +6 -0
  41. data/test/dummy/app/assets/javascripts/application.js +13 -0
  42. data/test/dummy/app/assets/stylesheets/application.css +15 -0
  43. data/test/dummy/app/controllers/application_controller.rb +5 -0
  44. data/test/dummy/app/controllers/secrets_controller.rb +3 -0
  45. data/test/dummy/app/helpers/application_helper.rb +2 -0
  46. data/test/dummy/app/models/user.rb +8 -0
  47. data/test/dummy/app/views/layouts/application.html.erb +16 -0
  48. data/test/dummy/app/views/secrets/index.html.erb +10 -0
  49. data/test/dummy/bin/bundle +3 -0
  50. data/test/dummy/bin/rails +4 -0
  51. data/test/dummy/bin/rake +4 -0
  52. data/test/dummy/config/application.rb +24 -0
  53. data/test/dummy/config/boot.rb +5 -0
  54. data/test/dummy/config/database.yml +25 -0
  55. data/test/dummy/config/environment.rb +5 -0
  56. data/test/dummy/config/environments/development.rb +37 -0
  57. data/test/dummy/config/environments/production.rb +78 -0
  58. data/test/dummy/config/environments/test.rb +39 -0
  59. data/test/dummy/config/initializers/assets.rb +8 -0
  60. data/test/dummy/config/initializers/backtrace_silencers.rb +7 -0
  61. data/test/dummy/config/initializers/cookies_serializer.rb +3 -0
  62. data/test/dummy/config/initializers/devise.rb +259 -0
  63. data/test/dummy/config/initializers/filter_parameter_logging.rb +4 -0
  64. data/test/dummy/config/initializers/inflections.rb +16 -0
  65. data/test/dummy/config/initializers/mime_types.rb +4 -0
  66. data/test/dummy/config/initializers/session_store.rb +3 -0
  67. data/test/dummy/config/initializers/two_factor_auth.rb +38 -0
  68. data/test/dummy/config/initializers/wrap_parameters.rb +14 -0
  69. data/test/dummy/config/locales/devise.en.yml +60 -0
  70. data/test/dummy/config/locales/en.yml +23 -0
  71. data/test/dummy/config/routes.rb +5 -0
  72. data/test/dummy/config/secrets.yml +22 -0
  73. data/test/dummy/config.ru +4 -0
  74. data/test/dummy/db/development.sqlite3 +0 -0
  75. data/test/dummy/db/migrate/20141026231953_devise_create_users.rb +42 -0
  76. data/test/dummy/db/migrate/20141224135949_create_two_factor_auth_registrations.rb +15 -0
  77. data/test/dummy/db/schema.rb +50 -0
  78. data/test/dummy/db/test.sqlite3 +0 -0
  79. data/test/dummy/log/development.log +198 -0
  80. data/test/dummy/log/test.log +3490 -0
  81. data/test/dummy/public/404.html +67 -0
  82. data/test/dummy/public/422.html +67 -0
  83. data/test/dummy/public/500.html +66 -0
  84. data/test/dummy/public/favicon.ico +0 -0
  85. data/test/dummy/tmp/cache/assets/test/sprockets/13fe41fee1fe35b49d145bcc06610705 +0 -0
  86. data/test/dummy/tmp/cache/assets/test/sprockets/2f5173deea6c795b8fdde723bb4b63af +0 -0
  87. data/test/dummy/tmp/cache/assets/test/sprockets/357970feca3ac29060c1e3861e2c0953 +0 -0
  88. data/test/dummy/tmp/cache/assets/test/sprockets/cffd775d018f68ce5dba1ee0d951a994 +0 -0
  89. data/test/dummy/tmp/cache/assets/test/sprockets/d771ace226fc8215a3572e0aa35bb0d6 +0 -0
  90. data/test/dummy/tmp/cache/assets/test/sprockets/f7cbd26ba1d28d48de824f0e94586655 +0 -0
  91. data/test/helpers/two_factor_auth/authentication_helper_test.rb +54 -0
  92. data/test/helpers/two_factor_auth/registrations_helper_test.rb +34 -0
  93. data/test/integration/navigation_test.rb +10 -0
  94. data/test/lib/two_factor_auth_test.rb +169 -0
  95. data/test/models/two_factor_auth/authentication_request_test.rb +35 -0
  96. data/test/models/two_factor_auth/authentication_response_test.rb +44 -0
  97. data/test/models/two_factor_auth/authentication_verifier_test.rb +83 -0
  98. data/test/models/two_factor_auth/client_data_test.rb +79 -0
  99. data/test/models/two_factor_auth/registration_request_test.rb +29 -0
  100. data/test/models/two_factor_auth/registration_response_test.rb +87 -0
  101. data/test/models/two_factor_auth/registration_verifier_test.rb +96 -0
  102. data/test/test_helper.rb +43 -0
  103. metadata +351 -0
metadata ADDED
@@ -0,0 +1,351 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: two_factor_auth
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.1
5
+ platform: ruby
6
+ authors:
7
+ - Peter Harkins
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2014-12-26 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: activemodel
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '4.0'
20
+ - - "<="
21
+ - !ruby/object:Gem::Version
22
+ version: '4.2'
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - "~>"
28
+ - !ruby/object:Gem::Version
29
+ version: '4.0'
30
+ - - "<="
31
+ - !ruby/object:Gem::Version
32
+ version: '4.2'
33
+ - !ruby/object:Gem::Dependency
34
+ name: adamantium
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: '0.2'
40
+ type: :runtime
41
+ prerelease: false
42
+ version_requirements: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - "~>"
45
+ - !ruby/object:Gem::Version
46
+ version: '0.2'
47
+ - !ruby/object:Gem::Dependency
48
+ name: virtus
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - "~>"
52
+ - !ruby/object:Gem::Version
53
+ version: '1.0'
54
+ type: :runtime
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - "~>"
59
+ - !ruby/object:Gem::Version
60
+ version: '1.0'
61
+ - !ruby/object:Gem::Dependency
62
+ name: rails
63
+ requirement: !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - "~>"
66
+ - !ruby/object:Gem::Version
67
+ version: '4.0'
68
+ - - "<="
69
+ - !ruby/object:Gem::Version
70
+ version: '4.2'
71
+ type: :development
72
+ prerelease: false
73
+ version_requirements: !ruby/object:Gem::Requirement
74
+ requirements:
75
+ - - "~>"
76
+ - !ruby/object:Gem::Version
77
+ version: '4.0'
78
+ - - "<="
79
+ - !ruby/object:Gem::Version
80
+ version: '4.2'
81
+ - !ruby/object:Gem::Dependency
82
+ name: devise
83
+ requirement: !ruby/object:Gem::Requirement
84
+ requirements:
85
+ - - "~>"
86
+ - !ruby/object:Gem::Version
87
+ version: '3.3'
88
+ - - "<"
89
+ - !ruby/object:Gem::Version
90
+ version: '4'
91
+ type: :development
92
+ prerelease: false
93
+ version_requirements: !ruby/object:Gem::Requirement
94
+ requirements:
95
+ - - "~>"
96
+ - !ruby/object:Gem::Version
97
+ version: '3.3'
98
+ - - "<"
99
+ - !ruby/object:Gem::Version
100
+ version: '4'
101
+ - !ruby/object:Gem::Dependency
102
+ name: minitest-rails
103
+ requirement: !ruby/object:Gem::Requirement
104
+ requirements:
105
+ - - "~>"
106
+ - !ruby/object:Gem::Version
107
+ version: '2.1'
108
+ type: :development
109
+ prerelease: false
110
+ version_requirements: !ruby/object:Gem::Requirement
111
+ requirements:
112
+ - - "~>"
113
+ - !ruby/object:Gem::Version
114
+ version: '2.1'
115
+ - !ruby/object:Gem::Dependency
116
+ name: pry
117
+ requirement: !ruby/object:Gem::Requirement
118
+ requirements:
119
+ - - "~>"
120
+ - !ruby/object:Gem::Version
121
+ version: '0.10'
122
+ type: :development
123
+ prerelease: false
124
+ version_requirements: !ruby/object:Gem::Requirement
125
+ requirements:
126
+ - - "~>"
127
+ - !ruby/object:Gem::Version
128
+ version: '0.10'
129
+ - !ruby/object:Gem::Dependency
130
+ name: sqlite3
131
+ requirement: !ruby/object:Gem::Requirement
132
+ requirements:
133
+ - - "~>"
134
+ - !ruby/object:Gem::Version
135
+ version: '1.3'
136
+ - - "<"
137
+ - !ruby/object:Gem::Version
138
+ version: '2'
139
+ type: :development
140
+ prerelease: false
141
+ version_requirements: !ruby/object:Gem::Requirement
142
+ requirements:
143
+ - - "~>"
144
+ - !ruby/object:Gem::Version
145
+ version: '1.3'
146
+ - - "<"
147
+ - !ruby/object:Gem::Version
148
+ version: '2'
149
+ description: TwoFactorAuth makes it easy to set up two-factor authentication for your
150
+ users, whether through Devise or your custom Rails or Ruby authentication.
151
+ email:
152
+ - ph@push.cx
153
+ executables: []
154
+ extensions: []
155
+ extra_rdoc_files: []
156
+ files:
157
+ - LICENSE
158
+ - Rakefile
159
+ - app/assets/javascripts/two_factor_auth/application.js
160
+ - app/assets/stylesheets/two_factor_auth/application.css
161
+ - app/controllers/two_factor_auth/authentications_controller.rb
162
+ - app/controllers/two_factor_auth/registrations_controller.rb
163
+ - app/controllers/two_factor_auth/trusted_facets_controller.rb
164
+ - app/controllers/two_factor_auth/two_factor_auth_controller.rb
165
+ - app/helpers/two_factor_auth/application_helper.rb
166
+ - app/helpers/two_factor_auth/authentications_helper.rb
167
+ - app/helpers/two_factor_auth/registrations_helper.rb
168
+ - app/models/two_factor_auth/authentication_client_data.rb
169
+ - app/models/two_factor_auth/authentication_request.rb
170
+ - app/models/two_factor_auth/authentication_response.rb
171
+ - app/models/two_factor_auth/authentication_verifier.rb
172
+ - app/models/two_factor_auth/client_data.rb
173
+ - app/models/two_factor_auth/registration.rb
174
+ - app/models/two_factor_auth/registration_request.rb
175
+ - app/models/two_factor_auth/registration_response.rb
176
+ - app/models/two_factor_auth/registration_verifier.rb
177
+ - app/views/layouts/two_factor_auth/application.html.erb
178
+ - app/views/two_factor_auth/authentications/new.html.erb
179
+ - app/views/two_factor_auth/registrations/new.html.erb
180
+ - config/routes.rb
181
+ - lib/generators/templates/README
182
+ - lib/generators/templates/initializer.rb
183
+ - lib/generators/templates/migration.rb
184
+ - lib/generators/two_factor_auth/install_generator.rb
185
+ - lib/tasks/two_factor_auth_tasks.rake
186
+ - lib/two_factor_auth.rb
187
+ - lib/two_factor_auth/authentication_hook.rb
188
+ - lib/two_factor_auth/engine.rb
189
+ - lib/two_factor_auth/registration_hook.rb
190
+ - lib/two_factor_auth/version.rb
191
+ - test/controllers/two_factor_auth/authentications_controller_test.rb
192
+ - test/controllers/two_factor_auth/registrations_controller_test.rb
193
+ - test/controllers/two_factor_auth/trusted_facets_controller_test.rb
194
+ - test/dummy/README.rdoc
195
+ - test/dummy/Rakefile
196
+ - test/dummy/app/assets/javascripts/application.js
197
+ - test/dummy/app/assets/stylesheets/application.css
198
+ - test/dummy/app/controllers/application_controller.rb
199
+ - test/dummy/app/controllers/secrets_controller.rb
200
+ - test/dummy/app/helpers/application_helper.rb
201
+ - test/dummy/app/models/user.rb
202
+ - test/dummy/app/views/layouts/application.html.erb
203
+ - test/dummy/app/views/secrets/index.html.erb
204
+ - test/dummy/bin/bundle
205
+ - test/dummy/bin/rails
206
+ - test/dummy/bin/rake
207
+ - test/dummy/config.ru
208
+ - test/dummy/config/application.rb
209
+ - test/dummy/config/boot.rb
210
+ - test/dummy/config/database.yml
211
+ - test/dummy/config/environment.rb
212
+ - test/dummy/config/environments/development.rb
213
+ - test/dummy/config/environments/production.rb
214
+ - test/dummy/config/environments/test.rb
215
+ - test/dummy/config/initializers/assets.rb
216
+ - test/dummy/config/initializers/backtrace_silencers.rb
217
+ - test/dummy/config/initializers/cookies_serializer.rb
218
+ - test/dummy/config/initializers/devise.rb
219
+ - test/dummy/config/initializers/filter_parameter_logging.rb
220
+ - test/dummy/config/initializers/inflections.rb
221
+ - test/dummy/config/initializers/mime_types.rb
222
+ - test/dummy/config/initializers/session_store.rb
223
+ - test/dummy/config/initializers/two_factor_auth.rb
224
+ - test/dummy/config/initializers/wrap_parameters.rb
225
+ - test/dummy/config/locales/devise.en.yml
226
+ - test/dummy/config/locales/en.yml
227
+ - test/dummy/config/routes.rb
228
+ - test/dummy/config/secrets.yml
229
+ - test/dummy/db/development.sqlite3
230
+ - test/dummy/db/migrate/20141026231953_devise_create_users.rb
231
+ - test/dummy/db/migrate/20141224135949_create_two_factor_auth_registrations.rb
232
+ - test/dummy/db/schema.rb
233
+ - test/dummy/db/test.sqlite3
234
+ - test/dummy/log/development.log
235
+ - test/dummy/log/test.log
236
+ - test/dummy/public/404.html
237
+ - test/dummy/public/422.html
238
+ - test/dummy/public/500.html
239
+ - test/dummy/public/favicon.ico
240
+ - test/dummy/tmp/cache/assets/test/sprockets/13fe41fee1fe35b49d145bcc06610705
241
+ - test/dummy/tmp/cache/assets/test/sprockets/2f5173deea6c795b8fdde723bb4b63af
242
+ - test/dummy/tmp/cache/assets/test/sprockets/357970feca3ac29060c1e3861e2c0953
243
+ - test/dummy/tmp/cache/assets/test/sprockets/cffd775d018f68ce5dba1ee0d951a994
244
+ - test/dummy/tmp/cache/assets/test/sprockets/d771ace226fc8215a3572e0aa35bb0d6
245
+ - test/dummy/tmp/cache/assets/test/sprockets/f7cbd26ba1d28d48de824f0e94586655
246
+ - test/helpers/two_factor_auth/authentication_helper_test.rb
247
+ - test/helpers/two_factor_auth/registrations_helper_test.rb
248
+ - test/integration/navigation_test.rb
249
+ - test/lib/two_factor_auth_test.rb
250
+ - test/models/two_factor_auth/authentication_request_test.rb
251
+ - test/models/two_factor_auth/authentication_response_test.rb
252
+ - test/models/two_factor_auth/authentication_verifier_test.rb
253
+ - test/models/two_factor_auth/client_data_test.rb
254
+ - test/models/two_factor_auth/registration_request_test.rb
255
+ - test/models/two_factor_auth/registration_response_test.rb
256
+ - test/models/two_factor_auth/registration_verifier_test.rb
257
+ - test/test_helper.rb
258
+ homepage: https://www.twofactorauth.io/rails
259
+ licenses:
260
+ - AGPL-3.0
261
+ - Commercial
262
+ metadata: {}
263
+ post_install_message:
264
+ rdoc_options: []
265
+ require_paths:
266
+ - lib
267
+ required_ruby_version: !ruby/object:Gem::Requirement
268
+ requirements:
269
+ - - ">="
270
+ - !ruby/object:Gem::Version
271
+ version: '0'
272
+ required_rubygems_version: !ruby/object:Gem::Requirement
273
+ requirements:
274
+ - - ">="
275
+ - !ruby/object:Gem::Version
276
+ version: '0'
277
+ requirements: []
278
+ rubyforge_project:
279
+ rubygems_version: 2.2.2
280
+ signing_key:
281
+ specification_version: 4
282
+ summary: Support FIDO alliance universal two-factor authentication
283
+ test_files:
284
+ - test/lib/two_factor_auth_test.rb
285
+ - test/models/two_factor_auth/authentication_response_test.rb
286
+ - test/models/two_factor_auth/authentication_request_test.rb
287
+ - test/models/two_factor_auth/registration_verifier_test.rb
288
+ - test/models/two_factor_auth/registration_response_test.rb
289
+ - test/models/two_factor_auth/registration_request_test.rb
290
+ - test/models/two_factor_auth/client_data_test.rb
291
+ - test/models/two_factor_auth/authentication_verifier_test.rb
292
+ - test/integration/navigation_test.rb
293
+ - test/controllers/two_factor_auth/trusted_facets_controller_test.rb
294
+ - test/controllers/two_factor_auth/authentications_controller_test.rb
295
+ - test/controllers/two_factor_auth/registrations_controller_test.rb
296
+ - test/helpers/two_factor_auth/authentication_helper_test.rb
297
+ - test/helpers/two_factor_auth/registrations_helper_test.rb
298
+ - test/dummy/config.ru
299
+ - test/dummy/config/secrets.yml
300
+ - test/dummy/config/initializers/session_store.rb
301
+ - test/dummy/config/initializers/devise.rb
302
+ - test/dummy/config/initializers/cookies_serializer.rb
303
+ - test/dummy/config/initializers/inflections.rb
304
+ - test/dummy/config/initializers/filter_parameter_logging.rb
305
+ - test/dummy/config/initializers/two_factor_auth.rb
306
+ - test/dummy/config/initializers/mime_types.rb
307
+ - test/dummy/config/initializers/backtrace_silencers.rb
308
+ - test/dummy/config/initializers/assets.rb
309
+ - test/dummy/config/initializers/wrap_parameters.rb
310
+ - test/dummy/config/routes.rb
311
+ - test/dummy/config/boot.rb
312
+ - test/dummy/config/environments/production.rb
313
+ - test/dummy/config/environments/development.rb
314
+ - test/dummy/config/environments/test.rb
315
+ - test/dummy/config/database.yml
316
+ - test/dummy/config/environment.rb
317
+ - test/dummy/config/locales/en.yml
318
+ - test/dummy/config/locales/devise.en.yml
319
+ - test/dummy/config/application.rb
320
+ - test/dummy/db/development.sqlite3
321
+ - test/dummy/db/test.sqlite3
322
+ - test/dummy/db/schema.rb
323
+ - test/dummy/db/migrate/20141026231953_devise_create_users.rb
324
+ - test/dummy/db/migrate/20141224135949_create_two_factor_auth_registrations.rb
325
+ - test/dummy/app/assets/javascripts/application.js
326
+ - test/dummy/app/assets/stylesheets/application.css
327
+ - test/dummy/app/models/user.rb
328
+ - test/dummy/app/controllers/application_controller.rb
329
+ - test/dummy/app/controllers/secrets_controller.rb
330
+ - test/dummy/app/helpers/application_helper.rb
331
+ - test/dummy/app/views/layouts/application.html.erb
332
+ - test/dummy/app/views/secrets/index.html.erb
333
+ - test/dummy/Rakefile
334
+ - test/dummy/bin/bundle
335
+ - test/dummy/bin/rake
336
+ - test/dummy/bin/rails
337
+ - test/dummy/tmp/cache/assets/test/sprockets/13fe41fee1fe35b49d145bcc06610705
338
+ - test/dummy/tmp/cache/assets/test/sprockets/d771ace226fc8215a3572e0aa35bb0d6
339
+ - test/dummy/tmp/cache/assets/test/sprockets/357970feca3ac29060c1e3861e2c0953
340
+ - test/dummy/tmp/cache/assets/test/sprockets/2f5173deea6c795b8fdde723bb4b63af
341
+ - test/dummy/tmp/cache/assets/test/sprockets/cffd775d018f68ce5dba1ee0d951a994
342
+ - test/dummy/tmp/cache/assets/test/sprockets/f7cbd26ba1d28d48de824f0e94586655
343
+ - test/dummy/README.rdoc
344
+ - test/dummy/log/development.log
345
+ - test/dummy/log/test.log
346
+ - test/dummy/public/422.html
347
+ - test/dummy/public/favicon.ico
348
+ - test/dummy/public/404.html
349
+ - test/dummy/public/500.html
350
+ - test/test_helper.rb
351
+ has_rdoc: