LineWalker fbfdc38dc8 fix(share): require login for share links, then return to the shared page
Opening /workspace/share/<token> while signed out rendered an empty ChatView
(header stuck on "New Chat") on top of a burst of 401s. Not a regression: every
endpoint behind a share has been LoginUserDep-gated since it was introduced, so
the share_link check inside those handlers was unreachable without a session —
the middleware anonymous allowlist only ever covered /api/v1/share-link itself.
Share links are viewable by any logged-in user (owner or not); anonymous viewing
was never supported. So gate the route explicitly instead of failing blank.

client:
- RequireLogin guards share/:token/:vid? — the route hangs directly off
  AuthLayout, so nothing used to stop it mounting content while unauthenticated.
  Three states: startup spinner / handoff card + redirect / blocked. A
  sessionStorage one-shot marker stops a redirect loop when the round trip comes
  back still anonymous.
  Authentication is read as `isAuthenticated || user`: isAuthenticated is state
  written from an effect and trails the Recoil user by one render. Root.tsx
  survives that frame by rendering null; a redirect cannot — it bounced
  signed-in users to the login page.
- loginRedirect centralises "go to login and come back" for the guard and the
  401 interceptor, which had drifted (the interceptor stored only
  location.pathname, losing query and hash). Stores an absolute same-origin URL
  so the platform app's return hop resolves against the right origin, is
  idempotent across a burst of parallel 401s, and takes force for a
  user-initiated retry.
- LoginHandoff is deliberately not an error screen: the link is fine, the viewer
  just has not identified themselves and will be returned here. Hence no lock
  illustration and no danger red; the one expressive element is a trace whose
  dot runs the rule and comes back, encoding the round trip.

platform:
- consumeLoginReturnTo validates (same-origin + 10 min freshness) and consumes
  the return target in one place. Also consumed on the authenticated landing in
  App.tsx, which is the only path an SSO/gateway callback takes — the local
  login form was the sole consumer before, so SSO users landed on the home page.

backend:
- bypass_tenant_filter_if widens share-token-authorized reads past tenant
  scoping. message / session / linsight_session_version / linsight_execute_task
  are all tenant-aware, so a recipient in another child tenant read nothing, the
  endpoint skipped its authorization branch and answered 200 [] — a blank page
  with no error. Only widens the read, only with a token; the owner /
  share_link check still runs afterwards.
- header_share_token_parser swallows NotFoundError to honour its
  Optional[ShareLink] contract. It started raising, which made ANY request
  carrying a stale share-token header 404 — including the session owner's own.
- file_download now accepts a whole-conversation (workbench_chat) share too, not
  just meta_data.versionId, so a task-mode share recipient can download the
  files the task produced.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-06 21:43:17 +08:00
2026-07-17 20:07:14 +08:00
2026-06-08 17:02:32 +08:00
2026-06-18 14:36:13 +08:00
2026-01-08 12:05:16 +08:00
2025-12-19 16:40:31 +08:00
2024-05-14 21:59:13 -04:00
2024-05-31 14:38:47 +08:00
2025-08-19 21:34:49 +08:00
2025-08-19 21:33:04 +08:00
2025-01-13 19:06:29 +08:00
2026-03-13 17:23:39 +08:00

Proudly made by ChineseMay we, like the creators of Deepseek and Black Myth: Wukong, bring more wonder and greatness to the world.

源自中国匠心,希望我们能像 [Deepseek]、[黑神话:悟空] 团队一样,给世界带来更多美好。

Bisheng banner

license

简体中文 | English | 日本語

dataelement%2Fbisheng | Trendshift

BISHENG is an open LLM application devops platform, focusing on enterprise scenarios. It has been used by a large number of industry leading organizations and Fortune 500 companies.

"Bi Sheng" was the inventor of movable type printing, which played a vital role in promoting the transmission of human knowledge. We hope that BISHENG can also provide strong support for the widespread implementation of intelligent applications. Everyone is welcome to participate.

