dsh-auth-remote 0.1.6 → 0.1.8
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.md +9 -0
- package/CHANGELOG.zh-CN.md +9 -0
- package/README.md +5 -3
- package/README.zh-CN.md +5 -3
- package/cordis.patch.yml +3 -3
- package/dist/index.js +15 -6
- package/dist/index.js.map +3 -3
- package/dist/types/http/gate.d.ts.map +1 -1
- package/dist/types/http/origin-policy.d.ts.map +1 -1
- package/dist/types/http/public-assets.d.ts +3 -0
- package/dist/types/http/public-assets.d.ts.map +1 -0
- package/dist/types/index.d.ts +1 -1
- package/dist/types/index.d.ts.map +1 -1
- package/docs/deployment.md +4 -2
- package/docs/deployment.zh-CN.md +4 -2
- package/docs/development.md +1 -1
- package/docs/development.zh-CN.md +1 -1
- package/docs/legacy-compatibility.md +13 -11
- package/docs/releasing.md +5 -5
- package/docs/releasing.zh-CN.md +5 -5
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"gate.d.ts","sourceRoot":"","sources":["../../../src/http/gate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,WAAW,CAAA;AAChE,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,aAAa,CAAA;AACzC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAChE,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAA;AAEhD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAA;AAEtD,OAAO,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA;AACpD,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAA;
|
|
1
|
+
{"version":3,"file":"gate.d.ts","sourceRoot":"","sources":["../../../src/http/gate.ts"],"names":[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{"version":3,"file":"origin-policy.d.ts","sourceRoot":"","sources":["../../../src/http/origin-policy.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"origin-policy.d.ts","sourceRoot":"","sources":["../../../src/http/origin-policy.ts"],"names":[],"mappings":"AAEA,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,QAAQ,CAAA;AAE/C,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,QAAQ,EAAE,cAAc,CAAA;IACjC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,WAAW,EAAE,SAAS,MAAM,EAAE,CAAA;CACxC;AAED,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,iBAAiB,EAAE,SAAS,gBAAgB,EAAE,CAAA;IACvD,cAAc,CAAC,IAAI,EAAE,MAAM,GAAG,gBAAgB,GAAG,SAAS,CAAA;CAC3D;AAED,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,UAAU,EAAE,SAAS,MAAM,EAAE,CAAA;IACtC,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IACnC,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAA;IACnC,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAA;CAC3B;AAED,MAAM,WAAW,oBAAoB;IACnC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,QAAQ,EAAE,cAAc,CAAA;IACjC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAA;IAC1B,QAAQ,CAAC,mBAAmB,EAAE,MAAM,CAAA;IACpC,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAA;IACzB,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAA;IAC5B,QAAQ,CAAC,cAAc,EAAE,OAAO,CAAA;CACjC;AA4ED,oGAAoG;AACpG,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,GAAG,YAAY,CAgC3E;AAkDD,oFAAoF;AACpF,wBAAgB,qBAAqB,CACnC,MAAM,EAAE,YAAY,EACpB,OAAO,EAAE,cAAc,GACtB,oBAAoB,GAAG,IAAI,CAyD7B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"public-assets.d.ts","sourceRoot":"","sources":["../../../src/http/public-assets.ts"],"names":[],"mappings":"AAEA,yEAAyE;AACzE,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,EAAE,QAAQ,EAAE,MAAM,GAAG,OAAO,CAEtF"}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -30,7 +30,7 @@ export declare class AuthRemoteWebServer extends GuardedWebServer {
|
|
|
30
30
|
get publicUrl(): string;
|
|
31
31
|
get storage(): AuthStateStore;
|
|
32
32
|
get authentication(): AuthService;
|
|
33
|
-
/**
|
|
33
|
+
/** Declare the finalized bridge and any public authorities used by preserved routes. */
|
|
34
34
|
get connectionTrustedHosts(): readonly string[];
|
|
35
35
|
}
|
|
36
36
|
export default AuthRemoteWebServer;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":"AAAA,4EAA4E;AAC5E,OAAO,EAAE,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,qBAAqB,CAAA;AAO3D,OAAO,EAAY,gBAAgB,EAAc,MAAM,6BAA6B,CAAA;AACpF,OAAO,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAA;AAC/C,OAAO,EAIL,KAAK,UAAU,EAIhB,MAAM,aAAa,CAAA;AAKpB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ACvD,OAAgB,MAAM,EAAwB,OAAO,gBAAgB,CAAC,MAAM,CAAA;IAC5E,OAAO,CAAC,UAAU,CAA4B;IAC9C,OAAO,CAAC,WAAW,CAAyB;IAC5C,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAmB;IAC3C,OAAO,CAAC,cAAc,CAAgC;IACtD,OAAO,CAAC,QAAQ,CAAC,UAAU,CAAY;gBAE3B,GAAG,EAAE,OAAO,EAAE,KAAK,EAAE,UAAU;IAmB5B,CAAC,OAAO,CAAC,IAAI,CAAC,IAAI,OAAO,CAAC,IAAI,CAAC;IA+F9C,OAAO,KAAK,QAAQ,GAGnB;IAED,qFAAqF;IACrF,IAAI,SAAS,IAAI,MAAM,CAEtB;IAED,IAAI,OAAO,IAAI,cAAc,CAG5B;IAED,IAAI,cAAc,IAAI,WAAW,CAGhC;IAED,wFAAwF;IACxF,IAAI,sBAAsB,IAAI,SAAS,MAAM,EAAE,CAK9C;CACF;AAED,eAAe,mBAAmB,CAAA"}
|
package/docs/deployment.md
CHANGED
|
@@ -10,7 +10,7 @@ Install the published package into the default `web` profile:
|
|
|
10
10
|
|
|
11
11
|
```sh
|
|
12
12
|
dsh --version
|
|
13
|
-
dsh plugin --profile web add dsh-auth-remote@0.1.
|
|
13
|
+
dsh plugin --profile web add dsh-auth-remote@0.1.8
|
|
14
14
|
dsh plugin --profile web list
|
|
15
15
|
dsh web --no-open --port 13090
|
|
16
16
|
```
|
|
@@ -113,9 +113,11 @@ Back up the old patch before upgrading. Replace a single item with `publicUrl: h
|
|
|
113
113
|
|
|
114
114
|
Admission is the one effective public origin plus literal loopback authorities. The URL's root path has no deployment prefix. Requests need one valid Host; mutations and WebSocket upgrades require a matching Origin, and cross-site or mismatched Fetch Metadata is rejected. An old public origin is no longer registered after replacement. `Forwarded` and `X-Forwarded-*` never decide admission or Cookie Secure. CLI `--trusted-host` configures native Connection only and does not enlarge this outer policy.
|
|
115
115
|
|
|
116
|
+
Anonymous GET/HEAD requests to exactly `/manifest.webmanifest`, `/favicon.svg`, and `/favicon-dark.svg` pass through to DSH's static server without a session. These PWA metadata and icons retain the same Host, Origin, Fetch Metadata, and readiness checks; HEAD on these paths accepts an absent Origin just like GET. The sign-in page links the manifest and allows it in CSP, so browsers can read application metadata before sign-in. Business pages, APIs, other assets, other methods, and WebSocket upgrades remain protected. Browser installation also depends on the upstream manifest and the browser's own requirements.
|
|
117
|
+
|
|
116
118
|
Plugin cookies follow the validated external origin and are host-only, HttpOnly and SameSite; HTTPS sets Secure. Native bridge credentials stay server-side and follow the native listener protocol, including HTTPS cookie audience/Secure when a public HTTP proxy fronts native HTTPS. Ports do not isolate browser cookies.
|
|
117
119
|
|
|
118
|
-
Standard `/api` routes work with `preserveOriginPaths: []`; there is no need to list `/api`. Add a prefix only when a downstream route needs the original public Host. The plugin forwards an Origin only when the request supplied one, and preflights the selected public authority for preserved paths. No separate Connection row
|
|
120
|
+
Standard `/api` routes work with `preserveOriginPaths: []`; there is no need to list `/api`. The plugin always declares its finalized native bridge authority in Connection's `trustedHosts`, using the actual bound port (including `--port 0`), so downstream plugins that read this list can recognize the bridge without an extra trusted-host flag. Explicit CLI trusted hosts are merged and deduplicated; they do not expand the outer public-origin policy. Add a prefix only when a downstream route needs the original public Host. The plugin forwards an Origin only when the request supplied one, and preflights and declares the selected public authority for preserved paths. No separate Connection row is needed. Ordinary alpha.2 routes use the normalized native bind authority; older Connection retains its internal HTTP loopback bridge. Both paths still require a full session. Revocation, Connection loss or storage failure closes active uploads, streams and upgrades and withdraws business admission. Readiness does not mean the account is initialized.
|
|
119
121
|
|
|
120
122
|
## Start and verify the public entry
|
|
121
123
|
|
package/docs/deployment.zh-CN.md
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
|
|
11
11
|
```sh
|
|
12
12
|
dsh --version
|
|
13
|
-
dsh plugin --profile web add dsh-auth-remote@0.1.
|
|
13
|
+
dsh plugin --profile web add dsh-auth-remote@0.1.8
|
|
14
14
|
dsh plugin --profile web list
|
|
15
15
|
dsh web --no-open --port 13090
|
|
16
16
|
```
|
|
@@ -113,9 +113,11 @@ alpha.2 的 IPv6 回环 HTTPS 可合并以下完整认证条目,使用自己
|
|
|
113
113
|
|
|
114
114
|
准入为唯一生效公开来源加字面回环 authority;URL 根路径不支持部署前缀。请求须有唯一合法 Host,修改请求和 WebSocket 升级须有匹配 Origin;跨站或不匹配 Fetch Metadata 被拒绝。替换后旧公开来源不再登记。`Forwarded`、`X-Forwarded-*` 不决定准入或 Cookie Secure;CLI `--trusted-host` 只配置原生 Connection,不扩大外层策略。
|
|
115
115
|
|
|
116
|
+
匿名 GET/HEAD 请求仅在精确匹配 `/manifest.webmanifest`、`/favicon.svg`、`/favicon-dark.svg` 时,无需会话即可交给 DSH 静态服务处理。这些 PWA 元数据与图标仍受 Host、Origin、Fetch Metadata 和就绪检查约束;这些路径的 HEAD 与 GET 一样允许缺少 Origin。登录页引用 manifest 并在 CSP 中允许加载,浏览器可在登录前读取应用信息。业务页面、API、其他资源、其他方法和 WebSocket 升级仍受鉴权保护;实际安装还取决于上游 manifest 与浏览器自身条件。
|
|
117
|
+
|
|
116
118
|
插件 Cookie 跟随已验证外部来源,限主机、HttpOnly、SameSite,HTTPS 设置 Secure。原生桥接凭据仅保留服务端,跟随原生监听协议;公开 HTTP 代理接入原生 HTTPS 时,其原生 Cookie audience/Secure 仍按 HTTPS。浏览器 Cookie 不通过端口隔离。
|
|
117
119
|
|
|
118
|
-
标准 `/api` 路由在 `preserveOriginPaths: []` 下即可工作,无需列 `/api
|
|
120
|
+
标准 `/api` 路由在 `preserveOriginPaths: []` 下即可工作,无需列 `/api`。插件始终将定稿的原生桥接 authority 登记到 Connection 的 `trustedHosts`,使用实际绑定端口(包含 `--port 0`),读取该列表的下游插件无需额外 trusted-host 参数即可识别桥接地址。显式 CLI trusted hosts 合并去重,不扩大外层公开来源策略。仅在下游需要原始公网 Host 时加入前缀;Origin 仅在请求已有时透传,保留路径预检并登记所选公开 authority。无需单独 Connection 条目。alpha.2 普通路径使用归一化原生 bind authority,旧 Connection 保留内部 HTTP 回环桥接;两类路径均需完整会话。撤销、Connection 丢失或存储故障会关闭活跃上传、流和升级连接,撤回业务准入。ready 不表示账号已初始化。
|
|
119
121
|
|
|
120
122
|
## 启动并验证公开入口
|
|
121
123
|
|
package/docs/development.md
CHANGED
|
@@ -14,7 +14,7 @@ pnpm pack:local
|
|
|
14
14
|
pnpm smoke
|
|
15
15
|
```
|
|
16
16
|
|
|
17
|
-
`pnpm check` runs type checking, formatting, build, package/deployment/document checks, then unit, integration, CLI, and browser tests. `pnpm pack:local` writes `artifacts/dsh-auth-remote-0.1.
|
|
17
|
+
`pnpm check` runs type checking, formatting, build, package/deployment/document checks, then unit, integration, CLI, and browser tests. `pnpm pack:local` writes `artifacts/dsh-auth-remote-0.1.8.tgz` after static checks; it does not publish. `pnpm smoke` installs that archive into an isolated DSH home, starts the pinned DSH runtime briefly, checks readiness, anonymous redirection/denial and an online CLI status, then stops it.
|
|
18
18
|
|
|
19
19
|
## Use the isolated development profile
|
|
20
20
|
|
|
@@ -16,7 +16,7 @@ pnpm pack:local
|
|
|
16
16
|
pnpm smoke
|
|
17
17
|
```
|
|
18
18
|
|
|
19
|
-
`pnpm check` 依次执行类型、格式、构建、包/部署/文档检查,以及单元、集成、CLI 和浏览器测试。`pnpm pack:local` 在静态检查后写出 `artifacts/dsh-auth-remote-0.1.
|
|
19
|
+
`pnpm check` 依次执行类型、格式、构建、包/部署/文档检查,以及单元、集成、CLI 和浏览器测试。`pnpm pack:local` 在静态检查后写出 `artifacts/dsh-auth-remote-0.1.8.tgz`,不会发布。`pnpm smoke` 将包安装到隔离 DSH_HOME,短暂启动固定版本的 DSH,验证就绪、匿名重定向/拒绝和在线 CLI 状态,然后停止。
|
|
20
20
|
|
|
21
21
|
## 使用隔离开发 profile
|
|
22
22
|
|
|
@@ -30,17 +30,17 @@
|
|
|
30
30
|
|
|
31
31
|
## DSH-PROTOCOL-001:旧原生 HTTP 协议假设
|
|
32
32
|
|
|
33
|
-
| 字段 | 内容
|
|
34
|
-
| --------------- |
|
|
35
|
-
| 类型 / 生效状态 | `dsh-runtime` / 旧版 HTTP 和回环 authority 回退保留;现代原生协议/地址桥接已接入
|
|
36
|
-
| 适用 DSH | 前五版没有 TLS/原生绑定 authority 识别;alpha.2 使用原生 protocol 和地址归一化
|
|
37
|
-
| 原因 | 前五版 startup 没有 TLS 配置且 Connection 不认识具体非回环 bind,继续使用服务端 HTTP/127.0.0.1 桥接;监听和公开 URL 仍为实际具体 IPv4。现代分支支持 IPv6/HTTPS
|
|
38
|
-
| 代码 / 上游证据 | `src/adapters/dsh/readiness.ts`、`src/adapters/dsh/browser-auth.ts`、`src/adapters/dsh/startup-urls.ts`、`src/http/gate.ts
|
|
39
|
-
| 实现位置 | `listenerProtocol`、`listenerTransport` 集中旧 HTTP/回环回退;现代回环使用原生 normalizeBindAddress/isLoopbackHost,非回环保留 Connection 绑定 authority 的 WHATWG IPv6 形式并去掉 zone;定稿 nativeAuthority/nativeOrigin 供 readiness 和 gate 共用;browser-auth 校验 token URL 协议和 Cookie Secure。外层 Cookie 按公开来源,原生 Cookie 按监听协议
|
|
40
|
-
| 关联测试 | `tests/integration/native-transport.test.ts`、`tests/browser/native-transport.spec.ts`、`tests/unit/config.test.ts`、既有 dsh-adapter / proxy-chain;包括旧非回环实际包、旧能力拒绝、两种协议方向代理和流撤销
|
|
41
|
-
| 客观退役条件 | 所有不提供原生监听协议能力的 DSH 均退出支持集合
|
|
42
|
-
| 删除 / 调整范围 | 仅能力适配器内旧 HTTP/回环回退与专属能力测试;保留 HTTP 正向、双向代理、Cookie 和撤销安全回归
|
|
43
|
-
| 最后复核依据 | 2026-10-10,rc.1 / alpha.1 真实包非回环绑定曾在统一改写真实 host 后无法激活;恢复旧回环桥接后可认证访问原生设置 API。alpha.2 真实 HTTPS/IPv6 MFA、Host 设置和 CLI 撤销通过;整分支审查发现非回环 mapped IPv6 经 WebServer 归一化后与 Connection 的绑定比较不一致,新增 HTTP/HTTPS、preserveOriginPaths 空数组的实际监听回归。完整六版产物证据由 CLI/browser/smoke 矩阵核对
|
|
33
|
+
| 字段 | 内容 |
|
|
34
|
+
| --------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
35
|
+
| 类型 / 生效状态 | `dsh-runtime` / 旧版 HTTP 和回环 authority 回退保留;现代原生协议/地址桥接已接入 |
|
|
36
|
+
| 适用 DSH | 前五版没有 TLS/原生绑定 authority 识别;alpha.2 使用原生 protocol 和地址归一化 |
|
|
37
|
+
| 原因 | 前五版 startup 没有 TLS 配置且 Connection 不认识具体非回环 bind,继续使用服务端 HTTP/127.0.0.1 桥接;监听和公开 URL 仍为实际具体 IPv4。现代分支支持 IPv6/HTTPS |
|
|
38
|
+
| 代码 / 上游证据 | `src/adapters/dsh/readiness.ts`、`src/adapters/dsh/browser-auth.ts`、`src/adapters/dsh/startup-urls.ts`、`src/http/gate.ts`、`src/index.ts`、[cordis.patch.yml](../cordis.patch.yml);对应 WebApp `lib/startup.js` |
|
|
39
|
+
| 实现位置 | `listenerProtocol`、`listenerTransport` 集中旧 HTTP/回环回退;现代回环使用原生 normalizeBindAddress/isLoopbackHost,非回环保留 Connection 绑定 authority 的 WHATWG IPv6 形式并去掉 zone;定稿 nativeAuthority/nativeOrigin 供 readiness 和 gate 共用;0.1.7 将同一 nativeAuthority 自动登记到 Connection.trustedHosts,保留路径所需公开 authority 与显式 CLI 信任合并去重;browser-auth 校验 token URL 协议和 Cookie Secure。外层 Cookie 按公开来源,原生 Cookie 按监听协议 |
|
|
40
|
+
| 关联测试 | `tests/integration/native-transport.test.ts`、`tests/browser/native-transport.spec.ts`、`tests/unit/config.test.ts`、既有 dsh-adapter / proxy-chain;包括旧非回环实际包、旧能力拒绝、两种协议方向代理和流撤销 |
|
|
41
|
+
| 客观退役条件 | 所有不提供原生监听协议能力的 DSH 均退出支持集合 |
|
|
42
|
+
| 删除 / 调整范围 | 仅能力适配器内旧 HTTP/回环回退与专属能力测试;保留 HTTP 正向、双向代理、Cookie 和撤销安全回归 |
|
|
43
|
+
| 最后复核依据 | 2026-10-10,rc.1 / alpha.1 真实包非回环绑定曾在统一改写真实 host 后无法激活;恢复旧回环桥接后可认证访问原生设置 API。alpha.2 真实 HTTPS/IPv6 MFA、Host 设置和 CLI 撤销通过;整分支审查发现非回环 mapped IPv6 经 WebServer 归一化后与 Connection 的绑定比较不一致,新增 HTTP/HTTPS、preserveOriginPaths 空数组的实际监听回归。完整六版产物证据由 CLI/browser/smoke 矩阵核对 |
|
|
44
44
|
|
|
45
45
|
## DSH-PUBLIC-001:旧宿主公开地址投影边界
|
|
46
46
|
|
|
@@ -113,3 +113,5 @@
|
|
|
113
113
|
2026-10-10 任务 5 复核:旧 HTTP/回环桥接集中在 runtime-capabilities;现代桥接使用原生协议和归一化 authority,zone 不进入便携公开 URL。静态检查、55 项单元、45 项集成通过;alpha.2 原生传输和既有代理浏览器 9/9,rc.1/alpha.1 旧能力拒绝与具体非回环 IPv4 真实包各 4/4,无跳过。TLS 材料错误、Connection 丢失和存储通知故障关闭入口;外层和原生 Cookie 协议独立验证。上述证据来自 0.1.5 开发包;开发包证据不能替代最终 0.1.6 全六版验证。
|
|
114
114
|
|
|
115
115
|
2026-10-10 任务 6 复核:默认测试/开发运行时为 alpha.2,两个既有 CI 矩阵覆盖六版;release 沿用共同默认。原生 systemPrompt Web section 与 DSH_WEB_URL 的最终地址相同且无 token。rc.1/alpha.1/alpha.2 的真实 startup/deployment/native-transport/admin CLI 分别 29/29、29/29、33/33,无跳过;旧多项、重复项、null 及新旧冲突均经过 Loader。静态、55 项单元、45 项集成通过。alpha.2 的最终 0.1.6 六版全量交付另需最终产物证据;onboarding 精确适用范围缺口继续保留。
|
|
116
|
+
|
|
117
|
+
2026-10-10,0.1.7 桥接信任修复复核:`connectionTrustedHosts` 始终返回监听后定稿的 nativeAuthority,保留路径所需公开 authority 与显式 CLI trusted hosts 合并去重。前五版继续登记 HTTP/127.0.0.1 桥接,alpha.2 登记归一化实际监听 authority,不由原始 CLI 参数拼接,亦不扩大外层公开来源。新增实际安装包回环/非回环 CLI host 覆盖与 port 0 回归,六个精确版本各 2/2 通过;验证下游声明列表、CLI 信任保留与去重、匿名拒绝,以及额外可信主机和错误 Origin 仍被外层拒绝。alpha.2 的 0.1.6 安装包已先复现下游 403;完整发布验证另由 CI 执行。支持集合未改变,旧适配继续保留。
|
package/docs/releasing.md
CHANGED
|
@@ -29,18 +29,18 @@ Use the version that is already on `master`:
|
|
|
29
29
|
```sh
|
|
30
30
|
git switch master
|
|
31
31
|
git pull --ff-only origin master
|
|
32
|
-
git tag -a v0.1.
|
|
33
|
-
git push origin v0.1.
|
|
32
|
+
git tag -a v0.1.8 -m "Release v0.1.8"
|
|
33
|
+
git push origin v0.1.8
|
|
34
34
|
```
|
|
35
35
|
|
|
36
|
-
Replace `0.1.
|
|
36
|
+
Replace `0.1.8` in these commands with the intended version. The tag must point to a commit reachable from `master`. A mismatched tag, missing changelog entry, failed test, or mismatched existing npm archive stops the release.
|
|
37
37
|
|
|
38
38
|
After the workflow completes, confirm the run, GitHub Release, and npm version:
|
|
39
39
|
|
|
40
40
|
```sh
|
|
41
41
|
gh run list --workflow release.yml --limit 5
|
|
42
|
-
gh release view v0.1.
|
|
43
|
-
npm view dsh-auth-remote@0.1.
|
|
42
|
+
gh release view v0.1.8
|
|
43
|
+
npm view dsh-auth-remote@0.1.8 version dist.integrity
|
|
44
44
|
```
|
|
45
45
|
|
|
46
46
|
The GitHub Release includes the `.tgz` and `SHA256SUMS`. Download them into the same directory and run `sha256sum -c SHA256SUMS` there to check the release asset. A failed workflow should be inspected in **Actions → Release** before retrying; npm versions are immutable, so the workflow only skips an existing version when its archive bytes match.
|
package/docs/releasing.zh-CN.md
CHANGED
|
@@ -29,18 +29,18 @@ pnpm smoke:packed
|
|
|
29
29
|
```sh
|
|
30
30
|
git switch master
|
|
31
31
|
git pull --ff-only origin master
|
|
32
|
-
git tag -a v0.1.
|
|
33
|
-
git push origin v0.1.
|
|
32
|
+
git tag -a v0.1.8 -m "Release v0.1.8"
|
|
33
|
+
git push origin v0.1.8
|
|
34
34
|
```
|
|
35
35
|
|
|
36
|
-
执行时把 `0.1.
|
|
36
|
+
执行时把 `0.1.8` 换成目标版本。标签必须指向 `master` 可达的提交。标签版本不匹配、缺少更新日志条目、测试失败,或 npm 现存版本与本次压缩包字节不同,都会阻止发布。
|
|
37
37
|
|
|
38
38
|
工作流结束后检查运行状态、GitHub Release 和 npm 版本:
|
|
39
39
|
|
|
40
40
|
```sh
|
|
41
41
|
gh run list --workflow release.yml --limit 5
|
|
42
|
-
gh release view v0.1.
|
|
43
|
-
npm view dsh-auth-remote@0.1.
|
|
42
|
+
gh release view v0.1.8
|
|
43
|
+
npm view dsh-auth-remote@0.1.8 version dist.integrity
|
|
44
44
|
```
|
|
45
45
|
|
|
46
46
|
GitHub Release 包含 `.tgz` 和 `SHA256SUMS`。把两者下载到同一个目录,在该目录运行 `sha256sum -c SHA256SUMS` 验证附件。工作流失败时先查看 **Actions → Release** 再重试;npm 版本不可覆盖,因此只有现存版本的压缩包字节与本次构建一致时,工作流才会跳过重复发布。
|