orthodox 0.3.5 → 0.3.6

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 (63) hide show
  1. checksums.yaml +4 -4
  2. data/.ruby-version +1 -0
  3. data/README.md +3 -7
  4. data/dummy/.ruby-version +1 -1
  5. data/dummy/Gemfile +2 -2
  6. data/dummy/Gemfile.lock +111 -113
  7. data/lib/generators/authentication/templates/controllers/concerns/authentication.rb.erb +24 -24
  8. data/lib/generators/authentication/templates/controllers/sessions_controller.rb.erb +4 -4
  9. data/lib/generators/authentication/templates/controllers/tfa_sessions_controller.rb.erb +2 -2
  10. data/lib/generators/authentication/templates/controllers/tfas_controller.rb.erb +2 -2
  11. data/lib/generators/authentication/templates/helpers/otp_credentials_helper.rb +2 -2
  12. data/lib/generators/authentication/templates/javascript/tfa_forms.js +3 -5
  13. data/lib/generators/authentication/templates/models/concerns/authenticateable.rb +2 -2
  14. data/lib/generators/authentication/templates/models/concerns/otpable.rb +2 -2
  15. data/lib/generators/authentication/templates/models/concerns/password_resetable.rb +2 -2
  16. data/lib/generators/authentication/templates/models/otp_credential.rb.erb +2 -2
  17. data/lib/generators/authentication/templates/models/password_reset_token.rb +2 -2
  18. data/lib/generators/authentication/templates/models/session.rb.erb +2 -2
  19. data/lib/generators/authentication/templates/models/tfa_session.rb +2 -2
  20. data/lib/generators/authentication/templates/spec/models/otp_credential_spec.rb +2 -2
  21. data/lib/generators/authentication/templates/spec/models/password_reset_token_spec.rb +2 -2
  22. data/lib/generators/authentication/templates/spec/models/session_spec.rb.erb +10 -11
  23. data/lib/generators/authentication/templates/spec/models/tfa_session_spec.rb.erb +35 -36
  24. data/lib/generators/authentication/templates/spec/support/authentication_helpers.rb +2 -2
  25. data/lib/generators/authentication/templates/spec/system/authentication_spec.rb.erb +2 -2
  26. data/lib/generators/authentication/templates/spec/system/password_resets_spec.rb.erb +2 -2
  27. data/lib/generators/authentication/templates/spec/system/tfa_authentication_spec.rb.erb +2 -2
  28. data/lib/orthodox/version.rb +1 -1
  29. data/orthodox.gemspec +1 -2
  30. metadata +6 -52
  31. data/docs/Authenticateable/ClassMethods.html +0 -105
  32. data/docs/Authenticateable.html +0 -246
  33. data/docs/AuthenticationGenerator.html +0 -1335
  34. data/docs/AuthenticationHelpers.html +0 -194
  35. data/docs/BaseControllerGenerator.html +0 -247
  36. data/docs/CoffeescriptGenerator.html +0 -495
  37. data/docs/ControllerGenerator.html +0 -855
  38. data/docs/LayoutHelperGenerator.html +0 -397
  39. data/docs/Orthodox/Railtie.html +0 -124
  40. data/docs/Orthodox.html +0 -133
  41. data/docs/OtpCredentialsHelper.html +0 -298
  42. data/docs/Otpable.html +0 -267
  43. data/docs/PasswordResetToken.html +0 -324
  44. data/docs/PasswordResetable.html +0 -193
  45. data/docs/SassGenerator.html +0 -549
  46. data/docs/TfaSession.html +0 -476
  47. data/docs/TwoFactorAuthentication/ClassMethods.html +0 -222
  48. data/docs/TwoFactorAuthentication.html +0 -121
  49. data/docs/_config.yml +0 -1
  50. data/docs/_index.html +0 -265
  51. data/docs/class_list.html +0 -51
  52. data/docs/css/common.css +0 -1
  53. data/docs/css/full_list.css +0 -58
  54. data/docs/css/style.css +0 -496
  55. data/docs/file.README.html +0 -311
  56. data/docs/file_list.html +0 -56
  57. data/docs/frames.html +0 -17
  58. data/docs/index.html +0 -311
  59. data/docs/js/app.js +0 -314
  60. data/docs/js/full_list.js +0 -216
  61. data/docs/js/jquery.js +0 -4
  62. data/docs/method_list.html +0 -555
  63. data/docs/top-level-namespace.html +0 -112
