Commit graph

4237 commits

Author SHA1 Message Date
Danny Avila
77c523ea35
🧽 fix: Strip Admin OAuth Redirect Params (#13181) 2026-05-18 15:27:19 -04:00
Danny Avila
c342e2345b
🪪 fix: Resolve Group-Scoped Config Overrides (#13176)
Some checks are pending
Docker Dev Branch Images Build / build (Dockerfile, lc-dev, node) (push) Waiting to run
Docker Dev Branch Images Build / build (Dockerfile.multi, lc-dev-api, api-build) (push) Waiting to run
GitNexus Index / index (push) Waiting to run
GitNexus Index / post-index (push) Blocked by required conditions
* fix: resolve group-scoped config overrides

* test: fix endpoint config request mock typing

* fix: keep remote agent preauth config tenant-scoped

* test: align config scoping expectations

* test: reproduce group endpoint override resolution
2026-05-18 10:16:20 -04:00
장병희
ac163c2212
🤝 fix: Honor OPENID_REUSE_TOKENS in Admin OAuth Exchange (#13154) 2026-05-18 09:34:58 -04:00
Danny Avila
89d10a0b83
🛡️ fix: Escape People Picker Search Regex (#13169) 2026-05-18 09:04:31 -04:00
github-actions[bot]
d2958bcfea
🌍 i18n: Update translation.json with latest translations (#13128)
Some checks failed
Docker Dev Branch Images Build / build (Dockerfile, lc-dev, node) (push) Has been cancelled
Docker Dev Branch Images Build / build (Dockerfile.multi, lc-dev-api, api-build) (push) Has been cancelled
GitNexus Index / index (push) Has been cancelled
GitNexus Index / post-index (push) Has been cancelled
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-05-15 14:54:13 -04:00
Danny Avila
b549966e4a 🧭 fix: Tighten Action OAuth Endpoint Validation (#13142)
Some checks failed
Docker Dev Images Build / build (Dockerfile, librechat-dev, node) (push) Has been cancelled
Docker Dev Images Build / build (Dockerfile.multi, librechat-dev-api, api-build) (push) Has been cancelled
GitNexus Index / index (push) Has been cancelled
Sync Locize Translations & Create Translation PR / Sync Translation Keys with Locize (push) Has been cancelled
GitNexus Index / post-index (push) Has been cancelled
Sync Locize Translations & Create Translation PR / Create Translation PR on Version Published (push) Has been cancelled
* fix: tighten action OAuth endpoint validation

* fix: reuse action OAuth validation primitives

* fix: preserve action OAuth address exemptions
2026-05-15 14:53:41 -04:00
Danny Avila
f3b165ea84 refactor: Speed Up Subagent Ticker Refresh (#13141) 2026-05-15 14:53:41 -04:00
Danny Avila
27266bbcdc 🛰️ fix: Redact Outbound Telemetry URL Queries (#13133)
* fix: redact outbound telemetry URL queries

* fix: handle telemetry redaction edge cases

* fix: keep sanitized telemetry URLs absolute

* fix: infer https telemetry URL scheme

* fix: avoid port-only telemetry protocol inference

* fix: bracket ipv6 telemetry hosts
2026-05-15 14:53:41 -04:00
JorgeCosta87
5b11a5a076
🪵 chore: Restore Winston Format Factory Shape In Test Mocks (#13139)
Four jest mocks for `winston` in the test suite return the wrong shape:

  api/test/__mocks__/logger.js                                   (returns inner fn directly)
  packages/api/src/agents/__tests__/memory.test.ts               (`format` is a plain object)
  packages/api/src/agents/__tests__/run-summarization.test.ts    (same)
  packages/api/src/agents/__tests__/initialize.test.ts           (same)

Real `winston.format(fn)` returns a Format constructor whose instances
expose a `.transform(info, opts)` method that winston's pipeline calls
with the log info object. The current mocks collapse this:

- `(fn) => fn` returns the inner transform fn directly. When module-load
  code in `@librechat/data-schemas/dist/config/parsers.cjs:52` does
  `const redactFormat = winston.format((info) => ...)`, `redactFormat`
  becomes the inner fn. The next line in `winston.cjs` calls
  `parsers.redactFormat()` which invokes the inner fn with no `info`,
  throwing `TypeError: Cannot read properties of undefined (reading 'level')`.

- `format: { combine, colorize, simple }` makes `winston.format` not
  callable at all — `winston.format((info) => ...)` throws
  `TypeError: winston.format is not a function`.

These currently pass in CI on GitHub Actions Ubuntu / Node 20.19, but
fail reproducibly on Node 24.x and on some Linux distros (verified on
WSL Ubuntu with Node 24.9.0). The CI passes appears to be environmental
luck around jest's mock-hoisting interaction with the workspace symlink
chain — the mocks are genuinely wrong against the data-schemas contract.

The fix: return a thunk that yields `{ transform: fn }` — matches real
winston's shape just enough that module-load completes; the inner fn is
only ever invoked by winston's pipeline (never at load time). Also adds
the full `winston.format.*` method surface (printf, timestamp, errors,
splat, json) plus `addColors` and the `DailyRotateFile`/`File` transports
that data-schemas's dist code references at module-load.

Verification (Node 24.9.0):
  npm run build:data-provider && npm run build:data-schemas && npm run build:api
  cd packages/api && npx jest src/agents/__tests__/{memory,run-summarization,initialize}.test.ts
  → 3 suites, 106 tests, all pass

No production code or behavior changes — test-only patch.

Co-authored-by: Jorge Costa <8352477+JorgeCosta87@users.noreply.github.com>
2026-05-15 14:51:53 -04:00
Danny Avila
ca8c212c0d
🗝️ fix: Protect Model Spec Instructions (#13125)
Some checks failed
Docker Dev Branch Images Build / build (Dockerfile, lc-dev, node) (push) Has been cancelled
Docker Dev Branch Images Build / build (Dockerfile.multi, lc-dev-api, api-build) (push) Has been cancelled
GitNexus Index / index (push) Has been cancelled
GitNexus Index / post-index (push) Has been cancelled
Docker Dev Images Build / build (Dockerfile, librechat-dev, node) (push) Has been cancelled
Docker Dev Images Build / build (Dockerfile.multi, librechat-dev-api, api-build) (push) Has been cancelled
Sync Locize Translations & Create Translation PR / Sync Translation Keys with Locize (push) Has been cancelled
Sync Locize Translations & Create Translation PR / Create Translation PR on Version Published (push) Has been cancelled
* fix: prevent instruction exposure

* fix: tighten model spec preset restoration

* refactor: type model spec preset handling
2026-05-14 10:07:23 -04:00
Danny Avila
b993d9fb28
🛟 test: Restore Playwright Smoke E2E (#13020)
* test: restore Playwright smoke e2e

* test: harden e2e smoke setup

* test: sync e2e server bindings

* test: normalize e2e auth urls
2026-05-14 09:49:26 -04:00
Danny Avila
738ed005b6
🏷️ feat: Hide Model Spec Badge Rows (#13124)
* feat: hide model spec badge row

* chore: import order

* feat: hide model spec badge row
2026-05-14 09:39:55 -04:00
Danny Avila
62da4c28ed
🛡️ fix: Sanitize Agent List Skill Scope (#13122) 2026-05-14 09:27:41 -04:00
Danny Avila
5f7092e029
🏷️ fix: Harden Helm Chart Tag Parsing (#13123) 2026-05-14 09:24:34 -04:00
Danny Avila
050b7fd43a
📡 feat: Add Backend OpenTelemetry Tracing (#12909)
* feat: add backend OpenTelemetry tracing

* fix: address telemetry type checks

* fix: mark aborted telemetry requests as errors

* fix: record telemetry identity after auth

* fix: avoid forced telemetry signal exit

* fix: harden telemetry request attribution

* fix: record telemetry errors on request span

* chore: order imports and reorganize middleware usage

* fix: reduce telemetry startup overhead

* fix: preserve live telemetry controller state

* fix: redact telemetry URL attributes
2026-05-14 09:08:55 -04:00
jingyeong
7e4c5d9ded
🧹 fix: Reset Redis Reorder State After Last Unsubscribe (#13117)
Co-authored-by: parkjingyeong <sand1166@hyundai.com>
2026-05-14 08:45:50 -04:00
Danny Avila
176e07755e
🗂️ refactor: Collapse Generated File Chips (#13116)
* fix: Collapse generated file chips

* style: Apply file chip formatting

* style: Sort grouped file locale key

* fix: Collapse text-backed file outputs

* style: Format text-backed file grouping

* fix: Preview grouped text file outputs

* fix: Count downloadable file outputs

* test: Cover grouped text preview clamp
2026-05-14 07:47:05 -04:00
Josh
c582e87e3b
🛡️ feat: Bedrock Guardrail Config Environment Variable Resolution (#11717)
Some checks are pending
Docker Dev Branch Images Build / build (Dockerfile, lc-dev, node) (push) Waiting to run
Docker Dev Branch Images Build / build (Dockerfile.multi, lc-dev-api, api-build) (push) Waiting to run
GitNexus Index / index (push) Waiting to run
GitNexus Index / post-index (push) Blocked by required conditions
* bedrock config loading

* Update packages/api/src/endpoints/bedrock/initialize.ts

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* test refactor

---------

Co-authored-by: Josh Fink <josh.fink@innovation.nj.gov>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-05-13 23:13:36 -04:00
Danny Avila
ae75fb68a6
📸 refactor: Refresh Shared Links With Latest Snapshot (#13095)
Some checks are pending
Docker Dev Branch Images Build / build (Dockerfile, lc-dev, node) (push) Waiting to run
Docker Dev Branch Images Build / build (Dockerfile.multi, lc-dev-api, api-build) (push) Waiting to run
GitNexus Index / index (push) Waiting to run
GitNexus Index / post-index (push) Blocked by required conditions
* fix: refresh shared links with latest target

* fix: validate shared link refresh payload
2026-05-13 19:38:28 -04:00
Danny Avila
7f58e4c2ed
🧾 feat: Add Structured Logging Context (#13110)
* feat: add structured logging context

* fix: reduce cloudfront disabled logging

* fix: preserve strict reject logging context

* chore: format auth middleware test

* fix: omit system tenant from log context

* fix: type parser spec formatter info

* fix: normalize tenant guard before reject checks
2026-05-13 19:17:39 -04:00
Danny Avila
9e8b8c3705
🧰 fix: Scope MCP Registry Initialization To Config Fingerprints (#13115) 2026-05-13 16:50:07 -04:00
Danny Avila
34dd8d5f2a
📈 feat: Add Prometheus Metrics Endpoint + AWS Credential Providers (#13111)
* feat: add prometheus metrics endpoint

* fix: format metrics route spec

* chore: update dependencies in package.json and package-lock.json correctly

- Bump `@smithy/core` to version 3.24.1
- Update `@aws-sdk/credential-providers` to version 3.1045.0
- Reintroduce `prom-client` dependency in package.json
- Remove unnecessary dependencies from package.json

* chore: import order

* fix: declare s3 presigner peer dependency

* fix: normalize shared link metrics path

* fix: bound metrics path labels

* fix: tighten metrics auth and peers

* fix: collapse partial metrics paths
2026-05-13 16:49:25 -04:00
Dan Lew
83ea3efbc1
🚧 feat: Support Guardrail Config Option streamProcessingMode (#12815)
`streamProcessingMode` affects how guardrail processes the stream from
the model. If it's in "sync" mode, it chunks up the response and processes
them before returning them to the user. If it's in "async" mode, it
both processes the chunk & sends it to the user at the same time, allowing
for smoother streaming (at the cost of guardrail only reacting *after*
offending content starts to stream, in some cases).
2026-05-13 14:54:50 -04:00
github-actions[bot]
e0a4e53b7f
🌍 i18n: Update translation.json with latest translations (#13107)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-05-13 13:14:00 -04:00
Danny Avila
947bfa4c40
📚 docs: Add Skills, Subagents, and CloudFront References (#13096) 2026-05-12 21:41:09 -04:00
Danny Avila
68d80f3324
v0.8.6-rc1 (#13094) 2026-05-12 21:40:23 -04:00
Danny Avila
8eb9de011f
📦 chore: bump @librechat/agents to v3.1.86, npm audit, build fix (#13105)
* 📦 chore: Bump `@librechat/agents` to v3.1.86 in package-lock.json and package.json files

* 📦 chore: Update dependencies in package-lock.json to latest versions, including @protobufjs/codegen, @protobufjs/inquire, @protobufjs/utf8, and protobufjs

* 📦 chore: Add `librechat-data-provider` dependency in package.json and package-lock.json, and update build dependencies in turbo.json
2026-05-12 16:19:55 -04:00
Danny Avila
b570ce4cd7
🐳 ci: Build Docker Client Package With Data Provider Dist (#13097) 2026-05-12 15:24:41 -04:00
Danny Avila
6b5596ec36
🍪 refactor: Refresh CloudFront Media Cookies (#13091)
* fix: refresh CloudFront media cookies

* fix: satisfy changed-file lint

* fix: centralize CloudFront image retry

* fix: honor base path for CloudFront refresh

* fix: bypass auth refresh for CloudFront cookie retry

* fix: pass app auth header to CloudFront retry

* test: cover CloudFront refresh with OpenID reuse

* fix: avoid duplicate CloudFront refresh retries

* fix: clear CloudFront scope cookie with matching flags
2026-05-12 13:26:05 -04:00
Ravi Kumar L
05d4e90f91
🌩️ feat: Strict CloudFront signed cookie enforcement via requireSignedAccess (#13078)
* feat(cloudfront): add requireSignedAccess to enforce strict signed access

Introduces cloudfront.requireSignedAccess (default false). When enabled,
initializeCloudFront requires both CLOUDFRONT_KEY_PAIR_ID and
CLOUDFRONT_PRIVATE_KEY, rejects the unimplemented imageSigning="url"
mode, and initializeFileStorage throws to block startup on any
CloudFront init failure. OSS path is unchanged: missing keys still
log-and-continue when requireSignedAccess is false.

Adds low-noise startup and cookie-issuance logs without leaking signed
URLs, policies, signatures, private keys, or cookie values.

* fix(cloudfront): reject requireSignedAccess unless imageSigning is "cookies"

Previously requireSignedAccess=true was accepted with imageSigning="none"
or "url", but setCloudFrontCookies() only runs for "cookies" — leaving
strict mode toothless: CloudFront stayed publicly accessible, or image
delivery broke on a distribution that actually requires signed access.

Adds a Zod refinement plus a runtime guard in initializeCloudFront so
the only currently-functional strict configuration is imageSigning
"cookies". Signed URL mode can lift this restriction once implemented.

* fix(cloudfront): resolve strict access type checks

* chore(cloudfront): reduce strict startup log noise

---------

Co-authored-by: Danny Avila <danny@librechat.ai>
2026-05-11 23:30:01 -04:00
Danny Avila
7b9a57a467
🛡️ fix: Harden OpenID Session Token Reuse (#13086)
* fix: Harden OpenID Session Token Reuse

* fix: Preserve OpenID Session Token On Forced Refresh

* fix: Gate Preserved OpenID Id Token By Expiry

* test: Cover OpenID Id Token Expiry Buffer
2026-05-11 23:29:01 -04:00
Danny Avila
17a08224e1
🍪 fix: Refresh CloudFront Cookies On Auth Refresh (#13083)
* fix: Refresh CloudFront Cookies On Auth Refresh

* fix: Exclude Federated Tokens From Refresh Lookup
2026-05-11 22:33:27 -04:00
github-actions[bot]
929082387f
🌍 i18n: Update translation.json with latest translations (#13080)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-05-11 21:15:53 -04:00
Danny Avila
3e7262cfe0
📦 chore: Bump @librechat/agents to v3.1.85 and mermaid to v11.15.0 (#13079)
* 📦 chore: Update @librechat/agents to version 3.1.85 in package-lock.json and package.json files

* 📦 chore: Update mermaid to version 11.15.0 in package.json and package-lock.json
2026-05-11 19:14:18 -04:00
Danny Avila
0a7255b234
🎭 feat: Support OpenID Audience On Refresh Grants (#13077) 2026-05-11 17:40:30 -04:00
Danny Avila
36e95353ed
🏷️ refactor: Rename Code Interpreter Labels To Run Code (#13071)
* fix: Rename Code Interpreter UI to Run Code

* fix: Remove unused Run Code i18n keys

* fix: Restore tool call labels

* fix: Keep assistant Code Interpreter copy

* fix: Update agent code environment copy

* fix: Update code environment upload copy

* fix: Use fresh run code locale keys

* fix: Update code environment test copy

* fix: Sort upload translation test keys
2026-05-11 16:24:33 -04:00
Danny Avila
c385f2ba88
📦 feat: Configure Skill Import Size Limit (#13073)
* fix: configure skill import size limit

* fix: validate skill import size in ui

* fix: align skill import size boundary

* fix: show exact skill import limit
2026-05-11 16:24:04 -04:00
Danny Avila
8735c1763c
🧵 fix: Preserve Upload Context Across Multipart Routes (#13072)
* fix skill multipart imports under strict isolation

* fix file upload context after multipart parsing

* fix skill upload tenant resolution

* fix rejected upload cleanup
2026-05-11 15:46:48 -04:00
Danny Avila
b32b328b87
🛡️ fix: Harden Artifact Routing Lookups (#13069) 2026-05-11 15:42:44 -04:00
Odrec
0f59cd79dd
🪙 fix: Pass appConfig to getBalanceConfig in set-balance script (#13070)
`config/set-balance.js` calls `getBalanceConfig()` without an argument,
so it cannot read the parsed `balance` section from librechat.yaml.
As a result the script always errors with "Balance is not enabled.
Use librechat.yaml to enable it" — even when balance is enabled.

`config/add-balance.js` already follows the correct pattern (fetch
`appConfig` via `getAppConfig()` and pass it into `getBalanceConfig`),
introduced in #9234. This applies the same pattern to set-balance.js.

Co-authored-by: Odrec <Odrec@users.noreply.github.com>
2026-05-11 15:08:23 -04:00
Danny Avila
0449c423a2
🗝️ fix: Enforce Skill Share Role Permission (#13062)
* fix: enforce skill share role permission

* fix: preserve share capability bypass

* refactor: move share policy middleware to api package

* style: order share middleware imports

* fix: satisfy share middleware type checks

* test: cover share policy resource types
2026-05-11 09:39:58 -04:00
Danny Avila
7631366f52
🪵 chore: Log Subagent Limit Hits (#13068) 2026-05-11 09:25:08 -04:00
Danny Avila
70b6bb69d3
🧬 fix: Bound Subagent Expansion (#13064)
* fix: Bound subagent expansion

* fix: Preserve subagent path depth
2026-05-11 08:53:53 -04:00
github-actions[bot]
508168fa57
🌍 i18n: Update translation.json with latest translations (#13058)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-05-11 08:41:16 -04:00
Danny Avila
9797c85e23
🧮 fix: Count Rejected Skill Import Bytes (#13063) 2026-05-11 08:40:31 -04:00
Danny Avila
822ad6c36a
🧯 fix: Bound Permission Superset Cache Inputs (#13065) 2026-05-11 08:39:37 -04:00
Danny Avila
52ccb1379b
🪪 refactor: Require Remote OIDC Audience for Agents API OAuth (#13066) 2026-05-11 08:38:13 -04:00
Danny Avila
7129b1b1e4
📜 refactor: Improve Skill Handling Logs (#13057)
* refactor: Streamline batch upload error handling in `uploadCodeEnvFile`
* refactor: Enhance session info error logging in `getSessionInfo`
* refactor: Update error logging to use `logAxiosError` in various agent handlers and skill file processing functions
* refactor: Consolidate missing resource checks in `createToolExecuteHandler` for better clarity
2026-05-11 02:15:51 -04:00
Danny Avila
763fab2e3e
🛂 fix: Restrict OpenID JWT Bearer Reuse (#13052)
* fix: Restrict OpenID JWT bearer reuse

* fix: Require signed OpenID reuse cookie

* fix: Bind OpenID reuse to authenticated user
2026-05-11 02:00:38 -04:00
Danny Avila
846eb0aa2c
🛰️ fix: Validate Vertex Endpoint Overrides (#13054)
* fix: Validate Vertex endpoint overrides

* fix: Allow Vertex PSC endpoint overrides

* fix: Allow restricted Vertex PSC endpoints
2026-05-11 01:11:14 -04:00