een-api-toolkit 0.3.70 → 0.3.79

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,83 +2,85 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file.
4
4
 
5
- ## [0.3.70] - 2026-02-10
5
+ ## [0.3.79] - 2026-02-14
6
6
 
7
7
  ### Release Summary
8
8
 
9
- #### PR #102: Release v0.3.69: CI improvements and dependency management
9
+ #### PR #108: Release v0.3.76: Hostname validation security hardening
10
10
  ## Summary
11
- - Dynamic E2E test matrix discovery (auto-detects example apps with `playwright.config.ts`)
12
- - Added missing `vue-jobs` to CI E2E testing
13
- - Dependabot configuration for automated dependency updates
14
- - Pinned GitHub Actions to immutable commit SHAs for supply chain security
11
+ - **Security Fix**: Validate hostname against EEN domain allowlist to prevent token exfiltration via malicious base URL injection
12
+ - **Hardening**: Fail-secure on tampered storage - clears all auth data when poisoned hostname/port detected
13
+ - **Validation**: Port validation (1-65535 range), protocol bypass prevention, subdomain spoofing protection
14
+ - **Tests**: Comprehensive hostname validation test suite for auth store (46 new tests)
15
+ - **Robustness**: Added `isAllowedEenHostname` utility with falsy guard, console.warn for rejected hostnames, `@internal` JSDoc tag on `ALLOWED_DOMAINS`
15
16
 
16
17
  ## Commits
17
- - `474e9bb` ci: Dynamically discover example apps for E2E matrix
18
- - `ad3f318` fix: pin GitHub Actions to immutable commit SHAs
19
- - `cc706d8` chore: add Dependabot configuration for automated dependency updates
20
- - `24a385b` Merge PR #95 (workflow SHA pinning security fix)
18
+ - fix: Validate hostname against EEN domain allowlist to prevent token exfiltration
19
+ - test: Add hostname validation tests for auth store security fix
20
+ - docs: Add @internal JSDoc tag to ALLOWED_DOMAINS constant
21
+ - fix: Use console.warn for rejected hostname validation messages
22
+ - fix: Add falsy guard to isAllowedEenHostname for robustness
23
+ - fix: harden hostname/port validation and fail-secure on tampered storage
21
24
 
22
25
  ## Test Results
23
- - **Lint**: Passed (0 errors, 1 warning)
24
- - **Unit tests**: 619/619 passed
25
- - **Build**: Successful
26
- - **E2E tests**: 11/11 example apps passed (1 transient OAuth timeout on vue-users, passed on rerun)
27
-
28
- ## Security Review
29
- Changes are CI/infrastructure only (workflow files, dependabot config). No source code changes. No security vulnerabilities.
26
+ - **Lint**: Passed (1 warning - pre-existing)
27
+ - **Unit Tests**: 639 passed (23 test files)
28
+ - **Build**: Successful (ESM + CJS)
29
+ - **E2E Tests**: All 11 example apps passed
30
30
 
31
31
  ## Version
