nextcloud / nextcloud/ios

Error during verification: Message digest doesn't match / Could not find the private key of the user: redacted-user

Open
#3,830 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Swift
Stars
2.5k
Forks
1k
Avg merge
2d 18h
Merged PRs (30d)
13

Description

Steps to reproduce
  1. Activate End-to-End Encryption in the NextCoud Server
  2. Activate End-to-End Encryption in the iOS App
  3. Create an encrpyted Folder in the iOS App
  4. Activate End-to-End Encryption in the Security category of your NextCloud Account in the Web Browser
Expected behaviour

Prompt to enter the 12-word mnemonic to access the encrypted folder.

Actual behaviour

A Error Message saying: Unerwarteter Fehler: Error during verification: Message digest doesn't match

Server configuration

Operating system: CentOS

Web server:

Database: mysql

PHP version: 8.2.20

Nextcloud version: 31.0.5.1

Updated from an older Nextcloud/ownCloud or fresh install: Yes

Signing status:

Signing status
No errors have been found.

List of activated apps:

App list
$ php occ app:list
Enabled:
  - activity: 4.0.0
  - app_api: 5.0.2
  - appointments: 2.4.4
  - bruteforcesettings: 4.0.0
  - calendar: 5.2.4
  - circles: 31.0.0
  - cloud_federation_api: 1.14.0
  - comments: 1.21.0
  - contacts: 7.1.1
  - contactsinteraction: 1.12.0
  - dashboard: 7.11.0
  - dav: 1.33.0
  - end_to_end_encryption: 1.17.0
  - federatedfilesharing: 1.21.0
  - federation: 1.21.0
  - files: 2.3.1
  - files_3dmodelviewer: 0.0.15
  - files_downloadlimit: 4.0.0
  - files_pdfviewer: 4.0.0
  - files_reminders: 1.4.0
  - files_sharing: 1.23.1
  - files_trashbin: 1.21.0
  - files_versions: 1.24.0
  - firstrunwizard: 4.0.0
  - forms: 5.1.0
  - groupfolders: 19.0.4
  - logreader: 4.0.0
  - lookup_server_connector: 1.19.0
  - nextcloud_announcements: 3.0.0
  - notes: 4.12.0
  - notifications: 4.0.0
  - notify_push: 1.1.0
  - oauth2: 1.19.1
  - password_policy: 3.0.0
  - photos: 4.0.0-dev.1
  - privacy: 3.0.0
  - profile: 1.0.0
  - provisioning_api: 1.21.0
  - recommendations: 4.0.0
  - related_resources: 2.0.0
  - serverinfo: 3.0.0
  - settings: 1.14.0
  - sharebymail: 1.21.0
  - socialsharing_email: 3.3.0
  - spreed: 21.0.4
  - support: 3.0.0
  - survey_client: 3.0.0
  - systemtags: 1.21.1
  - tasks: 0.16.1
  - text: 5.0.0
  - theming: 2.6.1
  - theming_customcss: 1.18.0
  - twofactor_backupcodes: 1.20.0
  - updatenotification: 1.21.0
  - user_status: 1.11.0
  - viewer: 4.0.0
  - weather_status: 1.11.0
  - webhook_listeners: 1.2.0
  - workflowengine: 2.13.0
Disabled:
  - admin_audit: 1.21.0
  - encryption: 2.19.0 (installed 2.19.0)
  - extract: 1.3.6 (installed 1.3.6)
  - files_external: 1.23.0
  - suspicious_login: 9.0.1
  - twofactor_nextcloud_notification: 5.0.0
  - twofactor_totp: 13.0.0-dev.0
  - user_ldap: 1.22.0

Nextcloud configuration:

Config report
php occ config:list system
{
    "system": {
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "nextcloud.redacted.de"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "dbtype": "mysql",
        "version": "31.0.5.1",
        "overwrite.cli.url": "https:\/\/nextcloud.redacted.de",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbport": "",
        "dbtableprefix": "oc_",
        "mysql.utf8mb4": true,
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "installed": true,
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpmode": "sendmail",
        "mail_sendmailmode": "pipe",
        "htaccess.RewriteBase": "\/",
        "memcache.local": "\\OC\\Memcache\\APCu",
        "redis": {
            "host": "***REMOVED SENSITIVE VALUE***",
            "port": "0",
            "timeout": "1.5"
        },
        "filelocking.enabled": "true",
        "memcache.locking": "\\OC\\Memcache\\Redis",
        "memcache.distributed": "\\OC\\Memcache\\Redis",
        "default_phone_region": "DE",
        "maintenance_window_start": 1,
        "trusted_proxies": "***REMOVED SENSITIVE VALUE***",
        "app_install_overwrite": [
            "extract"
        ],
        "defaultapp": "files",
        "maintenance": false,
        "theme": "",
        "loglevel": 2
    }
}

Are you using external storage, if yes which one: no

Are you using encryption: no

Are you using an external user-backend, if yes which one: no

Client configuration

