
Security News
Deno Goes the Way of the Dinosaur
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.
dsh-dragview
Advanced tools
DragView 是 DSH 的拖拽文件与预览插件:把本地文件拖进聊天界面,按配置复制进工作区或只解析真实路径,在输入框中渲染成 Codex 风格附件卡片,并安全预览或用系统默认应用打开——不把路径显示给用户。
GitHub 仓库名为 DragView,npm 与 DSH 包名为 dsh-dragview;品牌与 drag 搜索词同时保留,便于在 GitHub 和 DSH 插件市场检索。
| 模式 | 行为 | 适合场景 |
|---|---|---|
resolve(默认) | 拖入后解析文件的真实绝对路径,不复制、不动原文件 | 引用工作区已有文件;不破坏文件与邻居依赖的关系 |
copy | 松手即把文件字节复制进 <工作区>/<dropDir>/(默认 .drops),返回副本路径 | 拖入工作区外的任意文件,让模型能稳定读取 |
图片(image/*)不经过本插件,保留平台原生附件通道(缩略图、预览、历史渲染)。
@"<绝对路径>" 的文件引用(纯文本模型可读),但绝对路径不会进入附件 DOM、标题或浏览器日志。浏览器出于安全不会把真实路径交给网页,插件按顺序定位:
es.exe)才启用,否则用 PowerShell 递归兜底;macOS Spotlight;Linux plocate/locate。候选按名称+大小去重,按 |mtime − lastModified| 排序;即使只有一个 metadata 候选也必须经过内容证明。小于等于 3 × 64 KB 时 sample 已覆盖全文件;更大文件的 sample 匹配后必须再做全量指纹。候选绝对路径只保存在 host 的短期 resolution 中,浏览器只持有不透明 resolutionId/choiceId;仍分不清时选择器只显示安全编号。失败会弹出提示,不静默。
fileId;预览、系统打开与撤销接口只接受该 ID。realpath、文件类型、大小、mtime、设备号与 inode;过期、撤销、变化或非法 token 均拒绝。copy 只能写入当前 session 在 workspace registry 中权威绑定的工作区。dropDir 禁止绝对路径、..、符号链接/junction 与前缀碰撞逃逸。dshDragFileHost。drag-file host 验证来源仍位于该 exportRoot:resolve 直接为原导出文件签发 token,不创建工作区副本;只有 copy 才受限读取最多 4 MiB,并安全复制到 parent session 权威工作区的 .dsh-side-chat-exports 后注册。浏览器事件只接收已签发的 opaque token 与显示/发送元数据,不接收路径或 Markdown 来换取权限;未安装 drag-file 时,side-chat 仍以自身保存的 savedPath 创建 DSH 原生 reference chip。shell: false;不拼接 shell 命令。inline、no-store、nosniff,支持单段 Range(206/416)。文本文件最大 10 MB,最多读取并显示前 1 MB;无论原扩展名/MIME 是 HTML、XML、代码还是 Markdown,文本预览响应均强制 text/plain 并附加 sandbox CSP,避免主动内容执行。wx 创建后重新 realpath 验证目标仍位于 canonical workspace。受 Node 跨平台 API 限制,同权限恶意进程在验证与创建之间替换目录的极窄竞态不能被描述为完全消除,详见交接文档。npm run build # 产出 host/client bundle 与安全、指纹、rail 测试产物
npm run check
npm test # token/路径约束/Range/MIME/open argv/side 内容桥回归
把包同步到 web profile:
~/.hanako/plugin-data/dsh-hanako/dsh-home/profiles/web/node_modules/dsh-dragview/
├── src/ # 构建产物
├── package.json
└── cordis.patch.yml
并在 profiles/web/cordis.patch.yml 追加:
- insert:
- id: drag-file
name: dsh-dragview
客户端刷新页面即生效;host 端改动需重启 dsh web。
发布到 npm 后可直接 dsh plugin add dsh-dragview(dsh 字段 + dsh.bundle.patch 已声明)。
注:npm 上的
dsh-drag-file是其他维护者的既有包,不是 DragView;请使用完整包名dsh-dragview。GitHub 仓库改名后通常会为旧 URL 保留跳转,但 npm 包名不支持别名。
为避免旧配置和 side-chat 集成失效,改名后仍保留以下稳定接口:
drag-file;dsh-drag-file:add-pill;dshDragFileHost;/file-drop;dsh-drag-file-* DOM/CSS/data/header 标识。这些是有意保留的协议名,不表示仍需安装旧 npm 包。
CHANGELOG.md。SECURITY.md。docs/RELEASING.md。DSH 设置里新增 drag-file 分区:
mode:resolve(默认)| copydropDir:复制目标相对工作区的文件夹名,默认 .dropssrc/** 是源码(TypeScript);src/*.js / src/client.js 是构建产物,改动源码后必须 npm run build。/file-drop/config、resolve、copy、preview、text-preview、open、revoke;side-chat 导出使用 dshDragFileHost 的 host-to-host capability,不开放浏览器注册路由(见 src/index.ts)。src/client/index.ts)。常用类型(PDF/DOC/XLS/PPT/压缩/视频/音频/代码/文本)用 Bootstrap Icons 的内嵌 SVG 图标;其余类型直接把扩展名渲染成图标(小圆角方块 + 扩展名文字),不需要为任何新扩展名寻找图标资产。见 src/client/icons.ts。
详见 NOTICE。
FAQs
DragView:为 DeepSeek Harness 提供拖拽文件、Codex 风格附件卡片、安全文件预览与系统打开能力
We found that dsh-dragview demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Security News
Cloudflare is acquiring Deno’s team, which will provide another year of bug fixes and security updates before ending support for the runtime.

Security News
Anthropic’s free OSS Scanner uses Mythos and other Claude models to find open source vulnerabilities and send maintainers reports with proposed fixes.

Security News
On Front Lines’ Early Adopters: CISO podcast, Andrew Becherer shares lessons from Datadog, weighs the long-term costs of AI-built tools, and explains how founders can actually gain a CISO’s trust.