devise_google_authenticator 0.3.15 → 0.3.16
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
data.tar.gz: !binary |-
|
6
|
-
N2JmNTExODkzYTYxOWZjNjE0OWIwYzI5MDU5Y2M4ZjhmZWIxODNmMA==
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: a91d2025549af93ca8c7a5ed21498896285e1018
|
4
|
+
data.tar.gz: 8bae8a5614a383e8cb6e1ca34fa2762234ecbbe1
|
7
5
|
SHA512:
|
8
|
-
metadata.gz:
|
9
|
-
|
10
|
-
MDFlNjlkNzU0NWQ3ODlmNWUxOTk4Y2M0MGI5ZjdhYWUzMjJmY2U5ZmFmYTQy
|
11
|
-
MmY3YWUzZWMxMTZiYTA1NzI1NjA5ZTdjZjJjYzJjNWE5MGNhODc=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
NWUwMDJjN2I2MzkxMTk4NTAwOTgzZGRjYWVhNmRlOTI3OGU3YTA5NjlmNmU3
|
14
|
-
NzI5Yzk5MGEwMWRjZmExZWFkZmE5MDkxMWI1ZDczMmM5NGVkODI0YzdhMWMx
|
15
|
-
M2U1ODY2MjVkZGU2N2Y3ZGNlNjYzYjIxMWVlNTQ2NTc0YjFhYTM=
|
6
|
+
metadata.gz: edf585b0b9ee16248ddca6ce38510d5874814a3d6c7feec67228d2fa9b2400d710652192732d760d1b4dd8b00b18aed5733be5c8d9ef039a083c11742012d8f9
|
7
|
+
data.tar.gz: 231ba879a35e1e23c3072a94fe92021150e2c88e2d126b448d0f7f11fc0e40b4fe074fba27d36fa063589a9bf7ed603852fbe0fb6fb3aa79671ef0e5c69c002f
|
data/README.rdoc
CHANGED
@@ -7,7 +7,7 @@ This is a devise[https://github.com/plataformatec/devise] extension to allow you
|
|
7
7
|
Add the gem to your Gemfile (don't forget devise too):
|
8
8
|
|
9
9
|
* gem 'devise'
|
10
|
-
* gem 'devise_google_authenticator', '0.3.
|
10
|
+
* gem 'devise_google_authenticator', '0.3.16'
|
11
11
|
|
12
12
|
Don't forget to "bundle install"
|
13
13
|
|
@@ -81,6 +81,7 @@ With this extension enabled, the following is expected behaviour:
|
|
81
81
|
The install generator also installs an english copy of a Devise Google Authenticator i18n file. This can be modified (or used to create other language versions) and is located at: config/locales/devise.google_authenticator.en.yml
|
82
82
|
|
83
83
|
== Changes
|
84
|
+
* Version 0.3.16 - A few bug-fixes. Test-cases are now passing in Ruby 1.9.3 and 2.1.5
|
84
85
|
* Version 0.3.15 - Can now configure whether the displayqr page is displayed during sign-up. Can customise the app's name (thanks Felipe Lima). Require the users to enter the token when enabling or disabling the token (thanks again Felipe Lima). Handle namespaced Devise models (thanks Mikkel Garcia). Ability to set an Issuer within the OTP generation (thanks Sylvain UTARD).
|
85
86
|
* Version 0.3.14 - Users can now generate a new token if they wish. This is available from the displayqr page.
|
86
87
|
* Version 0.3.13 - Merged a feature to allow a qualifier for the Google Authenticator token display. This allows you to specify in your view a qualifier for the name of the OTP when it's enrolled into the Google Authenticator app. Thanks Michael Guymon for the pull.
|
@@ -1,12 +1,12 @@
|
|
1
1
|
class Devise::DisplayqrController < DeviseController
|
2
|
-
prepend_before_filter :authenticate_scope!, :only => [:show
|
2
|
+
prepend_before_filter :authenticate_scope!, :only => [:show, :update, :refresh]
|
3
3
|
|
4
4
|
include Devise::Controllers::Helpers
|
5
5
|
|
6
6
|
# GET /resource/displayqr
|
7
7
|
def show
|
8
8
|
if resource.nil? || resource.gauth_secret.nil?
|
9
|
-
sign_in
|
9
|
+
sign_in resource_class.new, resource
|
10
10
|
redirect_to stored_location_for(scope) || :root
|
11
11
|
else
|
12
12
|
@tmpid = resource.assign_tmp
|
@@ -21,7 +21,7 @@ class Devise::DisplayqrController < DeviseController
|
|
21
21
|
return
|
22
22
|
end
|
23
23
|
|
24
|
-
if resource.set_gauth_enabled(
|
24
|
+
if resource.set_gauth_enabled(params[resource_name]['gauth_enabled'])
|
25
25
|
set_flash_message :notice, (resource.gauth_enabled? ? :enabled : :disabled)
|
26
26
|
sign_in scope, resource, :bypass => true
|
27
27
|
redirect_to stored_location_for(scope) || :root
|
@@ -52,6 +52,7 @@ class Devise::DisplayqrController < DeviseController
|
|
52
52
|
self.resource = send("current_#{resource_name}")
|
53
53
|
end
|
54
54
|
|
55
|
+
# 7/2/15 - Unsure if this is used anymore - @xntrik
|
55
56
|
def resource_params
|
56
57
|
return params.require(resource_name.to_sym).permit(:gauth_enabled) if strong_parameters_enabled?
|
57
58
|
params
|
data/config/locales/en.yml
CHANGED
@@ -19,8 +19,9 @@ module Devise # :nodoc:
|
|
19
19
|
self.gauth_secret
|
20
20
|
end
|
21
21
|
|
22
|
-
def set_gauth_enabled(
|
23
|
-
self.update_without_password(params)
|
22
|
+
def set_gauth_enabled(param)
|
23
|
+
#self.update_without_password(params[gauth_enabled])
|
24
|
+
self.update_attributes(:gauth_enabled => param)
|
24
25
|
end
|
25
26
|
|
26
27
|
def assign_tmp
|
metadata
CHANGED
@@ -1,71 +1,43 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: devise_google_authenticator
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.16
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Christian Frichot
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2015-02-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
|
-
- !ruby/object:Gem::Dependency
|
14
|
-
name: railties
|
15
|
-
requirement: !ruby/object:Gem::Requirement
|
16
|
-
requirements:
|
17
|
-
- - ! '>='
|
18
|
-
- !ruby/object:Gem::Version
|
19
|
-
version: '3.0'
|
20
|
-
type: :runtime
|
21
|
-
prerelease: false
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
23
|
-
requirements:
|
24
|
-
- - ! '>='
|
25
|
-
- !ruby/object:Gem::Version
|
26
|
-
version: '3.0'
|
27
|
-
- !ruby/object:Gem::Dependency
|
28
|
-
name: actionmailer
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
30
|
-
requirements:
|
31
|
-
- - ! '>='
|
32
|
-
- !ruby/object:Gem::Version
|
33
|
-
version: 3.2.12
|
34
|
-
type: :runtime
|
35
|
-
prerelease: false
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
37
|
-
requirements:
|
38
|
-
- - ! '>='
|
39
|
-
- !ruby/object:Gem::Version
|
40
|
-
version: 3.2.12
|
41
13
|
- !ruby/object:Gem::Dependency
|
42
14
|
name: devise
|
43
15
|
requirement: !ruby/object:Gem::Requirement
|
44
16
|
requirements:
|
45
|
-
- -
|
17
|
+
- - "~>"
|
46
18
|
- !ruby/object:Gem::Version
|
47
|
-
version: 3.2
|
19
|
+
version: '3.2'
|
48
20
|
type: :runtime
|
49
21
|
prerelease: false
|
50
22
|
version_requirements: !ruby/object:Gem::Requirement
|
51
23
|
requirements:
|
52
|
-
- -
|
24
|
+
- - "~>"
|
53
25
|
- !ruby/object:Gem::Version
|
54
|
-
version: 3.2
|
26
|
+
version: '3.2'
|
55
27
|
- !ruby/object:Gem::Dependency
|
56
28
|
name: rotp
|
57
29
|
requirement: !ruby/object:Gem::Requirement
|
58
30
|
requirements:
|
59
|
-
- - ~>
|
31
|
+
- - "~>"
|
60
32
|
- !ruby/object:Gem::Version
|
61
|
-
version: 1.
|
33
|
+
version: '1.6'
|
62
34
|
type: :runtime
|
63
35
|
prerelease: false
|
64
36
|
version_requirements: !ruby/object:Gem::Requirement
|
65
37
|
requirements:
|
66
|
-
- - ~>
|
38
|
+
- - "~>"
|
67
39
|
- !ruby/object:Gem::Version
|
68
|
-
version: 1.
|
40
|
+
version: '1.6'
|
69
41
|
description: Devise Google Authenticator Extension, for adding Google's OTP to your
|
70
42
|
Rails apps!
|
71
43
|
email: xntrik@gmail.com
|
@@ -75,6 +47,8 @@ extra_rdoc_files:
|
|
75
47
|
- LICENSE.txt
|
76
48
|
- README.rdoc
|
77
49
|
files:
|
50
|
+
- LICENSE.txt
|
51
|
+
- README.rdoc
|
78
52
|
- app/controllers/devise/checkga_controller.rb
|
79
53
|
- app/controllers/devise/displayqr_controller.rb
|
80
54
|
- app/views/devise/checkga/show.html.erb
|
@@ -83,9 +57,9 @@ files:
|
|
83
57
|
- lib/devise_google_authenticatable/controllers/helpers.rb
|
84
58
|
- lib/devise_google_authenticatable/models/google_authenticatable.rb
|
85
59
|
- lib/devise_google_authenticatable/orm/active_record.rb
|
60
|
+
- lib/devise_google_authenticatable/patches.rb
|
86
61
|
- lib/devise_google_authenticatable/patches/check_ga.rb
|
87
62
|
- lib/devise_google_authenticatable/patches/display_qr.rb
|
88
|
-
- lib/devise_google_authenticatable/patches.rb
|
89
63
|
- lib/devise_google_authenticatable/rails.rb
|
90
64
|
- lib/devise_google_authenticatable/routes.rb
|
91
65
|
- lib/devise_google_authenticatable/schema.rb
|
@@ -96,8 +70,6 @@ files:
|
|
96
70
|
- lib/generators/devise_google_authenticator/install_generator.rb
|
97
71
|
- lib/generators/devise_google_authenticator/views_generator.rb
|
98
72
|
- lib/generators/mongoid/devise_google_authenticator_generator.rb
|
99
|
-
- LICENSE.txt
|
100
|
-
- README.rdoc
|
101
73
|
homepage: http://github.com/AsteriskLabs/devise_google_authenticator
|
102
74
|
licenses:
|
103
75
|
- MIT
|
@@ -108,17 +80,17 @@ require_paths:
|
|
108
80
|
- lib
|
109
81
|
required_ruby_version: !ruby/object:Gem::Requirement
|
110
82
|
requirements:
|
111
|
-
- -
|
83
|
+
- - ">="
|
112
84
|
- !ruby/object:Gem::Version
|
113
85
|
version: 1.9.2
|
114
86
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
115
87
|
requirements:
|
116
|
-
- -
|
88
|
+
- - ">="
|
117
89
|
- !ruby/object:Gem::Version
|
118
90
|
version: '0'
|
119
91
|
requirements: []
|
120
92
|
rubyforge_project:
|
121
|
-
rubygems_version: 2.
|
93
|
+
rubygems_version: 2.4.5
|
122
94
|
signing_key:
|
123
95
|
specification_version: 4
|
124
96
|
summary: Devise Google Authenticator Extension
|