data/docs/TfaSession.html DELETED
@@ -1,476 +0,0 @@
1
- <!DOCTYPE html>
2
- <html>
3
- <head>
4
- <meta charset="utf-8">
5
- <meta name="viewport" content="width=device-width, initial-scale=1.0">
6
- <title>
7
- Class: TfaSession
8
-
9
- &mdash; Orthodox
10
-
11
- </title>
12
-
13
- <link rel="stylesheet" href="css/style.css" type="text/css" />
14
-
15
- <link rel="stylesheet" href="css/common.css" type="text/css" />
16
-
17
- <script type="text/javascript">
18
- pathId = "TfaSession";
19
- relpath = '';
20
- </script>
21
-
22
-
23
- <script type="text/javascript" charset="utf-8" src="js/jquery.js"></script>
24
-
25
- <script type="text/javascript" charset="utf-8" src="js/app.js"></script>
26
-
27
-
28
- </head>
29
- <body>
30
- <div class="nav_wrap">
31
- <iframe id="nav" src="class_list.html?1"></iframe>
32
- <div id="resizer"></div>
33
- </div>
34
-
35
- <div id="main" tabindex="-1">
36
- <div id="header">
37
- <div id="menu">
38
-
39
- <a href="_index.html">Index (T)</a> &raquo;
40
-
41
-
42
- <span class="title">TfaSession</span>
43
-
44
- </div>
45
-
46
- <div id="search">
47
-
48
- <a class="full_list_link" id="class_list_link"
49
- href="class_list.html">
50
-
51
- <svg width="24" height="24">
52
- <rect x="0" y="4" width="24" height="4" rx="1" ry="1"></rect>
53
- <rect x="0" y="12" width="24" height="4" rx="1" ry="1"></rect>
54
- <rect x="0" y="20" width="24" height="4" rx="1" ry="1"></rect>
55
- </svg>
56
- </a>
57
-
58
- </div>
59
- <div class="clear"></div>
60
- </div>
61
-
62
- <div id="content"><h1>Class: TfaSession
63
-
64
-
65
-
66
- </h1>
67
- <div class="box_info">
68
-
69
- <dl>
70
- <dt>Inherits:</dt>
71
- <dd>
72
- <span class="inheritName">Object</span>
73
-
74
- <ul class="fullTree">
75
- <li>Object</li>
76
-
77
- <li class="next">TfaSession</li>
78
-
79
- </ul>
80
- <a href="#" class="inheritanceTree">show all</a>
81
-
82
- </dd>
83
- </dl>
84
-
85
-
86
-
87
-
88
-
89
-
90
- <dl>
91
- <dt>Includes:</dt>
92
- <dd>ActiveModel::Attributes, ActiveModel::Model</dd>
93
- </dl>
94
-
95
-
96
-
97
-
98
-
99
-
100
- <dl>
101
- <dt>Defined in:</dt>
102
- <dd>lib/generators/authentication/templates/models/tfa_session.rb</dd>
103
- </dl>
104
-
105
- </div>
106
-
107
- <h2>Overview</h2><div class="docstring">
108
- <div class="discussion">
109
- <p>Form object for handling two-factor authentication sessions</p>
110
-
111
- <p>Automatically generated by the orthodox gem (<a href="https://github.com/katanacode/orthodox">https://github.com/katanacode/orthodox</a>)
112
- (c) Copyright 2019 Katana Code Ltd. All Rights Reserved.</p>
113
-
114
-
115
- </div>
116
- </div>
117
- <div class="tags">
118
-
119
-
120
- </div>
121
-
122
- <h2>
123
- Constant Summary
124
- <small><a href="#" class="constants_summary_toggle">collapse</a></small>
125
- </h2>
126
-
127
- <dl class="constants">
128
-
129
- <dt id="OTP_FORMAT-constant" class="">OTP_FORMAT =
130
- <div class="docstring">
131
- <div class="discussion">
132
- <p>Regex for OTP format</p>
133
-
134
-
135
- </div>
136
- </div>
137
- <div class="tags">
138
-
139
-
140
- </div>
141
- </dt>
142
- <dd><pre class="code"><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>\A\d{3,5}\Z|</span><span class='regexp_end'>/</span></span></pre></dd>
143
-
144
- <dt id="RECOVERY_CODE_FORMAT-constant" class="">RECOVERY_CODE_FORMAT =
145
- <div class="docstring">
146
- <div class="discussion">
147
- <p>Regex for recovery code format</p>
148
-
149
-
150
- </div>
151
- </div>
152
- <div class="tags">
153
-
154
-
155
- </div>
156
- </dt>
157
- <dd><pre class="code"><span class='tstring'><span class='regexp_beg'>/</span><span class='tstring_content'>\A\w{5}\-\w{5}\Z</span><span class='regexp_end'>/</span></span></pre></dd>
158
-
159
- </dl>
160
-
161
-
162
-
163
-
164
-
165
-
166
-
167
-
168
-
169
- <h2>
170
- Instance Method Summary
171
- <small><a href="#" class="summary_toggle">collapse</a></small>
172
- </h2>
173
-
174
- <ul class="summary">
175
-
176
- <li class="public ">
177
- <span class="summary_signature">
178
-
179
- <a href="#otp%3F-instance_method" title="#otp? (instance method)">#<strong>otp?</strong> &#x21d2; Boolean </a>
180
-
181
-
182
-
183
- </span>
184
-
185
-
186
-
187
-
188
-
189
-
190
-
191
-
192
-
193
- <span class="summary_desc"><div class='inline'><p>=========================== = Public instance methods = ===========================.</p>
194
- </div></span>
195
-
196
- </li>
197
-
198
-
199
- <li class="private ">
200
- <span class="summary_signature">
201
-
202
- <a href="#otp_correct-instance_method" title="#otp_correct (instance method)">#<strong>otp_correct</strong> &#x21d2; Object </a>
203
-
204
-
205
-
206
- </span>
207
-
208
-
209
-
210
- <span class="note title private">private</span>
211
-
212
-
213
-
214
-
215
-
216
- <span class="summary_desc"><div class='inline'><p>============================ = Private instance methods = ============================.</p>
217
- </div></span>
218
-
219
- </li>
220
-
221
-
222
- <li class="public ">
223
- <span class="summary_signature">
224
-
225
- <a href="#recovery_code%3F-instance_method" title="#recovery_code? (instance method)">#<strong>recovery_code?</strong> &#x21d2; Boolean </a>
226
-
227
-
228
-
229
- </span>
230
-
231
-
232
-
233
-
234
-
235
-
236
-
237
-
238
-
239
- <span class="summary_desc"><div class='inline'></div></span>
240
-
241
- </li>
242
-
243
-
244
- <li class="private ">
245
- <span class="summary_signature">
246
-
247
- <a href="#recovery_code_correct-instance_method" title="#recovery_code_correct (instance method)">#<strong>recovery_code_correct</strong> &#x21d2; Object </a>
248
-
249
-
250
-
251
- </span>
252
-
253
-
254
-
255
- <span class="note title private">private</span>
256
-
257
-
258
-
259
-
260
-
261
- <span class="summary_desc"><div class='inline'></div></span>
262
-
263
- </li>
264
-
265
-
266
- </ul>
267
-
268
-
269
-
270
-
271
-
272
-
273
- <div id="instance_method_details" class="method_details_list">
274
- <h2>Instance Method Details</h2>
275
-
276
-
277
- <div class="method_details first">
278
- <h3 class="signature first" id="otp?-instance_method">
279
-
280
- #<strong>otp?</strong> &#x21d2; <tt>Boolean</tt>
281
-
282
-
283
-
284
-
285
-
286
- </h3><div class="docstring">
287
- <div class="discussion">
288
- <p>===========================</p>
289
-
290
- <h1>= Public instance methods =</h1>
291
-
292
-
293
- </div>
294
- </div>
295
- <div class="tags">
296
-
297
- <p class="tag_title">Returns:</p>
298
- <ul class="return">
299
-
300
- <li>
301
-
302
-
303
- <span class='type'>(<tt>Boolean</tt>)</span>
304
-
305
-
306
-
307
- </li>
308
-
309
- </ul>
310
-
311
- </div><table class="source_code">
312
- <tr>
313
- <td>
314
- <pre class="lines">
315
-
316
-
317
- 51
318
- 52
319
- 53</pre>
320
- </td>
321
- <td>
322
- <pre class="code"><span class="info file"># File 'lib/generators/authentication/templates/models/tfa_session.rb', line 51</span>
323
-
324
- <span class='kw'>def</span> <span class='id identifier rubyid_otp?'>otp?</span>
325
- <span class='id identifier rubyid_otp'>otp</span><span class='period'>.</span><span class='id identifier rubyid_present?'>present?</span>
326
- <span class='kw'>end</span></pre>
327
- </td>
328
- </tr>
329
- </table>
330
- </div>
331
-
332
- <div class="method_details ">
333
- <h3 class="signature " id="otp_correct-instance_method">
334
-
335
- #<strong>otp_correct</strong> &#x21d2; <tt>Object</tt> <span class="extras">(private)</span>
336
-
337
-
338
-
339
-
340
-
341
- </h3><div class="docstring">
342
- <div class="discussion">
343
- <p>============================</p>
344
-
345
- <h1>= Private instance methods =</h1>
346
-
347
-
348
- </div>
349
- </div>
350
- <div class="tags">
351
-
352
-
353
- </div><table class="source_code">
354
- <tr>
355
- <td>
356
- <pre class="lines">
357
-
358
-
359
- 65
360
- 66
361
- 67
362
- 68
363
- 69</pre>
364
- </td>
365
- <td>
366
- <pre class="code"><span class="info file"># File 'lib/generators/authentication/templates/models/tfa_session.rb', line 65</span>
367
-
368
- <span class='kw'>def</span> <span class='id identifier rubyid_otp_correct'>otp_correct</span>
369
- <span class='kw'>unless</span> <span class='id identifier rubyid_record'>record</span><span class='period'>.</span><span class='id identifier rubyid_valid_otp?'>valid_otp?</span><span class='lparen'>(</span><span class='id identifier rubyid_otp'>otp</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span><span class='rparen'>)</span>
370
- <span class='id identifier rubyid_errors'>errors</span><span class='period'>.</span><span class='id identifier rubyid_add'>add</span><span class='lparen'>(</span><span class='symbol'>:base</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>OTP code was not correct</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span>
371
- <span class='kw'>end</span>
372
- <span class='kw'>end</span></pre>
373
- </td>
374
- </tr>
375
- </table>
376
- </div>
377
-
378
- <div class="method_details ">
379
- <h3 class="signature " id="recovery_code?-instance_method">
380
-
381
- #<strong>recovery_code?</strong> &#x21d2; <tt>Boolean</tt>
382
-
383
-
384
-
385
-
386
-
387
- </h3><div class="docstring">
388
- <div class="discussion">
389
-
390
-
391
- </div>
392
- </div>
393
- <div class="tags">
394
-
395
- <p class="tag_title">Returns:</p>
396
- <ul class="return">
397
-
398
- <li>
399
-
400
-
401
- <span class='type'>(<tt>Boolean</tt>)</span>
402
-
403
-
404
-
405
- </li>
406
-
407
- </ul>
408
-
409
- </div><table class="source_code">
410
- <tr>
411
- <td>
412
- <pre class="lines">
413
-
414
-
415
- 55
416
- 56
417
- 57</pre>
418
- </td>
419
- <td>
420
- <pre class="code"><span class="info file"># File 'lib/generators/authentication/templates/models/tfa_session.rb', line 55</span>
421
-
422
- <span class='kw'>def</span> <span class='id identifier rubyid_recovery_code?'>recovery_code?</span>
423
- <span class='id identifier rubyid_recovery_code'>recovery_code</span><span class='period'>.</span><span class='id identifier rubyid_present?'>present?</span>
424
- <span class='kw'>end</span></pre>
425
- </td>
426
- </tr>
427
- </table>
428
- </div>
429
-
430
- <div class="method_details ">
431
- <h3 class="signature " id="recovery_code_correct-instance_method">
432
-
433
- #<strong>recovery_code_correct</strong> &#x21d2; <tt>Object</tt> <span class="extras">(private)</span>
434
-
435
-
436
-
437
-
438
-
439
- </h3><table class="source_code">
440
- <tr>
441
- <td>
442
- <pre class="lines">
443
-
444
-
445
- 71
446
- 72
447
- 73
448
- 74
449
- 75</pre>
450
- </td>
451
- <td>
452
- <pre class="code"><span class="info file"># File 'lib/generators/authentication/templates/models/tfa_session.rb', line 71</span>
453
-
454
- <span class='kw'>def</span> <span class='id identifier rubyid_recovery_code_correct'>recovery_code_correct</span>
455
- <span class='kw'>unless</span> <span class='id identifier rubyid_record'>record</span><span class='period'>.</span><span class='id identifier rubyid_valid_recovery_code?'>valid_recovery_code?</span><span class='lparen'>(</span><span class='id identifier rubyid_recovery_code'>recovery_code</span><span class='period'>.</span><span class='id identifier rubyid_to_s'>to_s</span><span class='rparen'>)</span>
456
- <span class='id identifier rubyid_errors'>errors</span><span class='period'>.</span><span class='id identifier rubyid_add'>add</span><span class='lparen'>(</span><span class='symbol'>:base</span><span class='comma'>,</span> <span class='tstring'><span class='tstring_beg'>&quot;</span><span class='tstring_content'>Recovery code was not correct</span><span class='tstring_end'>&quot;</span></span><span class='rparen'>)</span>
457
- <span class='kw'>end</span>
458
- <span class='kw'>end</span></pre>
459
- </td>
460
- </tr>
461
- </table>
462
- </div>
463
-
464
- </div>
465
-
466
- </div>
467
-
468
- <div id="footer">
469
- Generated on Thu Aug 13 16:36:42 2020 by
470
- <a href="http://yardoc.org" title="Yay! A Ruby Documentation Tool" target="_parent">yard</a>
471
- 0.9.24 (ruby-2.6.6).
472
- </div>
473
-
474
- </div>
475
- </body>
476
- </html>