Features

  1. Lingsight, a general-purpose agent with expert-level taste: Through the AGL(Agent Guidance Language) framework, we embed domain experts preferences, experience, and business logic into the AI, enabling the agent to exhibit “expert-level understanding” when handling tasks.

sence1

  1. Unique BISHENG Workflow

    • 🧩 Independent and comprehensive application orchestration framework: Enables the execution of various tasks within a single framework (while similar products rely on bot invocation or separate chatflow and workflow modules for different tasks).
    • 🔄 Human in the loop: Allows users to intervene and provide feedback during the execution of workflows (including multi-turn conversations), whereas similar products can only execute workflows from start to finish without intervention.
    • 💥 Powerful: Supports loops, parallelism, batch processing, conditional logic, and free combination of all logic components. It also handles complex scenarios such as multi-type input/output, report generation, content review, and more.
    • 🖐️ User-friendly and intuitive: Operations like loops, parallelism, and batch processing, which require specialized components in similar products, can be easily visualized in BISHENG as a "flowchart" (drawing a loop forms a loop, aligning elements creates parallelism, and selecting multiple items enables batch processing).

    sence0

  2. Designed for Enterprise Applications: Document review, fixed-layout report generation, multi-agent collaboration, policy update comparison, support ticket assistance, customer service assistance, meeting minutes generation, resume screening, call record analysis, unstructured data governance, knowledge mining, data analysis, and more.
    The platform supports the construction of highly complex enterprise application scenarios and offers deep optimization with hundreds of components and thousands of parameters.

sence1

  1. Enterprise-grade features are the fundamental guarantee for application implementation: security review, RBAC, user group management, traffic control by group, SSO/LDAP, vulnerability scanning and patching, high availability deployment solutions, monitoring, statistics, and more.

sence2

  1. High-Precision Document Parsing: Our high-precision document parsing model is trained on a vast amount of high-quality data accumulated over past 5 years. It includes high-precision printed text, handwritten text, and rare character recognition models, table recognition models, layout analysis models, and seal models., table recognition models, layout analysis models, and seal models. You can deploy it privately for free.

sence3

  1. A community for sharing best practices across various enterprise scenarios: An open repository of application cases and best practices.

Quick start

Please ensure the following conditions are met before installing BISHENG:

  • CPU >= 4 Virtual Cores
  • RAM >= 16 GB
  • Docker 19.03.9+
  • Docker Compose 1.25.1+

Recommended hardware condition: 18 virtual cores, 48G. In addition to installing BISHENG, we will also install the following third-party components by default: ES, Milvus, and Onlyoffice.

Download BISHENG

git clone https://github.com/dataelement/bisheng.git
# Enter the installation directory
cd bisheng/docker

# If the system does not have the git command, you can download the BISHENG code as a zip file.
wget https://github.com/dataelement/bisheng/archive/refs/heads/main.zip
# Unzip and enter the installation directory
unzip main.zip && cd bisheng-main/docker

Start BISHENG

docker compose -f docker-compose.yml -p bisheng up -d

After the startup is complete, access http://IP:3001 in the browser. The login page will appear, proceed with user registration.

By default, the first registered user will become the system admin.

For more installation and deployment issues, refer to:Self-hosting

Acknowledgement

This repo benefits from langchain langflow unstructured and LLaMA-Factory . Thanks for their wonderful works.

Thank you to our contributors

Community & contact

Welcome to join our discussion group

Wechat QR Code
S
Description
BISHENG is an open LLM devops platform for next generation Enterprise AI applications. Powerful and comprehensive features include: GenAI workflow, RAG, Agent, Unified model management, Evaluation, SFT, Dataset Management, Enterprise-level System Management, Observability and more.
Readme 254 MiB
Languages
TypeScript 65.1%
Python 32.2%
CSS 1.3%
JavaScript 1.2%
Shell 0.1%