@stacksjs/defaults 0.75.162 → 0.75.164

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.
@@ -78,7 +78,7 @@ Browser runtime bindings are documented separately in `stacks-auto-imports`.
78
78
  | `@stacksjs/router` | [`stacks-router`](../stacks-router/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/router/src/index.ts) | 87 |
79
79
  | `@stacksjs/scheduler` | [`stacks-scheduler`](../stacks-scheduler/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/scheduler/src/index.ts) | 13 |
80
80
  | `@stacksjs/search-engine` | [`stacks-search-engine`](../stacks-search-engine/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/search-engine/src/index.ts) | 10 |
81
- | `@stacksjs/security` | [`stacks-security`](../stacks-security/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/index.ts) | 5 |
81
+ | `@stacksjs/security` | [`stacks-security`](../stacks-security/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/index.ts) | 8 |
82
82
  | `@stacksjs/server` | [`stacks-server`](../stacks-server/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/server/src/index.ts) | 21 |
83
83
  | `@stacksjs/shell` | [`stacks-shell`](../stacks-shell/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/shell/src/index.ts) | 1 |
84
84
  | `@stacksjs/sites` | [`stacks-sites`](../stacks-sites/SKILL.md) | [entrypoint](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/sites/src/index.ts) | 3 |
@@ -749,9 +749,9 @@ Guidance: [`stacks-security`](../stacks-security/SKILL.md). Source: [storage/fra
749
749
 
750
750
  Read the entrypoint and package export map for re-exported or type-only surfaces.
751
751
 
752
- Local source modules: [src/crypt.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/crypt.ts), [src/hash.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/hash.ts), [src/key.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/key.ts), [src/webhook.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/webhook.ts).
752
+ Local source modules: [src/api-key.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/api-key.ts), [src/crypt.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/crypt.ts), [src/hash.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/hash.ts), [src/key.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/key.ts), [src/outbound.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/outbound.ts), [src/webhook.ts](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/src/webhook.ts).
753
753
 
754
- Evidence directory: [5 retained tests](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/tests). These files are evidence pointers, not a claim that all tests were run for this catalog.
754
+ Evidence directory: [8 retained tests](https://github.com/stacksjs/stacks/blob/main/storage/framework/core/security/tests). These files are evidence pointers, not a claim that all tests were run for this catalog.
755
755
 
756
756
  ### @stacksjs/server
757
757
 
@@ -161,7 +161,21 @@ PBKDF2-SHA-256 derivation in `core/security/src/crypt.ts`; decrypt retains
161
161
  legacy formats for upgrades. The base64: APP_KEY prefix is normalized by that
162
162
  implementation. Encryption/hashing/encoding are distinct APIs; use the exported
163
163
  webhook helpers from `core/security/src/webhook.ts` for signed callback
164
- validation rather than inventing a string comparison.
164
+ validation rather than inventing a string comparison. To SEND signed webhooks,
165
+ `signWebhook(secret | secrets[], body, { timestamp? })` returns the
166
+ `t=<unix>,v1=<hex>` header (HMAC-SHA256 of `${t}.${body}`, one `v1` per secret
167
+ while rotating) and `verifySignedWebhook` / `verifyWebhook('signed', ...)` is
168
+ the receiver's check (tolerance applies both ways). `generateWebhookSecret()`
169
+ mints a `whsec_` secret; store it encrypted, since signing needs the plaintext.
170
+
171
+ Outbound requests to a URL a user typed (webhook endpoints, import-from-URL)
172
+ go through `outboundUrlProblem(url, { allowHttp?, allowPrivate? })` when the
173
+ URL is saved and `await assertPublicOutboundUrl(url, opts)` right before the
174
+ request: https only, no credentials, and every resolved address public
175
+ (`isPrivateAddress` covers loopback, RFC 1918, CGNAT, link-local metadata,
176
+ IPv4-mapped/NAT64/6to4 forms). It throws `OutboundUrlError` with a `reason`.
177
+ API keys handed to integrations: `generateApiKey('myapp_live_')` returns
178
+ `{ key, hash, hint }`; show `key` once, store `hash` (`hashApiKey`), list `hint`.
165
179
 
166
180
  Generated model API exposure and ownership live under `config/security.ts`
167
181
  api settings. Read `stacks-models`/`stacks-router` before opening generated
@@ -2,7 +2,7 @@
2
2
  "publisher": "Stacks",
3
3
  "name": "vscode-stacks",
4
4
  "displayName": "Stacks",
5
- "version": "0.75.162",
5
+ "version": "0.75.164",
6
6
  "description": "Stacks, built into VS Code: stx templates, pickier linting and formatting, encrypted env files, the dev server preview and every buddy command. No other extensions required.",
7
7
  "license": "MIT",
8
8
  "funding": "https://github.com/sponsors/chrisbbreuer",
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@stacksjs/defaults",
3
3
  "type": "module",
4
4
  "sideEffects": false,
5
- "version": "0.75.162",
5
+ "version": "0.75.164",
6
6
  "repository": {
7
7
  "type": "git",
8
8
  "url": "git+https://github.com/stacksjs/stacks.git",
@@ -55,7 +55,7 @@
55
55
  "dependencies": {
56
56
  "@iconify-json/f7": "^1.2.2",
57
57
  "@iconify-json/hugeicons": "^1.2.35",
58
- "@stacksjs/mobile": "0.75.162",
58
+ "@stacksjs/mobile": "0.75.164",
59
59
  "@stacksjs/sanitizer": "^0.2.483",
60
60
  "@xterm/addon-fit": "^0.11.0",
61
61
  "@xterm/xterm": "^6.0.0",