fix: 只读/调试模式允许读取传输请求与版本(enableTransports 只控制只读传输工具族,写仍由 allowedPackages/allowTransportableEdits 拦截)

This commit is contained in:
QQ597901027
2026-10-21 10:32:46 +08:00
parent bde2d48557
commit fdd202caa1
5 changed files with 26 additions and 16 deletions
+4 -2
View File
@@ -82,10 +82,12 @@ profile 的 `package.json`:
| 模式 | 策略 | 说明 |
|---|---|---|
| 只读 | `allowedPackages` 哨兵值、`enableTransports=false`、`allowTransportableEdits=false`、`allowExecution=false`、`allowDebugger=false` | 安全基线 |
| 调试 | 只读 + `allowExecution=true` + `allowDebugger=true` | 断点/单步/变量/栈 |
| 只读 | `allowedPackages` 哨兵值、`allowTransportableEdits=false`、`allowExecution=false`、`allowDebugger=false`;`enableTransports=true`(**仅用于读**传输请求/版本) | 安全基线:可搜索/读源码/读传输请求与版本/数据预览,写与激活全部拒绝 |
| 调试 | 只读 + `allowExecution=true` + `allowDebugger=true` | 额外允许执行触发断点、断点/单步/变量/栈;写与传输修改仍关闭 |
| 更改 | `allowTransportableEdits=true`、`enableTransports=true`、`allowExecution=true`、`allowDebugger=true`、白名单 | 写前 diff、传输请求纪律 |
> 说明:abap-adt 的 `enableTransports` 会把整个 transport 工具族(`adt_transports`、`adt_object_versions`、`adt_cochange`)一起关掉——这些在 0.12.2 里**都是只读工具**,所以只读/调试模式保持 `enableTransports=true`,真正拦写的是 `allowedPackages` 哨兵值 + `allowTransportableEdits=false`。
- 模式切换**只在设置页**,会话里不提供开关(安全);
- 只读/调试下白名单不生效但会保留,切回更改时复用;
- 白名单存在 `<workspace>/.dsh-abap-adt/ui-settings.json`(本插件私有,abap-adt 不会读取)。