32
- `v0.3.69`
32
+ `0.3.76`
33
+
34
+ 🤖 Generated with [Claude Code](https://claude.com/claude-code)
33
35
 
34
- #### PR #94: Release v0.3.69: SSRF protection fix with test coverage
36
+ #### PR #110: fix: Security hardening - hostname validation and CI/CD pipeline
35
37
  ## Summary
36
- - Merges security fix from PR #93 (SSRF domain validation in `initMediaSession`)
37
- - Fixes broken unit tests caused by the domain validation (updated test domains from `example.com` to `eagleeyenetworks.com`)
38
- - Adds 2 new unit tests for domain validation coverage (untrusted domain rejection, `een.cloud` acceptance)
38
+
39
+ Release v0.3.79 - Security hardening fixes for three vulnerabilities identified in code review:
40
+
41
+ - **Hostname validation bypass**: Added DNS hostname character regex (`/^[a-z0-9]([a-z0-9.-]*[a-z0-9])?$/`) before `endsWith()` check in `isAllowedEenHostname()` to prevent bypass attacks like `evil.com/.eagleeyenetworks.com`
42
+ - **CI/CD branch restriction**: Added `head_branch == 'production'` check to npm-publish workflow to prevent publishing from non-production branches
43
+ - **Script injection prevention**: Moved `${{ }}` interpolation from shell `run:` blocks to `env:` blocks in test-release workflow at 3 locations
39
44
 
40
45
  ## Commits
41
- - `22aed68` Fix AUTH_BYPASS vulnerability in initMediaSession()
42
- - `b6d21d1` fix: Update media tests for SSRF domain validation and add coverage
46
+
47
+ - `d4e8a06` fix: harden hostname validation and CI/CD security
48
+ - `c870348` Update src/utils/hostname.ts
49
+ - `5a76991` Merge pull request #109
43
50
 
44
51
  ## Test Results
45
- - **Lint**: Passed (1 warning, 0 errors)
46
- - **Unit tests**: 619/619 passed
47
- - **Build**: Successful (v0.3.69)
48
- - **E2E tests**: 11/11 example apps passed
49
52
 
50
- ## Security Review
51
- The only source code change is the SSRF protection in `src/media/service.ts` which validates session URLs against allowed domains (`.eagleeyenetworks.com`, `.een.cloud`). This is a security improvement with no new vulnerabilities.
53
+ - **Lint**: 0 errors (1 pre-existing warning)
54
+ - **Unit tests**: 644 passed
55
+ - **Build**: Success
56
+ - **E2E tests**: 225 passed across all 11 example apps
57
+ - **Security review**: No HIGH-confidence vulnerabilities found
58
+
59
+ ## Files Changed
60
+
61
+ - `src/utils/hostname.ts` - Added hostname character validation regex
62
+ - `src/__tests__/auth.store.test.ts` - Added 5 test cases for malicious hostname bypass
63
+ - `.github/workflows/npm-publish.yml` - Added production branch restriction
64
+ - `.github/workflows/test-release.yml` - Fixed script injection at 3 locations
52
65
 
53
66
  ## Version
54
- `v0.3.69`
67
+
68
+ `0.3.79`
69
+
70
+ 🤖 Generated with [Claude Code](https://claude.com/claude-code)
55
71
 
56
72
 
57
73
  ### Detailed Changes
58
74
 
59
75
  #### Bug Fixes
60
- - fix: Address code review concerns for PR #102
61
- - fix: Revert TypeScript to ~5.8.0 and block minor bumps in Dependabot
62
- - fix: Revert eslint to v9 for typescript-eslint compatibility
63
- - fix: pin GitHub Actions to immutable commit SHAs
76
+ - fix: harden hostname validation and CI/CD security
64
77
 
65
78
  #### Other Changes
66
- - docs: Address minor review concerns for PR #102
67
- - docs: Fix documentation inaccuracies and regenerate API docs
68
- - chore(deps): bump github/codeql-action from 3.32.2 to 4.32.2
69
- - chore: Ignore eslint major version bumps in Dependabot
70
- - chore(deps-dev): bump the npm-dependencies group with 18 updates
71
- - chore(deps): bump actions/upload-artifact from 4.6.2 to 6.0.0
72
- - chore(deps): bump anthropics/claude-code-action
73
- - chore(deps): bump github/codeql-action
74
- - chore(deps): bump actions/setup-node from 4.4.0 to 6.2.0
75
- - chore(deps): bump actions/checkout from 4.3.1 to 6.0.2
76
- - chore: add Dependabot configuration for automated dependency updates
77
- - ci: Dynamically discover example apps for E2E matrix
79
+ - Update src/utils/hostname.ts
78
80
 
79
81
  ### Links
80
82
  - [npm package](https://www.npmjs.com/package/een-api-toolkit)
81
- - [Full Changelog](https://github.com/klaushofrichter/een-api-toolkit/compare/v0.3.69...v0.3.70)
83
+ - [Full Changelog](https://github.com/klaushofrichter/een-api-toolkit/compare/v0.3.78...v0.3.79)
82
84
 
83
85
  ---
84
- *Released: 2026-02-10 21:07:19 CST*
86
+ *Released: 2026-02-14 07:56:49 CST*