google_sign_in 1.2.0 → 1.2.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5831caee2b3640fd7ea360cffe55c7941066ace8c22e324ed389215c0cd7c65a
4
- data.tar.gz: 548b00fa1ad0739b039bed3ee80adfa2ee938a841737b5daef5d8eb5a5e11258
3
+ metadata.gz: 07ffe2df555e62583212eeed44495dad288e37609a46c4eb1f4717aedb11f4c9
4
+ data.tar.gz: b4eff8b60ac9cfdb32c835bf0780722f87fb34cfd4b0673a57bdfe4708841569
5
5
  SHA512:
6
- metadata.gz: 5f4d62b9a5b2a3ea7d56b643f53ce4f4ee14cf621c4ca54c68d8da546dd2a38f5844ba8516f63e33fab4d69e716791863b4075adedd2dbfcbd7e638c58faf26c
7
- data.tar.gz: d9e6e95a67eaf3ac07fc06361ede928f9e046e04f37806e0f63d937b5ff21db2380597aa9bf438dc426053586aa51cef15e2f904b97ee0639753bcb1c818e389
6
+ metadata.gz: 5fd9e9b40717cf051753ec5bf737281d33f0e3ba6914fbd364e9c8c1d316c9a21a8d0cdead93df94e1a674aa6d6774e3ec9608b6427e56e70021d6da199a7f79
7
+ data.tar.gz: 10c98f8dbb827cfeca28f59b9857d86bb5e6f3f0122e4f1b5dc64c4b29b663b2d01520893d41a18af94bf6cc6cc6e5d83e476be5554f27b08450f382e3f7a16e
data/.travis.yml CHANGED
@@ -6,8 +6,6 @@ cache: bundler
6
6
  before_install: gem update --system && gem install bundler -v 1.17.3
7
7
 
8
8
  rvm:
9
- - 2.3
10
- - 2.4
11
9
  - 2.5
12
10
  - 2.6
13
11
  - ruby-head
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- google_sign_in (1.1.2)
4
+ google_sign_in (1.2.0)
5
5
  google-id-token (>= 1.4.0)
6
6
  oauth2 (>= 1.4.0)
7
7
  rails (>= 5.2.0)
@@ -9,121 +9,140 @@ PATH
9
9
  GEM
10
10
  remote: https://rubygems.org/
11
11
  specs:
12
- actioncable (5.2.1)
13
- actionpack (= 5.2.1)
12
+ actioncable (6.0.0)
13
+ actionpack (= 6.0.0)
14
14
  nio4r (~> 2.0)
15
15
  websocket-driver (>= 0.6.1)
16
- actionmailer (5.2.1)
17
- actionpack (= 5.2.1)
18
- actionview (= 5.2.1)
19
- activejob (= 5.2.1)
16
+ actionmailbox (6.0.0)
17
+ actionpack (= 6.0.0)
18
+ activejob (= 6.0.0)
19
+ activerecord (= 6.0.0)
20
+ activestorage (= 6.0.0)
21
+ activesupport (= 6.0.0)
22
+ mail (>= 2.7.1)
23
+ actionmailer (6.0.0)
24
+ actionpack (= 6.0.0)
25
+ actionview (= 6.0.0)
26
+ activejob (= 6.0.0)
20
27
  mail (~> 2.5, >= 2.5.4)
21
28
  rails-dom-testing (~> 2.0)
22
- actionpack (5.2.1)
23
- actionview (= 5.2.1)
24
- activesupport (= 5.2.1)
29
+ actionpack (6.0.0)
30
+ actionview (= 6.0.0)
31
+ activesupport (= 6.0.0)
25
32
  rack (~> 2.0)
26
33
  rack-test (>= 0.6.3)
27
34
  rails-dom-testing (~> 2.0)
28
- rails-html-sanitizer (~> 1.0, >= 1.0.2)
29
- actionview (5.2.1)
30
- activesupport (= 5.2.1)
35
+ rails-html-sanitizer (~> 1.0, >= 1.2.0)
36
+ actiontext (6.0.0)
37
+ actionpack (= 6.0.0)
38
+ activerecord (= 6.0.0)
39
+ activestorage (= 6.0.0)
40
+ activesupport (= 6.0.0)
41
+ nokogiri (>= 1.8.5)
42
+ actionview (6.0.0)
43
+ activesupport (= 6.0.0)
31
44
  builder (~> 3.1)
32
45
  erubi (~> 1.4)
33
46
  rails-dom-testing (~> 2.0)
