firebase-admin 0.1.2 → 0.1.6

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: a4c4443edc00425f17776c80d7ac2891f9910facd4139229a8fafdcee89c4fe9
4
- data.tar.gz: 27af55f9e6a327a65d993140210caaf704c014eb074c5f255a93e32b407944a5
3
+ metadata.gz: 9693687c6c5f815855662c55897a1f9fc1b44f9e21b2887fa3f843f630613959
4
+ data.tar.gz: 1ea223a2eb707350eee44de4b46d115537d961986bc6b7bc513cbe4eba56d6ab
5
5
  SHA512:
6
- metadata.gz: 503314268323bac0314143979cecf76c887d95381df7ed02c9b7fe4979a8ef74d7c961a9bbc3e211134a4c20bec3a8ea88f4ab455d1291015b7269563fb54f3a
7
- data.tar.gz: 0c47a474b014ebadb40110e4ba4cb285424949f5d49fac7eeb07623bd32690be905d093755fb93ca365cb9688b35b819359a0a78a258f8053fbb234b07416e31
6
+ metadata.gz: c57e26695001a4be8cdec4a8850bfa6b0e49e5b33215c7163612b31805d28cc936e771f65333af1b0d219a706fe2ccb8fe65d952ed55a10a1d9929d868486154
7
+ data.tar.gz: 2d35835dccdddb45c97604f11bf79c24f03c714e96b1d3ec969bac8320499ed126f210b54e1ae02e966d93d85ec59f301da3bbb05b84e9de8eb6a07450f87fcf
data/Gemfile.lock CHANGED
@@ -1,43 +1,57 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- firebase-admin (0.1.2)
4
+ firebase-admin (0.1.6)
5
5
  addressable (~> 2.7)
6
6
  faraday (~> 1.3)
7
7
  faraday_middleware (~> 1.0)
8
8
  hashie (~> 4.1)
9
- jwt (~> 2.2.2)
9
+ jwt (>= 2.2)
10
10
  multi_json (~> 1.15)
11
11
 
12
12
  GEM
13
13
  remote: https://rubygems.org/
14
14
  specs:
15
- addressable (2.7.0)
15
+ addressable (2.8.0)
16
16
  public_suffix (>= 2.0.2, < 5.0)
17
17
  ast (2.4.2)
18
18
  crack (0.4.5)
19
19
  rexml
20
20
  diff-lcs (1.4.4)
21
- faraday (1.3.0)
21
+ faraday (1.8.0)
22
+ faraday-em_http (~> 1.0)
23
+ faraday-em_synchrony (~> 1.0)
24
+ faraday-excon (~> 1.1)
25
+ faraday-httpclient (~> 1.0.1)
22
26
  faraday-net_http (~> 1.0)
27
+ faraday-net_http_persistent (~> 1.1)
28
+ faraday-patron (~> 1.0)
29
+ faraday-rack (~> 1.0)
23
30
  multipart-post (>= 1.2, < 3)
24
- ruby2_keywords
31
+ ruby2_keywords (>= 0.0.4)
32
+ faraday-em_http (1.0.0)
33
+ faraday-em_synchrony (1.0.0)
34
+ faraday-excon (1.1.0)
35
+ faraday-httpclient (1.0.1)
25
36
  faraday-net_http (1.0.1)
26
- faraday_middleware (1.0.0)
37
+ faraday-net_http_persistent (1.2.0)
38
+ faraday-patron (1.0.0)
39
+ faraday-rack (1.0.0)
40
+ faraday_middleware (1.2.0)
27
41
  faraday (~> 1.0)
28
42
  hashdiff (1.0.1)
29
43
  hashie (4.1.0)
30
- jwt (2.2.2)
44
+ jwt (2.3.0)
31
45
  multi_json (1.15.0)
32
46
  multipart-post (2.1.1)
33
- parallel (1.20.1)
34
- parser (3.0.0.0)
47
+ parallel (1.21.0)
48
+ parser (3.0.3.1)
35
49
  ast (~> 2.4.1)
36
50
  public_suffix (4.0.6)
37
51
  rainbow (3.0.0)
38
- rake (13.0.3)
39
- regexp_parser (2.0.3)
40
- rexml (3.2.4)
52
+ rake (13.0.6)
53
+ regexp_parser (2.2.0)
54
+ rexml (3.2.5)
41
55
  rspec (3.10.0)
