Skip to content

v1.6.7 — the panel can reach its own API again

Choose a tag to compare

@stallenlu stallenlu released this 13 Nov 10:13
· 7 commits to main since this release

v1.6.7 — the panel can reach its own API again

Regression fix. 1.6.6 tightened the route's origin gate until it also refused the plugin's
own panel: the desktop window posts from dsh-app://app, which no http://127.0.0.1:<port>
comparison can ever match, and the desktop forwarder can strip the Origin header entirely.
Users saw "请求来源不被接受:请从面板里操作" on the first scan.

The gate now accepts both of those, but only when the request already arrived on a loopback
address. A web page cannot reach a loopback port without sending an Origin, so the protection
the change was for is untouched.

No other behaviour changed — this release is the origin gate and the documentation that
describes it.

Verify

node --check lib/index.js && node smoke.mjs   # 110 passed, 0 failed
request before 1.6.7 1.6.7
Origin: dsh-app://app, loopback Host (the real panel) 403 200
no Origin header, loopback Host (forwarded panel) 403 200
Origin: https://evil.example, loopback Host 403 403
no Origin, non-loopback Host 403 403
dsh plugin --profile <profile> add https://github.com/stallenlu/dsh-disk-cleaner/releases/download/v1.6.7/dsh-disk-cleaner-1.6.7.tgz