omniauth-roblox 0.0.2 → 0.0.4

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2dd6d4d68f0d8d55aec4ca6d6c85cef7f1a4e7e91d6500b6310a94bd2dac73d7
4
- data.tar.gz: 736f6ae03d00d819fa58d5a3dba63add7d102462c716c3d6cb29a9b24212af94
3
+ metadata.gz: b23dc782e6a4fd1f557b1f3a8dbc8fd225fac1d5ee92d9ac3840c45e4beddc2c
4
+ data.tar.gz: 92a13f6586a2cfa7a2c9007161b667c8c2bd8ff23b9afc8e89e60637ae4d0a24
5
5
  SHA512:
6
- metadata.gz: 3de492655bebbe58639ff622d6e876f271ac72afd0bb1ca56bc343095e3178d63c8f458fd815844af80558b8513f341bc81bac31512703dd136f926bd777a431
7
- data.tar.gz: 3b959e4e80414d53205c44e8de51cd0086f0f9bb18b876edd1b3a3dd4efb4a50f86de8fa7a89ba1fc6102e313c3a9df465e976928b27a599b5c7f3b2a07276ab
6
+ metadata.gz: d44f56dc85f3fb1c53c00c5fcc4617450b4946492820480426fd925b45ed5c4424d5455079bb5776adca5c691e6fe7cf88beda950ee790a42610dc40bfceafd9
7
+ data.tar.gz: 6e733ed48328390676540e81429ae94066a8453f5aa0cf1ae1a45ea82cbf5992fdd60c69c73e62d90eb8f514e37a69a4d7c817d79c3a563e59883dda34f6c96d
data/Gemfile.lock CHANGED
@@ -1,8 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- omniauth-roblox (0.0.1)
5
- jwt (~> 2.5)
4
+ omniauth-roblox (0.0.4)
6
5
  omniauth (~> 2.1)
7
6
  omniauth-oauth2 (~> 1.8)
8
7
 
@@ -10,22 +9,22 @@ GEM
10
9
  remote: https://rubygems.org/
11
10
  specs:
12
11
  ast (2.4.2)
13
- faraday (2.5.2)
12
+ faraday (2.7.4)
14
13
  faraday-net_http (>= 2.0, < 3.1)
15
14
  ruby2_keywords (>= 0.0.4)
16
- faraday-net_http (3.0.0)
15
+ faraday-net_http (3.0.2)
17
16
  hashie (5.0.0)
18
- json (2.6.2)
19
- jwt (2.5.0)
17
+ json (2.6.3)
18
+ jwt (2.7.0)
20
19
  multi_xml (0.6.0)
21
- oauth2 (2.0.8)
20
+ oauth2 (2.0.9)
22
21
  faraday (>= 0.17.3, < 3.0)
23
22
  jwt (>= 1.0, < 3.0)
24
23
  multi_xml (~> 0.5)
25
- rack (>= 1.2, < 3)
24
+ rack (>= 1.2, < 4)
26
25
  snaky_hash (~> 2.0)
27
26
  version_gem (~> 1.1)
28
- omniauth (2.1.0)
27
+ omniauth (2.1.1)
29
28
  hashie (>= 3.4.6)
30
29
  rack (>= 2.2.3)
31
30
  rack-protection
@@ -33,36 +32,37 @@ GEM
33
32
  oauth2 (>= 1.4, < 3)
34
33
  omniauth (~> 2.0)
35
34
  parallel (1.22.1)
36
- parser (3.1.2.1)
35
+ parser (3.2.2.0)
37
36
  ast (~> 2.4.1)
38
- rack (2.2.4)
39
- rack-protection (2.2.2)
37
+ rack (3.0.7)
38
+ rack-protection (3.0.5)
40
39
  rack
41
40
  rainbow (3.1.1)
42
41
  rake (13.0.6)
43
- regexp_parser (2.5.0)
42
+ regexp_parser (2.7.0)
44
43
  rexml (3.2.5)
45
- rubocop (1.36.0)
44
+ rubocop (1.49.0)
46
45
  json (~> 2.3)
47
46
  parallel (~> 1.10)
48
- parser (>= 3.1.2.1)
47
+ parser (>= 3.2.0.0)
49
48
  rainbow (>= 2.2.2, < 4.0)
50
49
  regexp_parser (>= 1.8, < 3.0)
51
50
  rexml (>= 3.2.5, < 4.0)
52
- rubocop-ast (>= 1.20.1, < 2.0)
51
+ rubocop-ast (>= 1.28.0, < 2.0)
53
52
  ruby-progressbar (~> 1.7)
54
- unicode-display_width (>= 1.4.0, < 3.0)
55
- rubocop-ast (1.21.0)
56
- parser (>= 3.1.1.0)
57
- ruby-progressbar (1.11.0)
53
+ unicode-display_width (>= 2.4.0, < 3.0)
54
+ rubocop-ast (1.28.0)
55
+ parser (>= 3.2.1.0)
56
+ ruby-progressbar (1.13.0)
58
57
  ruby2_keywords (0.0.5)
