@eduwork/dsh-mail 0.2.1 → 0.2.2

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.
package/CHANGELOG.en.md CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  [简体中文](CHANGELOG.md) | **English**
4
4
 
5
+ ## 0.2.2 — 2026-10-24
6
+
7
+ - Load mail protocol and parsing libraries on the first mail tool call, reducing module evaluation during plugin startup; concurrent calls share module loading.
8
+ - Preserve read-only IMAP, reading/sending switches, send approvals and attachment permission boundaries, including existing failure and cancellation handling.
9
+
5
10
  ## 0.2.1 — 2026-10-22
6
11
 
7
12
  - Show email-send and attachment-save approval prompts in the active DSH UI language (Chinese or English), using the official approval panel.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  **简体中文** | [English](CHANGELOG.en.md)
4
4
 
5
+ ## 0.2.2 — 2026-10-24
6
+
7
+ - 邮件协议与解析库改为首次执行邮件工具时加载,减少插件启动时的模块求值;并发调用复用模块加载。
8
+ - 保留只读 IMAP、收发开关、发信审批及附件权限边界,失败和取消继续走原有处理。
9
+
5
10
  ## 0.2.1 — 2026-10-22
6
11
 
7
12
  - 发信和附件保存的审批提示随 DSH 界面语言显示中英文,继续使用官方审批面板。
@@ -56,7 +56,7 @@ This trades a small amount of latency for simpler credential rotation, cleanup,
56
56
 
57
57
  Outbound attachments use `ctx.fs`: resolve from the session `cwd`, verify containment, require a regular file, enforce an aggregate size bound, then use bounded `readBytes`.
58
58
 
59
- The Host artifact embeds the IMAP/SMTP implementation libraries in `lib/index.js`. Users do not install a second protocol runtime after npm, source-package, or offline-product installation, and plugin dependencies cannot collide with a product's private Node runtime during updates.
59
+ The Host artifact embeds the IMAP/SMTP and mail parsing libraries in a separate bundled module, loaded on the first mail tool execution. The startup entry still registers settings, tools, and permission checks. Users do not install a second protocol runtime after npm, source-package, or offline-product installation.
60
60
 
61
61
  DSH `0.2.1-rc.2` does not expose `writeBytes`. Attachment download therefore requires a local Host filesystem. The plugin resolves the logical destination with `ctx.fs`, creates the directory, resolves real workspace and directory paths, rechecks containment to reject pre-existing symlinks or junctions, and finally performs a random-name `wx` exclusive write. Replace this local adapter when DSH provides an official binary-write seam.
62
62
 
@@ -64,7 +64,7 @@ handle 用于完整性检查和防误用,不是授权令牌,也不包含密
64
64
 
65
65
  发送附件完全走 `ctx.fs`:以会话 `cwd` 解析、验证包含关系、检查普通文件、累计大小,再通过 `readBytes` 有界读取。
66
66
 
67
- Host 产物会把 IMAP/SMTP 运行依赖编入 `lib/index.js`。因此通过 npm、源码包或产品离线装配安装后,终端用户都不需要再安装 Node 依赖;这也避免了插件依赖与宿主随版本更新的私有 Node 运行时互相覆盖。
67
+ Host 产物把 IMAP/SMTP 和邮件解析依赖编入包内的独立模块,首次执行邮件工具时才加载。启动入口仍注册设置、工具和权限检查。通过 npm、源码包或产品离线装配安装后,终端用户不需要再安装 Node 依赖。
68
68
 
69
69
  DSH `0.2.1-rc.2` 暂无 `writeBytes`。下载附件因此只在本地 Host FS 上可用:插件先用 `ctx.fs` 解析逻辑路径,创建目录后再解析工作区与目标目录的真实路径并重新验证包含关系,最后把随机文件名以 `wx` 独占模式写入。这样会拒绝预置符号链接或目录联接造成的工作区逃逸。未来官方提供二进制写 seam 后,应删除这段本地适配,直接复用官方能力。
70
70