ai-saas-guard 0.27.0 → 0.27.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/CONTRIBUTING.md CHANGED
@@ -7,7 +7,7 @@
7
7
  1. Open an issue or comment on an existing issue before large feature work.
8
8
  2. Keep pull requests focused. Separate scanner behavior, docs, workflow changes, and release work when practical.
9
9
  3. Include tests for behavior changes. New scanner rules need a vulnerable fixture, a safe fixture, and assertions for both.
10
- 4. Update documentation when behavior, commands, outputs, or release expectations change. If `README.md` changes, review and update `README.zh-CN.md` in the same pull request.
10
+ 4. Update documentation when behavior, commands, outputs, or release expectations change. If `README.md` changes, review and update `docs/README.zh-CN.md` in the same pull request.
11
11
  5. Fill out the pull request template with release gate evidence and known limitations.
12
12
 
13
13
  ## Local Development
package/README.md CHANGED
@@ -13,7 +13,7 @@
13
13
  </p>
14
14
 
15
15
  <p align="center">
16
- English | <a href="README.zh-CN.md">中文 README</a>
16
+ English | <a href="docs/README.zh-CN.md">中文 README</a>
17
17
  </p>
18
18
 
19
19
  <p align="center">
@@ -73,13 +73,13 @@ The CLI is published on npm as `ai-saas-guard`, and the GitHub Action is availab
73
73
  | Area | Status |
74
74
  | --- | --- |
75
75
  | Public GitHub repository | Available |
76
- | npm CLI | `ai-saas-guard@0.27.0` |
77
- | GitHub Action | `zr9959/ai-saas-guard@v0` or fixed tag `v0.27.0` |
76
+ | npm CLI | `ai-saas-guard@0.27.2` |
77
+ | GitHub Action | `zr9959/ai-saas-guard@v0` or fixed tag `v0.27.2` |
78
78
  | Outputs | Terminal, JSON, SARIF, and PR-focused markdown |
79
79
  | Project config | `.ai-saas-guard.json` rule toggles, severity overrides, suppressions, and fail thresholds |
80
80
  | Privacy model | Local-first, read-only scan commands, no LLM calls, no code upload |
81
- | Versioned Action tags | `v0.27.0`, `v0` |
82
- | Current release | `0.27.0` launch-gate report summary for CLI and hosted Check Runs |
81
+ | Versioned Action tags | `v0.27.2`, `v0` |
82
+ | Current release | `0.27.2` npm README metadata fix; launch-gate report summary remains current |
83
83
  | npm publishing | Trusted Publisher/OIDC, no long-lived publish token |
84
84
  | Repository trust hardening | Strict branch protection, Dependabot, CodeQL, fast-check fuzzing, signed release provenance assets, private vulnerability reporting, secret scanning, and push protection |
85
85
  | Cloudflare hosted ingress | Deployed at `https://ai-saas-guard-hosted.zr9959.workers.dev`; Worker health and Check Run publisher configuration are live, but end-to-end GitHub App webhook delivery is still blocked pending private App settings verification |
@@ -294,7 +294,7 @@ Use `suppressions` for narrower false-positive handling when one rule is noisy o
294
294
 
295
295
  ## GitHub Action
296
296
 
297
- The repo includes a composite Action. Use `v0` for the latest compatible pre-1.0 Action, a specific release tag such as `v0.27.0` for controlled upgrades, or pin a reviewed commit SHA for stricter supply-chain control:
297
+ The repo includes a composite Action. Use `v0` for the latest compatible pre-1.0 Action, a specific release tag such as `v0.27.2` for controlled upgrades, or pin a reviewed commit SHA for stricter supply-chain control:
298
298
 