42
56
  rspec-core (~> 3.10.0)
43
57
  rspec-expectations (~> 3.10.0)
@@ -50,23 +64,23 @@ GEM
50
64
  rspec-mocks (3.10.2)
51
65
  diff-lcs (>= 1.2.0, < 2.0)
52
66
  rspec-support (~> 3.10.0)
53
- rspec-support (3.10.2)
54
- rubocop (1.9.0)
67
+ rspec-support (3.10.3)
68
+ rubocop (1.23.0)
55
69
  parallel (~> 1.10)
56
70
  parser (>= 3.0.0.0)
57
71
  rainbow (>= 2.2.2, < 4.0)
58
72
  regexp_parser (>= 1.8, < 3.0)
59
73
  rexml
60
- rubocop-ast (>= 1.2.0, < 2.0)
74
+ rubocop-ast (>= 1.12.0, < 2.0)
61
75
  ruby-progressbar (~> 1.7)
62
76
  unicode-display_width (>= 1.4.0, < 3.0)
63
- rubocop-ast (1.4.1)
64
- parser (>= 2.7.1.5)
77
+ rubocop-ast (1.14.0)
78
+ parser (>= 3.0.1.1)
65
79
  ruby-progressbar (1.11.0)
66
- ruby2_keywords (0.0.4)
67
- unicode-display_width (2.0.0)
68
- webmock (3.11.2)
69
- addressable (>= 2.3.6)
80
+ ruby2_keywords (0.0.5)
81
+ unicode-display_width (2.1.0)
82
+ webmock (3.14.0)
83
+ addressable (>= 2.8.0)
70
84
  crack (>= 0.3.2)
71
85
  hashdiff (>= 0.4.0, < 2.0.0)
72
86
 
@@ -81,4 +95,4 @@ DEPENDENCIES
81
95
  webmock (~> 3.11)
82
96
 
83
97
  BUNDLED WITH
84
- 2.2.6
98
+ 2.2.22
@@ -10,7 +10,7 @@ Gem::Specification.new do |s|
10
10
  s.add_runtime_dependency('faraday_middleware', '~> 1.0')
11
11
  s.add_runtime_dependency('hashie', '~> 4.1')
12
12
  s.add_runtime_dependency('multi_json', '~> 1.15')
13
- s.add_runtime_dependency('jwt', '~> 2.2.2')
13
+ s.add_runtime_dependency('jwt', '>= 2.2')
14
14
  s.authors = ['Colin Harris']
15
15
  s.description = 'A Ruby wrapper for the Firebase Admin APIs'
16
16
  s.email = ['colin@jiva.ag']
@@ -93,6 +93,20 @@ module FirebaseAdmin
93
93
  post('v1/accounts:signInWithCustomToken', { token: token, returnSecureToken: true })
94
94
  end
95
95
 
96
+ # Sign in based on the UID of an account
97
+ # This generates a custom token for the UID and signs in using the custom token
98
+ #
99
+ # @param uid [String] The uid of a user
100
+ #
101
+ # @return [Resource] with idToken
102
+ #
103
+ # @example
104
+ # FirebaseAdmin.sign_in_for_uid("...")
105
+ def sign_in_for_uid(uid)
106
+ custom_token = create_custom_token(uid)
107
+ sign_in_with_custom_token(custom_token)
108
+ end
109
+
96
110
  # Create a custom JWT token for a UID
97
111
  #
98
112
  # @param uid [String] The uid of a user
@@ -103,11 +117,6 @@ module FirebaseAdmin
103
117
  # @example
104
118
  # FirebaseAdmin.create_custom_token('...')
105
119
  def create_custom_token(uid)
106
- credentials = default_credentials
107
-
108
- service_account_email = credentials.fetch('client_email', ENV['GOOGLE_CLIENT_EMAIL'])
109
- private_key = OpenSSL::PKey::RSA.new credentials.fetch('private_key', unescape(ENV['GOOGLE_PRIVATE_KEY']))
110
-
111
120
  now_seconds = Time.now.to_i
112
121
  payload = {
113
122
  iss: service_account_email,
@@ -155,10 +164,40 @@ module FirebaseAdmin
155
164
  str
156
165
  end
157
166
 
167
+ def service_account_email
168
+ email = default_credentials.fetch('client_email') { ENV['GOOGLE_CLIENT_EMAIL'] }
169
+ if email.nil? || email == ''
170
+ raise InvalidCredentials,
171
+ "No client email provided via 'GOOGLE_APPLICATION_CREDENTIALS' or 'GOOGLE_CLIENT_EMAIL'"
172
+ end
173
+
174
+ email
175
+ end
176
+
177
+ def private_key
178
+ key = default_credentials.fetch('private_key') { unescape(ENV['GOOGLE_PRIVATE_KEY']) }
179
+ if key.nil? || key == ''
180
+ raise InvalidCredentials,
181
+ "No private key provided via 'GOOGLE_APPLICATION_CREDENTIALS' or 'GOOGLE_PRIVATE_KEY'"
182
+ end
183
+
184
+ OpenSSL::PKey::RSA.new(key)
185
+ end
186
+
158
187
  def default_credentials
159
- return {} if ENV['GOOGLE_APPLICATION_CREDENTIALS'].nil?
188
+ @default_credentials ||= read_default_credentials
189
+ end
160
190
 
161
- JSON.parse(File.read(ENV['GOOGLE_APPLICATION_CREDENTIALS']))
191
+ def read_default_credentials
192
+ credentials_path = ENV['GOOGLE_APPLICATION_CREDENTIALS']
193
+ if credentials_path && File.exist?(credentials_path)
194
+ JSON.parse(File.read(credentials_path))
195
+ else
196
+ {}
197
+ end
198
+ rescue StandardError => e
199
+ raise InvalidCredentials,
200
+ "Failed reading credentials from '#{ENV['GOOGLE_APPLICATION_CREDENTIALS']}'. Error: #{e.message}"
162
201
  end
163
202
  end
164
203
  end
@@ -17,7 +17,7 @@ module FirebaseAdmin
17
17
  }.merge(connection_options)
18
18
 
19
19
  Faraday::Connection.new(options) do |connection|
20
- connection.authorization :Bearer, access_token if access_token
20
+ connection.request :authorization, 'Bearer', access_token if access_token
21
21
  connection.use Faraday::Request::UrlEncoded
22
22
  connection.use FaradayMiddleware::Mashify
23
23
  connection.use Faraday::Response::ParseJson
@@ -25,4 +25,7 @@ module FirebaseAdmin
25
25
 
26
26
  # Raised when Firebase returns the HTTP status code 429
27
27
  class RateLimitExceeded < Error; end
28
+
29
+ # Raised when no valid credentials are found
30
+ class InvalidCredentials < Error; end
28
31
  end
@@ -1,3 +1,3 @@
1
1
  module FirebaseAdmin
2
- VERSION = '0.1.2'.freeze unless defined?(::FirebaseAdmin::VERSION)
2
+ VERSION = '0.1.6'.freeze unless defined?(::FirebaseAdmin::VERSION)
3
3
  end
@@ -20,4 +20,82 @@ describe FirebaseAdmin::Client do
20
20
  ).to have_been_made
21
21
  end
22
22
  end
