masks 0.4.0 → 0.6.0

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 (180) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +29 -0
  3. data/LICENSE +21 -0
  4. data/README.md +235 -29
  5. data/app/controllers/masks/rails/avatars_controller.rb +51 -0
  6. data/app/controllers/masks/rails/base_controller.rb +13 -0
  7. data/app/controllers/masks/rails/handshakes_controller.rb +86 -0
  8. data/app/controllers/masks/rails/sessions_controller.rb +118 -0
  9. data/app/views/layouts/masks/rails/plain.html.erb +47 -0
  10. data/app/views/masks/rails/handshakes/refused.html.erb +12 -0
  11. data/app/views/masks/rails/handshakes/show.html.erb +40 -0
  12. data/config/routes.rb +11 -82
  13. data/lib/generators/masks/install/install_generator.rb +35 -22
  14. data/lib/generators/masks/install/templates/masks.rb.tt +38 -0
  15. data/lib/masks/client/claims.rb +144 -0
  16. data/lib/masks/client/errors.rb +60 -0
  17. data/lib/masks/client/handshake.rb +104 -0
  18. data/lib/masks/client/http.rb +96 -0
  19. data/lib/masks/client/introspection.rb +29 -0
  20. data/lib/masks/client/issuer.rb +92 -0
  21. data/lib/masks/client/pkce.rb +27 -0
  22. data/lib/masks/client/rack.rb +62 -0
  23. data/lib/masks/client/registration.rb +115 -0
  24. data/lib/masks/client/registry.rb +25 -0
  25. data/lib/masks/client/resource.rb +92 -0
  26. data/lib/masks/client/session.rb +146 -0
  27. data/lib/masks/client/stores.rb +40 -0
  28. data/lib/masks/client/tokens.rb +70 -0
  29. data/lib/masks/client/tracker.rb +122 -0
  30. data/lib/masks/client/verifier.rb +42 -0
  31. data/lib/masks/client.rb +51 -0
  32. data/lib/masks/rails/authentication.rb +260 -0
  33. data/lib/masks/rails/configurable.rb +11 -0
  34. data/lib/masks/rails/configuration.rb +184 -0
  35. data/lib/masks/rails/credentials.rb +60 -0
  36. data/lib/masks/rails/engine.rb +20 -0
  37. data/lib/masks/rails/protected_resource.rb +51 -0
  38. data/lib/masks/rails.rb +10 -0
  39. data/lib/masks/version.rb +1 -3
  40. data/lib/masks.rb +3 -183
  41. metadata +48 -416
  42. data/MIT-LICENSE +0 -20
  43. data/Rakefile +0 -11
  44. data/app/assets/builds/masks/application.css +0 -1
  45. data/app/assets/builds/masks/application.js +0 -8549
  46. data/app/assets/builds/masks/application.js.map +0 -7
  47. data/app/assets/images/masks.png +0 -0
  48. data/app/assets/javascripts/application.js +0 -2
  49. data/app/assets/javascripts/controllers/application.js +0 -9
  50. data/app/assets/javascripts/controllers/emails_controller.js +0 -28
  51. data/app/assets/javascripts/controllers/index.js +0 -21
  52. data/app/assets/javascripts/controllers/keys_controller.js +0 -20
  53. data/app/assets/javascripts/controllers/recover_controller.js +0 -21
  54. data/app/assets/javascripts/controllers/recover_password_controller.js +0 -21
  55. data/app/assets/javascripts/controllers/session_controller.js +0 -94
  56. data/app/assets/javascripts/controllers/table_controller.js +0 -15
  57. data/app/assets/manifest.js +0 -2
  58. data/app/assets/masks_manifest.js +0 -2
  59. data/app/assets/stylesheets/application.css +0 -34
  60. data/app/controllers/concerns/masks/controller.rb +0 -114
  61. data/app/controllers/masks/actors_controller.rb +0 -15
  62. data/app/controllers/masks/application_controller.rb +0 -35
  63. data/app/controllers/masks/backup_codes_controller.rb +0 -34
  64. data/app/controllers/masks/debug_controller.rb +0 -9
  65. data/app/controllers/masks/devices_controller.rb +0 -20
  66. data/app/controllers/masks/emails_controller.rb +0 -60
  67. data/app/controllers/masks/error_controller.rb +0 -14
  68. data/app/controllers/masks/keys_controller.rb +0 -45
  69. data/app/controllers/masks/manage/actors_controller.rb +0 -83
  70. data/app/controllers/masks/manage/base_controller.rb +0 -20
  71. data/app/controllers/masks/manage/clients_controller.rb +0 -84
  72. data/app/controllers/masks/manage/dashboard_controller.rb +0 -15
  73. data/app/controllers/masks/manage/devices_controller.rb +0 -19
  74. data/app/controllers/masks/one_time_code_controller.rb +0 -49
  75. data/app/controllers/masks/openid/authorizations_controller.rb +0 -45
  76. data/app/controllers/masks/openid/discoveries_controller.rb +0 -55
  77. data/app/controllers/masks/openid/tokens_controller.rb +0 -45
  78. data/app/controllers/masks/openid/userinfo_controller.rb +0 -28
  79. data/app/controllers/masks/passwords_controller.rb +0 -33
  80. data/app/controllers/masks/recoveries_controller.rb +0 -43
  81. data/app/controllers/masks/sessions_controller.rb +0 -53
  82. data/app/helpers/masks/application_helper.rb +0 -49
  83. data/app/jobs/masks/application_job.rb +0 -7
  84. data/app/jobs/masks/expire_actors_job.rb +0 -15
  85. data/app/jobs/masks/expire_recoveries_job.rb +0 -15
  86. data/app/mailers/masks/actor_mailer.rb +0 -22
  87. data/app/mailers/masks/application_mailer.rb +0 -15
  88. data/app/models/concerns/masks/access.rb +0 -162
  89. data/app/models/concerns/masks/actor.rb +0 -132
  90. data/app/models/concerns/masks/adapter.rb +0 -68
  91. data/app/models/concerns/masks/role.rb +0 -9
  92. data/app/models/concerns/masks/scoped.rb +0 -54
  93. data/app/models/masks/access/actor_password.rb +0 -21
  94. data/app/models/masks/access/actor_scopes.rb +0 -18
  95. data/app/models/masks/access/actor_signup.rb +0 -21
  96. data/app/models/masks/actors/anonymous.rb +0 -40
  97. data/app/models/masks/actors/system.rb +0 -24
  98. data/app/models/masks/adapters/active_record.rb +0 -85
  99. data/app/models/masks/application_model.rb +0 -15
  100. data/app/models/masks/application_record.rb +0 -8
  101. data/app/models/masks/check.rb +0 -192
  102. data/app/models/masks/credential.rb +0 -166
  103. data/app/models/masks/credentials/access_token.rb +0 -60
  104. data/app/models/masks/credentials/backup_code.rb +0 -30
  105. data/app/models/masks/credentials/device.rb +0 -59
  106. data/app/models/masks/credentials/email.rb +0 -48
  107. data/app/models/masks/credentials/factor2.rb +0 -71
  108. data/app/models/masks/credentials/key.rb +0 -38
  109. data/app/models/masks/credentials/last_login.rb +0 -12
  110. data/app/models/masks/credentials/masquerade.rb +0 -32
  111. data/app/models/masks/credentials/nickname.rb +0 -63
  112. data/app/models/masks/credentials/one_time_code.rb +0 -34
  113. data/app/models/masks/credentials/password.rb +0 -28
  114. data/app/models/masks/credentials/recovery.rb +0 -71
  115. data/app/models/masks/credentials/return_to.rb +0 -27
  116. data/app/models/masks/credentials/session.rb +0 -67
  117. data/app/models/masks/device.rb +0 -30
  118. data/app/models/masks/error.rb +0 -51
  119. data/app/models/masks/event.rb +0 -14
  120. data/app/models/masks/mask.rb +0 -266
  121. data/app/models/masks/openid/authorization.rb +0 -116
  122. data/app/models/masks/openid/token.rb +0 -56
  123. data/app/models/masks/rails/actor.rb +0 -212
  124. data/app/models/masks/rails/actor_role.rb +0 -12
  125. data/app/models/masks/rails/device.rb +0 -47
  126. data/app/models/masks/rails/email.rb +0 -96
  127. data/app/models/masks/rails/key.rb +0 -61
  128. data/app/models/masks/rails/openid/access_token.rb +0 -55
  129. data/app/models/masks/rails/openid/authorization.rb +0 -45
  130. data/app/models/masks/rails/openid/client.rb +0 -186
  131. data/app/models/masks/rails/openid/id_token.rb +0 -43
  132. data/app/models/masks/rails/recovery.rb +0 -116
  133. data/app/models/masks/rails/role.rb +0 -20
  134. data/app/models/masks/rails/scope.rb +0 -15
  135. data/app/models/masks/session.rb +0 -447
  136. data/app/models/masks/sessions/access.rb +0 -27
  137. data/app/models/masks/sessions/inline.rb +0 -16
  138. data/app/models/masks/sessions/request.rb +0 -42
  139. data/app/resources/masks/actor_resource.rb +0 -9
  140. data/app/resources/masks/session_resource.rb +0 -15
  141. data/app/views/layouts/masks/application.html.erb +0 -17
  142. data/app/views/layouts/masks/mailer.html.erb +0 -17
  143. data/app/views/layouts/masks/mailer.text.erb +0 -1
  144. data/app/views/layouts/masks/manage.html.erb +0 -42
  145. data/app/views/masks/actor_mailer/recover_credentials.html.erb +0 -32
  146. data/app/views/masks/actor_mailer/recover_credentials.text.erb +0 -1
  147. data/app/views/masks/actor_mailer/verify_email.html.erb +0 -33
  148. data/app/views/masks/actor_mailer/verify_email.text.erb +0 -8
  149. data/app/views/masks/actors/current.html.erb +0 -145
  150. data/app/views/masks/application/_header.html.erb +0 -30
  151. data/app/views/masks/backup_codes/new.html.erb +0 -117
  152. data/app/views/masks/emails/new.html.erb +0 -109
  153. data/app/views/masks/emails/verify.html.erb +0 -51
  154. data/app/views/masks/keys/new.html.erb +0 -127
  155. data/app/views/masks/manage/actors/index.html.erb +0 -104
  156. data/app/views/masks/manage/actors/show.html.erb +0 -172
  157. data/app/views/masks/manage/clients/index.html.erb +0 -102
  158. data/app/views/masks/manage/clients/show.html.erb +0 -156
  159. data/app/views/masks/manage/dashboard/index.html.erb +0 -10
  160. data/app/views/masks/manage/devices/index.html.erb +0 -47
  161. data/app/views/masks/one_time_code/new.html.erb +0 -167
  162. data/app/views/masks/openid/authorizations/error.html.erb +0 -23
  163. data/app/views/masks/openid/authorizations/new.html.erb +0 -46
  164. data/app/views/masks/passwords/edit.html.erb +0 -71
  165. data/app/views/masks/recoveries/new.html.erb +0 -69
  166. data/app/views/masks/recoveries/password.html.erb +0 -63
  167. data/app/views/masks/sessions/new.html.erb +0 -152
  168. data/config/brakeman.ignore +0 -28
  169. data/config/initializers/inflections.rb +0 -5
  170. data/config/locales/en.yml +0 -307
  171. data/db/migrate/20231205173845_create_actors.rb +0 -94
  172. data/db/migrate/20240329182422_support_openid.rb +0 -64
  173. data/lib/generators/masks/install/USAGE +0 -8
  174. data/lib/generators/masks/install/templates/initializer.rb +0 -5
  175. data/lib/generators/masks/install/templates/masks.json +0 -9
  176. data/lib/masks/configuration.rb +0 -249
  177. data/lib/masks/engine.rb +0 -25
  178. data/lib/masks/middleware.rb +0 -70
  179. data/lib/tasks/masks_tasks.rake +0 -72
  180. data/masks.json +0 -315
