RocketChat / RocketChat/Rocket.Chat

File upload with Webdav

Open
#11,666 10 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type: bug
Dominant language
TypeScript
Stars
46.1k
Forks
13.9k
Avg merge
3d 3h
Merged PRs (30d)
130

Description

Hello,

we're using upload over WebDAV to Nextcloud with encryption. When sending bigger files (more than 20MB) it's getting an error 500, because checking if file exists after upload is before upload has finished, see logs below:

10.120.104.1 - rocket [02/Aug/2018:10:05:05 +0200] "GET /remote.php/webdav/AzXTGobezzwM968XN HTTP/1.1" 404 5 "-" "node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"
10.120.104.1 - rocket [02/Aug/2018:10:05:06 +0200] "DELETE /remote.php/webdav/AzXTGobezzwM968XN HTTP/1.1" 404 5 "-" "node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"
10.120.104.1 - rocket [02/Aug/2018:10:05:06 +0200] "DELETE /remote.php/webdav/AzXTGobezzwM968XN HTTP/1.1" 404 5 "-" "node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"
10.120.104.1 - rocket [02/Aug/2018:10:05:06 +0200] "PUT /remote.php/webdav/AzXTGobezzwM968XN HTTP/1.1" 201 0 "-" "node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"
10.120.104.1 - rocket [02/Aug/2018:10:05:06 +0200] "DELETE /remote.php/webdav/AzXTGobezzwM968XN HTTP/1.1" 204 0 "-" "node-fetch/1.0 (+https://github.com/bitinn/node-fetch)"

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the WebDAV upload implementation and reproduce the failure with an encrypted file larger than 20MB. Review the request sequence shown in the logs, then verify that completion checks and cleanup do not run before the upload finishes and that the upload no longer returns a 500 error.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, typescript
Domain
backend, cloud, networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.