34
- rails-html-sanitizer (~> 1.0, >= 1.0.3)
35
- activejob (5.2.1)
36
- activesupport (= 5.2.1)
47
+ rails-html-sanitizer (~> 1.1, >= 1.2.0)
48
+ activejob (6.0.0)
49
+ activesupport (= 6.0.0)
37
50
  globalid (>= 0.3.6)
38
- activemodel (5.2.1)
39
- activesupport (= 5.2.1)
40
- activerecord (5.2.1)
41
- activemodel (= 5.2.1)
42
- activesupport (= 5.2.1)
43
- arel (>= 9.0)
44
- activestorage (5.2.1)
45
- actionpack (= 5.2.1)
46
- activerecord (= 5.2.1)
51
+ activemodel (6.0.0)
52
+ activesupport (= 6.0.0)
53
+ activerecord (6.0.0)
54
+ activemodel (= 6.0.0)
55
+ activesupport (= 6.0.0)
56
+ activestorage (6.0.0)
57
+ actionpack (= 6.0.0)
58
+ activejob (= 6.0.0)
59
+ activerecord (= 6.0.0)
47
60
  marcel (~> 0.3.1)
48
- activesupport (5.2.1)
61
+ activesupport (6.0.0)
49
62
  concurrent-ruby (~> 1.0, >= 1.0.2)
50
63
  i18n (>= 0.7, < 2)
51
64
  minitest (~> 5.1)
52
65
  tzinfo (~> 1.1)
53
- addressable (2.5.2)
54
- public_suffix (>= 2.0.2, < 4.0)
55
- arel (9.0.0)
66
+ zeitwerk (~> 2.1, >= 2.1.8)
67
+ addressable (2.8.0)
68
+ public_suffix (>= 2.0.2, < 5.0)
56
69
  builder (3.2.3)
57
- byebug (9.1.0)
58
- concurrent-ruby (1.0.5)
70
+ byebug (11.0.1)
71
+ concurrent-ruby (1.1.5)
59
72
  crack (0.4.3)
60
73
  safe_yaml (~> 1.0.0)
61
74
  crass (1.0.4)
62
- erubi (1.7.1)
63
- faraday (0.15.3)
75
+ erubi (1.9.0)
76
+ faraday (0.16.2)
64
77
  multipart-post (>= 1.2, < 3)
65
- globalid (0.4.1)
78
+ globalid (0.4.2)
66
79
  activesupport (>= 4.2.0)
67
80
  google-id-token (1.4.2)
68
81
  jwt (>= 1)
69
- hashdiff (0.3.7)
70
- i18n (1.1.1)
82
+ hashdiff (1.0.0)
83
+ i18n (1.6.0)
71
84
  concurrent-ruby (~> 1.0)
72
- jwt (1.5.6)
73
- loofah (2.2.2)
85
+ jwt (2.2.1)
86
+ loofah (2.3.0)
74
87
  crass (~> 1.0.2)
75
88
  nokogiri (>= 1.5.9)
76
89
  mail (2.7.1)
77
90
  mini_mime (>= 0.1.1)
78
91
  marcel (0.3.3)
79
92
  mimemagic (~> 0.3.2)
80
- method_source (0.9.0)
81
- mimemagic (0.3.2)
82
- mini_mime (1.0.1)
83
- mini_portile2 (2.4.0)
84
- minitest (5.11.3)
93
+ method_source (0.9.2)
94
+ mimemagic (0.3.10)
95
+ nokogiri (~> 1)
96
+ rake
97
+ mini_mime (1.0.2)
98
+ mini_portile2 (2.6.1)
99
+ minitest (5.14.4)
85
100
  multi_json (1.13.1)
86
101
  multi_xml (0.6.0)
87
- multipart-post (2.0.0)
88
- nio4r (2.3.1)
89
- nokogiri (1.10.8)
90
- mini_portile2 (~> 2.4.0)
91
- oauth2 (1.4.1)
92
- faraday (>= 0.8, < 0.16.0)
102
+ multipart-post (2.1.1)
103
+ nio4r (2.5.2)
104
+ nokogiri (1.12.5)
105
+ mini_portile2 (~> 2.6.1)
106
+ racc (~> 1.4)
107
+ oauth2 (1.4.2)
108
+ faraday (>= 0.8, < 2.0)
93
109
  jwt (>= 1.0, < 3.0)
94
110
  multi_json (~> 1.3)
95
111
  multi_xml (~> 0.5)
96
112
  rack (>= 1.2, < 3)
97
- public_suffix (3.0.3)
98
- rack (2.0.5)
113
+ public_suffix (4.0.1)
114
+ racc (1.5.2)
115
+ rack (2.0.7)
99
116
  rack-test (1.1.0)
100
117
  rack (>= 1.0, < 3)
