App crash while opening E2EE subfolder

オープン
#17,694 コメント 8 件 リアクション 1 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
72/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
android, kotlin
領域
mobile, security

調査の方向性

Start with com.nextcloud.utils.e2ee.E2EEKeyInspector.kt, especially decryptsMetadataV2 at line 117 and canDecryptFolderMetadata. Reproduce the crash by opening a subfolder inside an E2EE folder on the reported Android setup, then trace the null metadata path. Done means the subfolder opens after entering the mnemonic instead of crashing.

索引モデルが issue の本文から書いたものです。

説明

0. Needs triage bug feature: encryption (client-side)
⚠️ Before posting ⚠️
  • This is a bug, not a question or an enhancement.
  • I've searched for similar issues and didn't find a duplicate.
  • I've written a clear and descriptive title for this issue, not just "Bug" or "Crash".
  • I agree to follow Nextcloud's Code of Conduct.
Steps to reproduce
  1. Created Storage Share Hetzner instance
  2. Enable E2E app in browser
  3. Login and create an E2E folder in Linux desktop client: /Private
  4. Add files and folders inside ~/Nextcloud/Private/...
  5. Install and open Nextcloud Android app
  6. I can see Private folder with a key symbol, it says 0 B for some reason
  7. I open Private folder (I enter mnemonic when prompted)
  8. I see all folders and files inside Private (all folders say 0 B, except the files)
  9. I can open and see the content of files (Private -> image.png)
  10. When I press on any folder, the app crashes:
Cause of error
Exception in thread "main" java.lang.NullPointerException: Attempt to invoke interface method 'java.util.Iterator java.lang.Iterable.iterator()' on a null object reference
    at com.nextcloud.utils.e2ee.E2EEKeyInspector.decryptsMetadataV2(E2EEKeyInspector.kt:117)
    at com.nextcloud.utils.e2ee.E2EEKeyInspector.access$decryptsMetadataV2(E2EEKeyInspector.kt:33)
    at com.nextcloud.utils.e2ee.E2EEKeyInspector$canDecryptFolderMetadata$2.invokeSuspend(E2EEKeyInspector.kt:105)
    at com.nextcloud.utils.e2ee.E2EEKeyInspector$canDecryptFolderMetadata$2.invoke(E2EEKeyInspector.kt:8)
    at com.nextcloud.utils.e2ee.E2EEKeyInspector$canDecryptFolderMetadata$2.invoke(E2EEKeyInspector.kt:4)
    at kotlinx.coroutines.intrinsics.UndispatchedKt.startUndispatched(Undispatched.kt:66)
    at kotlinx.coroutines.intrinsics.UndispatchedKt.startUndispatchedOrReturn(Undispatched.kt:43)
    at kotlinx.coroutines.BuildersKt__Builders_commonKt.withContext(Builders.common.kt:497)
    at kotlinx.coroutines.BuildersKt.withContext(dex-id-9e0b1687ed506aa331b8e1c93a1337b6b72f4b70:1)
    at com.nextcloud.utils.e2ee.E2EEKeyInspector.canDecryptFolderMetadata(E2EEKeyInspector.kt:86)
    at com.nextcloud.utils.e2ee.E2EEActionResolver$checkFolderMetadataKey$2.invokeSuspend(E2EEActionResolver.kt:44)
    at kotlin.coroutines.jvm.internal.BaseContinuationImpl.resumeWith(ContinuationImpl.kt:34)
    at kotlinx.coroutines.DispatchedTask.run(DispatchedTask.kt:100)
    at kotlinx.coroutines.internal.LimitedDispatcher$Worker.run(LimitedDispatcher.kt:124)
    at kotlinx.coroutines.scheduling.TaskImpl.run(Tasks.kt:89)
    at kotlinx.coroutines.scheduling.CoroutineScheduler.runSafely(CoroutineScheduler.kt:586)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.executeTask(CoroutineScheduler.kt:798)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.runWorker(CoroutineScheduler.kt:717)
    at kotlinx.coroutines.scheduling.CoroutineScheduler$Worker.run(CoroutineScheduler.kt:704)

App information
  • ID: com.nextcloud.client
  • Version: 350000090
  • Build flavor: gplay
Device information
  • Brand: Fairphone
  • Device: FP6
  • Model: Fairphone 6
  • Id: FP6.QREL.16.100.0
  • Product: FP6
Firmware
  • SDK: 36
  • Release: 16
  • Incremental: WS1M
Expected behaviour

To open the subfolder (of E2E enabled folder) as it does in browser (when I enter mnemonic)

Actual behaviour

It crashes instantly on trying to open a subfolder of E2E folder

Android version

16

Device brand and model

Fairphone 6

Stock or custom OS?

Stock

Nextcloud android app version

350000090

Nextcloud server version

Nextcloud Hub 26 Winter

Using a reverse proxy?

No

Android logs

No response

Server error logs
Not sure if I have access on Hetzner Storage Share
Additional information

No response

主要言語
Kotlin
スター
5.7k
フォーク
2.1k
平均マージ
1日 22時間
マージ済み PR(30日)
135

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

nextcloud/android のほかの issue

nextcloud/android の issue をすべて見る

似ている issue

Kotlin の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。