panda_pal 5.3.13 → 5.4.0.beta1

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: c8eb58ee2c4df4d91c08b20c3ea717a1227ebbc212500b6f5a0abad01855fd8c
4
- data.tar.gz: ba0b60f6ee46634a554ac779b6cadf671edb922bc33201ac762de4fa9263ec45
3
+ metadata.gz: 46890814bf0be5add6c0db17248c08bbc756bd7bdbdd4eb1ef52a23494bfcf1f
4
+ data.tar.gz: a76de9599bd0ca52b4488814e2d5d03bffde6bb94c1614f3e45e886bd001d55a
5
5
  SHA512:
6
- metadata.gz: 1337a89241f5a12bc0f5d202197f17f6ea4478be3e44786e68cd2b2161fc8df0cc2338418c4cdacbaa99cb1ec9e07a06446bac3a9a9a965285f35b4cbdce91cb
7
- data.tar.gz: 83c6c892aad41adc5fd7ec2709dd8f5b5a70c238764b9caad989f5a2021ee92d81c64ac05e6ce7a3e72d321d2abfa8b1aba3b1298b2225fff4d476b57d4bd3c6
6
+ metadata.gz: 7d8640b016ca32a5d1c9d57f4abb7380e2d41f0035f138b2e6fb61155a0e6dec93be6601bdf607303606b5a8d0f3901dafa04424e09f66a942952980c3c2959d
7
+ data.tar.gz: 6ae5fbd00abad5e6387ad87226f533c8a1c73561865341d16f821c71eadff43e685643387f8d0745606b3d688965dd9a22d12b060aef735385d662b90cafa692
@@ -42,7 +42,7 @@ module LtiXml
42
42
  else
43
43
  ims_lti_config[:launch_url] = parsed_request_url.host
44
44
  end
45
- @tc = IMS::LTI::Services::ToolConfig.new(ims_lti_config)
45
+ @tc = IMS::LTI::ToolConfig.new(ims_lti_config)
46
46
  end
47
47
 
48
48
  def add_domain
data/lib/panda_pal.rb CHANGED
@@ -1,6 +1,8 @@
1
1
  require "panda_pal/engine"
2
2
  require 'panda_pal/plugins'
3
3
  require 'panda_pal/helpers'
4
+ require 'oauth/request_proxy/rack_request'
5
+ require 'oauth/request_proxy/action_dispatch_request'
4
6
 
5
7
  module PandaPal
6
8
  class LtiNavigationInUse < StandardError;end
@@ -24,9 +24,24 @@ module PandaPal
24
24
  end
25
25
  end
26
26
 
27
+ initializer 'interop dependencies' do
28
+ if $LOADED_FEATURES.grep(/\/ros-apartment-\d/).present?
29
+ if $LOADED_FEATURES.grep(/\/apartment-\d/).present? || $LOADED_FEATURES.grep(/\/apartment-sidekiq-\d/).present?
30
+ raise "ros-apartment is used, but apartment or apartment-sidekiq is loaded. Do not mix legacy and ros- variants! (You most likely need to update your Gemfile to use the ros- variant)"
31
+ end
32
+ end
33
+ if defined?(Sidekiq)
34
+ begin
35
+ require 'apartment-sidekiq'
36
+ rescue LoadError
37
+ raise "Sidekiq is used, but apartment-sidekiq is not installed. Add [gem 'ros-apartment-sidekiq'] to your Gemfile"
38
+ end
39
+ end
40
+ end
41
+
27
42
  initializer 'Sidekiq Scheduler Hooks' do
28
43
  ActiveSupport.on_load(:active_record) do
29
- if Sidekiq.server? && PandaPal::Organization.respond_to?(:sync_schedules)
44
+ if defined?(Sidekiq) && Sidekiq.server? && PandaPal::Organization.respond_to?(:sync_schedules)
30
45
  PandaPal::Organization.sync_schedules
31
46
  end
32
47
  end
@@ -50,8 +50,8 @@ module PandaPal::Helpers
50
50
  safe_unexpected_params.each do |p|
51
51
  sanitized_params.delete(p)
52
52
  end
53
- authenticator = IMS::LTI::Services::MessageAuthenticator.new(request.original_url, sanitized_params, @organization.secret)
54
- authorized = authenticator.valid_signature?
53
+ tp = IMS::LTI::ToolProvider.new(@organization.key, @organization.secret, sanitized_params)
54
+ authorized = tp.valid_request?(request)
55
55
  end
56
56
 
57
57
  if !authorized
@@ -1,3 +1,3 @@
1
1
  module PandaPal
2
- VERSION = "5.3.13"
2
+ VERSION = "5.4.0.beta1"
3
3
  end
data/panda_pal.gemspec CHANGED
@@ -16,9 +16,9 @@ Gem::Specification.new do |s|
16
16
  s.test_files = Dir["spec/**/*"]
17
17
 
18
18
  s.add_dependency "rails", ">= 4.2"
19
+ s.add_dependency 'ros-apartment', '~> 2.2'
19
20
  s.add_dependency 'pg', '>= 0.20', '< 1.0.0'
20
- s.add_dependency 'apartment', '~> 2.2.0'
21
- s.add_dependency 'ims-lti', '~> 2.2.3'
21
+ s.add_dependency 'ims-lti', '~> 1.2.4'
22
22
  s.add_dependency 'browser', '2.5.0'
23
23
  s.add_dependency 'attr_encrypted', '~> 3.0.0'
24
24
  s.add_dependency 'secure_headers', '~> 6.1'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: panda_pal
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.3.13
4
+ version: 5.4.0.beta1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Instructure ProServe
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-02-24 00:00:00.000000000 Z
11
+ date: 2021-04-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -24,6 +24,20 @@ dependencies:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
26
  version: '4.2'
27
+ - !ruby/object:Gem::Dependency
28
+ name: ros-apartment
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '2.2'
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '2.2'
27
41
  - !ruby/object:Gem::Dependency
28
42
  name: pg
29
43
  requirement: !ruby/object:Gem::Requirement
@@ -44,34 +58,20 @@ dependencies:
44
58
  - - "<"
45
59
  - !ruby/object:Gem::Version
46
60
  version: 1.0.0
47
- - !ruby/object:Gem::Dependency
48
- name: apartment
49
- requirement: !ruby/object:Gem::Requirement
50
- requirements:
51
- - - "~>"
52
- - !ruby/object:Gem::Version
53
- version: 2.2.0
54
- type: :runtime
55
- prerelease: false
56
- version_requirements: !ruby/object:Gem::Requirement
57
- requirements:
58
- - - "~>"
59
- - !ruby/object:Gem::Version
60
- version: 2.2.0
61
61
  - !ruby/object:Gem::Dependency
62
62
  name: ims-lti
63
63
  requirement: !ruby/object:Gem::Requirement
64
64
  requirements:
65
65
  - - "~>"
66
66
  - !ruby/object:Gem::Version
67
- version: 2.2.3
67
+ version: 1.2.4
68
68
  type: :runtime
69
69
  prerelease: false
70
70
  version_requirements: !ruby/object:Gem::Requirement
71
71
  requirements:
72
72
  - - "~>"
73
73
  - !ruby/object:Gem::Version
74
- version: 2.2.3
74
+ version: 1.2.4
75
75
  - !ruby/object:Gem::Dependency
76
76
  name: browser
77
77
  requirement: !ruby/object:Gem::Requirement
@@ -312,9 +312,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
312
312
  version: '0'
313
313
  required_rubygems_version: !ruby/object:Gem::Requirement
314
314
  requirements:
315
- - - ">="
315
+ - - ">"
316
316
  - !ruby/object:Gem::Version
317
- version: '0'
317
+ version: 1.3.1
318
318
  requirements: []
319
319
  rubygems_version: 3.0.3
320
320
  signing_key: