devise-authy 2.2.1 → 2.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/build.yml +30 -0
- data/Appraisals +1 -1
- data/CHANGELOG.md +9 -0
- data/Gemfile +1 -4
- data/LICENSE.txt +1 -1
- data/README.md +4 -12
- data/app/views/devise/enable_authy.html.erb +2 -2
- data/app/views/devise/enable_authy.html.haml +2 -2
- data/app/views/devise/verify_authy.html.erb +4 -4
- data/app/views/devise/verify_authy.html.haml +4 -4
- data/app/views/devise/verify_authy_installation.html.erb +6 -6
- data/app/views/devise/verify_authy_installation.html.haml +6 -6
- data/devise-authy.gemspec +2 -2
- data/gemfiles/rails_5_2.gemfile +0 -1
- data/gemfiles/rails_6.gemfile +0 -1
- data/lib/devise-authy/controllers/helpers.rb +1 -1
- data/lib/devise-authy/controllers/view_helpers.rb +1 -1
- data/lib/devise-authy/version.rb +1 -1
- metadata +9 -9
- data/.travis.yml +0 -17
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 172c6e55ba9cea022fd4428e398af18be1668965361249ee0dff1e6d45ed042f
|
4
|
+
data.tar.gz: 5b8b1cbc2529cfa5b448ae2b3f3b4b7c7759f3b82173d26387e89738bda427c1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3c462910e527dbfdb1ed0fa46295d7cbe783aa7feab75dbd3d30fc07ee016a793f0824262a533e4b0f41ea89f87018be6b8af5cf1205a9d26864fda8b5246d85
|
7
|
+
data.tar.gz: 29039ec4944775c87dcc25c17269409f072cef4db8b054b082242435f5affe786df45a9c16be54f79fe1309a321e0e0150af63e17512110b53437d8294ed5fa6
|
@@ -0,0 +1,30 @@
|
|
1
|
+
name: build
|
2
|
+
|
3
|
+
on: [push, pull_request]
|
4
|
+
|
5
|
+
jobs:
|
6
|
+
test:
|
7
|
+
runs-on: ubuntu-latest
|
8
|
+
strategy:
|
9
|
+
fail-fast: false
|
10
|
+
matrix:
|
11
|
+
ruby: [2.5, 2.6, 2.7, 3.0, head]
|
12
|
+
gemfile: [rails_5_2, rails_6]
|
13
|
+
exclude:
|
14
|
+
- ruby: 3.0
|
15
|
+
gemfile: rails_5_2
|
16
|
+
- ruby: head
|
17
|
+
gemfile: rails_5_2
|
18
|
+
continue-on-error: ${{ endsWith(matrix.ruby, 'head') }}
|
19
|
+
env:
|
20
|
+
BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile
|
21
|
+
steps:
|
22
|
+
- uses: actions/checkout@v2
|
23
|
+
- name: Set up Ruby ${{ matrix.ruby }}
|
24
|
+
uses: ruby/setup-ruby@v1
|
25
|
+
with:
|
26
|
+
ruby-version: ${{ matrix.ruby }}
|
27
|
+
- name: Install dependencies
|
28
|
+
run: bundle install
|
29
|
+
- name: Run tests
|
30
|
+
run: bundle exec rspec
|
data/Appraisals
CHANGED
data/CHANGELOG.md
CHANGED
@@ -9,6 +9,15 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
|
|
9
9
|
|
10
10
|
...
|
11
11
|
|
12
|
+
## [2.3.0] - 2021-01-07
|
13
|
+
|
14
|
+
### Fixed
|
15
|
+
|
16
|
+
- Fixes calls to `I18n.t` with keyword arguments to support Ruby 3.0
|
17
|
+
- Replaces Travis CI with GitHub Actions
|
18
|
+
- Updates webmock development dependency
|
19
|
+
- Removes sdoc from Gemfile
|
20
|
+
|
12
21
|
## [2.2.1] - 2020-10-13
|
13
22
|
|
14
23
|
### Fixed
|
data/Gemfile
CHANGED
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# Authy Devise [![Build Status](https://
|
1
|
+
# Authy Devise [![Build Status](https://github.com/twilio/authy-devise/workflows/build/badge.svg)](https://github.com/twilio/authy-devise/actions)
|
2
2
|
|
3
3
|
This is a [Devise](https://github.com/plataformatec/devise) extension to add [Two-Factor Authentication with Authy](https://www.twilio.com/docs/authy) to your Rails application.
|
4
4
|
|
@@ -227,20 +227,12 @@ end
|
|
227
227
|
|
228
228
|
## Running Tests
|
229
229
|
|
230
|
-
|
231
|
-
|
232
|
-
```bash
|
233
|
-
$ cd spec/rails-app
|
234
|
-
$ bundle install
|
235
|
-
$ RAILS_ENV=test bundle exec rake db:migrate
|
236
|
-
```
|
237
|
-
|
238
|
-
Now on the project root run the following commands:
|
230
|
+
Run the following command:
|
239
231
|
|
240
232
|
```bash
|
241
|
-
$ bundle exec rspec
|
233
|
+
$ bundle exec rspec
|
242
234
|
```
|
243
235
|
|
244
236
|
## Copyright
|
245
237
|
|
246
|
-
Copyright (c) 2012-
|
238
|
+
Copyright (c) 2012-2021 Authy Inc. See LICENSE.txt for further details.
|
@@ -1,7 +1,7 @@
|
|
1
|
-
<h2><%= I18n.t('authy_register_title',
|
1
|
+
<h2><%= I18n.t('authy_register_title', scope: 'devise') %></h2>
|
2
2
|
|
3
3
|
<%= enable_authy_form do %>
|
4
4
|
<%= text_field_tag :country_code, '', :autocomplete => :off, :placeholder => I18n.t('devise.country'), :id => "authy-countries"%>
|
5
5
|
<%= text_field_tag :cellphone, '', :autocomplete => :off, :placeholder => I18n.t('devise.cellphone'), :id => "authy-cellphone"%>
|
6
|
-
<p><%= submit_tag I18n.t('enable_authy',
|
6
|
+
<p><%= submit_tag I18n.t('enable_authy', scope: 'devise') %></p>
|
7
7
|
<% end %>
|
@@ -1,5 +1,5 @@
|
|
1
|
-
%h2= I18n.t('authy_register_title',
|
1
|
+
%h2= I18n.t('authy_register_title', scope: 'devise')
|
2
2
|
= enable_authy_form do
|
3
3
|
= text_field_tag :country_code, '', :autocomplete => :off, :placeholder => I18n.t('devise.country'), :id => "authy-countries"
|
4
4
|
= text_field_tag :cellphone, '', :autocomplete => :off, :placeholder => I18n.t('devise.cellphone'), :id => "authy-cellphone"
|
5
|
-
%p= submit_tag I18n.t('enable_authy',
|
5
|
+
%p= submit_tag I18n.t('enable_authy', scope: 'devise')
|
@@ -1,14 +1,14 @@
|
|
1
1
|
<h2>
|
2
|
-
<%= I18n.t('submit_token_title',
|
2
|
+
<%= I18n.t('submit_token_title', scope: 'devise') %>
|
3
3
|
</h2>
|
4
4
|
|
5
5
|
<%= verify_authy_form do %>
|
6
|
-
<legend><%= I18n.t('submit_token_title',
|
6
|
+
<legend><%= I18n.t('submit_token_title', scope: 'devise') %></legend>
|
7
7
|
<%= label_tag 'authy-token' %>
|
8
8
|
<%= text_field_tag :token, "", :autocomplete => "one-time-code", :inputmode => "numeric", :pattern => "[0-9]*", :id => 'authy-token' %>
|
9
9
|
<label>
|
10
10
|
<%= check_box_tag :remember_device %>
|
11
|
-
<span><%= I18n.t('remember_device',
|
11
|
+
<span><%= I18n.t('remember_device', scope: 'devise') %></span>
|
12
12
|
</label>
|
13
13
|
|
14
14
|
<!-- Help tooltip -->
|
@@ -17,7 +17,7 @@
|
|
17
17
|
<!-- <%= link_to '?', '#', :id => 'authy-help' %> -->
|
18
18
|
|
19
19
|
<%= authy_request_sms_link %>
|
20
|
-
<%= submit_tag I18n.t('submit_token',
|
20
|
+
<%= submit_tag I18n.t('submit_token', scope: 'devise'), :class => 'btn' %>
|
21
21
|
<% end %>
|
22
22
|
|
23
23
|
<% if @onetouch_uuid %>
|
@@ -1,13 +1,13 @@
|
|
1
|
-
%h2= I18n.t('authy_register_title',
|
1
|
+
%h2= I18n.t('authy_register_title', scope: 'devise')
|
2
2
|
|
3
3
|
= verify_authy_form do
|
4
|
-
%legend= I18n.t('submit_token_title',
|
4
|
+
%legend= I18n.t('submit_token_title', scope: 'devise')
|
5
5
|
= hidden_field_tag :"#{resource_name}_id", @resource.id
|
6
6
|
= label_tag 'authy-token'
|
7
7
|
= text_field_tag :token, "", :autocomplete => "one-time-code", :inputmode => "numeric", :pattern => "[0-9]*", :id => 'authy-token'
|
8
8
|
%label
|
9
9
|
= check_box_tag :remember_device
|
10
|
-
%span= I18n.t('remember_device',
|
10
|
+
%span= I18n.t('remember_device', scope: 'devise')
|
11
11
|
|
12
12
|
/ Help Tooltip
|
13
13
|
/ You need to configure a help message.
|
@@ -15,7 +15,7 @@
|
|
15
15
|
/ = link_to '?', '#', :id => 'authy-help', :'data-message' => 'a message'
|
16
16
|
|
17
17
|
= authy_request_sms_link
|
18
|
-
= submit_tag I18n.t('submit_token',
|
18
|
+
= submit_tag I18n.t('submit_token', scope: 'devise'), :class => 'btn'
|
19
19
|
|
20
20
|
- if @onetouch_uuid
|
21
21
|
:javascript
|
@@ -1,18 +1,18 @@
|
|
1
|
-
<h2><%= I18n.t('authy_verify_installation_title',
|
1
|
+
<h2><%= I18n.t('authy_verify_installation_title', scope: 'devise') %></h2>
|
2
2
|
|
3
3
|
<% if @authy_qr_code %>
|
4
|
-
<%= image_tag @authy_qr_code, :size => '256x256', :alt => I18n.t('authy_qr_code_alt',
|
5
|
-
<p><%= I18n.t('authy_qr_code_instructions',
|
4
|
+
<%= image_tag @authy_qr_code, :size => '256x256', :alt => I18n.t('authy_qr_code_alt', scope: 'devise') %>
|
5
|
+
<p><%= I18n.t('authy_qr_code_instructions', scope: 'devise') %></p>
|
6
6
|
<% end %>
|
7
7
|
|
8
8
|
<%= verify_authy_installation_form do %>
|
9
|
-
<legend><%= I18n.t('submit_token_title',
|
9
|
+
<legend><%= I18n.t('submit_token_title', scope: 'devise') %></legend>
|
10
10
|
<%= label_tag :token %>
|
11
11
|
<%= text_field_tag :token, "", :autocomplete => "one-time-code", :inputmode => "numeric", :pattern => "[0-9]*", :id => 'authy-token' %>
|
12
12
|
<label>
|
13
13
|
<%= check_box_tag :remember_device %>
|
14
|
-
<span><%= I18n.t('remember_device',
|
14
|
+
<span><%= I18n.t('remember_device', scope: 'devise') %></span>
|
15
15
|
</label>
|
16
16
|
<%= authy_request_sms_link %>
|
17
|
-
<%= submit_tag I18n.t('enable_my_account',
|
17
|
+
<%= submit_tag I18n.t('enable_my_account', scope: 'devise'), :class => 'btn' %>
|
18
18
|
<% end %>
|
@@ -1,16 +1,16 @@
|
|
1
|
-
%h2= I18n.t('authy_verify_installation_title',
|
1
|
+
%h2= I18n.t('authy_verify_installation_title', scope: 'devise')
|
2
2
|
|
3
3
|
- if @authy_qr_code
|
4
|
-
= image_tag @authy_qr_code, :size => '256x256', :alt => I18n.t('authy_qr_code_alt',
|
5
|
-
%p= I18n.t('authy_qr_code_instructions',
|
4
|
+
= image_tag @authy_qr_code, :size => '256x256', :alt => I18n.t('authy_qr_code_alt', scope: 'devise')
|
5
|
+
%p= I18n.t('authy_qr_code_instructions', scope: 'devise')
|
6
6
|
|
7
7
|
= verify_authy_installation_form do
|
8
|
-
%legend= I18n.t('submit_token_title',
|
8
|
+
%legend= I18n.t('submit_token_title', scope: 'devise')
|
9
9
|
= label_tag :token
|
10
10
|
= text_field_tag :token, "", :autocomplete => "one-time-code", :inputmode => "numeric", :pattern => "[0-9]*", :id => 'authy-token'
|
11
11
|
%label
|
12
12
|
= check_box_tag :remember_device
|
13
|
-
%span= I18n.t('remember_device',
|
13
|
+
%span= I18n.t('remember_device', scope: 'devise')
|
14
14
|
= authy_request_sms_link
|
15
|
-
= submit_tag I18n.t('enable_my_account',
|
15
|
+
= submit_tag I18n.t('enable_my_account', scope: 'devise'), :class => 'btn'
|
16
16
|
|
data/devise-authy.gemspec
CHANGED
@@ -29,7 +29,7 @@ Gem::Specification.new do |spec|
|
|
29
29
|
spec.require_paths = ["lib"]
|
30
30
|
|
31
31
|
spec.add_dependency "devise", ">= 4.0.0"
|
32
|
-
spec.add_dependency "authy", "
|
32
|
+
spec.add_dependency "authy", "~> 3.0"
|
33
33
|
|
34
34
|
spec.add_development_dependency "appraisal", "~> 2.2"
|
35
35
|
spec.add_development_dependency "bundler", ">= 1.16"
|
@@ -41,7 +41,7 @@ Gem::Specification.new do |spec|
|
|
41
41
|
spec.add_development_dependency "yard", "~> 0.9.11"
|
42
42
|
spec.add_development_dependency "rdoc", "~> 4.3.0"
|
43
43
|
spec.add_development_dependency "simplecov", "~> 0.17.1"
|
44
|
-
spec.add_development_dependency "webmock", "~> 3.
|
44
|
+
spec.add_development_dependency "webmock", "~> 3.11.0"
|
45
45
|
spec.add_development_dependency "rails", ">= 5"
|
46
46
|
spec.add_development_dependency "sqlite3"
|
47
47
|
spec.add_development_dependency "generator_spec"
|
data/gemfiles/rails_5_2.gemfile
CHANGED
data/gemfiles/rails_6.gemfile
CHANGED
@@ -77,7 +77,7 @@ module DeviseAuthy
|
|
77
77
|
end
|
78
78
|
|
79
79
|
def send_one_touch_request(authy_id)
|
80
|
-
Authy::OneTouch.send_approval_request(id: authy_id, message: I18n.t('request_to_login',
|
80
|
+
Authy::OneTouch.send_approval_request(id: authy_id, message: I18n.t('request_to_login', scope: 'devise'))
|
81
81
|
end
|
82
82
|
|
83
83
|
def record_authy_authentication
|
@@ -3,7 +3,7 @@ module DeviseAuthy
|
|
3
3
|
module Helpers
|
4
4
|
def authy_request_phone_call_link(opts = {})
|
5
5
|
title = opts.delete(:title) do
|
6
|
-
I18n.t('request_phone_call',
|
6
|
+
I18n.t('request_phone_call', scope: 'devise')
|
7
7
|
end
|
8
8
|
opts = {
|
9
9
|
:id => "authy-request-phone-call-link",
|
data/lib/devise-authy/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: devise-authy
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Authy Inc.
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-01-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: devise
|
@@ -28,16 +28,16 @@ dependencies:
|
|
28
28
|
name: authy
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
31
|
+
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version:
|
33
|
+
version: '3.0'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - "
|
38
|
+
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version:
|
40
|
+
version: '3.0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: appraisal
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -184,14 +184,14 @@ dependencies:
|
|
184
184
|
requirements:
|
185
185
|
- - "~>"
|
186
186
|
- !ruby/object:Gem::Version
|
187
|
-
version: 3.
|
187
|
+
version: 3.11.0
|
188
188
|
type: :development
|
189
189
|
prerelease: false
|
190
190
|
version_requirements: !ruby/object:Gem::Requirement
|
191
191
|
requirements:
|
192
192
|
- - "~>"
|
193
193
|
- !ruby/object:Gem::Version
|
194
|
-
version: 3.
|
194
|
+
version: 3.11.0
|
195
195
|
- !ruby/object:Gem::Dependency
|
196
196
|
name: rails
|
197
197
|
requirement: !ruby/object:Gem::Requirement
|
@@ -270,9 +270,9 @@ extensions: []
|
|
270
270
|
extra_rdoc_files: []
|
271
271
|
files:
|
272
272
|
- ".document"
|
273
|
+
- ".github/workflows/build.yml"
|
273
274
|
- ".gitignore"
|
274
275
|
- ".rspec"
|
275
|
-
- ".travis.yml"
|
276
276
|
- Appraisals
|
277
277
|
- CHANGELOG.md
|
278
278
|
- Gemfile
|
data/.travis.yml
DELETED
@@ -1,17 +0,0 @@
|
|
1
|
-
language: ruby
|
2
|
-
script: bundle exec rspec
|
3
|
-
rvm:
|
4
|
-
- 2.7
|
5
|
-
- 2.6
|
6
|
-
- 2.5
|
7
|
-
- 2.4
|
8
|
-
- ruby-head
|
9
|
-
gemfile:
|
10
|
-
- gemfiles/rails_5_2.gemfile
|
11
|
-
- gemfiles/rails_6.gemfile
|
12
|
-
matrix:
|
13
|
-
allow_failures:
|
14
|
-
- rvm: ruby-head
|
15
|
-
exclude:
|
16
|
-
- rvm: 2.4
|
17
|
-
gemfile: gemfiles/rails_6.gemfile
|