Android: "Cannot upload null" with end-to-end encryption enabled

Created on 25 Nov 2018  Â·  41Comments  Â·  Source: nextcloud/android

Actual behaviour

This notification is shown:
notification: "Hochladen fehlgeschlagen – Cannot upload 'null'"

And this is how it is shown in the recent uploads:
uploadlist

Expected behaviour

Upload file.

Steps to reproduce

  1. Setup e2e encryption on Android in the exact same app.
  2. (Tried to) upload something in the dir in Nextcloud Desktop 2.5.0 on Fedora 29.
  3. Access dir in Android app. It shows no files… :confused:
  4. Now try to upload a small <500kB file.

Environment data

Android version: LineageOS 14.1

Stock or customized system: custom

Nextcloud app version: 3.3.2 (F-Droid)

Nextcloud server version: 14

Logs

Web server error log

I checked when the error occurred, no error logged here.

Nextcloud log (data/nextcloud.log)

I checked when the error occurred, nothing special in there.

E2E approved bug

Most helpful comment

This application did not receive an update in the last 4 weeks. Please take a look again and update the application with new code, otherwise the issue will be open forever.

All 41 comments

GitMate.io thinks possibly related issues are https://github.com/nextcloud/android/issues/1599 (End to end encryption - overview), https://github.com/nextcloud/android/issues/1863 (Beta end-to-end encryption missing), https://github.com/nextcloud/android/issues/2388 (Andoird end-to-end encryption having issues after upgrade), https://github.com/nextcloud/android/issues/2309 (E2E encryption : not able to re-enable a folder as E2E encrypted), and https://github.com/nextcloud/android/issues/2691 (Instant Upload not syncing after re-enabling it).

On the desktop it also does not work, BTW: https://github.com/nextcloud/desktop/issues/890

Any news here what I can do to troubleshoot/debug this, or is this "expected"??

It seems that somehow the setup of encryption keys failed and thus "null" is used.
Can you try it with a complete new test user?

Did so and it worked with a completely new user for some reason…

I directly uploaded a file after setting it up on Android. maybe that was the big difference… :thinking:
And I've only connected the broken desktop e2e setup (https://github.com/nextcloud/desktop/issues/560) after I've set it up on Android. :thinking:

Okay, on the desktop client syncing a 30kB file seems to have worked, but a 80kB file failed:

image

here is some client-side log:


[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(NoError)
[OCC::WebFlowCredentials::stillValid    "Unknown error"
[OCC::GetFolderEncryptStatusJob::finished   GetFolderEncryptStatus of QUrl("https://server.url:1111/subDir/remote.php/webdav") finished with status QNetworkReply::NetworkError(NoError) ""
[OCC::SocketApi::slotReadSocket     Received SocketAPI message <-- "RETRIEVE_FILE_STATUS:/local/path/to/e2e/dir.43b76200f31043bd880519b2b523a1a6.~53bf0994" from QLocalSocket(0x556ccaeb9e60)
[OCC::SocketListener::sendMessage   Sending SocketAPI message --> "STATUS:IGNORE:/local/path/to/e2e/dir.43b76200f31043bd880519b2b523a1a6.~53bf0994" to QLocalSocket(0x556ccaeb9e60)
[OCC::SocketApi::slotReadSocket     Received SocketAPI message <-- "GET_MENU_ITEMS:" from QLocalSocket(0x556ccaeb9e60)
[OCC::SocketListener::sendMessage   Sending SocketAPI message --> "GET_MENU_ITEMS:BEGIN" to QLocalSocket(0x556ccaeb9e60)
[OCC::SocketListener::sendMessage   Sending SocketAPI message --> "GET_MENU_ITEMS:END" to QLocalSocket(0x556ccaeb9e60)
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::AbstractNetworkJob::slotFinished  QNetworkReply::NetworkError(UnknownContentError) "Error transferring https://server.url:1111/subDir/remote.php/dav/files/userName/dir/43b76200f31043bd880519b2b523a1a6 - server replied: " QVariant(int, 423)
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(UnknownContentError)
[OCC::WebFlowCredentials::stillValid    "Error transferring https://server.url:1111/subDir/remote.php/dav/files/userName/dir/43b76200f31043bd880519b2b523a1a6 - server replied: "
[OCC::SyncJournalDb::setErrorBlacklistEntry     Setting blacklist entry for  "dir/43b76200f31043bd880519b2b523a1a6" 6 "Error transferring https://server.url:1111/subDir/remote.php/dav/files/userName/dir/43b76200f31043bd880519b2b523a1a6 - server replied: " 1544277907 0 1541430936 "71c60dcb32c26d54d6d997458b226c56" "" 0
[OCC::blacklistUpdate   escalating soft error on  "dir/43b76200f31043bd880519b2b523a1a6"  to normal error,  423
[OCC::PropagateItemJob::done    Could not complete propagation of "dir/43b76200f31043bd880519b2b523a1a6" by OCC::PropagateDownloadFile(0x556ccbb1a0d0) with status 2 and error: "Error transferring https://server.url:1111/subDir/remote.php/dav/files/userName/dir/43b76200f31043bd880519b2b523a1a6 - server replied: "
[OCC::SocketListener::sendMessage   Sending SocketAPI message --> "STATUS:ERROR:/local/path/to/e2e/dir43b76200f31043bd880519b2b523a1a6" to QLocalSocket(0x556ccaeb9e60)
[OCC::ActivityWidget::slotItemCompleted     Item  "dir/43b76200f31043bd880519b2b523a1a6"  retrieved resulted in  "Error transferring https://server.url:1111/subDir/remote.php/dav/files/userName/dir/43b76200f31043bd880519b2b523a1a6 - server replied: "
[OCC::ActivityWidget::slotItemCompleted     Item  "dir/43b76200f31043bd880519b2b523a1a6"  retrieved resulted in error  "Error transferring https://server.url:1111/subDir/remote.php/dav/files/userName/dir/43b76200f31043bd880519b2b523a1a6 - server replied: "
[OCC::ActivityListModel::addErrorToActivityList     Error successfully added to the notification list:  "Error transferring https://server.url:1111/subDir/remote.php/dav/files/userName/dir/43b76200f31043bd880519b2b523a1a6 - server replied: "
[OCC::SocketApi::slotReadSocket     Received SocketAPI message <-- "GET_MENU_ITEMS:" from QLocalSocket(0x556ccaeb9e60)
[OCC::SocketListener::sendMessage   Sending SocketAPI message --> "GET_MENU_ITEMS:BEGIN" to QLocalSocket(0x556ccaeb9e60)
[OCC::SocketListener::sendMessage   Sending SocketAPI message --> "GET_MENU_ITEMS:END" to QLocalSocket(0x556ccaeb9e60)
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(NoError)
[OCC::WebFlowCredentials::stillValid    "Unknown error"
[OCC::LsColJob::finished    LSCOL of QUrl("https://server.url:1111/subDir/remote.php/dav/files/rugk/") FINISHED WITH STATUS "OK"
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(NoError)
[OCC::WebFlowCredentials::stillValid    "Unknown error"
[OCC::PropfindJob::finished     PROPFIND of QUrl("https://server.url:1111/subDir/remote.php/dav/files/userName/") FINISHED WITH STATUS "OK"
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(NoError)
[OCC::WebFlowCredentials::stillValid    "Unknown error"
[OCC::GetFolderEncryptStatusJob::finished   GetFolderEncryptStatus of QUrl("https://server.url:1111/subDir/remote.php/webdav") finished with status QNetworkReply::NetworkError(NoError) ""
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(NoError)
[OCC::WebFlowCredentials::stillValid    "Unknown error"
[OCC::LsColJob::finished    LSCOL of QUrl("https://server.url:1111/subDir/remote.php/dav/files/userName/") FINISHED WITH STATUS "OK"
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::AbstractNetworkJob::slotFinished  QNetworkReply::NetworkError(ContentAccessDenied) "Error transferring https://server.url:1111/subDir/ocs/v2.php/apps/end_to_end_encryption/api/v1/lock/124927?format=json - server replied: " QVariant(int, 403)
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(ContentAccessDenied)
[OCC::WebFlowCredentials::stillValid    "Error transferring https://server.url:1111/subDir/ocs/v2.php/apps/end_to_end_encryption/api/v1/lock/124927?format=json - server replied: "
[OCC::LockEncryptFolderApiJob::finished     error locking file "ocs/v2.php/apps/end_to_end_encryption/api/v1/lock/124927" "Error transferring https://server.url:1111/subDir/ocs/v2.php/apps/end_to_end_encryption/api/v1/lock/124927?format=json - server replied: " 403
[OCC::AccessManager::createRequest  6 "PROPFIND" "https://server.url:1111/subDir/remote.php/dav/files/rugk/" has X-Request-ID "573817b5-c89f-4432-98ab-6ce37cfeefbb"
[OCC::AbstractNetworkJob::start     OCC::PropfindJob created for "https://server.url/nextcloud" + "/" "OCC::ConnectionValidator"
[OCC::AccessManager::createRequest  6 "PROPFIND" "https://server.url:1111/subDir/remote.php/dav/files/userName/" has X-Request-ID "641758e5-7d00-4890-863a-b0329ab901d9"
[OCC::AbstractNetworkJob::start     OCC::PropfindJob created for "https://server.url/nextcloud" + "/" "OCC::ConnectionValidator"
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(NoError)
[OCC::WebFlowCredentials::stillValid    "Unknown error"
[OCC::PropfindJob::finished     PROPFIND of QUrl("https://server.url:1111/subDir/remote.php/dav/files/userName/") FINISHED WITH STATUS "OK"
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(NoError)
[OCC::WebFlowCredentials::stillValid    "Unknown error"
[OCC::PropfindJob::finished     PROPFIND of QUrl("https://server.url:1111/subDir/remote.php/dav/files/rugk/") FINISHED WITH STATUS "OK"
[OCC::AccessManager::createRequest  6 "PROPFIND" "https://server.url:1111/subDir/remote.php/dav/files/userName/" has X-Request-ID "7adaf089-42cb-430d-9d49-e55cb1b69b4f"
[OCC::AbstractNetworkJob::start     OCC::PropfindJob created for "https://server.url/nextcloud" + "/" "OCC::QuotaInfo"
[OCC::WebFlowCredentials::slotFinished  request finished
[OCC::WebFlowCredentials::stillValid    Still valid?
[OCC::WebFlowCredentials::stillValid    QNetworkReply::NetworkError(NoError)
[OCC::WebFlowCredentials::stillValid    "Unknown error"
[OCC::PropfindJob::finished     PROPFIND of QUrl("https://server.url:1111/subDir/remote.php/dav/files/userName/") FINISHED WITH STATUS "OK"

Also got this on the server, but this may be related to the fact that I added a new client and just had to enter the e2e password(?):

image

Also this was once shown on a client (note this is really the new user!):
mess

translation: …cannot be downloaded, because there are no encryption information.

Exact the same problems here. Today I created a complete new user (with a username never used before) to be sure that my old user isn't the problem.

To reproduce the problem, I do following steps:

  1. Create a new folder in the Android App and set is as encrypted
  2. Upload a file, see it works
  3. Delete the file, see it works
  4. Upload the file again, still works
  5. Sync with Desktop Client, see and check the file, yay, seems to work, but:
  6. Try to delete the file in Andoid client: Server not reachable.
  7. Try to delete the file on Desktop: Works sometimes, sometimes provokes only sync errors
  8. Try to upload another file in that folder in Android App: Fails with unknown error or folder error (Ordnerfehler)
  9. Try to upload/sync any new file from Desktop App leads to several different errors, but never seen a working file reaching the Android App.
  10. Removing encryption in Android App works, then deleting the folder in the Webapp, too (but not from Android App).
  11. Start at 1. and repeat several times.

So when the Android App works alone, it works. When I sync with the Desktop App only once, the new folder is messed up and nothing works anymore in that folder.

Edit: Andoid App is 3.5.0 and Windows Desktop App is 2.5.1. Both also never worked in previous versions. Tried from the first beta onwards: Since the Desktop client has E2EE, the above happens.

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!

I'm pretty sure this is a problem of the desktop software, since the Android client works fine alone. There are several open issues over there, so I think this one here can be closed.

Yesterday I tried everything again with a completely new (hosted) Nextcloud-15-instance with new users and the current client versions and could reproduce the steps above: When the desktop client comes in, the encrypted folder is messed up and stops working at all.

@spackmat any known workaround for the desktop client e2e mess?

@marbetschar I haven't seen one and simply consider e2ee in nextcloud as not ready. And for me, it doesn't look like this will be fixed soon, as it in broken from day 1 on.

@spackmat thanks for clarification. It‘s a pity, E2E seemed like a huge step forward.

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!

Thanks bot for reminding us, this annoying issue is still not fixed. :cry:

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!

I love that bot and its message: "We ignored the problem for another 4 weeks, so we suggest considering it as solved."

No, it is far away from being solved. It still exists and it is still unclear, if it is only related to the windows client or if the android client is part of the problem, too. Before closing it, at least, this should be clarified.

if the android client is part of the problem, too.

It's better there, but AFAIK it also has it's problems. After all – in case you did not notice – you've commented on the issue in the Android app repo. :wink:

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!

Still not working.

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!

Still relevant

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!

Will there be any progress in e2e in the foreseeable future?

Tested it with NC 15.0.11 and the NC app (3.8.1) under Android 9 (LineageOS 16) - still not possible.

I confirm also that this is still existent with the new desktop client v2.6.1-rc1. See, for example, this issue over there: https://github.com/nextcloud/desktop/issues/890

That's the thing - Either it doesn't encrypt the files (which in my case is true) even if the folder is set to e2e or it blocks uploading files like above.

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!

.

I should automate this.

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!

This application did not receive an update in the last 4 weeks. Please take a look again and update the application with new code, otherwise the issue will be open forever.

At least, if this is really a problem related exclusively to the desktop app, the android client could detect that and raise a more helpful error message. Cannot upload null doesn't point to a E2EE-related problem in any way.

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!

I do love playing ping pong with you, bot.

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!

pong.

I guess we should program a bot for replying to that stale bot. This is only fair, IMHO. :smiley:

There might be a chance that desktop messed something up.
Can you try it with a new empty folder on Android?

@tobiasKaminsky I described my reproduction-steps above in https://github.com/nextcloud/android/issues/3291#issuecomment-466401422

In short: A new folder in Android works fine, until the Desktop-Sync tries to change somethin in that folder, then it is crashed. I could play that game several times, seems as if the Desktop-client sets a lock or something, fails and doesn't remove the lock, so all access is blocked from that time on.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tobiasKaminsky picture tobiasKaminsky  Â·  3Comments

Bugsbane picture Bugsbane  Â·  3Comments

rainer042 picture rainer042  Â·  3Comments

AndyScherzinger picture AndyScherzinger  Â·  3Comments

tobiasKaminsky picture tobiasKaminsky  Â·  3Comments