101
- rails (5.2.1)
102
- actioncable (= 5.2.1)
103
- actionmailer (= 5.2.1)
104
- actionpack (= 5.2.1)
105
- actionview (= 5.2.1)
106
- activejob (= 5.2.1)
107
- activemodel (= 5.2.1)
108
- activerecord (= 5.2.1)
109
- activestorage (= 5.2.1)
110
- activesupport (= 5.2.1)
118
+ rails (6.0.0)
119
+ actioncable (= 6.0.0)
120
+ actionmailbox (= 6.0.0)
121
+ actionmailer (= 6.0.0)
122
+ actionpack (= 6.0.0)
123
+ actiontext (= 6.0.0)
124
+ actionview (= 6.0.0)
125
+ activejob (= 6.0.0)
126
+ activemodel (= 6.0.0)
127
+ activerecord (= 6.0.0)
128
+ activestorage (= 6.0.0)
129
+ activesupport (= 6.0.0)
111
130
  bundler (>= 1.3.0)
112
- railties (= 5.2.1)
131
+ railties (= 6.0.0)
113
132
  sprockets-rails (>= 2.0.0)
114
133
  rails-dom-testing (2.0.3)
115
134
  activesupport (>= 4.2.0)
116
135
  nokogiri (>= 1.6)
117
- rails-html-sanitizer (1.0.4)
136
+ rails-html-sanitizer (1.2.0)
118
137
  loofah (~> 2.2, >= 2.2.2)
119
- railties (5.2.1)
120
- actionpack (= 5.2.1)
121
- activesupport (= 5.2.1)
138
+ railties (6.0.0)
139
+ actionpack (= 6.0.0)
140
+ activesupport (= 6.0.0)
122
141
  method_source
123
142
  rake (>= 0.8.7)
124
- thor (>= 0.19.0, < 2.0)
125
- rake (12.3.3)
126
- safe_yaml (1.0.4)
143
+ thor (>= 0.20.3, < 2.0)
144
+ rake (13.0.0)
145
+ safe_yaml (1.0.5)
127
146
  sprockets (3.7.2)
128
147
  concurrent-ruby (~> 1.0)
129
148
  rack (> 1, < 3)
@@ -131,17 +150,18 @@ GEM
131
150
  actionpack (>= 4.0)
132
151
  activesupport (>= 4.0)
133
152
  sprockets (>= 3.0.0)
134
- thor (0.20.0)
153
+ thor (0.20.3)
135
154
  thread_safe (0.3.6)
136
155
  tzinfo (1.2.5)
137
156
  thread_safe (~> 0.1)
138
- webmock (3.4.2)
157
+ webmock (3.7.6)
139
158
  addressable (>= 2.3.6)
140
159
  crack (>= 0.3.2)
141
- hashdiff
142
- websocket-driver (0.7.0)
160
+ hashdiff (>= 0.4.0, < 2.0.0)
161
+ websocket-driver (0.7.1)
143
162
  websocket-extensions (>= 0.1.0)
144
- websocket-extensions (0.1.3)
163
+ websocket-extensions (0.1.4)
164
+ zeitwerk (2.1.10)
145
165
 
146
166
  PLATFORMS
147
167
  ruby
@@ -155,4 +175,4 @@ DEPENDENCIES
155
175
  webmock (>= 3.4.2)
156
176
 
157
177
  BUNDLED WITH
158
- 1.17.2
178
+ 1.17.3
data/README.md CHANGED
@@ -159,13 +159,16 @@ information contained in the token via the following instance methods:
159
159
 
160
160
  * `given_name`: The user's given name.
161
161
 
162
- * `last_name`: The user's last name.
162
+ * `family_name`: The user's last name.
163
163
 
164
164
 
165
165
  ## Security
166
166
 
167
167
  For information on our security response procedure, see [SECURITY.md](SECURITY.md).
168
168
 
169
+ ## Maintenance
170
+
171
+ Short of patching critical security issues, this gem is now considered done, and will not see any further feature development or minor bug fixes. Feel free to fork this work under the MIT license and continue the feature development under a different name.
169
172
 
170
173
  ## License
171
174
 
@@ -5,7 +5,7 @@ class GoogleSignIn::AuthorizationsController < GoogleSignIn::BaseController
5
5
 
6
6
  def create
7
7
  redirect_to login_url(scope: 'openid profile email', state: state),
8
- flash: { proceed_to: params.require(:proceed_to), state: state }
8
+ allow_other_host: true, flash: { proceed_to: params.require(:proceed_to), state: state }
9
9
  end
10
10
 
11
11
  private
