@karmaniverous/jeeves-server-core 0.1.0 → 0.1.1
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/package.json +7 -4
- package/.env.local +0 -13
- package/.env.local.template +0 -13
- package/CHANGELOG.md +0 -354
- package/src/crypto.ts +0 -81
- package/src/index.ts +0 -29
- package/src/types.ts +0 -108
- package/tsconfig.json +0 -21
package/package.json
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@karmaniverous/jeeves-server-core",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"type": "module",
|
|
5
|
+
"files": [
|
|
6
|
+
"dist"
|
|
7
|
+
],
|
|
5
8
|
"publishConfig": {
|
|
6
9
|
"access": "public"
|
|
7
10
|
},
|
|
@@ -12,6 +15,7 @@
|
|
|
12
15
|
"lint:fix": "eslint --fix .",
|
|
13
16
|
"test": "vitest run --passWithNoTests",
|
|
14
17
|
"typecheck": "tsc --noEmit",
|
|
18
|
+
"changelog": "git-cliff -o CHANGELOG.md",
|
|
15
19
|
"release": "dotenvx run -f .env.local -- release-it",
|
|
16
20
|
"release:pre": "dotenvx run -f .env.local -- release-it --no-git.requireBranch --github.prerelease --preRelease"
|
|
17
21
|
},
|
|
@@ -27,7 +31,6 @@
|
|
|
27
31
|
"devDependencies": {
|
|
28
32
|
"vitest": "^4.1.2",
|
|
29
33
|
"release-it": "^19.2.4",
|
|
30
|
-
"auto-changelog": "^2.5.0",
|
|
31
34
|
"@dotenvx/dotenvx": "^1.59.1"
|
|
32
35
|
},
|
|
33
36
|
"engines": {
|
|
@@ -35,7 +38,7 @@
|
|
|
35
38
|
},
|
|
36
39
|
"release-it": {
|
|
37
40
|
"git": {
|
|
38
|
-
"changelog": "npx
|
|
41
|
+
"changelog": "npx git-cliff --unreleased --strip header",
|
|
39
42
|
"commitMessage": "chore: release @karmaniverous/jeeves-server-core v${version}",
|
|
40
43
|
"tagName": "core/${version}",
|
|
41
44
|
"requireBranch": "main"
|
|
@@ -51,7 +54,7 @@
|
|
|
51
54
|
"npm run build"
|
|
52
55
|
],
|
|
53
56
|
"before:npm:release": [
|
|
54
|
-
"npx
|
|
57
|
+
"npx git-cliff -o CHANGELOG.md",
|
|
55
58
|
"git add -A"
|
|
56
59
|
],
|
|
57
60
|
"after:release": [
|
package/.env.local
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
# This file is a template for the .env.local. Add your Personal Access Token
|
|
2
|
-
# below to streamline the release process from your desktop! Just follow these
|
|
3
|
-
# steps:
|
|
4
|
-
#
|
|
5
|
-
# 1. Make a copy of this file and rename it to .env.local.
|
|
6
|
-
#
|
|
7
|
-
# 2. Create a Personal Access Token at https://github.com/settings/tokens and
|
|
8
|
-
# enter it below.
|
|
9
|
-
#
|
|
10
|
-
# .env.local is gitignored and will NOT be persisted to your repo, but don't
|
|
11
|
-
# put any secrets in this template!
|
|
12
|
-
|
|
13
|
-
GITHUB_TOKEN=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
|
package/.env.local.template
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
# This file is a template for the .env.local. Add your Personal Access Token
|
|
2
|
-
# below to streamline the release process from your desktop! Just follow these
|
|
3
|
-
# steps:
|
|
4
|
-
#
|
|
5
|
-
# 1. Make a copy of this file and rename it to .env.local.
|
|
6
|
-
#
|
|
7
|
-
# 2. Create a Personal Access Token at https://github.com/settings/tokens and
|
|
8
|
-
# enter it below.
|
|
9
|
-
#
|
|
10
|
-
# .env.local is gitignored and will NOT be persisted to your repo, but don't
|
|
11
|
-
# put any secrets in this template!
|
|
12
|
-
|
|
13
|
-
GITHUB_TOKEN=
|
package/CHANGELOG.md
DELETED
|
@@ -1,354 +0,0 @@
|
|
|
1
|
-
### Changelog
|
|
2
|
-
|
|
3
|
-
All notable changes to this project will be documented in this file. Dates are displayed in UTC.
|
|
4
|
-
|
|
5
|
-
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
6
|
-
|
|
7
|
-
#### [v0.1.0](https://github.com/karmaniverous/jeeves-server/compare/v2.9.3...v0.1.0)
|
|
8
|
-
|
|
9
|
-
- fix: rename shared to core, add release-it, upgrade client eslint [`#197`](https://github.com/karmaniverous/jeeves-server/pull/197)
|
|
10
|
-
- fix: upgrade client eslint to v10, fix lint errors from stricter rules [`#196`](https://github.com/karmaniverous/jeeves-server/pull/196)
|
|
11
|
-
- feat: create shared package, add missing plugin tools, DRY types (#194) [`#195`](https://github.com/karmaniverous/jeeves-server/pull/195)
|
|
12
|
-
- feat: create shared package, add missing plugin tools, DRY types [`#194`](https://github.com/karmaniverous/jeeves-server/pull/194)
|
|
13
|
-
- fix: remove state.json and dead keyRotatedAt code (#192) [`#193`](https://github.com/karmaniverous/jeeves-server/pull/193)
|
|
14
|
-
- fix: remove state.json and dead keyRotatedAt code [`#192`](https://github.com/karmaniverous/jeeves-server/pull/192)
|
|
15
|
-
- fix: resolve state.json from state root instead of package directory (#185) [`#186`](https://github.com/karmaniverous/jeeves-server/pull/186)
|
|
16
|
-
- feat: add copy button to table cell hover controls (#188) [`#189`](https://github.com/karmaniverous/jeeves-server/pull/189)
|
|
17
|
-
- fix: add /api prefix to OAuth API routes (#190) [`#191`](https://github.com/karmaniverous/jeeves-server/pull/191)
|
|
18
|
-
- fix: add /api prefix to OAuth API routes [`#190`](https://github.com/karmaniverous/jeeves-server/pull/190)
|
|
19
|
-
- feat: add copy button to table cell hover controls [`#188`](https://github.com/karmaniverous/jeeves-server/pull/188)
|
|
20
|
-
- fix: store insider seeds in config.json instead of state.json (#185) [`#187`](https://github.com/karmaniverous/jeeves-server/pull/187)
|
|
21
|
-
- fix: store insider seeds in config.json instead of state.json [`#185`](https://github.com/karmaniverous/jeeves-server/pull/185)
|
|
22
|
-
- fix: resolve state.json from state root instead of package directory [`#185`](https://github.com/karmaniverous/jeeves-server/pull/185)
|
|
23
|
-
- fix: authenticate embedded images for all outsider shares (#183) [`#184`](https://github.com/karmaniverous/jeeves-server/pull/184)
|
|
24
|
-
- feat: /go/:slug shortlink redirects (#180) [`#182`](https://github.com/karmaniverous/jeeves-server/pull/182)
|
|
25
|
-
- fix: resolve serverRoot via package.json discovery (#178) [`#179`](https://github.com/karmaniverous/jeeves-server/pull/179)
|
|
26
|
-
- fix: edit popup scrollbar and word wrap [`#173`](https://github.com/karmaniverous/jeeves-server/pull/173)
|
|
27
|
-
- fix: dev server white screen — serve built client under tsx [`#171`](https://github.com/karmaniverous/jeeves-server/pull/171)
|
|
28
|
-
- fix: constrain edit popup height to prevent overflow [`#169`](https://github.com/karmaniverous/jeeves-server/pull/169)
|
|
29
|
-
- feat: markdown-it migration, inline block editing, OAuth2 flow (#162, #163) [`#165`](https://github.com/karmaniverous/jeeves-server/pull/165)
|
|
30
|
-
- fix: make clear-cache visible to outsiders in download menu [`#161`](https://github.com/karmaniverous/jeeves-server/pull/161)
|
|
31
|
-
- refactor: simplify checkbox toggle to fire-and-forget [`#160`](https://github.com/karmaniverous/jeeves-server/pull/160)
|
|
32
|
-
- fix: checkbox indexing for loose list items [`#159`](https://github.com/karmaniverous/jeeves-server/pull/159)
|
|
33
|
-
- fix: post-merge checkbox toggle, Gemini review, CI wildcard [`#158`](https://github.com/karmaniverous/jeeves-server/pull/158)
|
|
34
|
-
- feat: v3.7.0 / v0.8.0 — shareable URLs, insider checkbox toggles, events route fix [`#157`](https://github.com/karmaniverous/jeeves-server/pull/157)
|
|
35
|
-
- [V3-7] feat: wire MarkdownView checkbox toggling [`#154`](https://github.com/karmaniverous/jeeves-server/pull/154)
|
|
36
|
-
- [V3-7] feat: add POST /api/file/*/toggle-checkbox endpoint [`#154`](https://github.com/karmaniverous/jeeves-server/pull/154)
|
|
37
|
-
- [V3-7] feat: add checkbox indexing and mtime to markdown pipeline [`#154`](https://github.com/karmaniverous/jeeves-server/pull/154)
|
|
38
|
-
- [V3-7] feat: update TOOLS guidance to note automatic URL rewriting [`#152`](https://github.com/karmaniverous/jeeves-server/pull/152)
|
|
39
|
-
- [V3-7] feat: add publicUrl config for shareable URL rewriting [`#145`](https://github.com/karmaniverous/jeeves-server/pull/145)
|
|
40
|
-
- [V3-7] fix: correct /events route path to /api/events [`#156`](https://github.com/karmaniverous/jeeves-server/pull/156)
|
|
41
|
-
- fix: consume core importMetaUrl for plugin install (#150, #147) [`#151`](https://github.com/karmaniverous/jeeves-server/pull/151)
|
|
42
|
-
- [150] fix: consume core importMetaUrl for plugin install [`#150`](https://github.com/karmaniverous/jeeves-server/pull/150)
|
|
43
|
-
- chore: dependency updates — jeeves ^0.5.3, jsonmap ^2.1.1, @types/node ^25.5.2, and minor/patch bumps [`#149`](https://github.com/karmaniverous/jeeves-server/pull/149)
|
|
44
|
-
- feat: v3.6.0 core v0.5.1 adoption + core service alignment + UX improvements [`#146`](https://github.com/karmaniverous/jeeves-server/pull/146)
|
|
45
|
-
- [53] Fix pre-existing lint + knip errors (Commander type resolution) [`#140`](https://github.com/karmaniverous/jeeves-server/pull/140)
|
|
46
|
-
- [53] Integrate core v0.4.6: init() before descriptor.run() + knip fixes [`#139`](https://github.com/karmaniverous/jeeves-server/pull/139)
|
|
47
|
-
- [51] Integrate descriptor.run from core v0.4.5 [`#137`](https://github.com/karmaniverous/jeeves-server/pull/137)
|
|
48
|
-
- Fix config validate test assertion [`#136`](https://github.com/karmaniverous/jeeves-server/pull/136)
|
|
49
|
-
- [35] Component SDK adoption (core v0.4.4) + plugin/CLI factories [`#134`](https://github.com/karmaniverous/jeeves-server/pull/134)
|
|
50
|
-
- [35] refactor: replace hand-rolled package.json walk with packageDirectorySync [`#96`](https://github.com/karmaniverous/jeeves-server/pull/96)
|
|
51
|
-
- [35] fix: show user-friendly search error messages [`#98`](https://github.com/karmaniverous/jeeves-server/pull/98)
|
|
52
|
-
- [35] fix: decode HTML entities in TOC heading text [`#102`](https://github.com/karmaniverous/jeeves-server/pull/102)
|
|
53
|
-
- Remove /health proxy, rename /stats to /status, align client types [`#122`](https://github.com/karmaniverous/jeeves-server/pull/122)
|
|
54
|
-
- Fix runner proxy routes calling wrong endpoints [`#121`](https://github.com/karmaniverous/jeeves-server/pull/121)
|
|
55
|
-
- Bump core to v0.3.0 and consolidate status endpoint [`#119`](https://github.com/karmaniverous/jeeves-server/pull/119)
|
|
56
|
-
- Add configurable host bind + metaUrl service probe [`#114`](https://github.com/karmaniverous/jeeves-server/pull/114)
|
|
57
|
-
- feat: core v0.2.0 SDK adoption [`#111`](https://github.com/karmaniverous/jeeves-server/pull/111)
|
|
58
|
-
- feat(openclaw): adopt jeeves core component writer [`#105`](https://github.com/karmaniverous/jeeves-server/pull/105)
|
|
59
|
-
- docs: document scope override precedence in OpenClaw skill [`#95`](https://github.com/karmaniverous/jeeves-server/pull/95)
|
|
60
|
-
- feat: explicit scope overrides take precedence over named scopes [`#94`](https://github.com/karmaniverous/jeeves-server/pull/94)
|
|
61
|
-
- fix: parse inline tokens in heading renderer [`#93`](https://github.com/karmaniverous/jeeves-server/pull/93)
|
|
62
|
-
- fix: prevent full data reload on tab switch [`#91`](https://github.com/karmaniverous/jeeves-server/pull/91)
|
|
63
|
-
- fix: Rendered tab persists when switching to Raw on watcher-rendered files [`#90`](https://github.com/karmaniverous/jeeves-server/pull/90)
|
|
64
|
-
- feat: extend /api/status with ?events=N for recent event log [`#89`](https://github.com/karmaniverous/jeeves-server/pull/89)
|
|
65
|
-
- fix: server_share sends POST with JSON body instead of GET [`#87`](https://github.com/karmaniverous/jeeves-server/pull/87)
|
|
66
|
-
- docs: guide index content + typedoc jsonl highlight [`#86`](https://github.com/karmaniverous/jeeves-server/pull/86)
|
|
67
|
-
- docs: refresh README + guides for v3 [`#85`](https://github.com/karmaniverous/jeeves-server/pull/85)
|
|
68
|
-
- feat: named access scopes [`#84`](https://github.com/karmaniverous/jeeves-server/pull/84)
|
|
69
|
-
- fix: plugin auth chain, status endpoint improvements [`#83`](https://github.com/karmaniverous/jeeves-server/pull/83)
|
|
70
|
-
- fix: resetConfig should reload, not clear [`#82`](https://github.com/karmaniverous/jeeves-server/pull/82)
|
|
71
|
-
- chore: integrate client as npm workspace member [`#81`](https://github.com/karmaniverous/jeeves-server/pull/81)
|
|
72
|
-
- fix: force white background in panzoom fullscreen (dark mode) [`#80`](https://github.com/karmaniverous/jeeves-server/pull/80)
|
|
73
|
-
- chore: make both packages releasable [`#79`](https://github.com/karmaniverous/jeeves-server/pull/79)
|
|
74
|
-
- fix: address Gemini code review feedback (PRs #65-#76) [`#78`](https://github.com/karmaniverous/jeeves-server/pull/78)
|
|
75
|
-
- chore: fix all gap analysis findings (10 items) [`#77`](https://github.com/karmaniverous/jeeves-server/pull/77)
|
|
76
|
-
- Phase 4, Steps 16-18: Document rendering pipeline [`#76`](https://github.com/karmaniverous/jeeves-server/pull/76)
|
|
77
|
-
- Phase 3, Steps 11-15: OpenClaw plugin [`#75`](https://github.com/karmaniverous/jeeves-server/pull/75)
|
|
78
|
-
- Phase 2, Steps 9-10: Search facets proxy + filter UI [`#74`](https://github.com/karmaniverous/jeeves-server/pull/74)
|
|
79
|
-
- Phase 2, Step 8: Scroll anchoring [`#73`](https://github.com/karmaniverous/jeeves-server/pull/73)
|
|
80
|
-
- chore: SOLID/DRY/coverage audit pass 2 [`#72`](https://github.com/karmaniverous/jeeves-server/pull/72)
|
|
81
|
-
- Phase 2, Step 7: Link availability endpoint [`#71`](https://github.com/karmaniverous/jeeves-server/pull/71)
|
|
82
|
-
- Phase 1, Step 6: Port migration [`#70`](https://github.com/karmaniverous/jeeves-server/pull/70)
|
|
83
|
-
- Phase 1, Step 5: Diagram dependency internalization [`#69`](https://github.com/karmaniverous/jeeves-server/pull/69)
|
|
84
|
-
- Phase 1, Step 4: Server Status API [`#68`](https://github.com/karmaniverous/jeeves-server/pull/68)
|
|
85
|
-
- Phase 1, Step 3: CLI commands [`#67`](https://github.com/karmaniverous/jeeves-server/pull/67)
|
|
86
|
-
- Phase 1, Step 2: Config migration (jiti → cosmiconfig) [`#66`](https://github.com/karmaniverous/jeeves-server/pull/66)
|
|
87
|
-
- Phase 1: Monorepo & Config (v3.0.0) [`#65`](https://github.com/karmaniverous/jeeves-server/pull/65)
|
|
88
|
-
- feat: align search browse filter with watcher domains convention [`#64`](https://github.com/karmaniverous/jeeves-server/pull/64)
|
|
89
|
-
- fix: exit edit mode after save [`#63`](https://github.com/karmaniverous/jeeves-server/pull/63)
|
|
90
|
-
- chore: add default port 1934 [`#62`](https://github.com/karmaniverous/jeeves-server/pull/62)
|
|
91
|
-
- chore: add default port 1934 [`#61`](https://github.com/karmaniverous/jeeves-server/pull/61)
|
|
92
|
-
- [150] fix: consume core importMetaUrl for plugin install (#150) [`#150`](https://github.com/karmaniverous/jeeves-server/issues/150) [`#147`](https://github.com/karmaniverous/jeeves-server/issues/147)
|
|
93
|
-
- [360] feat: Phase 3 — UX improvements (CSV tables, directory item counts, collapsible frontmatter, collapsible TOC) [`#48`](https://github.com/karmaniverous/jeeves-server/issues/48)
|
|
94
|
-
- [360] feat: Phase 1 — core service adoption (getServiceUrl, getBindAddress, Node 22 fast-fail) [`#135`](https://github.com/karmaniverous/jeeves-server/issues/135)
|
|
95
|
-
- [35] refactor: remove Connected Services from TOOLS.md writer (closes #128) [`#128`](https://github.com/karmaniverous/jeeves-server/issues/128)
|
|
96
|
-
- fix: parse inline tokens in heading renderer (code spans, bold, italic) [`#92`](https://github.com/karmaniverous/jeeves-server/issues/92)
|
|
97
|
-
- [35] chore: update deps (peer-safe) [`c87c3a1`](https://github.com/karmaniverous/jeeves-server/commit/c87c3a1d10a15654ceac04c493d90abd65fe05d6)
|
|
98
|
-
- chore: add docs workflow, gitignore generated docs [`10bffb8`](https://github.com/karmaniverous/jeeves-server/commit/10bffb8b6ce9c45c31e88b07e26c4657cfba0776)
|
|
99
|
-
- fix: regenerate lockfile with npm 11.11.0 for Linux CI compatibility [`05c0014`](https://github.com/karmaniverous/jeeves-server/commit/05c00141c9d1df2f2763e535dfca315a3ac29ea8)
|
|
100
|
-
|
|
101
|
-
#### [v2.9.3](https://github.com/karmaniverous/jeeves-server/compare/v2.9.2...v2.9.3)
|
|
102
|
-
|
|
103
|
-
> 26 February 2026
|
|
104
|
-
|
|
105
|
-
- feat: render YAML frontmatter as code block [`#60`](https://github.com/karmaniverous/jeeves-server/pull/60)
|
|
106
|
-
- feat: render YAML frontmatter as code block in markdown view [`3045a94`](https://github.com/karmaniverous/jeeves-server/commit/3045a94a2364455cdeac6f36f3446fc561d37737)
|
|
107
|
-
- chore: release v2.9.3 [`1475596`](https://github.com/karmaniverous/jeeves-server/commit/1475596bcb2dd22f2c5f1621b670fc50898a11d7)
|
|
108
|
-
|
|
109
|
-
#### [v2.9.2](https://github.com/karmaniverous/jeeves-server/compare/v2.9.1...v2.9.2)
|
|
110
|
-
|
|
111
|
-
> 24 February 2026
|
|
112
|
-
|
|
113
|
-
- feat: sortable columns on runner dashboard [`023a473`](https://github.com/karmaniverous/jeeves-server/commit/023a473b53b1469b52eccda5dff76f4da2d8989f)
|
|
114
|
-
- chore: release v2.9.2 [`d3db011`](https://github.com/karmaniverous/jeeves-server/commit/d3db011a3d395de57537b7054e7ad06be160d698)
|
|
115
|
-
|
|
116
|
-
#### [v2.9.1](https://github.com/karmaniverous/jeeves-server/compare/v2.9.0...v2.9.1)
|
|
117
|
-
|
|
118
|
-
> 24 February 2026
|
|
119
|
-
|
|
120
|
-
- fix: dark mode status pills via custom-variant [`30454de`](https://github.com/karmaniverous/jeeves-server/commit/30454dec84984573214abdff5d9fcbe12d3b4e9a)
|
|
121
|
-
- chore: release v2.9.1 [`d34fd62`](https://github.com/karmaniverous/jeeves-server/commit/d34fd6205e87bd9ec7f5941ba498d3493a87f6ea)
|
|
122
|
-
- chore: release v2.9.0 [`7cdc030`](https://github.com/karmaniverous/jeeves-server/commit/7cdc03037b0bc4c25b69e849bed7f7be0f47be93)
|
|
123
|
-
|
|
124
|
-
#### [v2.9.0](https://github.com/karmaniverous/jeeves-server/compare/v2.8.0...v2.9.0)
|
|
125
|
-
|
|
126
|
-
> 24 February 2026
|
|
127
|
-
|
|
128
|
-
- feat: add runner dashboard [`#59`](https://github.com/karmaniverous/jeeves-server/pull/59)
|
|
129
|
-
- fix: event queue byte/char cursor mismatch + postbuild client [`#52`](https://github.com/karmaniverous/jeeves-server/pull/52)
|
|
130
|
-
- fix: client TS errors + picomatch dot matching [`#51`](https://github.com/karmaniverous/jeeves-server/pull/51)
|
|
131
|
-
- gitignores [`601737f`](https://github.com/karmaniverous/jeeves-server/commit/601737f2218dcd87c6979176541df4795279aa39)
|
|
132
|
-
- chore: release v2.9.0 [`7813907`](https://github.com/karmaniverous/jeeves-server/commit/78139078c7c5339e963db21940a7e70b1d4a78c1)
|
|
133
|
-
|
|
134
|
-
#### [v2.8.0](https://github.com/karmaniverous/jeeves-server/compare/v2.7.5...v2.8.0)
|
|
135
|
-
|
|
136
|
-
> 23 February 2026
|
|
137
|
-
|
|
138
|
-
- [GH-46] Semantic search UI [`#47`](https://github.com/karmaniverous/jeeves-server/pull/47)
|
|
139
|
-
- [GH-46] GH-46: Semantic search — backend proxy + frontend modal [`80383d1`](https://github.com/karmaniverous/jeeves-server/commit/80383d1ac18b3e7ad3278f384d6d7a533fac10dd)
|
|
140
|
-
- [GH-46] GH-46: Date range filtering (relative + absolute) [`e775502`](https://github.com/karmaniverous/jeeves-server/commit/e775502c4c26576bc7d38f2cd2c9dd1b1cf639c0)
|
|
141
|
-
- [GH-46] GH-46: Accordion chunks with scrollable container [`d9462e0`](https://github.com/karmaniverous/jeeves-server/commit/d9462e05b6958484f3ded9baf12d48b435818bc2)
|
|
142
|
-
|
|
143
|
-
#### [v2.7.5](https://github.com/karmaniverous/jeeves-server/compare/v2.7.4...v2.7.5)
|
|
144
|
-
|
|
145
|
-
> 22 February 2026
|
|
146
|
-
|
|
147
|
-
- [GH-44] Cache exports + Clear Cache control [`#45`](https://github.com/karmaniverous/jeeves-server/pull/45)
|
|
148
|
-
- [GH-44] GH-44: Add export cache + Clear Cache endpoint and UI [`bf41cd0`](https://github.com/karmaniverous/jeeves-server/commit/bf41cd00ac2d56c6f42d763115feb9ae88e1f5aa)
|
|
149
|
-
- [GH-44] Clear cache covers standalone diagram files (mmd/puml) [`63ba5c8`](https://github.com/karmaniverous/jeeves-server/commit/63ba5c823ca0be448bebe5c691819d8dd039c79d)
|
|
150
|
-
- [GH-44] Add .export-cache/ to gitignore [`80ade63`](https://github.com/karmaniverous/jeeves-server/commit/80ade63660b02ebecede3f08f73cd281bf1fc69e)
|
|
151
|
-
|
|
152
|
-
#### [v2.7.4](https://github.com/karmaniverous/jeeves-server/compare/v2.7.3...v2.7.4)
|
|
153
|
-
|
|
154
|
-
> 22 February 2026
|
|
155
|
-
|
|
156
|
-
- GH-42: Unify raw view on CodeMirror 6 with code folding [`#43`](https://github.com/karmaniverous/jeeves-server/pull/43)
|
|
157
|
-
- [GH-42] Replace highlight.js raw view with CodeMirror 6 read-only viewer [`547315c`](https://github.com/karmaniverous/jeeves-server/commit/547315ca640b352d54c6ab58f4dad0c83383a6e8)
|
|
158
|
-
- [GH-42] Remove highlight.js — CM6 handles all syntax highlighting [`52415ae`](https://github.com/karmaniverous/jeeves-server/commit/52415aed229b25ad2bb75473b7e1eb0cb28cd769)
|
|
159
|
-
- [GH-42] Fix DOCX code block rendering — per-line paragraphs with NBSP indent [`61db677`](https://github.com/karmaniverous/jeeves-server/commit/61db677ca130fa04e3ffba475ed1c11a2676cd2c)
|
|
160
|
-
|
|
161
|
-
#### [v2.7.3](https://github.com/karmaniverous/jeeves-server/compare/v2.7.2...v2.7.3)
|
|
162
|
-
|
|
163
|
-
> 22 February 2026
|
|
164
|
-
|
|
165
|
-
- GH-40: Retry button for failed inline diagram renders [`#41`](https://github.com/karmaniverous/jeeves-server/pull/41)
|
|
166
|
-
- [GH-40] Add retry button to failed inline diagram renders [`1fe10bd`](https://github.com/karmaniverous/jeeves-server/commit/1fe10bd731f9429c1cf691317a283d71b6a9592b)
|
|
167
|
-
- [GH-40] Improve error message and add reload hint on retry failure [`b0c02c8`](https://github.com/karmaniverous/jeeves-server/commit/b0c02c88cfa5b67f73de5f64dff47d87779e0999)
|
|
168
|
-
|
|
169
|
-
#### [v2.7.2](https://github.com/karmaniverous/jeeves-server/compare/v2.7.1...v2.7.2)
|
|
170
|
-
|
|
171
|
-
> 22 February 2026
|
|
172
|
-
|
|
173
|
-
- GH-38: Terms of Service, Privacy Policy & search engine blocking [`#39`](https://github.com/karmaniverous/jeeves-server/pull/39)
|
|
174
|
-
|
|
175
|
-
#### [v2.7.1](https://github.com/karmaniverous/jeeves-server/compare/v2.7.0...v2.7.1)
|
|
176
|
-
|
|
177
|
-
> 21 February 2026
|
|
178
|
-
|
|
179
|
-
- SOLID/DRY codebase audit — comprehensive refactor [`#37`](https://github.com/karmaniverous/jeeves-server/pull/37)
|
|
180
|
-
|
|
181
|
-
#### [v2.7.0](https://github.com/karmaniverous/jeeves-server/compare/v2.6.0...v2.7.0)
|
|
182
|
-
|
|
183
|
-
> 21 February 2026
|
|
184
|
-
|
|
185
|
-
- GH-32 + GH-33: Diagram cache + lazy-load embedded diagrams [`74b68be`](https://github.com/karmaniverous/jeeves-server/commit/74b68be594735260dbd9645e565f04a73ba76d5e)
|
|
186
|
-
|
|
187
|
-
#### [v2.6.0](https://github.com/karmaniverous/jeeves-server/compare/v2.5.0...v2.6.0)
|
|
188
|
-
|
|
189
|
-
> 20 February 2026
|
|
190
|
-
|
|
191
|
-
- feat: in-browser text editing (GH-30) [`#31`](https://github.com/karmaniverous/jeeves-server/pull/31)
|
|
192
|
-
- chore: bump version to 2.6.0 [`7d54aa3`](https://github.com/karmaniverous/jeeves-server/commit/7d54aa3be4c4ae0093ed86bd16d98e57ed3bdf77)
|
|
193
|
-
|
|
194
|
-
#### [v2.5.0](https://github.com/karmaniverous/jeeves-server/compare/v2.4.0...v2.5.0)
|
|
195
|
-
|
|
196
|
-
> 20 February 2026
|
|
197
|
-
|
|
198
|
-
- feat: Render embedded Mermaid/PlantUML code blocks (GH-23) [`#27`](https://github.com/karmaniverous/jeeves-server/pull/27)
|
|
199
|
-
- chore: bump version to 2.5.0 [`2c42e14`](https://github.com/karmaniverous/jeeves-server/commit/2c42e14aa5e6324b67c5ef0dc615cece50cf1992)
|
|
200
|
-
|
|
201
|
-
#### [v2.4.0](https://github.com/karmaniverous/jeeves-server/compare/v2.3.5...v2.4.0)
|
|
202
|
-
|
|
203
|
-
> 20 February 2026
|
|
204
|
-
|
|
205
|
-
- feat: Native PlantUML support (GH-22) [`#25`](https://github.com/karmaniverous/jeeves-server/pull/25)
|
|
206
|
-
- chore: bump version to 2.4.0 [`ddf9d87`](https://github.com/karmaniverous/jeeves-server/commit/ddf9d87cf8b42420d0bc3e24b46489bbec04aff8)
|
|
207
|
-
|
|
208
|
-
#### [v2.3.5](https://github.com/karmaniverous/jeeves-server/compare/v2.3.4...v2.3.5)
|
|
209
|
-
|
|
210
|
-
> 20 February 2026
|
|
211
|
-
|
|
212
|
-
- fix: case-insensitive email comparison for insider matching [`#24`](https://github.com/karmaniverous/jeeves-server/pull/24)
|
|
213
|
-
|
|
214
|
-
#### [v2.3.4](https://github.com/karmaniverous/jeeves-server/compare/v2.3.3...v2.3.4)
|
|
215
|
-
|
|
216
|
-
> 19 February 2026
|
|
217
|
-
|
|
218
|
-
- refactor: Copy Raw Link builds /api/raw/ URL directly, remove raw=1 redirect [`#21`](https://github.com/karmaniverous/jeeves-server/pull/21)
|
|
219
|
-
|
|
220
|
-
#### [v2.3.3](https://github.com/karmaniverous/jeeves-server/compare/v2.3.2...v2.3.3)
|
|
221
|
-
|
|
222
|
-
> 19 February 2026
|
|
223
|
-
|
|
224
|
-
- feat: raw=1 on /browse/* redirects to /api/raw/* for raw file delivery [`#20`](https://github.com/karmaniverous/jeeves-server/pull/20)
|
|
225
|
-
|
|
226
|
-
#### [v2.3.2](https://github.com/karmaniverous/jeeves-server/compare/v2.3.1...v2.3.2)
|
|
227
|
-
|
|
228
|
-
> 19 February 2026
|
|
229
|
-
|
|
230
|
-
- fix: forward auth params on downloads, show error popup on failure [`#19`](https://github.com/karmaniverous/jeeves-server/pull/19)
|
|
231
|
-
|
|
232
|
-
#### [v2.3.1](https://github.com/karmaniverous/jeeves-server/compare/v2.3.0...v2.3.1)
|
|
233
|
-
|
|
234
|
-
> 18 February 2026
|
|
235
|
-
|
|
236
|
-
- refactor: replace hand-rolled glob matching with picomatch [`#18`](https://github.com/karmaniverous/jeeves-server/pull/18)
|
|
237
|
-
|
|
238
|
-
#### [v2.3.0](https://github.com/karmaniverous/jeeves-server/compare/v2.2.1...v2.3.0)
|
|
239
|
-
|
|
240
|
-
> 18 February 2026
|
|
241
|
-
|
|
242
|
-
- [GH-16] feat(GH-16): utility share-for endpoint + outsider policy [`#17`](https://github.com/karmaniverous/jeeves-server/pull/17)
|
|
243
|
-
|
|
244
|
-
#### [v2.2.1](https://github.com/karmaniverous/jeeves-server/compare/v2.2.0...v2.2.1)
|
|
245
|
-
|
|
246
|
-
> 18 February 2026
|
|
247
|
-
|
|
248
|
-
- Allow/deny scopes for insiders and keys [`#15`](https://github.com/karmaniverous/jeeves-server/pull/15)
|
|
249
|
-
- chore: update repo description and add keywords to package.json [`5130698`](https://github.com/karmaniverous/jeeves-server/commit/51306983c3bcf6e8f8af8d49316512437c1cc1ff)
|
|
250
|
-
|
|
251
|
-
#### [v2.2.0](https://github.com/karmaniverous/jeeves-server/compare/v2.1.0...v2.2.0)
|
|
252
|
-
|
|
253
|
-
> 17 February 2026
|
|
254
|
-
|
|
255
|
-
- GH-13: Linux compatibility [`#14`](https://github.com/karmaniverous/jeeves-server/pull/14)
|
|
256
|
-
|
|
257
|
-
#### [v2.1.0](https://github.com/karmaniverous/jeeves-server/compare/v2.0.1...v2.1.0)
|
|
258
|
-
|
|
259
|
-
> 17 February 2026
|
|
260
|
-
|
|
261
|
-
- [GH-11] Deep share links with depth and directory controls [`#12`](https://github.com/karmaniverous/jeeves-server/pull/12)
|
|
262
|
-
- docs: add platform support section, sync requirements with GH-11 implementation, call out Linux as next-up [`261ff4d`](https://github.com/karmaniverous/jeeves-server/commit/261ff4d69de26ef7fdc83295c7ea9e255ce9214e)
|
|
263
|
-
- fix: header button hover in light mode - use white/10 overlay instead of accent bg [`eeb370c`](https://github.com/karmaniverous/jeeves-server/commit/eeb370c1dfaa79ba03f4685fddd664874f2b3e7a)
|
|
264
|
-
|
|
265
|
-
#### [v2.0.1](https://github.com/karmaniverous/jeeves-server/compare/v2.0.0...v2.0.1)
|
|
266
|
-
|
|
267
|
-
> 17 February 2026
|
|
268
|
-
|
|
269
|
-
- Fix PDF/DOCX export rendering [`#10`](https://github.com/karmaniverous/jeeves-server/pull/10)
|
|
270
|
-
- Decommission path routes [`#8`](https://github.com/karmaniverous/jeeves-server/pull/8)
|
|
271
|
-
- [GH-9] fix DOCX SVG export — render SVGs in clean isolated pages [`#9`](https://github.com/karmaniverous/jeeves-server/issues/9)
|
|
272
|
-
- [GH-9] fix DOCX SVG screenshot offset — use element.screenshot() instead of clip [`#9`](https://github.com/karmaniverous/jeeves-server/issues/9)
|
|
273
|
-
- [GH-9] fix SVG rendering in SPA and PDF/DOCX export issues [`#9`](https://github.com/karmaniverous/jeeves-server/issues/9)
|
|
274
|
-
- [GH-9] fix PDF/DOCX exports rendering panzoom container chrome [`#9`](https://github.com/karmaniverous/jeeves-server/issues/9)
|
|
275
|
-
- [GH-7] decommission /path routes — migrate to /api/raw, /api/export, /browse redirect [`#7`](https://github.com/karmaniverous/jeeves-server/issues/7)
|
|
276
|
-
- [GH-7] remove legacy server.js — replaced by src/server.ts [`6a701e6`](https://github.com/karmaniverous/jeeves-server/commit/6a701e6eb9325c39b20799673f5aee58877538ee)
|
|
277
|
-
- [GH-7] remove server-rendered about page, templates, and test PDFs [`bad31ca`](https://github.com/karmaniverous/jeeves-server/commit/bad31ca3c4da5eb00ea9183c0b5a1dbb9442a0cf)
|
|
278
|
-
- [GH-9] render DOCX SVGs at full page width (1152px) [`dbb5bae`](https://github.com/karmaniverous/jeeves-server/commit/dbb5bae948f762b65da047980fdcdf44c1999727)
|
|
279
|
-
|
|
280
|
-
### [v2.0.0](https://github.com/karmaniverous/jeeves-server/compare/v1.2.1...v2.0.0)
|
|
281
|
-
|
|
282
|
-
> 16 February 2026
|
|
283
|
-
|
|
284
|
-
- v2.0.0: React SPA migration [`#6`](https://github.com/karmaniverous/jeeves-server/pull/6)
|
|
285
|
-
- [GH-5] merge: resolve conflicts with main (keep feature branch for frozen server pages) [`2c57b6f`](https://github.com/karmaniverous/jeeves-server/commit/2c57b6f11a0293c22da9c74c1b80b229b01f0fe0)
|
|
286
|
-
- [GH-5] feat: React + Vite scaffold with file browser, API endpoints, and SPA serving (GH-5) [`6a8ffb5`](https://github.com/karmaniverous/jeeves-server/commit/6a8ffb5e932e648a44311ac9a686e5cb1b31c104)
|
|
287
|
-
- [GH-5] Dropdown menus, TS config, state separation, local static assets [`16f40b4`](https://github.com/karmaniverous/jeeves-server/commit/16f40b4607037c8b5992a7a3bbf1d586d697cce8)
|
|
288
|
-
|
|
289
|
-
#### [v1.2.1](https://github.com/karmaniverous/jeeves-server/compare/v1.2.0...v1.2.1)
|
|
290
|
-
|
|
291
|
-
> 15 February 2026
|
|
292
|
-
|
|
293
|
-
- fix: wrap entire startup in try/catch, surface errors instead of silent exit [`1913fe1`](https://github.com/karmaniverous/jeeves-server/commit/1913fe13af0bc992df7d49fc2d3a953fb4b1b538)
|
|
294
|
-
- fix: mobile header — hide redundant share UI on directories, allow header wrapping (GH-4) [`6306f27`](https://github.com/karmaniverous/jeeves-server/commit/6306f27da93700757a328de83f34c5179b89bfc5)
|
|
295
|
-
- fix: header stretches to full content width when zoomed out [`bbebeec`](https://github.com/karmaniverous/jeeves-server/commit/bbebeec052f1d76a1e1b14a7574bf35ffd1a3dc5)
|
|
296
|
-
|
|
297
|
-
#### [v1.2.0](https://github.com/karmaniverous/jeeves-server/compare/v1.1.0...v1.2.0)
|
|
298
|
-
|
|
299
|
-
> 15 February 2026
|
|
300
|
-
|
|
301
|
-
- Merge feature/GH-4-google-oauth: Google OAuth + per-row share icons [`4706828`](https://github.com/karmaniverous/jeeves-server/commit/470682852b610da5a262501a216feaf71c035d34)
|
|
302
|
-
- [GH-4] feat: add Google OAuth and cookie sessions (GH-4) [`89b6d72`](https://github.com/karmaniverous/jeeves-server/commit/89b6d729edc6e9a360aa1d8c745de0cdcd8d573f)
|
|
303
|
-
- [GH-4] feat: directory outsider links, new share UI, per-insider key age (GH-4) [`4cbc001`](https://github.com/karmaniverous/jeeves-server/commit/4cbc001b1ed163b6735ff1667c70008d20729b43)
|
|
304
|
-
|
|
305
|
-
#### [v1.1.0](https://github.com/karmaniverous/jeeves-server/compare/v1.0.3...v1.1.0)
|
|
306
|
-
|
|
307
|
-
> 15 February 2026
|
|
308
|
-
|
|
309
|
-
- v1.1.0: TypeScript/Fastify refactor, event gateway, named keys with scopes [`f3711f8`](https://github.com/karmaniverous/jeeves-server/commit/f3711f82ed0f30156c7980440ad55dec336be0df)
|
|
310
|
-
- Merge feature/GH-3-ts-refactor: TypeScript/Fastify refactor with event gateway and named keys [`a920a99`](https://github.com/karmaniverous/jeeves-server/commit/a920a99e9975215c653a29decad2e9e578b438de)
|
|
311
|
-
- [GH-3] TypeScript refactor scaffolding and core modules [`8dd0b92`](https://github.com/karmaniverous/jeeves-server/commit/8dd0b927e70eb89af416ce9708dcbc8de05a41da)
|
|
312
|
-
|
|
313
|
-
#### [v1.0.3](https://github.com/karmaniverous/jeeves-server/compare/v1.0.2...v1.0.3)
|
|
314
|
-
|
|
315
|
-
> 8 February 2026
|
|
316
|
-
|
|
317
|
-
- Reduce PDF/DOCX font sizes to 10pt base [`2617ac9`](https://github.com/karmaniverous/jeeves-server/commit/2617ac969c6dc3d503fdb63760d8d8f68cdae0c7)
|
|
318
|
-
- Fix PDF font size - add 10pt to PDF-specific styles [`18b3505`](https://github.com/karmaniverous/jeeves-server/commit/18b35059f3eef267cdcb01e51dd49e1d8a9fb173)
|
|
319
|
-
|
|
320
|
-
#### [v1.0.2](https://github.com/karmaniverous/jeeves-server/compare/v1.0.1...v1.0.2)
|
|
321
|
-
|
|
322
|
-
> 7 February 2026
|
|
323
|
-
|
|
324
|
-
- Fix raw download for markdown files [`25952cd`](https://github.com/karmaniverous/jeeves-server/commit/25952cd0362a47ebdaf4958fc86436a96c1f8c1f)
|
|
325
|
-
- Add top hat branding to outsider pages, improve filename display [`cacbb60`](https://github.com/karmaniverous/jeeves-server/commit/cacbb605b58064002aba3911009c5fb3788990ff)
|
|
326
|
-
- Add 'Jeeves Server' tooltip to top hat in all modes [`26902d4`](https://github.com/karmaniverous/jeeves-server/commit/26902d45d74aea615f706700ebdf2068c4f95bd7)
|
|
327
|
-
|
|
328
|
-
### [v1.0.1](https://github.com/karmaniverous/jeeves-server/compare/v0.1.2...v1.0.1)
|
|
329
|
-
|
|
330
|
-
> 7 February 2026
|
|
331
|
-
|
|
332
|
-
#### [v0.1.2](https://github.com/karmaniverous/jeeves-server/compare/v0.1.1...v0.1.2)
|
|
333
|
-
|
|
334
|
-
> 7 February 2026
|
|
335
|
-
|
|
336
|
-
- Add HTML wrapper for SVG files with proper constraints [`edf794b`](https://github.com/karmaniverous/jeeves-server/commit/edf794beb8e1c81d4c4d698d4fc7ecef2412d66c)
|
|
337
|
-
- Allow clickthrough on binary files, block only dangerous executables [`be338eb`](https://github.com/karmaniverous/jeeves-server/commit/be338ebdb7872b60682836ddd761f4e1a215ef5e)
|
|
338
|
-
- Fix panzoom overlay sizing for tall SVGs - strip inline styles, size based on aspect ratio [`1fabf75`](https://github.com/karmaniverous/jeeves-server/commit/1fabf753cd0f22531cce2861e2fe80727dc00635)
|
|
339
|
-
|
|
340
|
-
#### [v0.1.1](https://github.com/karmaniverous/jeeves-server/compare/v0.1.0...v0.1.1)
|
|
341
|
-
|
|
342
|
-
> 7 February 2026
|
|
343
|
-
|
|
344
|
-
- Fix DOCX image sizing: preserve aspect ratio within max bounds [`9755b15`](https://github.com/karmaniverous/jeeves-server/commit/9755b15d20e82c78c452e48c220214f1fb238293)
|
|
345
|
-
- docs: add integration guide for other projects [`4512d9b`](https://github.com/karmaniverous/jeeves-server/commit/4512d9b881fd3de20f8c9c68fe3097fd4e97b7e7)
|
|
346
|
-
- feat: detect text files by content (null bytes) instead of extension whitelist [`cf8c99a`](https://github.com/karmaniverous/jeeves-server/commit/cf8c99a911b268df9761da9efdde7526c4004e2b)
|
|
347
|
-
|
|
348
|
-
#### v0.1.0
|
|
349
|
-
|
|
350
|
-
> 7 February 2026
|
|
351
|
-
|
|
352
|
-
- feat: track key rotation timestamp, display relative time, DRY up header components [`993023e`](https://github.com/karmaniverous/jeeves-server/commit/993023e240174cc420f43ca93187b69d9b49812f)
|
|
353
|
-
- Add heading anchors, TOC, and Windows path linking [`f49962d`](https://github.com/karmaniverous/jeeves-server/commit/f49962da01488d244898aaceef4c5d0cecf72915)
|
|
354
|
-
- Initial commit: Express server with webhook receiver, file server, and path-key auth [`31c83ca`](https://github.com/karmaniverous/jeeves-server/commit/31c83ca0593a09bfcece5501920dad7f8c78a74f)
|
package/src/crypto.ts
DELETED
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Cryptographic utilities for HMAC key computation and verification.
|
|
3
|
-
*
|
|
4
|
-
* @packageDocumentation
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
import crypto from 'node:crypto';
|
|
8
|
-
|
|
9
|
-
/**
|
|
10
|
-
* Compute path-specific key: HMAC-SHA256(apiKey, normalizedPath)
|
|
11
|
-
*/
|
|
12
|
-
export function computePathKey(apiKey: string, urlPath: string): string {
|
|
13
|
-
const normalized = urlPath.toLowerCase().replace(/^\/+|\/+$/g, '');
|
|
14
|
-
const hash = crypto
|
|
15
|
-
.createHmac('sha256', apiKey)
|
|
16
|
-
.update(normalized)
|
|
17
|
-
.digest('hex');
|
|
18
|
-
return hash.substring(0, 32);
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
/**
|
|
22
|
-
* Compute insider key: HMAC-SHA256(apiKey, "insider")
|
|
23
|
-
* Works for any path, grants full navigation
|
|
24
|
-
*/
|
|
25
|
-
export function computeInsiderKey(apiKey: string): string {
|
|
26
|
-
const hash = crypto
|
|
27
|
-
.createHmac('sha256', apiKey)
|
|
28
|
-
.update('insider')
|
|
29
|
-
.digest('hex');
|
|
30
|
-
return hash.substring(0, 32);
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
/**
|
|
34
|
-
* Compute outsider key with expiry: HMAC-SHA256(apiKey, path + "|" + expiry)
|
|
35
|
-
*/
|
|
36
|
-
export function computeOutsiderKeyWithExpiry(
|
|
37
|
-
apiKey: string,
|
|
38
|
-
urlPath: string,
|
|
39
|
-
expiry: string | number,
|
|
40
|
-
): string {
|
|
41
|
-
const normalized = urlPath.toLowerCase().replace(/^\/+|\/+$/g, '');
|
|
42
|
-
const data = `${normalized}|${String(expiry)}`;
|
|
43
|
-
const hash = crypto.createHmac('sha256', apiKey).update(data).digest('hex');
|
|
44
|
-
return hash.substring(0, 32);
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
/**
|
|
48
|
-
* Deep share key parameters
|
|
49
|
-
*/
|
|
50
|
-
export interface DeepShareParams {
|
|
51
|
-
depth: number;
|
|
52
|
-
dirs: boolean;
|
|
53
|
-
stack: string; // lz-string compressToEncodedURIComponent'd path stack
|
|
54
|
-
exp?: string;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
/**
|
|
58
|
-
* Compute deep share key: HMAC-SHA256(seed, path + "|" + d + "|" + dirs + "|" + stack + "|" + exp)
|
|
59
|
-
* Used for share links with depth \> 0 or dirs enabled.
|
|
60
|
-
*/
|
|
61
|
-
export function computeDeepShareKey(
|
|
62
|
-
seed: string,
|
|
63
|
-
urlPath: string,
|
|
64
|
-
params: DeepShareParams,
|
|
65
|
-
): string {
|
|
66
|
-
const normalized = urlPath.toLowerCase().replace(/^\/+|\/+$/g, '');
|
|
67
|
-
const data = `${normalized}|${String(params.depth)}|${params.dirs ? '1' : '0'}|${params.stack}|${params.exp ?? ''}`;
|
|
68
|
-
const hash = crypto.createHmac('sha256', seed).update(data).digest('hex');
|
|
69
|
-
return hash.substring(0, 32);
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
/**
|
|
73
|
-
* Timing-safe string comparison
|
|
74
|
-
*/
|
|
75
|
-
export function timingSafeEqual(a: string, b: string): boolean {
|
|
76
|
-
try {
|
|
77
|
-
return crypto.timingSafeEqual(Buffer.from(a), Buffer.from(b));
|
|
78
|
-
} catch {
|
|
79
|
-
return false;
|
|
80
|
-
}
|
|
81
|
-
}
|
package/src/index.ts
DELETED
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Shared utilities and types for jeeves-server packages.
|
|
3
|
-
*
|
|
4
|
-
* @packageDocumentation
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
export {
|
|
8
|
-
computeDeepShareKey,
|
|
9
|
-
computeInsiderKey,
|
|
10
|
-
computeOutsiderKeyWithExpiry,
|
|
11
|
-
computePathKey,
|
|
12
|
-
type DeepShareParams,
|
|
13
|
-
timingSafeEqual,
|
|
14
|
-
} from './crypto.js';
|
|
15
|
-
export type {
|
|
16
|
-
AuthStatusResponse,
|
|
17
|
-
DriveEntry,
|
|
18
|
-
ExportCacheClearResponse,
|
|
19
|
-
ExportLink,
|
|
20
|
-
FileMutationAction,
|
|
21
|
-
LinkInfoResponse,
|
|
22
|
-
OAuthStartRequest,
|
|
23
|
-
OAuthStartResponse,
|
|
24
|
-
RotateKeyResponse,
|
|
25
|
-
ShareForRequest,
|
|
26
|
-
ShareForResponse,
|
|
27
|
-
ShareRequest,
|
|
28
|
-
ShareResponse,
|
|
29
|
-
} from './types.js';
|
package/src/types.ts
DELETED
|
@@ -1,108 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Shared API request/response types between service and plugin.
|
|
3
|
-
*
|
|
4
|
-
* @packageDocumentation
|
|
5
|
-
*/
|
|
6
|
-
|
|
7
|
-
/** POST /api/share request body. */
|
|
8
|
-
export interface ShareRequest {
|
|
9
|
-
path: string;
|
|
10
|
-
expiry?: string;
|
|
11
|
-
depth?: number;
|
|
12
|
-
dirs?: boolean;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/** POST /api/share response. */
|
|
16
|
-
export interface ShareResponse {
|
|
17
|
-
url: string;
|
|
18
|
-
path: string;
|
|
19
|
-
exp: string | null;
|
|
20
|
-
depth?: number;
|
|
21
|
-
dirs?: boolean;
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
/** POST /api/util/share-for request body. */
|
|
25
|
-
export interface ShareForRequest {
|
|
26
|
-
path: string;
|
|
27
|
-
insiders: string[];
|
|
28
|
-
depth?: number;
|
|
29
|
-
dirs?: boolean;
|
|
30
|
-
enforceOutsiderPolicy?: boolean;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
/** POST /api/util/share-for response. */
|
|
34
|
-
export interface ShareForResponse {
|
|
35
|
-
url: string | null;
|
|
36
|
-
type: 'insider' | 'outsider-share' | 'blocked' | 'policy-denied';
|
|
37
|
-
reason?: string;
|
|
38
|
-
blocked?: string[];
|
|
39
|
-
warning?: string;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
/** POST /api/oauth/start request body. */
|
|
43
|
-
export interface OAuthStartRequest {
|
|
44
|
-
provider: string;
|
|
45
|
-
account: string;
|
|
46
|
-
clientId: string;
|
|
47
|
-
clientSecret: string;
|
|
48
|
-
scopes?: string[];
|
|
49
|
-
origin?: string;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
/** POST /api/oauth/start response. */
|
|
53
|
-
export interface OAuthStartResponse {
|
|
54
|
-
authUrl?: string;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
/** GET /api/link-info response. */
|
|
58
|
-
export interface LinkInfoResponse {
|
|
59
|
-
exists: boolean;
|
|
60
|
-
isDirectory?: boolean;
|
|
61
|
-
pageUrl?: string;
|
|
62
|
-
rawUrl?: string | null;
|
|
63
|
-
exportLinks?: ExportLink[];
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
/** Export link entry in link-info response. */
|
|
67
|
-
export interface ExportLink {
|
|
68
|
-
format: string;
|
|
69
|
-
url: string;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
/** GET /api/export-cache DELETE response. */
|
|
73
|
-
export interface ExportCacheClearResponse {
|
|
74
|
-
cleared: {
|
|
75
|
-
exports: number;
|
|
76
|
-
diagrams: number;
|
|
77
|
-
};
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
/** File mutation action types. */
|
|
81
|
-
export type FileMutationAction =
|
|
82
|
-
| 'edit-block'
|
|
83
|
-
| 'delete-block'
|
|
84
|
-
| 'insert-block'
|
|
85
|
-
| 'edit-cell'
|
|
86
|
-
| 'toggle-checkbox';
|
|
87
|
-
|
|
88
|
-
/** POST /api/rotate-key response. */
|
|
89
|
-
export interface RotateKeyResponse {
|
|
90
|
-
ok: boolean;
|
|
91
|
-
keyCreatedAt: string;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
/** GET /api/auth/status response. */
|
|
95
|
-
export interface AuthStatusResponse {
|
|
96
|
-
authenticated: boolean;
|
|
97
|
-
email?: string;
|
|
98
|
-
picture?: string;
|
|
99
|
-
isInsider: boolean;
|
|
100
|
-
keyCreatedAt?: string | null;
|
|
101
|
-
searchEnabled?: boolean;
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
/** GET /api/drives response entry. */
|
|
105
|
-
export interface DriveEntry {
|
|
106
|
-
letter: string;
|
|
107
|
-
label: string;
|
|
108
|
-
}
|
package/tsconfig.json
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "../../tsconfig.json",
|
|
3
|
-
"compilerOptions": {
|
|
4
|
-
"outDir": "dist",
|
|
5
|
-
"rootDir": ".",
|
|
6
|
-
"noEmit": false,
|
|
7
|
-
"declaration": true,
|
|
8
|
-
"declarationMap": true,
|
|
9
|
-
"types": [
|
|
10
|
-
"node",
|
|
11
|
-
"vitest/globals"
|
|
12
|
-
]
|
|
13
|
-
},
|
|
14
|
-
"include": [
|
|
15
|
-
"src/**/*"
|
|
16
|
-
],
|
|
17
|
-
"exclude": [
|
|
18
|
-
"dist",
|
|
19
|
-
"node_modules"
|
|
20
|
-
]
|
|
21
|
-
}
|