59
- snaky_hash (2.0.0)
58
+ snaky_hash (2.0.1)
60
59
  hashie
61
- version_gem (~> 1.1)
62
- unicode-display_width (2.2.0)
63
- version_gem (1.1.0)
60
+ version_gem (~> 1.1, >= 1.1.1)
61
+ unicode-display_width (2.4.2)
62
+ version_gem (1.1.2)
64
63
 
65
64
  PLATFORMS
65
+ arm64-darwin-22
66
66
  x86_64-linux
67
67
 
68
68
  DEPENDENCIES
@@ -71,4 +71,4 @@ DEPENDENCIES
71
71
  rubocop (~> 1.36)
72
72
 
73
73
  BUNDLED WITH
74
- 2.3.21
74
+ 2.4.10
data/README.md CHANGED
@@ -25,5 +25,4 @@ end
25
25
  ## Configuration Options
26
26
  - `scope`: No scopes are currently set by default, Roblox requires the `openid` scope at the minimum.
27
27
  - `image_type`: The type of image that should be returned by roblox, defaults to `headshot`. Allowed values: `[empty string]` (full body), `bust`, and `headshot`.
28
- - `jwt_leeway`: Amount of leeway in seconds passed to the JWT library, only works with version 2.1 or earlier.
29
28
  - `skip_image`: If this is set to `true`, no image url will be returned.
@@ -1,7 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require 'base64'
3
4
  require 'json'
4
- require 'jwt'
5
5
  require 'net/http'
6
6
  require 'omniauth/strategies/oauth2'
7
7
  require 'uri'
@@ -16,11 +16,10 @@ module OmniAuth
16
16
  option :name, 'roblox'
17
17
 
18
18
  option :client_options,
19
- authorize_url: 'https://authorize.roblox.com/',
19
+ authorize_url: 'v1/authorize',
20
20
  site: 'https://apis.roblox.com/oauth',
21
21
  token_url: 'v1/token'
22
22
 
23
- option :jwt_leeway, 60
24
23
  option :authorize_options, %i[consent login selectAccount]
25
24
  option :image_type, 'headshot'
26
25
  option :skip_image, false
@@ -52,7 +51,11 @@ module OmniAuth
52
51
  end
53
52
 
54
53
  def raw_info
55
- @raw_info ||= ::JWT.decode(access_token['id_token'], nil, false).first
54
+ @raw_info ||= JSON.parse(
55
+ Base64.urlsafe_decode(
56
+ access_token['id_token'].split('.')[1]
57
+ )
58
+ )
56
59
 
57
60
  return if @raw_info['name']
58
61
 
@@ -1,5 +1,5 @@
1
1
  module OmniAuth
2
2
  module Roblox
3
- VERSION = '0.0.2'
3
+ VERSION = '0.0.4'
4
4
  end
5
5
  end
@@ -12,7 +12,6 @@ Gem::Specification.new do |gem|
12
12
  gem.summary = 'OmniAuth strategy for Roblox'
13
13
  gem.version = OmniAuth::Roblox::VERSION
14
14
 
15
- gem.add_dependency 'jwt', '~> 2.5'
16
15
  gem.add_dependency 'omniauth', '~> 2.1'
17
16
  gem.add_dependency 'omniauth-oauth2', '~> 1.8'
18
17
  end
metadata CHANGED
@@ -1,29 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: omniauth-roblox
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Wolftallemo
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-09-08 00:00:00.000000000 Z
11
+ date: 2023-04-04 00:00:00.000000000 Z
12
12
  dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: jwt
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - "~>"
18
- - !ruby/object:Gem::Version
19
- version: '2.5'
20
- type: :runtime
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - "~>"
25
- - !ruby/object:Gem::Version
26
- version: '2.5'
27
13
  - !ruby/object:Gem::Dependency
28
14
  name: omniauth
29
15
  requirement: !ruby/object:Gem::Requirement
@@ -52,8 +38,8 @@ dependencies:
52
38
  - - "~>"
53
39
  - !ruby/object:Gem::Version
54
40
  version: '1.8'
55
- description:
56
- email:
41
+ description:
42
+ email:
57
43
  executables: []
58
44
  extensions: []
59
45
  extra_rdoc_files: []
@@ -71,7 +57,7 @@ homepage: https://github.com/Wolftallemo/omniauth-roblox
71
57
  licenses:
72
58
  - MIT
73
59
  metadata: {}
74
- post_install_message:
60
+ post_install_message:
75
61
  rdoc_options: []
76
62
  require_paths:
77
63
  - lib
@@ -86,8 +72,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
86
72
  - !ruby/object:Gem::Version
87
73
  version: '0'
88
74
  requirements: []
89
- rubygems_version: 3.2.5
90
- signing_key:
75
+ rubygems_version: 3.4.10
76
+ signing_key:
91
77
  specification_version: 4
92
78
  summary: OmniAuth strategy for Roblox
93
79
  test_files: []