@constructive-io/graphql-server 4.18.6 → 4.19.0
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.
|
@@ -214,6 +214,9 @@ const buildPreset = (pool, schemas, anonRole, roleName) => {
|
|
|
214
214
|
'jwt.claims.user_id': req.token.user_id,
|
|
215
215
|
...context,
|
|
216
216
|
};
|
|
217
|
+
if (req.token.session_id) {
|
|
218
|
+
pgSettings['jwt.claims.session_id'] = req.token.session_id;
|
|
219
|
+
}
|
|
217
220
|
// Propagate credential metadata as JWT claims so PG functions
|
|
218
221
|
// can read them via current_setting('jwt.claims.access_level') etc.
|
|
219
222
|
if (req.token.access_level) {
|
package/middleware/graphile.js
CHANGED
|
@@ -223,6 +223,9 @@ const buildPreset = (pool, schemas, anonRole, roleName) => {
|
|
|
223
223
|
'jwt.claims.user_id': req.token.user_id,
|
|
224
224
|
...context,
|
|
225
225
|
};
|
|
226
|
+
if (req.token.session_id) {
|
|
227
|
+
pgSettings['jwt.claims.session_id'] = req.token.session_id;
|
|
228
|
+
}
|
|
226
229
|
// Propagate credential metadata as JWT claims so PG functions
|
|
227
230
|
// can read them via current_setting('jwt.claims.access_level') etc.
|
|
228
231
|
if (req.token.access_level) {
|
package/middleware/types.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@constructive-io/graphql-server",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.19.0",
|
|
4
4
|
"author": "Constructive <developers@constructive.io>",
|
|
5
5
|
"description": "Constructive GraphQL Server",
|
|
6
6
|
"main": "index.js",
|
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
"graphile-build-pg": "5.0.0",
|
|
64
64
|
"graphile-cache": "^3.5.0",
|
|
65
65
|
"graphile-config": "1.0.0",
|
|
66
|
-
"graphile-settings": "^4.21.
|
|
66
|
+
"graphile-settings": "^4.21.6",
|
|
67
67
|
"graphile-utils": "5.0.0",
|
|
68
68
|
"graphql": "16.13.0",
|
|
69
69
|
"graphql-upload": "^13.0.0",
|
|
@@ -85,10 +85,10 @@
|
|
|
85
85
|
"@types/multer": "^2.1.0",
|
|
86
86
|
"@types/pg": "^8.18.0",
|
|
87
87
|
"@types/request-ip": "^0.0.41",
|
|
88
|
-
"graphile-test": "4.9.
|
|
88
|
+
"graphile-test": "4.9.2",
|
|
89
89
|
"makage": "^0.3.0",
|
|
90
90
|
"nodemon": "^3.1.14",
|
|
91
91
|
"ts-node": "^10.9.2"
|
|
92
92
|
},
|
|
93
|
-
"gitHead": "
|
|
93
|
+
"gitHead": "4988b64539a61786647412a456c56cb486722e18"
|
|
94
94
|
}
|