@plasius/oauth2-core 0.1.7 → 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 CHANGED
@@ -2,6 +2,22 @@
2
2
 
3
3
  ## Unreleased
4
4
 
5
+ - **Added**
6
+ - (placeholder)
7
+
8
+ - **Changed**
9
+ - (placeholder)
10
+
11
+ - **Fixed**
12
+ - (placeholder)
13
+
14
+ - **Security**
15
+ - (placeholder)
16
+
17
+ ## [0.1.8] - 2026-10-21
18
+
19
+ - Restore trusted push-only self-hosted CI on the approved quarantined runner group, retain strict install/coverage/artifact gates, and document reviewed branch admission and rollback. Hosted exact-main production OIDC publication remains unchanged.
20
+
5
21
  - **Added**
6
22
  - (placeholder)
7
23
 
@@ -149,3 +165,4 @@
149
165
  [0.1.5]: https://github.com/Plasius-LTD/oauth2-core/releases/tag/v0.1.5
150
166
  [0.1.6]: https://github.com/Plasius-LTD/oauth2-core/releases/tag/v0.1.6
151
167
  [0.1.7]: https://github.com/Plasius-LTD/oauth2-core/releases/tag/v0.1.7
168
+ [0.1.8]: https://github.com/Plasius-LTD/oauth2-core/releases/tag/v0.1.8
package/README.md CHANGED
@@ -51,7 +51,7 @@ not evaluate remote flags itself.
51
51
  ## Development
52
52
 
