svenstaro/miniserve

Links to files with special characters within their name are not working

Switch123456789 opened this issue · 3 comments

As far as I can tell (as a noob) some special characters like
[ ] , need to be encoded like this
%5B %5D %2C to work as a URL. Doing this manually gives a working URL.

rtkpX commented

What browser are you using? If I try opening a file with special characters like [], I have no issues.

https://10.10.10.10:444/[thisisatest].txt -> For example, works just fine, I'm using Brave, by the way, anyway, Firefox usually translates the URLs properly.

I am using ungoogled chromium, can you try a filename with ,? Those are the ones broken in the browser for me. Sometimes I copy a link from the browser to use it for other applications and those don't like these URL's at all.

EDIT: I did some more testing, suddenly all file(names) work fine in the browser, but the issue remains if URL's are used outside the browser.

Talking about special characters that break things... if the folder I pick for uploads with -u has # within the name, the upload-feature won't appear in the interface. However, if -U is used, the create-directory-feature does appear & works fine with this folder.

EDIT: Since this might matter at this point:
OS: EndeavourOS x86_64
Version: AUR > miniserve-bin 0.23.0-1
File-system: NTFS