@synopackageland/cli 0.48.17 → 0.48.18

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
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.48.18
4
+
5
+ - Skill documents HTTP/HTTPS handling: HTTP stays allowed with no automatic redirect, `identity_gateway.secure_context: required` for Apps that need a secure context, and upstream OIDC callbacks that follow the request scheme instead of a hard-coded https
6
+
3
7
  ## 0.48.17
4
8
 
5
9
  - install and repair reclaim a stopped Container Manager project left behind by the same package (exact Compose path ownership) before reinstalling; named volumes, data and images are kept, and foreign or active projects stop the install
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@synopackageland/cli",
3
- "version": "0.48.17",
3
+ "version": "0.48.18",
4
4
  "description": "Syno Package Land Developer Kit CLI",
5
5
  "type": "module",
6
6
  "bin": {
package/skills/SKILL.md CHANGED
@@ -385,6 +385,11 @@ App 不要預設強制 HTTPS。只有使用 secure context 能力(`getUserMedi
385
385
  fragment 不保留。PortInfo 限管理員,一般使用者呼叫可能被拒或關閉 DSM 視窗;
386
386
  一般使用者只顯示說明文字。查不到埠時不猜測、不阻擋說明頁。
387
387
 
388
+ HTTP 允許,不做自動 HTTP→HTTPS 轉址或自製轉址頁。identity gateway App 需要
389
+ secure context 時宣告 `identity_gateway.secure_context: required`;上游 OIDC
390
+ callback 必須跟隨實際請求的 scheme,不可在上游設定寫死 https。細節見
391
+ [identity-gateway.md](reference/identity-gateway.md) 的「HTTP, HTTPS and redirects」。
392
+
388
393
  舊 DSM 分頁可能在其他分頁重新登入後繼續帶舊 `X-SYNO-TOKEN`。對明確宣告
389
394
  `effect: read` 的一般 JSON RPC,可用 `createClient({sessionRetry: ...})`
390
395
  搭配 `createDsmSession` 的 `refresh(rejectedToken)` 更新 token 後重試一次。
@@ -90,6 +90,28 @@ also apply: Cloudflare edge enforces the zone's upload limit, and long
90
90
  responses need heartbeats within 60 seconds; use SSE or
91
91
  `Cache-Control: no-transform` for streaming.
92
92
 
93
+ ## HTTP, HTTPS and redirects
94
+
95
+ HTTP is allowed. Do not add an automatic HTTP→HTTPS redirect, a custom
96
+ redirect page or a forced-HTTPS upstream setting. The gateway shows the
97
+ existing HTTP warning; HTTPS behavior is unchanged.
98
+
99
+ Declare `identity_gateway.secure_context: required` only when the App truly
100
+ needs a secure context (WebCrypto `subtle`, `getUserMedia`, Service Worker,
101
+ clipboard, strict upstream Origin checks). It works for Compose and standalone
102
+ gateways; any value other than `required` fails `check`. HTTP top-level
103
+ navigations then get a localized HTTPS-required page with a user-operated
104
+ "Open using HTTPS" link and no automatic redirect; HTTP API, resource and
105
+ iframe requests get 403 `https_required`. The HTTPS port comes from DSM's own
106
+ declaration; when none is found, the page shows text guidance and never
107
+ guesses a port. See the CLI's `docs/path-ingress.md`.
108
+
109
+ Upstream OIDC callbacks and generated absolute URLs must follow the scheme of
110
+ the actual request. Never hard-code `https` in upstream settings (for example a
111
+ scheme override or a default-protocol variable set to https): sign-in over HTTP
112
+ then fails with a redirect_uri mismatch. Let upstream detect HTTPS through its
113
+ trusted proxy header instead. Test sign-in over both HTTP and HTTPS.
114
+
93
115
  ## Per-request OIDC browser origins (development)
94
116
 
95
117
  `oidc.browser_redirect: {}` opts into per-request browser origins for SDK/CLI