Skip to content

🪢 Open source agent evals & observability: Trace, evaluate, and improve LLM applications with one open platform.

security: upgrade jsonpath-plus (#5409)

Max Deichmann129c94c455da
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index fce2165c4b..53e691ea5c 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -59,7 +59,7 @@ importers:
next-auth:
specifier: ^4.24.11
zod:
specifier: ^3.23.8
version: 3.23.8
@@ -224,7 +224,7 @@ importers:
version: 4.17.21
next-auth:
specifier: ^4.24.11
nodemailer:
specifier: ^6.9.15
version: 6.9.15
@@ -315,7 +315,7 @@ importers:
version: 5.4.5
vitest:
specifier: ^2.1.2
web:
dependencies:
@@ -621,7 +621,7 @@ importers:
next-auth:
specifier: ^4.24.11
next-query-params:
specifier: ^5.0.1
@@ -1017,7 +1017,7 @@ importers:
version: 5.4.5
vitest:
specifier: ^2.1.2
wait-for-expect:
specifier: ^3.0.2
version: 3.0.2
@@ -2416,14 +2416,14 @@ packages:
'@js-sdsl/[email protected]':
resolution: {integrity: sha512-iUKgm52T8HOE/makSxjqoWhe95ZJA1/G1sYsGev2JDKUSS14KAgg1LHb+Ba+IPow0xflbnSkOsZcO08C7w1gYw==}
- '@jsep-plugin/[email protected]':
- resolution: {integrity: sha512-gaHqbubTi29aZpVbBlECRpmdia+L5/lh2BwtIJTmtxdbecEyyX/ejAOg7eQDGNvGOUmPY7Z2Yxdy9ioyH/VJeA==}
+ '@jsep-plugin/[email protected]':
+ resolution: {integrity: sha512-VVgV+CXrhbMI3aSusQyclHkenWSAm95WaiKrMxRFam3JSUiIaQjoMIw2sEs/OX4XifnqeQUN4DYbJjlA8EfktQ==}
engines: {node: '>= 10.16.0'}
peerDependencies:
jsep: ^0.4.0||^1.0.0
- '@jsep-plugin/[email protected]':
- resolution: {integrity: sha512-XfZgry4DwEZvSFtS/6Y+R48D7qJYJK6R9/yJFyUFHCIUMEEHuJ4X95TDgJp5QkmzfLYvapMPzskV5HpIDrREug==}
+ '@jsep-plugin/[email protected]':
+ resolution: {integrity: sha512-q7qL4Mgjs1vByCaTnDFcBnV9HS7GVPJX5vyVoCgZHNSC9rjwIlmbXG5sUuorR5ndfHAIlJ8pVStxvjXHbNvtUg==}
engines: {node: '>= 10.16.0'}
peerDependencies:
jsep: ^0.4.0||^1.0.0
@@ -5786,8 +5786,8 @@ packages:
resolution: {integrity: sha512-rPQy70G6AGUMnbwS1z6Xg+RkHYPAi18ihs47GH0jcxIG7wArmPgY3XbS2sRdBbxJljp3thdT8BIqv9ccCypiPA==}
- resolution: {integrity: sha512-pDCPkvzfa39ehJtJ+OwGT/2yvT2SbjfHhiIW2LWOAcMQ7BzwxT/XuyUp4OTOd0XFWA6BKw0JalnBHgSi5DGJBQ==}
+ resolution: {integrity: sha512-GwNPlWJin8E+d7Gxq96jxM6w0w+VFeyyXRsjU58emtkYqnbwHqXm5uT2uCmO0RQE9htWknOP4xtBlLmM/gWxvQ==}
resolution: {integrity: sha512-eyrF0jiFpY+3drT6383f1qhkbGsLSifNAjA61IUjZjmLCWjItY6LB9ft9YhoDgwfmclB2zhu51Lc7+95b8NRAg==}
@@ -6689,8 +6689,8 @@ packages:
resolution: {integrity: sha512-+cYTcFB1QqD4j4LegwLfpCNxifb6dDFUAwk6RsLusCwIaZI6or2f+q8rs5tTB2YC53HhOlIbEaqHMAAC8IOIwA==}
- resolution: {integrity: sha512-C3PN4aydfW91Natdyd449Kw+BzhLmof6tzy5W1pFC5SpQxVXT+oyiyOG9AgYYSN9OdA/ik3YkCrpwqI8ug5Tug==}
+ resolution: {integrity: sha512-M+29jTcfNNoR9NV7la4SwUqzWAxEwnc7ThA5e1m6LRSotmpfpCpLcIfgtSCVL+MllNLgAyM/5ru86iMRemPzDQ==}
resolution: {integrity: sha512-DeWwawk6r5yR9jFgnDKYt4sLS0LmHJJi3ZOnb5/JdbYwj3nW+FxQnHIjhBKz8YLC7oRNPVM9NQ47I3CVx34eqQ==}
@@ -6723,8 +6723,8 @@ packages:
resolution: {integrity: sha512-LMHl3dXhTcfv8gM4kEzIUeTQ+7fpdA0l2tUf34BddXPkz2A5xJ5L/Pchd5BL6rdccM9QGvu0sWZzK1Z1t4wwyg==}
engines: {node: '>=10.13.0'}
- resolution: {integrity: sha512-0/r0MySGYG8YqlayBZ6MuCfECmHFdJ5qyPh8s8wa5Hnm6SaFLSK1VYCbj+NKp090Nm1caZhD+QTnmxO7esYGyQ==}
+ resolution: {integrity: sha512-ZSW3ma5GkcQBIpwZTSRAI8N71Uuwgs93IezB7mf7R60tC8ZbJideoDNKjHn2O9KIlx6rkGTTEk1xUCK2E1Y2Yg==}
engines: {node: '>=10.13.0'}
@@ -8255,8 +8255,8 @@ packages:
canvas:
optional: true
- resolution: {integrity: sha512-i1rBX5N7VPl0eYb6+mHNp52sEuaS2Wi8CDYx1X5sn9naevL78+265XJqy1qENEk7mRKwS06NHpUqiBwR7qeodw==}
+ resolution: {integrity: sha512-B7qPcEVE3NVkmSJbaYxvv4cHkVW7DQsZz13pUMrfS8z8Q/BuShN+gcTXrUlPiGqM2/t/EEaI030bpxMqY8gMlw==}
engines: {node: '>= 10.16.0'}
@@ -10403,6 +10403,11 @@ packages:
engines: {node: '>=10'}
hasBin: true
+ resolution: {integrity: sha512-hlq8tAfn0m/61p4BVRcPzIGr6LKiMwo4VM6dGi6pt4qcRkmNzTcWq6eCEjEh+qXjkMDvPlOFFSGwQjoEa6gyMA==}
+ engines: {node: '>=10'}
+ hasBin: true
+
resolution: {integrity: sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==}
engines: {node: '>= 0.8.0'}
@@ -10863,8 +10868,8 @@ packages:
uglify-js:
optional: true
- resolution: {integrity: sha512-B8wRRkmre4ERucLM/uXx4MOV5cbnOlVAqUst+1+iLKPI0dOgFO28f84ptoQt9HEI537PMzfYa/d+GEPKTRXmYA==}
+ resolution: {integrity: sha512-a4GD5R1TjEeuCT6ZRiYMHmIf7okbCPEuhQET8bczV6FrQMMlFXA1n+G0KKjdlFCm3TEHV77GxfZB3vZSUQGFpg==}
engines: {node: '>=10'}
hasBin: true
@@ -12469,10 +12474,10 @@ snapshots:
dependencies:
'@aws-sdk/credential-provider-env': 3.667.0
'@aws-sdk/credential-provider-http': 3.667.0
- '@aws-sdk/credential-provider-ini': 3.675.0(@aws-sdk/[email protected](@aws-sdk/[email protected]))(@aws-sdk/[email protected])
+ '@aws-sdk/credential-provider-ini': 3.675.0(@aws-sdk/[email protected](@aws-sdk/[email protected]))(@aws-sdk/[email protected])
'@aws-sdk/credential-provider-process': 3.667.0
- '@aws-sdk/credential-provider-sso': 3.675.0(@aws-sdk/[email protected](@aws-sdk/[email protected]))
- '@aws-sdk/credential-provider-web-identity': 3.667.0(@aws-sdk/[email protected])
+ '@aws-sdk/credential-provider-sso': 3.675.0(@aws-sdk/[email protected](@aws-sdk/[email protected]))
+ '@aws-sdk/credential-provider-web-identity': 3.667.0(@aws-sdk/[email protected])
'@aws-sdk/types': 3.667.0
'@smithy/credential-provider-imds': 3.2.4
'@smithy/property-provider': 3.1.7
@@ -14081,13 +14086,13 @@ snapshots:
'@js-sdsl/[email protected]': {}
dependencies:
- jsep: 1.3.9
+ jsep: 1.4.0
dependencies:
- jsep: 1.3.9
+ jsep: 1.4.0
dependencies:
@@ -14483,7 +14488,7 @@ snapshots:
dependencies:
'@next/[email protected]': {}
@@ -17489,7 +17494,7 @@ snapshots:
'@typescript-eslint/eslint-plugin': 7.3.1(@typescript-eslint/[email protected]([email protected])([email protected]))([email protected])([email protected])
'@typescript-eslint/parser': 7.12.0([email protected])([email protected])
eslint-config-prettier: 9.1.0([email protected])
- eslint-import-resolver-alias: 1.1.2([email protected](@typescript-eslint/[email protected]([email protected])([email protected]))([email protected]))
eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/[email protected]([email protected])([email protected]))([email protected])([email protected])
eslint-plugin-eslint-comments: 3.2.0([email protected])
@@ -17522,14 +17527,14 @@ snapshots:
chai: 5.1.1
tinyrainbow: 1.2.0
dependencies:
'@vitest/spy': 2.1.2
estree-walker: 3.0.3
magic-string: 0.30.11
optionalDependencies:
- vite: 5.2.14(@types/[email protected])([email protected])
+ vite: 5.2.14(@types/[email protected])([email protected])
dependencies:
@@ -18171,8 +18176,8 @@ snapshots:
dependencies:
- caniuse-lite: 1.0.30001696
- electron-to-chromium: 1.5.90
+ caniuse-lite: 1.0.30001697
+ electron-to-chromium: 1.5.93
node-releases: 2.0.19
update-browserslist-db: 1.1.2([email protected])
@@ -18200,7 +18205,7 @@ snapshots:
dependencies:
- semver: 7.7.0
+ semver: 7.7.1
dependencies:
@@ -18248,7 +18253,7 @@ snapshots:
@@ -19177,7 +19182,7 @@ snapshots:
@@ -19202,7 +19207,7 @@ snapshots:
graceful-fs: 4.2.11
tapable: 2.2.1
dependencies:
graceful-fs: 4.2.11
tapable: 2.2.1
@@ -19387,7 +19392,7 @@ snapshots:
dependencies:
eslint: 8.57.0
- semver: 7.7.0
+ semver: 7.7.1
dependencies:
@@ -19424,7 +19429,7 @@ snapshots:
eslint: 8.57.0
eslint-plugin-turbo: 1.13.4([email protected])
dependencies:
@@ -19515,7 +19520,7 @@ snapshots:
doctrine: 2.1.0
eslint: 8.57.0
eslint-import-resolver-node: 0.3.9
hasown: 2.0.2
is-core-module: 2.15.1
is-glob: 4.0.3
@@ -19542,7 +19547,7 @@ snapshots:
doctrine: 2.1.0
eslint: 8.57.0
eslint-import-resolver-node: 0.3.9
hasown: 2.0.2
is-core-module: 2.15.1
is-glob: 4.0.3
@@ -19603,7 +19608,7 @@ snapshots:
is-core-module: 2.16.1
minimatch: 3.1.2
resolve: 1.22.10
- semver: 7.7.0
+ semver: 7.7.1
@@ -19700,7 +19705,7 @@ snapshots:
eslint: 8.57.0
optionalDependencies:
'@typescript-eslint/eslint-plugin': 7.3.1(@typescript-eslint/[email protected]([email protected])([email protected]))([email protected])([email protected])
transitivePeerDependencies:
- supports-color
- typescript
@@ -21394,7 +21399,7 @@ snapshots:
- supports-color
- utf-8-validate
@@ -21441,9 +21446,9 @@ snapshots:
dependencies:
- '@jsep-plugin/assignment': 1.2.1([email protected])
- '@jsep-plugin/regex': 1.0.3([email protected])
- jsep: 1.3.9
+ '@jsep-plugin/assignment': 1.3.0([email protected])
+ '@jsep-plugin/regex': 1.0.4([email protected])
+ jsep: 1.4.0
@@ -22339,7 +22344,7 @@ snapshots:
dependencies:
type-fest: 2.19.0
dependencies:
'@babel/runtime': 7.26.0
'@panva/hkdf': 1.1.1
@@ -23777,6 +23782,8 @@ snapshots:
+
dependencies:
debug: 2.6.9
@@ -24286,10 +24293,10 @@ snapshots:
jest-worker: 27.5.1
schema-utils: 4.3.0
serialize-javascript: 6.0.2
- terser: 5.37.0
+ terser: 5.38.0
webpack: 5.95.0
dependencies:
'@jridgewell/source-map': 0.3.6
acorn: 8.14.0
@@ -24776,12 +24783,12 @@ snapshots:
- terser
optional: true
dependencies:
cac: 6.7.14
debug: 4.3.7([email protected])
pathe: 1.1.2
- vite: 5.2.14(@types/[email protected])([email protected])
+ vite: 5.2.14(@types/[email protected])([email protected])
transitivePeerDependencies:
- '@types/node'
- less
@@ -24802,7 +24809,7 @@ snapshots:
fsevents: 2.3.3
optional: true
dependencies:
esbuild: 0.20.2
postcss: 8.4.49
@@ -24810,7 +24817,7 @@ snapshots:
optionalDependencies:
'@types/node': 20.11.29
fsevents: 2.3.3
- terser: 5.37.0
+ terser: 5.38.0
dependencies:
@@ -24846,10 +24853,10 @@ snapshots:
- terser
optional: true
dependencies:
'@vitest/expect': 2.1.2
'@vitest/pretty-format': 2.1.2
'@vitest/runner': 2.1.2
'@vitest/snapshot': 2.1.2
@@ -24864,8 +24871,8 @@ snapshots:
tinyexec: 0.3.0
tinypool: 1.0.1
tinyrainbow: 1.2.0
- vite: 5.2.14(@types/[email protected])([email protected])
- vite-node: 2.1.2(@types/[email protected])([email protected])
+ vite: 5.2.14(@types/[email protected])([email protected])
+ vite-node: 2.1.2(@types/[email protected])([email protected])
why-is-node-running: 2.3.0
optionalDependencies:
'@types/node': 20.11.29
@@ -24950,7 +24957,7 @@ snapshots:
acorn-import-attributes: 1.9.5([email protected])
browserslist: 4.24.4
chrome-trace-event: 1.0.4
- enhanced-resolve: 5.18.0
+ enhanced-resolve: 5.18.1
es-module-lexer: 1.6.0
eslint-scope: 5.1.1
events: 3.3.0
diff --git a/worker/package.json b/worker/package.json
index 3e3c5902a4..544fe1f49f 100644
--- a/worker/package.json
+++ b/worker/package.json
@@ -49,7 +49,7 @@
"handlebars": "^4.7.8",
"helmet": "^7.1.0",
"ioredis": "^5.4.1",
- "jsonpath-plus": "10.0.7",
+ "jsonpath-plus": "10.2.0",
"kysely": "^0.27.4",
"lodash": "^4.17.21",
"pg": "^8.13.0",
diff --git a/worker/src/ee/evaluation/evalService.ts b/worker/src/ee/evaluation/evalService.ts
index d07f6a91f6..bab2764618 100644
--- a/worker/src/ee/evaluation/evalService.ts
+++ b/worker/src/ee/evaluation/evalService.ts
@@ -656,6 +656,9 @@ export const parseDatabaseRowToString = (
let jsonSelectedColumn;
if (mapping.jsonSelector) {
+ logger.debug(
+ `Parsing JSON for json selector ${mapping.jsonSelector} from ${JSON.stringify(selectedColumn)}`,
+ );
try {
jsonSelectedColumn = JSONPath({
path: mapping.jsonSelector,