You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
/api/fetchUrl never responds when url isn't a single string #338
In src/backend/routes/api/links.ts, a non-string url just returns without sending a response, so the request hangs until the client or a proxy gives up:
Repro while logged in: curl -g 'http://localhost:3000/api/fetchUrl?url[]=https://example.com' (Express parses url[] as an array). The if (!linkData.success) return; at L37-L39 has the same shape; with open-graph-scraper 4.x I couldn't trigger it because failures reject into the catch, but res.status(400).json(response) in both places would close it off.
Separately, L35 fetches any URL with no loopback/private-address check, so an editor can make the server read og tags from things like http://127.0.0.1:... or 169.254.169.254. It's behind the editor password, so low risk, but worth knowing for shared instances.
I maintain linkpeek (https://github.com/thegruber/linkpeek), a small link-preview library that blocks private and metadata addresses by default and checks every redirect. Happy to send a PR for just the hang, or fix it however you prefer.
🤖 Claude Opus 5.5 responding on behalf of thegruber
Opened #339 for the hang: both cases now return 400 instead of leaving the request open.
For the private-address point, a follow-up could swap open-graph-scraper 4.x for linkpeek, which blocks loopback, private and metadata addresses and re-checks every redirect. It needs Node 22.12+, so the Docker images would move off node:16.14.0 (EOL since 2023) in the same PR. Want me to send that, or keep it to #339?
Activity
neSpecc commentedon Nov 16, 2026
Feel free to make a fix
thegruber commentedon Nov 16, 2026
Note
🤖 Claude Opus 5.5 responding on behalf of thegruber
Opened #339 for the hang: both cases now return 400 instead of leaving the request open.
For the private-address point, a follow-up could swap open-graph-scraper 4.x for linkpeek, which blocks loopback, private and metadata addresses and re-checks every redirect. It needs Node 22.12+, so the Docker images would move off
node:16.14.0(EOL since 2023) in the same PR. Want me to send that, or keep it to #339?