23
+
24
+ describe '.update_account' do
25
+ before do
26
+ stub_post('v1/projects/test-project/accounts:update')
27
+ .to_return(body: fixture('update_account.json'), headers: { content_type: 'application/json; charset=utf-8' })
28
+ end
29
+
30
+ it 'should post to the update endpoint' do
31
+ @client.update_account(email: 'john@smith.com', password: 'supersecret')
32
+ expect(
33
+ a_post('v1/projects/test-project/accounts:update')
34
+ .with(body: { email: 'john@smith.com', password: 'supersecret' }.to_json)
35
+ .with(headers: { 'Authorization' => 'Bearer owner' })
36
+ ).to have_been_made
37
+ end
38
+ end
39
+
40
+ describe '.create_custom_token' do
41
+ context 'when credentials are set via GOOGLE_APPLICATION_CREDENTIALS' do
42
+ before do
43
+ ENV['GOOGLE_APPLICATION_CREDENTIALS'] = fixture('google_credentials.json').path
44
+ end
45
+
46
+ it 'returns a valid JWT token' do
47
+ token = @client.create_custom_token('user-123')
48
+ token_data, _alg = JWT.decode(token, nil, false)
49
+ expect(token_data['uid']).to eq('user-123')
50
+ end
51
+ end
52
+
53
+ context 'when GOOGLE_APPLICATION_CREDENTIALS points to an invalid file' do
54
+ before do
55
+ ENV['GOOGLE_APPLICATION_CREDENTIALS'] = fixture('google_credentials_invalid.json').path
56
+ end
57
+
58
+ it 'raises an error' do
59
+ expect { @client.create_custom_token('user-123') }.to raise_error FirebaseAdmin::InvalidCredentials
60
+ end
61
+ end
62
+
63
+ context 'when credentials are set via GOOGLE_CLIENT_EMAIL / GOOGLE_PRIVATE_KEY' do
64
+ let(:email) { 'example@example.com' }
65
+ let(:private_key) { fixture('example_key').read }
66
+
67
+ before do
68
+ ENV['GOOGLE_APPLICATION_CREDENTIALS'] = nil
69
+ ENV['GOOGLE_CLIENT_EMAIL'] = email
70
+ ENV['GOOGLE_PRIVATE_KEY'] = private_key
71
+ end
72
+
73
+ it 'returns a valid JWT token' do
74
+ token = @client.create_custom_token('user-123')
75
+ token_data, _alg = JWT.decode(token, nil, false)
76
+ expect(token_data['uid']).to eq('user-123')
77
+ end
78
+ end
79
+
80
+ context 'when no credentials are provided' do
81
+ before do
82
+ ENV['GOOGLE_APPLICATION_CREDENTIALS'] = nil
83
+ ENV['GOOGLE_CLIENT_EMAIL'] = nil
84
+ ENV['GOOGLE_PRIVATE_KEY'] = nil
85
+ end
86
+
87
+ it 'raises an error' do
88
+ expect { @client.create_custom_token('user-123') }.to raise_error FirebaseAdmin::InvalidCredentials
89
+ end
90
+ end
91
+ end
92
+
93
+ describe '.sign_in_for_uid' do
94
+ it 'should post to the update endpoint' do
95
+ expect(@client).to receive(:create_custom_token).with('user-123').and_return('token')
96
+ expect(@client).to receive(:sign_in_with_custom_token).with('token').and_return('result')
97
+ result = @client.sign_in_for_uid('user-123')
98
+ expect(result).to eq('result')
99
+ end
100
+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Pyzw1+lnqxaNmKF2EU/OXoGTUG\ntqu1xPu0NXr8bZn5YRwR1Zc+6cbXqUFIm5BtBlKXfc+Yrg7XFw1Y28aakSa3Kvft\n8GL9g+8QLQKBgQCdDvH9olGLJB9pW/QhyGjfek8Ykibld8eJ5YPgXfDJJcQCb7rM\nrHV5HxGqe14SZ6I8Ozy9qtnmTnyVw/iV2SjigqIvGnPqBk/qGlohTH9wHEI/KaDZ\nz1IMrakN0lxnmb6sViCirIQMFSKAGjFNJBNmVd81GAMrU6NrR8gND2d9wQKBgEbF\ntPlYQkTJdOtJ+crWeSOdZXYB63dML9voJ9W2ePkGiZwSg4gxYN1LUIhEiiNU7+Cv\nFW49Axd48s8DbgKSS03pVFXMqLZLtJzSs9qJftaDAfYvW75ASxEoWo1Ub+gTpt7v\nWIKbxcSXXCnzBRtxQOsLZiY6YSGW4vZnrfJ5atoxAoGBAJF9oxseUWLFi8G9jaMD\nBnGqha7wCrQE6rFjgG9olbYxVB0IYN6hnPoelkrJWDJDz9bpvXSsbO7lwFv0x3Ks\n6ehj1fDjibTz9BNiqNwFzoPWq4Th2TqHrYY34ohtcW4tQdtLYPgQyhmNASUytAlG\nzipYnskyVze/3An/VEFrhSdy\n-----END PRIVATE KEY-----\n
@@ -0,0 +1,12 @@
1
+ {
2
+ "type": "service_account",
3
+ "project_id": "example-project",
4
+ "private_key_id": "123",
5
+ "private_key": "-----BEGIN PRIVATE KEY-----\nMIIEvgIBADANBgkqhkiG9w0BAQEFAASCBKgwggSkAgEAAoIBAQDW04sWbA5qIYUQ\nLU+dVoEf0ipYYmu9/2Z+Teobkhd9f6ZQ++1a0hnpelIx3vulrO0uPU/CZIh75cPR\nl/UGg2wxB2QnQcznUCJylOKoV412L7nTauYolNkI71X95npQyQtP+i3E7mQHAEJc\nOqF+cd6ufH5KouKtkJvSioHVKMr1YWDAmCfvQdYQ9Chv4K3Fvr1yniFk7OqcB1Td\nf9XcMpCaC6XokOzgvZ0TbNoqG2ceR66E04J33nRenq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N1LUIhEiiNU7+Cv\nFW49Axd48s8DbgKSS03pVFXMqLZLtJzSs9qJftaDAfYvW75ASxEoWo1Ub+gTpt7v\nWIKbxcSXXCnzBRtxQOsLZiY6YSGW4vZnrfJ5atoxAoGBAJF9oxseUWLFi8G9jaMD\nBnGqha7wCrQE6rFjgG9olbYxVB0IYN6hnPoelkrJWDJDz9bpvXSsbO7lwFv0x3Ks\n6ehj1fDjibTz9BNiqNwFzoPWq4Th2TqHrYY34ohtcW4tQdtLYPgQyhmNASUytAlG\nzipYnskyVze/3An/VEFrhSdy\n-----END PRIVATE KEY-----\n",
6
+ "client_email": "example@example.iam.gserviceaccount.com",
7
+ "client_id": "456",
8
+ "auth_uri": "https://accounts.google.com/o/oauth2/auth",
9
+ "token_uri": "https://oauth2.googleapis.com/token",
10
+ "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs",
11
+ "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/example%40example.iam.gserviceaccount.com"
12
+ }
@@ -0,0 +1 @@
1
+ invalid
@@ -0,0 +1,6 @@
1
+ {
2
+ "kind": "identitytoolkit#SignupNewUserResponse",
3
+ "localId": "abcdefghijklmnopqrstuvwxyzab",
4
+ "displayName": "John Smith",
5
+ "email": "john@smith.com"
6
+ }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: firebase-admin
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Colin Harris
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-03-11 00:00:00.000000000 Z
11
+ date: 2021-12-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -140,16 +140,16 @@ dependencies:
140
140
  name: jwt