53
53
  ```bash
54
- npm install
54
+ npm ci
55
55
  npm run build
56
56
  npm test
57
57
  npm run test:coverage
@@ -66,11 +66,34 @@ Apache-2.0
66
66
  ## Release integrity
67
67
 
68
68
  CI keeps the administrative contributor registry outside Git and npm package
69
- artifacts using exact, case-normalised path checks. CI runs on approved
70
- GitHub-hosted runners for same-repository pull requests and `main`, with
71
- package-manager cache finalization disabled; fork PR code is denied.
69
+ artifacts using exact, case-normalised path checks. Both CI jobs run only for pushes in this repository on the approved
70
+ `Public CI - Quarantined` group with explicit `[self-hosted, Linux, X64]`
71
+ labels. Pull-request, target, dispatch and reusable-call entry points are
72
+ absent. The group admits only selected repositories and reviewed workflow
73
+ refs; there is no hosted fallback or caller-controlled runner selector.
74
+ Checkout credentials are not persisted, package-manager cache finalization
75
+ is disabled, and jobs have 15/10 minute limits. Strict `npm ci`, lint, types,
76
+ audit, build, 80% LCOV, source/index admission and final package checks remain
77
+ mandatory.
72
78
  Publication uses the GitHub-hosted `production` job with Node 24 and a pinned
73
79
  npm 11.6.2 client. It is token-free and proceeds only while the prepared SHA
74
80
  is the exact `main` head after successful push-triggered CI. Do not dispatch CD
75
81
  until the npm trusted-publisher binding is verified.
82
+
83
+ Before pushing a source branch, review its workflow and temporarily admit only
84
+ that exact branch workflow ref in the existing restricted group. Remove the
85
+ temporary entry after its checks finish and it is merged. For a pipeline-created
86
+ release metadata PR, verify its App author, base, preparation run, head SHA and
87
+ version/lockfile/CHANGELOG-only diff, then admit that exact branch while it is
88
+ available. Preserve it until CI finishes. If required reviews/checks block merge,
89
+ complete them before allowing preparation to continue; never bypass protection.
90
+ Keep the group's selected repositories, public policy and other refs unchanged.
91
+
92
+ This recovery inherits `platform.public-artifact-integrity.enabled` from Feature
93
+ #1597: enabled permits verified staged promotion; disabled stops promotion;
94
+ rollback disables the affected workflow/distribution channel. The governed
95
+ platform store evaluates the flag, with no package-local flag or capability.
96
+ Source, index and package admission remain mandatory in all three states. Never
97
+ restore the administrative registry, introduce a token fallback or reuse a
98
+ removed npm version. See [ADR-0003](docs/adrs/adr-0003-quarantined-public-ci.md).
76
99
  <!-- END PLASIUS RELEASE INTEGRITY -->
@@ -15,8 +15,10 @@ Publication is phase-isolated: dependency installation, package validation, SBOM
15
15
  Publish only from the GitHub-hosted `production` job using npm trusted
16
16
  publishing. Prove the prepared SHA is still the exact remote `main` head and
17
17
  that push-triggered `ci.yml` succeeded for it. Require Node 24 and npm 11.5.1 or
18
- newer, request provenance, and prohibit npm write-token fallbacks. Reviewed CI
19
- uses explicit GitHub-hosted runners; fork PR code is denied.
18
+ newer, request provenance, and prohibit npm write-token fallbacks. CI validation
19
+ uses the approved quarantined self-hosted runner group under
20
+ [ADR-0003](adr-0003-quarantined-public-ci.md); only trusted repository pushes
21
+ are admitted. Publication remains hosted.
20
22
 
21
23
  ## Consequences
22
24
 
@@ -0,0 +1,62 @@
1
+ # ADR-0003: Quarantined public CI with hosted package publication
2
+
3
+ - Status: Accepted
4
+ - Date: 2026-10-21
5
+ - Project: oauth2-core#5; plasius-ltd-site#1626; Feature #1597
6
+ - Supersedes: ADR-0002's CI runner policy only
7
+
8
+ ## Context
9
+
10
+ The public oauth2-core repository must satisfy its Project requirement for approved
11
+ self-hosted validation without allowing external-fork code onto organisation
12
+ capacity. Hosted OIDC publication is a separate, existing trust boundary.
13
+
14
+ ## Decision
15
+
16
+ Accept only push events from the literal `Plasius-LTD/oauth2-core` repository.
17
+ Both CI jobs use the literal `Public CI - Quarantined` group and
18
+ `[self-hosted, Linux, X64]` labels. The group's selected repository/workflow
19
+ allowlist admits main and only specifically reviewed source branches while
20
+ needed. No pull-request/target/dispatch/call trigger, dynamic selector or hosted
21
+ fallback exists. Checkout does not persist credentials, package-manager cache
22
+ finalization is disabled, and validation is bounded to 15/10 minutes.
23
+
24
+ Use clean `npm ci` and keep lint, types, runtime audit, build, 80% LCOV,
25
+ source/index artifact admission and final package-manifest checks. Reuse the
26
+ existing validators rather than introducing a second admission implementation.
27
+ No package dependencies, runtime source or public API change.
28
+
29
+ Keep ADR-0002's hosted exact-main production OIDC publication unchanged. Before
30
+ release verify visibility, production, publisher identity and an unused patch
31
+ version, then use only main's approved two-phase cd.yml. The preparation
32
+ pipeline owns version/changelog metadata and tags; exact-main push CI gates
33
+ publication. Verify registry bytes, provenance, signatures and public release.
34
+
35
+ The inherited `platform.public-artifact-integrity.enabled` flag is evaluated
36
+ by the platform's governed store. Enabled permits staged verified promotion;
37
+ disabled stops it. Mandatory integrity gates remain active in either state.
38
+ This library needs no capability, runtime flag evaluation or env override.
39
+
40
+ ## Alternatives
41
+
42
+ Hosted CI contradicts the tracked acceptance criteria. Public PR-head
43
+ execution, caller-selected runner inputs and automatic hosted fallbacks weaken
44
+ the intended admission boundary. A new shared package or runtime flag would
45
+ add an unnecessary package boundary for repository workflow configuration.
46
+
47
+ ## Impact and tests
48
+
49
+ Workflow regressions first demonstrate failures for event admission, runner
50
+ isolation and reproducible quality/artifact gates, then enforce both jobs and
51
+ the unchanged hosted production OIDC/exact-SHA boundary. Run full package
52
+ validation and actionlint, source/main CI, and approved CD. Runtime source is
53
+ unchanged, so changed-runtime-file LCOV is N/A; retain overall 80% coverage.
54
+ No UI, browser, SEO, backend deployment or ACA secret-reference change applies.
55
+ Bounded jobs and explicit logs support reliability and observability.
56
+
57
+ ## Rollback
58
+
59
+ Disable the affected CI/CD workflow or distribution channel and stop promotion;
60
+ remove temporary source-branch workflow admission after merge/checks. Retain
61
+ source, index and package admission; never restore the administrative registry,
62
+ fall back to a long-lived npm token, or reuse a removed version.
@@ -2,3 +2,4 @@
2
2
 
3
3
  - [ADR 0001: OAuth 2 Core Package Boundary](./adr-0001-oauth2-core-package-boundary.md)
4
4
  - [ADR-0002: Hosted OIDC Package Publication](./adr-0002-hosted-oidc-package-publication.md)
5
+ - [ADR-0003: Quarantined public CI with hosted package publication](./adr-0003-quarantined-public-ci.md)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@plasius/oauth2-core",
3
- "version": "0.1.7",
3
+ "version": "0.1.8",
4
4
  "description": "Standards-focused OAuth 2.1, PKCE, metadata, and bearer-token primitives for Plasius services.",
5
5
  "type": "module",
6
6
  "sideEffects": false,