@@ -1,307 +0,0 @@
1
- # Files in the config/locales directory are used for internationalization and
2
- # are automatically loaded by Rails. If you want to use locales other than
3
- # English, add the necessary files in this directory.
4
- #
5
- # To use the locales, use `I18n.t`:
6
- #
7
- # I18n.t "hello"
8
- #
9
- # In views, this is aliased to just `t`:
10
- #
11
- # <%= t("hello") %>
12
- #
13
- # To use a different locale, set it with `I18n.locale`:
14
- #
15
- # I18n.locale = :es
16
- #
17
- # This would use the information in config/locales/es.yml.
18
- #
19
- # To learn more about the API, please read the Rails Internationalization guide
20
- # at https://guides.rubyonrails.org/i18n.html.
21
- #
22
- # Be aware that YAML interprets the following case-insensitive strings as
23
- # booleans: `true`, `false`, `on`, `off`, `yes`, `no`. Therefore, these strings
24
- # must be quoted to be interpreted as strings. For example:
25
- #
26
- # en:
27
- # "yes": yup
28
- # enabled: "ON"
29
-
30
- en:
31
- scope:
32
- openid_name: account
33
- openid_desc: your account identifier
34
- profile_name: profile
35
- profile_desc: your name, email, and other personal details
36
- phone_name: phone
37
- phone_desc: your phone number
38
- address_name: address
39
- address_desc: your physical address
40
- layouts:
41
- masks:
42
- application:
43
- meta:
44
- title: masks
45
- manage:
46
- meta:
47
- title: masks
48
- masks:
49
- application:
50
- header:
51
- logged_in: welcome
52
- actor_mailer:
53
- recover_credentials:
54
- recover: reset password
55
- nickname: your nickname
56
- subheading: hey there, you recently requested help recovering your credentials...
57
- call_to_action: your username is listed above. you can reset your password if you forgot it.
58
- sign_off: reply to this email if you need more help. cheers
59
- verify_email:
60
- subject: verify your email - things
61
- heading: verify your email
62
- subheading: |
63
- hey there, you recently added this email to your account. you must verify it's yours by pressing the button below...
64
- subheading_plain: |
65
- hey there, you recently added this email to your account. you must verify it's yours by visiting the link below...
66
- call_to_action: once verified, this email will be usable future logins and account recovery.
67
- sign_off: thanks
68
- verify: "verify"
69
- verify_plain: "verify here — "
70
- added: added
71
- actors:
72
- current:
73
- emails:
74
- zero: no emails found
75
- one: "%{email}"
76
- other: "%{email}"
77
- add_email: add...
78
- add_more_email: add more...
79
- change_password: change your password...
80
- credentials: credentials
81
- password: password
82
- one_time_codes: one-time code
83
- backup_codes: backup codes
84
- created: created
85
- manage: manage...
86
- enable: enable...
87
- logout: logout
88
- never_logged_in: never...
89
- last_accessed: last accessed
90
- last_login: last login
91
- ago: ago
92
- devices: devices
93
- change: change...
94
- keys: keys
95
- add_key: add...
96
- add_more_key: add more...
97
-
98
- passwords:
99
- edit:
100
- placeholder:
101
- password: your current password...
102
- change: your new password...
103
- submit: change
104
- one_time_code:
105
- new:
106
- tfa: secondary credential
107
- disabled: disabled
108
- enabled: enabled
109
- enable_qr: to enable, scan this qr code into your authenticator app.
110
- enable_manual: you can also enter the secret manually.
111
- heading: one-time code
112
- empty_detail: you must enable two-factor authentication to use backup codes.
113
- disabled_heading: add a one-time password
114
- placeholder:
115
- otp: one-time code...
116
- password: your password...
117
- delete: enter your password...
118
- secret: secret
119
- submit: enable
120
- delete: disable
121
- delete_div: disable one-time codes
122
- backup_codes: save backup codes...
123
- reset_codes: view backup codes...
124
- backup_codes:
125
- new:
126
- tfa: secondary credential
127
- disabled: disabled
128
- enabled: enabled
129
- heading: backup codes
130
- empty_detail: backup codes are available once you add a secondary credential, like a one-time code.
131
- disabled_heading: backup codes are disabled
132
- save_codes: save your 10-digit backup codes somewhere safe, then press enable to use them as another secondary credential...
133
- reset_codes: press delete to disable backup codes. afterward you can generate a new set of codes.
134
- download: download
135
- enable: enable
136
- delete: delete
137
- placeholder:
138
- password: enter your password...
139
- emails:
140
- verify:
141
- verified: verified!
142
- verification_expired: email verification link expired
143
- card_title: how verified emails work...
144
- details: |
145
- you can use your newly verified email:
146
- list_html: |
147
- <li>instead of your nickname during login
148
- <li>for password-less login via email links
149
- <li>to recover your nickname or password
150
- privacy: your emails will never be shared.
151
- manage: to manage it and others...
152
- manage_expired: to try again...
153
- added: manage it in
154
- emails: view your emails
155
- new:
156
- page: your email
157
- placeholder:
158
- email:
159
- zero: enter a new email address...
160
- one: enter another email address...
161
- other: enter another email address...
162
- password: enter your password...
163
- heading: no emails found
164
- no_emails: no emails added
165
- no_emails_detail: your email can act as an alternate way to access and recover your account.
166
- heading_new:
167
- zero: no emails found
168
- one: your email
169
- other: your emails
170
- help_title: how it works
171
- help_body: if you enter valid information you will be contacted with instructions to recover your credentials.
172
- help_more: need more help?
173
- help_contact: contact support
174
- help_button: "help"
175
- support_url:
176
- submit: add
177
- back: go back...
178
- email_verified: verified %{ago} ago
179
- email_taken: email already taken.
180
- pending_verification: awaiting verification...
181
- expired_verification: verification expired.
182
- add: add an email...
183
- keys:
184
- new:
185
- heading: your keys
186
- added: allow automated tools to act on your behalf...
187
- page: your key
188
- placeholder:
189
- name: enter a name...
190
- password: enter your password...
191
- secret: leave blank to generate a secret...
192
- no_keys_detail: keys allow automated tools to act on your behalf...
193
- heading_new:
194
- zero: no keys found
195
- one: your key
196
- other: your keys
197
- help_title: how it works
198
- help_body: if you enter valid information you will be contacted with instructions to recover your credentials.
199
- help_more: need more help?
200
- help_contact: contact support
201
- help_button: "help"
202
- support_url:
203
- submit: make key
204
- back: go back...
205
- key_verified: verified %{ago} ago
206
- key_taken: key already taken.
207
- pending_verification: awaiting verification...
208
- expired_verification: verification expired.
209
- add: add key
210
- recoveries:
211
- password:
212
- placeholder: new password...
213
- heading: reset your password
214
- heading_success: password reset
215
- heading_expired: password reset expired
216
- subheading: enter a new password. you can use it to login to your account after it's changed...
217
- subheading_success: your password has been changed. you can login using the password you just entered.
218
- subheading_expired: this password reset link is expired or invalid.
219
- help_title: how it works
220
- help_body: if you enter valid information you will be contacted with instructions to recover your credentials.
221
- help_more: need more help?
222
- help_contact: contact support
223
- help_button: "help"
224
- support_url:
225
- submit: reset
226
- login: back to login
227
- new:
228
- placeholder: nickname, email or phone...
229
- heading: recover your credentials
230
- subheading: enter a nickname, email, or phone number associated with your account to recover your credentials...
231
- help_title: how it works
232
- help_body: if you enter valid information you will be contacted with instructions to recover your credentials.
233
- help_more: need more help?
234
- help_contact: contact support
235
- help_button: "help"
236
- support_url:
237
- submit: recover
238
- back: go back...
239
- submitted:
240
- heading: check your notifications...
241
- description: if you have an account with us you'll receive an email or message on your phone with instructions on how to recover your account.
242
- sessions:
243
- new:
244
- submit: continue
245
- remember_me: remember me
246
- start_over:
247
- text: or
248
- link: start over...
249
- or_start_over: or
250
- recover_credentials: "forgot your credentials?"
251
- enter_factor2: enter a secondary credential to continue...
252
- enter_credentials: "enter your credentials to continue..."
253
- enter_password: "enter your password to continue..."
254
- continue: "press continue to authorize..."
255
- one_time_code: enter a 6-digit one-time code from your authenticator app...
256
- backup_code: enter one of your saved 10-digit backup codes...
257
- logged_in: welcome!
258
- tab:
259
- one_time_code: one-time code
260
- backup_code: backup code
261
- placeholder:
262
- nickname: nickname, email, or phone number...
263
- password: password...
264
- one_time_code: one-time code...
265
- backup_code: backup code...
266
- openid:
267
- authorizations:
268
- new:
269
- authorize_client: "authorize %{name}?"
270
- authorize_account: "%{name} wants access to your account."
271
- authorize_scoped: "%{name} wants access to your account and the following data:"
272
- approve: approve
273
- deny: deny
274
- error:
275
- title: authorization failed
276
- description: an unrecoverable error occurred during authorization...
277
- home: go home
278
- activerecord:
279
- attributes:
280
- masks/rails/actor:
281
- nickname: nickname
282
- password: password
283
- signup: invalid
284
- masks/rails/email:
285
- email: email
286
- masks/rails/key:
287
- name: name
288
- secret: secret
289
- scopes: scopes
290
- errors:
291
- models:
292
- masks/rails/actor:
293
- format: is invalid
294
- attributes:
295
- signup:
296
- disabled: credentials...
297
- activemodel:
298
- attributes:
299
- masks/credentials/password:
300
- password: password
301
- masks/credentials/nickname:
302
- nickname: nickname
303
- errors:
304
- models:
305
- masks/session:
306
- credentials: invalid credentials...
307
- access: invalid access...
@@ -1,94 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- class CreateActors < ActiveRecord::Migration[7.1]
4
- def change
5
- create_table :actors do |t|
6
- t.string :type
7
- t.string :nickname
8
- t.string :version
9
- t.string :password_digest
10
- t.string :phone_number
11
- t.string :totp_secret
12
- t.text :backup_codes
13
-
14
- t.timestamps
15
- t.datetime :last_login_at
16
- t.datetime :changed_password_at
17
- t.datetime :added_phone_number_at
18
- t.datetime :added_totp_secret_at
19
- t.datetime :saved_backup_codes_at
20
- t.datetime :notified_inactive_at
21
-
22
- t.index :nickname, unique: true
23
- end
24
-
25
- create_table :scopes do |t|
26
- t.string :name
27
- t.references :actor, polymorphic: true
28
- t.index %i[name actor_id], unique: true
29
- t.timestamps
30
- end
31
-
32
- create_table :roles do |t|
33
- t.string :type
34
- t.references :actor, polymorphic: true
35
- t.references :record, polymorphic: true
36
- t.timestamps
37
- end
38
-
39
- add_index :roles,
40
- %i[type actor_id actor_type record_id record_type],
41
- unique: true
42
-
43
- create_table :emails do |t|
44
- t.string :email
45
- t.string :token
46
- t.references :actor
47
- t.boolean :verified, null: true
48
- t.datetime :verified_at
49
- t.datetime :notified_at
50
- t.timestamps
51
-
52
- t.index %i[email verified], unique: true
53
- t.index %i[token], unique: true
54
- end
55
-
56
- create_table :recoveries do |t|
57
- t.string :token
58
- t.string :nickname, null: true
59
- t.string :email, null: true
60
- t.string :phone, null: true
61
- t.references :actor
62
- t.datetime :notified_at
63
- t.timestamps
64
-
65
- t.index %i[token actor_id], unique: true
66
- end
67
-
68
- create_table :devices do |t|
69
- t.string :key
70
- t.string :user_agent
71
- t.string :ip_address
72
- t.string :fingerprint
73
- t.string :version
74
-
75
- t.references :actor
76
- t.datetime :accessed_at
77
- t.timestamps
78
-
79
- t.index %i[key actor_id], unique: true
80
- end
81
-
82
- create_table :keys do |t|
83
- t.string :name
84
- t.string :sha
85
- t.text :scopes
86
-
87
- t.references :actor
88
- t.timestamps
89
- t.datetime :accessed_at
90
-
91
- t.index %i[sha], unique: true
92
- end
93
- end
94
- end
@@ -1,64 +0,0 @@
1
- # frozen_string_literal: true
2
- class SupportOpenID < ActiveRecord::Migration[7.1]
3
- def change
4
- create_table :openid_clients do |t|
5
- t.string :name
6
- t.string :key
7
- t.string :secret
8
- t.string :client_type
9
- t.text :redirect_uris
10
- t.text :scopes
11
- t.boolean :consent
12
- t.string :subject_type
13
- t.string :sector_identifier
14
- t.string :code_expires_in
15
- t.string :token_expires_in
16
- t.string :refresh_expires_in
17
- t.text :rsa_private_key
18
-
19
- t.timestamps
20
-
21
- t.index :key, unique: true
22
- end
23
-
24
- create_table :openid_authorizations do |t|
25
- t.string :code
26
- t.string :nonce
27
- t.string :redirect_uri
28
- t.text :scopes
29
-
30
- t.references :actor
31
- t.references :openid_client
32
- t.datetime :expires_at
33
- t.timestamps
34
-
35
- t.index :code, unique: true
36
- end
37
-
38
- create_table :openid_access_tokens do |t|
39
- t.string :token
40
- t.string :refresh_token
41
- t.string :refreshed_token
42
- t.text :scopes
43
-
44
- t.references :actor, null: true
45
- t.references :openid_client
46
- t.datetime :expires_at
47
- t.datetime :revoked_at
48
- t.timestamps
49
-
50
- t.index :token, unique: true
51
- t.index :refresh_token, unique: true
52
- t.index :refreshed_token, unique: true
53
- end
54
-
55
- create_table :openid_id_tokens do |t|
56
- t.string :nonce
57
- t.datetime :expires_at
58
-
59
- t.references :actor
60
- t.references :openid_client
61
- t.timestamps
62
- end
63
- end
64
- end
@@ -1,8 +0,0 @@
1
- Description:
2
- Explain the generator
3
-
4
- Example:
5
- bin/rails generate install Thing
6
-
7
- This will create:
8
- what/will/it/create
@@ -1,5 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- Masks.configure do |config|
4
- # see https://masks.geiger.to/get-started for configuration options
5
- end
@@ -1,9 +0,0 @@
1
- {
2
- "name": "<%= Rails.application.name %>",
3
- "url": "http://localhost:3000",
4
- "extend": "masks",
5
- "masks": [],
6
- "openid": {
7
- "pairwise_salt": "<%= SecureRandom.uuid %>"
8
- }
9
- }