299
299
  ```yaml
300
300
  name: ai-saas-guard
@@ -13,15 +13,15 @@
13
13
  </p>
14
14
 
15
15
  <p align="center">
16
- <a href="README.md">English README</a> | 中文
16
+ <a href="../README.md">English README</a> | 中文
17
17
  </p>
18
18
 
19
19
  <p align="center">
20
20
  <a href="https://github.com/zr9959/ai-saas-guard/actions/workflows/ci.yml"><img alt="CI" src="https://github.com/zr9959/ai-saas-guard/actions/workflows/ci.yml/badge.svg"></a>
21
21
  <a href="https://www.bestpractices.dev/projects/12955"><img alt="OpenSSF Best Practices" src="https://www.bestpractices.dev/projects/12955/badge"></a>
22
22
  <a href="https://www.npmjs.com/package/ai-saas-guard"><img alt="npm" src="https://img.shields.io/npm/v/ai-saas-guard.svg"></a>
23
- <a href="LICENSE"><img alt="License: MIT" src="https://img.shields.io/badge/license-MIT-blue.svg"></a>
24
- <a href="package.json"><img alt="Node.js >=20" src="https://img.shields.io/badge/node-%3E%3D20-339933.svg"></a>
23
+ <a href="../LICENSE"><img alt="License: MIT" src="https://img.shields.io/badge/license-MIT-blue.svg"></a>
24
+ <a href="../package.json"><img alt="Node.js >=20" src="https://img.shields.io/badge/node-%3E%3D20-339933.svg"></a>
25
25
  </p>
26
26
 
27
27
  ---
@@ -67,22 +67,22 @@ AI 能很快把一个 SaaS 做到“看起来能用”。真正危险的是上
67
67
 
68
68
  这个仓库是公开 GitHub 仓库。
69
69
 
70
- CLI 已发布到 npm:`ai-saas-guard@0.27.0`。GitHub Action 支持 `v0` 浮动标签,也支持固定版本标签,例如 `v0.27.0`。
70
+ CLI 已发布到 npm:`ai-saas-guard@0.27.2`。GitHub Action 支持 `v0` 浮动标签,也支持固定版本标签,例如 `v0.27.2`。
71
71
 
72
72
  | 模块 | 状态 |
73
73
  | --- | --- |
74
74
  | 公开 GitHub 仓库 | 已可用 |
75
- | npm CLI | `ai-saas-guard@0.27.0` |
76
- | GitHub Action | `zr9959/ai-saas-guard@v0` 或固定标签 `v0.27.0` |
75
+ | npm CLI | `ai-saas-guard@0.27.2` |
76
+ | GitHub Action | `zr9959/ai-saas-guard@v0` 或固定标签 `v0.27.2` |
77
77
  | 输出格式 | Terminal、JSON、SARIF 和 PR markdown |
78
78
  | 项目配置 | `.ai-saas-guard.json` 支持规则开关、severity 覆盖、suppressions 和 fail threshold |
79
79
  | 隐私模型 | 本地优先、只读扫描、不调用 LLM、不上传代码 |
80
- | 当前版本 | `0.27.0` CLI 和 hosted Check Run 的 launch-gate report summary |
81
- | Action 标签 | `v0.27.0`、`v0` |
80
+ | 当前版本 | `0.27.2` npm README metadata fix;CLI 和 hosted Check Run 的 launch-gate report summary 仍是当前功能 |
81
+ | Action 标签 | `v0.27.2`、`v0` |
82
82
  | npm 发布 | GitHub Actions Trusted Publisher/OIDC,无需长期 npm token |
83
83
  | 仓库可信度加固 | 严格 branch protection、Dependabot、CodeQL、fast-check fuzzing、signed release provenance assets、private vulnerability reporting、secret scanning 和 push protection |
84
84
  | Cloudflare hosted ingress | 已部署到 `https://ai-saas-guard-hosted.zr9959.workers.dev`;Worker health 和 Check Run publisher 配置已在线,但端到端 GitHub App webhook delivery 仍需要验证私有 App 设置 |
85
- | Hosted GitHub App staging | 私有 App `ai-saas-guard-hosted`(`3834787`)已安装到 `zr9959/ai-saas-guard`;hosted operations evidence 见 [docs/hosted-operations-evidence.md](docs/hosted-operations-evidence.md) |
85
+ | Hosted GitHub App staging | 私有 App `ai-saas-guard-hosted`(`3834787`)已安装到 `zr9959/ai-saas-guard`;hosted operations evidence 见 [docs/hosted-operations-evidence.md](hosted-operations-evidence.md) |
86
86
  | OpenSSF Best Practices | 已获得 passing badge,项目 `12955`;`.bestpractices.json` 继续作为保守证据记录 |
87
87
 
88
88
  ## 快速开始
@@ -148,17 +148,17 @@ node dist/cli.js scan --root /path/to/your-saas
148
148
  | GitHub Actions | workflow 权限过宽、PR workflow 缺 concurrency cancel、docs-only 改动跑全量 CI、secret/tool version 缺 fail-fast、`pr-risk` checkout 太浅、Action 未 pin SHA |
149
149
  | PR risk | auth、billing、RLS、env、deploy、API、storage、silent-success、测试删除、缺 spec/context、大型混合 diff |
150
150
 
151
- 完整规则请看 [docs/rules.md](docs/rules.md)。
151
+ 完整规则请看 [docs/rules.md](rules.md)。
152
152
 
153
153
  ## 仓库可信度加固
154
154
 
155
- 公开仓库的维护和发布控制见 [docs/repository-trust-hardening.md](docs/repository-trust-hardening.md)。当前已经配置严格 branch protection、required CI checks、Dependabot npm/GitHub Actions 更新、CodeQL SAST、fast-check fuzz/property tests、基于 npm trusted publishing provenance 的 signed GitHub release assets、private vulnerability reporting、secret scanning 和 push protection。
155
+ 公开仓库的维护和发布控制见 [docs/repository-trust-hardening.md](repository-trust-hardening.md)。当前已经配置严格 branch protection、required CI checks、Dependabot npm/GitHub Actions 更新、CodeQL SAST、fast-check fuzz/property tests、基于 npm trusted publishing provenance 的 signed GitHub release assets、private vulnerability reporting、secret scanning 和 push protection。
156
156
 
157
157
  最新 GitHub releases 会镜像 npm package tarball,并附带 `*.tgz.sigstore.json` 和 `*.tgz.intoto.jsonl` provenance assets。上传前会用 npm registry metadata 校验 tarball digest,并使用 npm provenance 作为来源。
158
158
 
159
159
  当前 Scorecard 提升路线优先做真实控制,不做表面刷分:更严格的 review gate、可被检测到的 fuzzing、以及 OpenSSF Best Practices Badge 流程。仓库年龄、贡献者多样性、已 review 的 PR 历史这些分数只能随着真实维护逐步提升。
160
160
 