141
141
  requirement: !ruby/object:Gem::Requirement
142
142
  requirements:
143
- - - "~>"
143
+ - - ">="
144
144
  - !ruby/object:Gem::Version
145
- version: 2.2.2
145
+ version: '2.2'
146
146
  type: :runtime
147
147
  prerelease: false
148
148
  version_requirements: !ruby/object:Gem::Requirement
149
149
  requirements:
150
- - - "~>"
150
+ - - ">="
151
151
  - !ruby/object:Gem::Version
152
- version: 2.2.2
152
+ version: '2.2'
153
153
  description: A Ruby wrapper for the Firebase Admin APIs
154
154
  email:
155
155
  - colin@jiva.ag
@@ -185,7 +185,11 @@ files:
185
185
  - spec/fixtures/400_error.json
186
186
  - spec/fixtures/bad_gateway.html
187
187
  - spec/fixtures/create_account.json
188
+ - spec/fixtures/example_key
188
189
  - spec/fixtures/gateway_timeout.html
190
+ - spec/fixtures/google_credentials.json
191
+ - spec/fixtures/google_credentials_invalid.json
192
+ - spec/fixtures/update_account.json
189
193
  - spec/spec_helper.rb
190
194
  homepage: https://github.com/col/firebase-admin
191
195
  licenses:
@@ -219,5 +223,9 @@ test_files:
219
223
  - spec/fixtures/400_error.json
220
224
  - spec/fixtures/bad_gateway.html
221
225
  - spec/fixtures/create_account.json
226
+ - spec/fixtures/example_key
222
227
  - spec/fixtures/gateway_timeout.html
228
+ - spec/fixtures/google_credentials.json
229
+ - spec/fixtures/google_credentials_invalid.json
230
+ - spec/fixtures/update_account.json
223
231
  - spec/spec_helper.rb