3 ms·
Why does the sshx.io/get URL detect a browser using the Accept-Encoding header and return 404? Generally I don’t have much to say about curl | bash, but going
by supriyo-biswas 3y ago
Why does the sshx.io/get URL detect a browser using the Accept-Encoding header and return 404?
Generally I don’t have much to say about curl | bash, but going out of your way to hide the script is a bit suspicious.
- d-z-m 3y agoI don't think it's anything nefarious. Can't pipe a brotli'd response into bash. My browser wasn't accepting the 'identity' encoding. If you alter your browser to accept 'identity', it will return the script.
- supriyo-biswas 3y agocurl --compressed is very much a thing, and some people may have that set as the default.
- d-z-m 3y agoha, learn something new everyday. Hadn't run across the --compressed option before.
- deleted 3y ago[deleted]
- ekzhang 3y agoI'm not sure honestly, if you could raise an issue I'd appreciate it. I didn't go out of my way to do this; it seems to be some default of SvelteKit or the server code that I don't understand?
- 698969 3y agoSeems like something to do with your deployment server config. You may be redirecting all pages to your fallback spa.html. I built the site and served it with `python3 -m http.server --dir build` and it served the script to the browser without an issue.