161
- 仓库现在已经获得 [OpenSSF Best Practices passing badge](https://www.bestpractices.dev/projects/12955)。[.bestpractices.json](.bestpractices.json) 继续作为公开项目条目的保守证据记录。`dynamic_analysis_enable_assertions` 仍然谨慎标为 unmet,直到运行时断言覆盖面超过当前测试、property 和 fuzz assertions。
161
+ 仓库现在已经获得 [OpenSSF Best Practices passing badge](https://www.bestpractices.dev/projects/12955)。[.bestpractices.json](../.bestpractices.json) 继续作为公开项目条目的保守证据记录。`dynamic_analysis_enable_assertions` 仍然谨慎标为 unmet,直到运行时断言覆盖面超过当前测试、property 和 fuzz assertions。
162
162
 
163
163
  ## PR 风险分流
164
164
 
@@ -229,7 +229,7 @@ jobs:
229
229
  config: .ai-saas-guard.json
230
230
  ```
231
231
 
232
- 更多 GitHub Action 示例请看 [docs/github-action.md](docs/github-action.md)。
232
+ 更多 GitHub Action 示例请看 [docs/github-action.md](github-action.md)。
233
233
 
234
234
  ## 项目配置
235
235
 
@@ -270,23 +270,23 @@ jobs:
270
270
 
271
271
  ## Hosted GitHub App 设计
272
272
 
273
- 当前仓库已经包含未来 Hosted GitHub App 的设计文档、纯契约测试,以及第一个真实 Cloudflare hosted ingress。私有 staging GitHub App `ai-saas-guard-hosted` 已安装到 `zr9959/ai-saas-guard`,Cloudflare 已配置所需的云端凭据绑定。Worker 代码已经能接收签名 webhook、写入 KV 队列、换取 scoped installation token、读取 GitHub PR file metadata、做 compact PR-risk classification,并发布有长度上限的 Check Run summary;但当前端到端 GitHub App webhook delivery smoke 还被私有 App webhook 设置阻断,证据记录在 [docs/hosted-operations-evidence.md](docs/hosted-operations-evidence.md)。它还不是完整 source checkout scan worker。
273
+ 当前仓库已经包含未来 Hosted GitHub App 的设计文档、纯契约测试,以及第一个真实 Cloudflare hosted ingress。私有 staging GitHub App `ai-saas-guard-hosted` 已安装到 `zr9959/ai-saas-guard`,Cloudflare 已配置所需的云端凭据绑定。Worker 代码已经能接收签名 webhook、写入 KV 队列、换取 scoped installation token、读取 GitHub PR file metadata、做 compact PR-risk classification,并发布有长度上限的 Check Run summary;但当前端到端 GitHub App webhook delivery smoke 还被私有 App webhook 设置阻断,证据记录在 [docs/hosted-operations-evidence.md](hosted-operations-evidence.md)。它还不是完整 source checkout scan worker。
274
274
 
275
275
  相关文档:
276
276
 
277
- - [docs/github-app-design.md](docs/github-app-design.md)
278
- - [docs/github-app-deployment.md](docs/github-app-deployment.md)
279
- - [docs/hosted-first-service-slice.md](docs/hosted-first-service-slice.md)
280
- - [docs/hosted-deployment-model.md](docs/hosted-deployment-model.md)
281
- - [docs/hosted-service-runtime.md](docs/hosted-service-runtime.md)
282
- - [docs/hosted-production-adapters.md](docs/hosted-production-adapters.md)
283
- - [docs/hosted-node-container-app.md](docs/hosted-node-container-app.md)
284
- - [docs/hosted-staging-deployment.md](docs/hosted-staging-deployment.md)
285
- - [docs/hosted-staging-harness.md](docs/hosted-staging-harness.md)
286
- - [docs/hosted-operational-release-gate.md](docs/hosted-operational-release-gate.md)
287
- - [docs/hosted-uninstall-data-deletion.md](docs/hosted-uninstall-data-deletion.md)
288
- - [docs/hosted-pricing-packaging.md](docs/hosted-pricing-packaging.md)
289
- - [docs/hosted-preimplementation-contracts.md](docs/hosted-preimplementation-contracts.md)
277
+ - [docs/github-app-design.md](github-app-design.md)
278
+ - [docs/github-app-deployment.md](github-app-deployment.md)
279
+ - [docs/hosted-first-service-slice.md](hosted-first-service-slice.md)
280
+ - [docs/hosted-deployment-model.md](hosted-deployment-model.md)
281
+ - [docs/hosted-service-runtime.md](hosted-service-runtime.md)
282
+ - [docs/hosted-production-adapters.md](hosted-production-adapters.md)
283
+ - [docs/hosted-node-container-app.md](hosted-node-container-app.md)
284
+ - [docs/hosted-staging-deployment.md](hosted-staging-deployment.md)
285
+ - [docs/hosted-staging-harness.md](hosted-staging-harness.md)
286
+ - [docs/hosted-operational-release-gate.md](hosted-operational-release-gate.md)
287
+ - [docs/hosted-uninstall-data-deletion.md](hosted-uninstall-data-deletion.md)
288
+ - [docs/hosted-pricing-packaging.md](hosted-pricing-packaging.md)
289
+ - [docs/hosted-preimplementation-contracts.md](hosted-preimplementation-contracts.md)
290
290
 
291
291
  已经实现的 hosted 预实现纯契约包括:
292
292
 
@@ -307,7 +307,7 @@ jobs:
307
307
  - worker checkout cleanup planner
308
308
  - retention/deletion cleanup planner:把 compact report 删除、按仓库或 installation 范围取消队列和 running job、worker checkout 删除、retention 过期清理、最小审计记录合成一个安全计划;不会输出源码、diff、secret、customer payload、private URL、checkout path 或底层 cleanup error
309
309
  - operational release gate evaluator:检查 hosted 暴露前是否具备 fresh CI、webhook replay、workflow static check、dependency/container scan、cleanup、privacy、monitoring、rollback、incident response 和 release cleanup 证据;缺任何 P0 证据都会阻止 hosted exposure
310
- - hosted compact report fixture:[examples/hosted-compact-report.json](examples/hosted-compact-report.json)
310
+ - hosted compact report fixture:[examples/hosted-compact-report.json](../examples/hosted-compact-report.json)
311
311
 
312
312
  这些 helper 不会暴露公开服务、不会直接调用 GitHub API、不会持久化 installation token、不会真实写 check run、不会发 PR comment,也不会上传源码。
313
313
 
@@ -334,12 +334,12 @@ npm run build
334
334
  node dist/cli.js scan --root .
335
335
  ```
336
336
 
337
- 发布 CLI、GitHub Action、npm package 或任何公开仓库更新前,必须按照 [docs/release-quality-knowledge-base.md](docs/release-quality-knowledge-base.md) 的 release gate 执行。
337
+ 发布 CLI、GitHub Action、npm package 或任何公开仓库更新前,必须按照 [docs/release-quality-knowledge-base.md](release-quality-knowledge-base.md) 的 release gate 执行。
338
338
 
339
- 以后更新英文 `README.md` 时,也要同步检查并更新本中文 `README.zh-CN.md`。
339
+ 以后更新英文 `README.md` 时,也要同步检查并更新本中文 `docs/README.zh-CN.md`。
340
340
 
341
- 贡献要求见 [CONTRIBUTING.md](CONTRIBUTING.md),里面说明了 PR 流程、测试要求、规则设计、release gate evidence 和公开安全边界。
341
+ 贡献要求见 [CONTRIBUTING.md](../CONTRIBUTING.md),里面说明了 PR 流程、测试要求、规则设计、release gate evidence 和公开安全边界。
342
342
 
343
343
  ## 安全报告
344
344
 
345
- 报告漏洞前请阅读 [SECURITY.md](SECURITY.md)。不要在公开 issue 中发布真实 API key、客户数据、私有源码或生产 URL。
345
+ 报告漏洞前请阅读 [SECURITY.md](../SECURITY.md)。不要在公开 issue 中发布真实 API key、客户数据、私有源码或生产 URL。
@@ -2,7 +2,7 @@
2
2
 
3
3
  `ai-saas-guard` ships as a composite GitHub Action for pull request and code scanning workflows.
4
4
 
5
- Use `zr9959/ai-saas-guard@v0` for the latest compatible pre-1.0 Action. Use a specific tag such as `v0.27.0` or a reviewed commit SHA when reproducibility is more important than automatic minor updates.
5
+ Use `zr9959/ai-saas-guard@v0` for the latest compatible pre-1.0 Action. Use a specific tag such as `v0.27.2` or a reviewed commit SHA when reproducibility is more important than automatic minor updates.
6
6
 
7
7
  ## PR Summary
8
8
 
@@ -5,11 +5,11 @@
5
5
  ## Current State
6
6
 
7
7
  - Package name: `ai-saas-guard`
8
- - Current published version: `0.27.0`
8
+ - Current published version: `0.27.2`
9
9
  - Next source candidate: none
10
10
  - npm registry state: published at <https://www.npmjs.com/package/ai-saas-guard>
11
11
  - First npm-published version: `0.1.1`
12
- - GitHub Release: `v0.27.0`
12
+ - GitHub Release: `v0.27.2`
13
13
  - Publish workflow: `.github/workflows/npm-publish.yml`
14
14
  - Trusted Publisher: GitHub Actions, `zr9959/ai-saas-guard`, workflow `npm-publish.yml`, allowed action `npm publish`
15
15
  - Long-lived npm publish token: not required
@@ -18,7 +18,7 @@
18
18
 
19
19
  Use GitHub Actions with npm Trusted Publisher/OIDC:
20
20
 
21
- 1. Create and review a release tag such as `v0.27.0`.
21
+ 1. Create and review a release tag such as `v0.27.2`.
22
22
  2. Publish from the GitHub Release or run the `Publish npm` workflow manually with `ref` set to that tag.
23
23
  3. Keep `permissions.id-token: write` in the workflow so npm can exchange the GitHub Actions OIDC identity for a short-lived publish credential.
24
24
  4. Run `npm publish --access public` from the workflow. Trusted publishing automatically generates provenance for this public package from this public repository.
@@ -160,7 +160,7 @@ OpenSSF Best Practices:
160
160
  Publishing:
161
161
 
162
162
  - npm package: `ai-saas-guard`
163
- - Current published release line: `v0.27.0`
163
+ - Current published release line: `v0.27.2`
164
164
  - Next source candidate: none
165
165
  - Publish workflow: `.github/workflows/npm-publish.yml`
166
166
  - Trusted Publisher: GitHub Actions for `zr9959/ai-saas-guard`, workflow `npm-publish.yml`
@@ -173,7 +173,7 @@ Allowed in this public repository:
173
173
  - CLI source code
174
174
  - tests and intentionally vulnerable fixtures
175
175
  - public docs
176
- - English README and Chinese README; when `README.md` changes, review and update `README.zh-CN.md` in the same change
176
+ - English README and Chinese README; when `README.md` changes, review and update `docs/README.zh-CN.md` in the same change
177
177
  - GitHub Action wrapper
178
178
  - examples that contain only inert fake data
179
179
  - release-quality process docs
@@ -235,7 +235,7 @@ P0:
235
235
  - `types` points to generated declaration files if package exports TypeScript API.
236
236
  - `exports` is accurate.
237
237
  - README install examples match the published package name.
238
- - If `README.md` changes, `README.zh-CN.md` must be reviewed and updated or explicitly confirmed still current.
238
+ - If `README.md` changes, `docs/README.zh-CN.md` must be reviewed and updated or explicitly confirmed still current.
239
239
  - Version follows semver.
240
240
  - Release notes state breaking changes, new checks, false-positive changes, and migration notes.
241
241
  - Publish with npm trusted publishing/OIDC when possible.
@@ -125,6 +125,6 @@ The repository also includes `.bestpractices.json` with conservative proposed an
125
125
  Current badge evidence:
126
126
 
127
127
  - `CONTRIBUTING.md` documents the pull request process, test expectations, rule-design requirements, release gate evidence, and public-safety constraints.
128
- - `README.md` and `README.zh-CN.md` document the problem, install path, CLI commands, privacy model, GitHub Action use, hosted boundaries, and trust-hardening controls.
128
+ - `README.md` and `docs/README.zh-CN.md` document the problem, install path, CLI commands, privacy model, GitHub Action use, hosted boundaries, and trust-hardening controls.
129
129
  - `.bestpractices.json` records only repository-backed OpenSSF Best Practices proposed answers; unknown or future claims should stay out until they can be supported by public evidence.
130
130
  - `dynamic_analysis_enable_assertions` is intentionally still marked unmet because the production CLI does not yet have broad runtime assertion coverage beyond tests, property tests, and fuzzing.
package/package.json CHANGED
@@ -1,7 +1,8 @@
1
1
  {
2
2
  "name": "ai-saas-guard",
3
- "version": "0.27.0",
3
+ "version": "0.27.2",
4
4
  "description": "Repo-local launch-readiness scanner for AI-built SaaS apps.",
5
+ "readmeFilename": "README.md",
5
6
  "type": "module",
6
7
  "homepage": "https://github.com/zr9959/ai-saas-guard#readme",
7
8
  "repository": {
@@ -80,8 +81,7 @@
80
81
  "dist",
81
82
  "examples",
82
83
  "hosted",
83
- "README.md",
84
- "README.zh-CN.md"
84
+ "README.md"
85
85
  ],
86
86
  "license": "MIT",
87
87
  "devDependencies": {