Browser: Google Chrome 136.0.7103.114

Operating system: macOS 15.4.1 (24E263)

Logs
Nextcloud log (data/nextcloud.log)
Nextcloud log
{"reqId":"aCyhOSLCBLBi0js6QxD8DgAAANE","level":2,"time":"2025-05-20T15:35:21+00:00","remoteAddr":"2a02:3100:8415:c200:1176:f08d:5277:bcf2","user":"redacted-user","app":"end_to_end_encryption","method":"GET","url":"/ocs/v2.php/apps/end_to_end_encryption/api/v1/private-key","message":"Could not find the private key of the user: redacted-user","userAgent":"Mozilla/5.0 (iOS) Nextcloud-iOS/6.6.2","version":"31.0.5.1","data":{"app":"end_to_end_encryption"}}
{"reqId":"aCyl0_qh0Q1d9n_Z1rHCxgAAAI0","level":3,"time":"2025-05-20T15:54:59+00:00","remoteAddr":"2a02:3100:8415:c200:2df0:bcad:e59:be0e","user":"redacted-user","app":"end_to_end_encryption","method":"DELETE","url":"/ocs/v2.php/apps/end_to_end_encryption/api/v1/encrypted-files","message":"No file for owner with ID 1103","userAgent":"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/136.0.0.0 Safari/537.36","version":"31.0.5.1","exception":{"Exception":"OCP\\Files\\NotFoundException","Message":"No file for owner with ID 1103","Code":0,"Trace":[{"file":"/var/www/virtual/redacted-user/html/nextcloud/apps/end_to_end_encryption/lib/MetaDataStorage.php","line":147,"function":"verifyOwner","class":"OCA\\EndToEndEncryption\\MetaDataStorage","type":"->","args":["redacted-user",1103]},{"file":"/var/www/virtual/redacted-user/html/nextcloud/apps/end_to_end_encryption/lib/Controller/EncryptionController.php","line":97,"function":"deleteMetaData","class":"OCA\\EndToEndEncryption\\MetaDataStorage","type":"->","args":["redacted-user",1103]},{"file":"/var/www/virtual/redacted-user/html/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":200,"function":"removeEncryptedFolders","class":"OCA\\EndToEndEncryption\\Controller\\EncryptionController","type":"->","args":[]},{"file":"/var/www/virtual/redacted-user/html/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":114,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[{"__class__":"OCA\\EndToEndEncryption\\Controller\\EncryptionController"},"removeEncryptedFolders"]},{"file":"/var/www/virtual/redacted-user/html/nextcloud/lib/private/AppFramework/App.php","line":161,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->","args":[{"__class__":"OCA\\EndToEndEncryption\\Controller\\EncryptionController"},"removeEncryptedFolders"]},{"file":"/var/www/virtual/redacted-user/html/nextcloud/lib/private/Route/Router.php","line":307,"function":"main","class":"OC\\AppFramework\\App","type":"::","args":["OCA\\EndToEndEncryption\\Controller\\EncryptionController","removeEncryptedFolders",{"__class__":"OC\\AppFramework\\DependencyInjection\\DIContainer"},{"apiVersion":"1","_route":"ocs.end_to_end_encryption.encryption.removeencryptedfolders"}]},{"file":"/var/www/virtual/redacted-user/html/nextcloud/ocs/v1.php","line":49,"function":"match","class":"OC\\Route\\Router","type":"->","args":["/ocsapp/apps/end_to_end_encryption/api/v1/encrypted-files"]},{"file":"/var/www/virtual/redacted-user/html/nextcloud/ocs/v2.php","line":7,"args":["/var/www/virtual/redacted-user/html/nextcloud/ocs/v1.php"],"function":"require_once"}],"File":"/var/www/virtual/redacted-user/html/nextcloud/apps/end_to_end_encryption/lib/MetaDataStorage.php","Line":287,"message":"No file for owner with ID 1103","exception":{},"CustomMessage":"No file for owner with ID 1103"}}
{"reqId":"aCymB_qh0Q1d9n_Z1rHDNwAAAIo","level":2,"time":"2025-05-20T15:55:51+00:00","remoteAddr":"2a02:3100:8415:c200:1176:f08d:5277:bcf2","user":"redacted-user","app":"end_to_end_encryption","method":"GET","url":"/ocs/v2.php/apps/end_to_end_encryption/api/v1/private-key","message":"Could not find the private key of the user: redacted-user","userAgent":"Mozilla/5.0 (iOS) Nextcloud-iOS/6.6.2","version":"31.0.5.1","data":{"app":"end_to_end_encryption"}}

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

Start by tracing the iOS End-to-End Encryption flow around the /ocs/v2.php/apps/end_to_end_encryption/api/v1/private-key request and compare it with the reported mnemonic prompt. Review the server log entries showing the missing private key and digest mismatch; done means reproducing the flow without either error and confirming access to the encrypted folder.

Written by the indexing model from the issue text.

Assessment

Tech stack
ios, swift
Domain
mobile-dev, security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.