@@ -1,4 +1,4 @@
1
- require_dependency 'google_sign_in/redirect_protector'
1
+ require 'google_sign_in/redirect_protector'
2
2
 
3
3
  class GoogleSignIn::CallbacksController < GoogleSignIn::BaseController
4
4
  def show
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'google_sign_in'
3
- s.version = '1.2.0'
3
+ s.version = '1.2.1'
4
4
  s.authors = ['David Heinemeier Hansson', 'George Claghorn']
5
5
  s.email = ['david@basecamp.com', 'george@basecamp.com']
6
6
  s.summary = 'Sign in (or up) with Google for Rails applications'
@@ -13,10 +13,8 @@ module GoogleSignIn
13
13
  end
14
14
  end
15
15
 
16
- initializer 'google_sign_in.helpers' do
17
- ActiveSupport.on_load :action_controller_base do
18
- helper GoogleSignIn::Engine.helpers
19
- end
16
+ config.to_prepare do
17
+ ActionController::Base.helper GoogleSignIn::Engine.helpers
20
18
  end
21
19
 
22
20
  initializer 'google_sign_in.mount' do |app|
@@ -10,7 +10,7 @@ Bundler.require(*Rails.groups)
10
10
  module Dummy
11
11
  class Application < Rails::Application
12
12
  # Initialize configuration defaults for originally generated Rails version.
13
- config.load_defaults 5.2
13
+ config.load_defaults 6.0
14
14
 
15
15
  # Settings in config/environments/* take precedence over those specified here.
16
16
  # Application configuration can go into files in config/initializers
@@ -4,7 +4,6 @@ class GoogleSignIn::ButtonHelperTest < ActionView::TestCase
4
4
  test "generating a login button with text content" do
5
5
  assert_dom_equal <<-HTML, google_sign_in_button("Log in with Google", proceed_to: "https://www.example.com/login")
6
6
  <form action="/google_sign_in/authorization" accept-charset="UTF-8" method="post">
7
- <input name="utf8" type="hidden" value="&#x2713;" />
8
7
  <input name="proceed_to" type="hidden" value="https://www.example.com/login" />
9
8
  <button type="submit">Log in with Google</button>
10
9
  </form>
@@ -14,7 +13,6 @@ class GoogleSignIn::ButtonHelperTest < ActionView::TestCase
14
13
  test "generating a login button with HTML content" do
15
14
  assert_dom_equal <<-HTML, google_sign_in_button(proceed_to: "https://www.example.com/login") { image_tag("google.png") }
16
15
  <form action="/google_sign_in/authorization" accept-charset="UTF-8" method="post">
17
- <input name="utf8" type="hidden" value="&#x2713;" />
18
16
  <input name="proceed_to" type="hidden" value="https://www.example.com/login" />
19
17
  <button type="submit"><img src="/images/google.png"></button>
20
18
  </form>
@@ -27,7 +25,6 @@ class GoogleSignIn::ButtonHelperTest < ActionView::TestCase
27
25
 
28
26
  assert_dom_equal <<-HTML, button
29
27
  <form action="/google_sign_in/authorization" accept-charset="UTF-8" method="post">
30
- <input name="utf8" type="hidden" value="&#x2713;" />
31
28
  <input name="proceed_to" type="hidden" value="https://www.example.com/login" />
32
29
  <button type="submit" class="login-button" data-disable-with="Loading Google login…">Log in with Google</button>
33
30
  </form>
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: google_sign_in
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Heinemeier Hansson
8
8
  - George Claghorn
9
- autorequire:
9
+ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2020-05-23 00:00:00.000000000 Z
12
+ date: 2021-12-06 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rails
@@ -95,7 +95,7 @@ dependencies:
95
95
  - - ">="
96
96
  - !ruby/object:Gem::Version
97
97
  version: 3.4.2
98
- description:
98
+ description:
99
99
  email:
100
100
  - david@basecamp.com
101
101
  - george@basecamp.com
@@ -197,7 +197,7 @@ homepage: https://github.com/basecamp/google_sign_in
197
197
  licenses:
198
198
  - MIT
199
199
  metadata: {}
200
- post_install_message:
200
+ post_install_message:
201
201
  rdoc_options: []
202
202
  require_paths:
203
203
  - lib
@@ -212,8 +212,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
212
212
  - !ruby/object:Gem::Version
213
213
  version: '0'
214
214
  requirements: []
215
- rubygems_version: 3.1.2
216
- signing_key:
215
+ rubygems_version: 3.2.22
216
+ signing_key:
217
217
  specification_version: 4
218
218
  summary: Sign in (or up) with Google for Rails applications
219
219
  test_files: