atomic_lti 1.5.4 → 1.5.6
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 +4 -4
- data/app/assets/builds/atomic_lti/init_app.js +13 -6
- data/app/assets/builds/atomic_lti/init_app.js.map +4 -4
- data/app/javascript/atomic_lti/init_app.ts +11 -0
- data/app/views/atomic_lti/shared/init.html.erb +3 -3
- data/lib/atomic_lti/open_id_middleware.rb +10 -8
- data/lib/atomic_lti/version.rb +1 -1
- metadata +3 -3
- data/app/javascript/atomic_lti/init_app.js +0 -3
@@ -0,0 +1,11 @@
|
|
1
|
+
import { initOIDCLaunch } from '@atomicjolt/lti-client';
|
2
|
+
import type { InitSettings } from '@atomicjolt/lti-client/types';
|
3
|
+
|
4
|
+
declare global {
|
5
|
+
interface Window {
|
6
|
+
INIT_SETTINGS: InitSettings;
|
7
|
+
}
|
8
|
+
}
|
9
|
+
|
10
|
+
const initSettings: InitSettings = window.INIT_SETTINGS;
|
11
|
+
initOIDCLaunch(initSettings);
|
@@ -5,6 +5,9 @@
|
|
5
5
|
.hidden { display: none !important; }
|
6
6
|
</style>
|
7
7
|
<link href="https://fonts.googleapis.com/icon?family=Material+Icons+Outlined" rel="stylesheet">
|
8
|
+
<script type="text/javascript">
|
9
|
+
window.INIT_SETTINGS = <%= @settings.to_json.html_safe %>;
|
10
|
+
</script>
|
8
11
|
<%= stylesheet_link_tag "atomic_lti/launch" %>
|
9
12
|
<%= javascript_include_tag "atomic_lti/init_app" %>
|
10
13
|
</head>
|
@@ -19,8 +22,5 @@
|
|
19
22
|
</noscript>
|
20
23
|
<div id="main-content">
|
21
24
|
</div>
|
22
|
-
<script type="text/javascript">
|
23
|
-
InitOIDCLaunch(window.SETTINGS);
|
24
|
-
</script>
|
25
25
|
</body>
|
26
26
|
</html>
|
@@ -169,14 +169,16 @@ module AtomicLti
|
|
169
169
|
env["atomic.validated.id_token"] = id_token
|
170
170
|
|
171
171
|
platform = AtomicLti::Platform.find_by!(iss: id_token_decoded["iss"])
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
172
|
+
|
173
|
+
# Add the values needed to do client side validate to the environment
|
174
|
+
env["atomic.validated.state_validation"] = {
|
175
|
+
state: state,
|
176
|
+
state_verified: state_verified,
|
177
|
+
}
|
178
|
+
|
179
|
+
if !state_verified && request.params["lti_storage_target"].present? && AtomicLti.use_post_message_storage
|
180
|
+
env["atomic.validated.state_validation"][:lti_storage_params] =
|
181
|
+
build_lti_storage_params(request, platform)
|
180
182
|
end
|
181
183
|
|
182
184
|
@app.call(env)
|
data/lib/atomic_lti/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: atomic_lti
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.5.
|
4
|
+
version: 1.5.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matt Petro
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2023-
|
13
|
+
date: 2023-10-28 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: pg
|
@@ -61,7 +61,7 @@ files:
|
|
61
61
|
- app/assets/stylesheets/atomic_lti/launch.css
|
62
62
|
- app/controllers/atomic_lti/jwks_controller.rb
|
63
63
|
- app/helpers/atomic_lti/launch_helper.rb
|
64
|
-
- app/javascript/atomic_lti/init_app.
|
64
|
+
- app/javascript/atomic_lti/init_app.ts
|
65
65
|
- app/jobs/atomic_lti/application_job.rb
|
66
66
|
- app/lib/atomic_lti/auth_token.rb
|
67
67
|
- app/lib/atomic_lti/authorization.rb
|