Using local language in name of file

Description

Hi!
I have local installation of rocket.chat. When I load file which name (Мессенджер ТЗ.docx) written by russian upload work without problems. But when I download the file it dosen’t work. I see that te link https://<example.com>/file-upload/5B4YPLQbirHJHWdtH/Мессенджер%20ТЗ.docx has russian symbols but they should be changed.

Does anyone see a similar problem? Maybe with a different language …

Server Setup Information

  • Version of Rocket.Chat Server: 3.6.1 or 3.8.1
  • Operating System: Mac OS
  • Deployment Method: docker 2.4
  • Number of Running Instances: 1
  • DB Replicaset Oplog:
  • NodeJS Version: 14.8
  • MongoDB Version: 4.0
  • Proxy: apache
  • Firewalls involved:

Any additional Information

It’s work equal if i use FileSystem of GridFS.

Thanks in Advance.

After upgrade Version of Rocket.Chat Server to: 3.9.2
Anybody has solution for the problem?
When i download file I get the message about error in log:

Exception in callback of async function: URIError: URI malformed
at decodeURI (<anonymous>)
at Router.match (/app/bundle/programs/server/npm/node_modules/meteor/simple_json-routes/node_modules/connect-route/lib/connect-route.js:61:12)
at /app/bundle/programs/server/npm/node_modules/meteor/simple_json-routes/node_modules/connect-route/lib/connect-route.js:102:24
at runWithEnvironment (packages/meteor.js:1286:24)
at packages/meteor.js:1299:14
at /app/bundle/programs/server/npm/node_modules/meteor/promise/node_modules/meteor-promise/fiber_pool.js:43:40

If somebody interesting in look at variant to fix the problem:

This branch is out-of-date with the base branch

Can you please bump the PR with the current branch and I will try and attract some attention.

@john.crisp
I did new PR (Fixing problem with file name in utf-8 format by pkonetskiy · Pull Request #22442 · RocketChat/Rocket.Chat · GitHub). Is it correct branch?

I have asked for someone to take a look.

I’ll keep you posted.

Ahhh - you’ll need to do this against 3.16.x

Can you do that please?

@john.crisp
Sorry, I don’t see the branch.

Use branch ‘develop’ I think.

@john.crisp
I started with this - develop. Look at my the first message about PR.

Ahhhh you have two PRs open. That is confusing…

So I think 22442 is wrong

pkonetskiy](pkonetskiy (Petr) · GitHub) wants to merge 210 commits into RocketChat:release-3.14.6-beta from pkonetskiy:develop

And 22388 is right:

pkonetskiy wants to merge 1 commit into RocketChat:develop from pkonetskiy:develop

I started from this PR:

You asked me to do new PR and I did this:

Now I have closed PR 22442.

Yes - sorry I meant ‘update’ the PR!!

Thanks.

OK. Without problem. Done.

I have raised it with the Product Team. See if we can get it fixed.

Thank you. I am sure you can. )))

I would like to raise the topic

I’m currently testing versions 5.4.10 and 6.3.7 and both of them do not work correctly behind Apache reverse proxy with names in local encoding.

version 6.4.8
programs/server/npm/node_modules/meteor/rocketchat_restivus/node_modules/connect-route/lib/connect-route.js

line 61

parts = decodeURI(url).split('?', 1)[0].replace(separator, '').split('/'),

remove decodeURI

parts = url.split('?', 1)[0].replace(separator, '').split('/'),