Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When uploading to external mount without write permissions, file can be deleted from local device under upload. #3375

Closed
dali99 opened this issue Dec 15, 2018 · 8 comments

Comments

@dali99
Copy link

dali99 commented Dec 15, 2018

Actual behaviour

If you try to upload to a sftp external storage that you can't write to, the file shows up for a split second and is then removed.

If delete from device after upload is on, the file will also be removed from the phone.

Expected behaviour

Upload should fail and not delete the file from the phone.

Steps to reproduce

  1. Add unwritable sftp external storage
  2. Upload from phone app with "delete file from local device" turned on
  3. Cry

This might be a nextcloud server thing rather than mobile, since the server probably should fail the upload. But never the less I was surprised that the phone doesn't verify the upload was correct before deleting data.

@dali99 dali99 added the bug label Dec 15, 2018
@nextcloud-android-bot

This comment has been minimized.

@AndyScherzinger
Copy link
Member

Pinging @nextcloud/server-triage for feedback 👋

@MorrisJobke
Copy link
Member

@dali99 Looks weird. Is it the same behavior like with read-only shared folders? This would then allow us to know if this is a permission or external storage issue.

@dali99
Copy link
Author

dali99 commented Jan 4, 2019

I'm not sure how I would test read-only shared folders, since the app disallows me to upload to them / fails with "you are not permitted to upload to this folder" (without deleting the source file 🎉)

Changing the permissions on the external storage did allow me to upload successfully for the record

@MorrisJobke
Copy link
Member

Okay - then it seems to be a permission propagation issue. cc @rullzer @icewind1991

@tobiasKaminsky
Copy link
Member

Like on other folder dav should give the client a proper info if a folder is writable. Then we can simply hide the upload button on it.

@rullzer
Copy link
Member

rullzer commented Jan 10, 2019

Of course we do not always know. If the user doesn't have write permission on the external storage there is no reliable way for us to check that.

Of course the upload should also just fail then.

I'll see if I can reproduce this.

@stale
Copy link

stale bot commented May 9, 2019

This request did not receive an update in the last 4 weeks. Please take a look again and update the issue with new details, otherwise the issue will be automatically closed in 2 weeks. Thank you!

@stale stale bot added the stale label May 9, 2019
@stale stale bot closed this as completed May 23, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants