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

Authentication via Davdroid app not working #12651

Closed
dartmann opened this issue Nov 24, 2018 · 7 comments
Closed

Authentication via Davdroid app not working #12651

dartmann opened this issue Nov 24, 2018 · 7 comments

Comments

@dartmann
Copy link

dartmann commented Nov 24, 2018

Steps to reproduce

  1. Create app password for Davdroid app.
  2. Using my Samsung Galaxy S8 to add an account in its DavDroid app for my Nextcloud server. Following the manual of Davdroid itself: https://www.davdroid.com/tested-with/nextcloud/
  3. Login process fails with the response that a Carddav or Caldav service could not be found.

Expected behaviour

Should login to my Nextcloud with user and dedicated app password to sync contacts and calenders via Davdroid. Using another smartphone, the login process works flawless.

Actual behaviour

The app responds with a message that no Card-/CalDav service could be discovered.

Server configuration

Operating system: Ubuntu 18.04.1 LTS

Web server: Apache/2.4.29

Database: 10.1.34-MariaDB

PHP version: PHP 7.2.10

Nextcloud version: (14.0.4.2

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

Where did you install Nextcloud from: https://nextcloud.com/install/#instructions-server

Signing status:

Signing status
No errors have been found.

List of activated apps:

App list
Enabled:
  - accessibility: 1.0.1
  - activity: 2.7.0
  - audioplayer: 2.4.1
  - bruteforcesettings: 1.2.0
  - calendar: 1.6.4
  - cloud_federation_api: 0.0.1
  - comments: 1.4.0
  - contacts: 2.1.7
  - dav: 1.6.0
  - federatedfilesharing: 1.4.0
  - federation: 1.4.0
  - files: 1.9.0
  - files_pdfviewer: 1.3.2
  - files_sharing: 1.6.2
  - files_texteditor: 2.6.0
  - files_trashbin: 1.4.1
  - files_versions: 1.7.1
  - files_videoplayer: 1.3.0
  - firstrunwizard: 2.3.0
  - gallery: 18.1.0
  - logreader: 2.0.0
  - lookup_server_connector: 1.2.0
  - nextcloud_announcements: 1.3.0
  - notes: 2.5.0
  - notifications: 2.2.1
  - oauth2: 1.2.1
  - password_policy: 1.4.0
  - provisioning_api: 1.4.0
  - serverinfo: 1.4.0
  - sharebymail: 1.4.0
  - support: 1.0.0
  - survey_client: 1.2.0
  - systemtags: 1.4.0
  - tasks: 0.9.8
  - theming: 1.5.0
  - twofactor_backupcodes: 1.3.1
  - twofactor_totp: 1.5.0
  - updatenotification: 1.4.1
  - workflowengine: 1.4.0
Disabled:
  - admin_audit
  - encryption
  - files_external
  - files_retention
  - passman
  - spreed
  - user_external
  - user_ldap

Nextcloud configuration:

Config report
{
    "system": {
        "instanceid": "***REMOVED SENSITIVE VALUE***",
        "passwordsalt": "***REMOVED SENSITIVE VALUE***",
        "secret": "***REMOVED SENSITIVE VALUE***",
        "trusted_domains": [
            "keller2",
            "192.168.178.64",
            "keller2.sensitivevalue.myfritz.net",
            "keller2.fritz.box",
            "sensitivevalue.myfritz.net"
        ],
        "datadirectory": "***REMOVED SENSITIVE VALUE***",
        "overwrite.cli.url": "http:\/\/keller2\/nextcloud",
        "dbtype": "mysql",
        "version": "14.0.4.2",
        "dbname": "***REMOVED SENSITIVE VALUE***",
        "dbhost": "***REMOVED SENSITIVE VALUE***",
        "dbtableprefix": "oc_",
        "dbuser": "***REMOVED SENSITIVE VALUE***",
        "dbpassword": "***REMOVED SENSITIVE VALUE***",
        "logtimezone": "UTC",
        "installed": true,
        "memcache.local": "\\OC\\Memcache\\APCu",
        "theme": "",
        "loglevel": 2,
        "maintenance": false,
        "trashbin_retention_obligation": "auto",
        "updatechecker": false,
        "integrity.check.disabled": false,
        "mail_smtpmode": "smtp",
        "mail_from_address": "***REMOVED SENSITIVE VALUE***",
        "mail_domain": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpauthtype": "LOGIN",
        "mail_smtpauth": 1,
        "mail_smtphost": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpport": "587",
        "mail_smtpname": "***REMOVED SENSITIVE VALUE***",
        "mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
        "mail_smtpsecure": "tls",
        "updater.secret": "***REMOVED SENSITIVE VALUE***"
    }
}

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: not relevant

Operating system: Android 8.0.0

Logs

Web server error log

Nothing noteworthy there.

Nextcloud log (data/nextcloud.log)

Nextcloud log
{"reqId":"gHRanNCoGPFa6ac74zV4","level":2,"time":"2018-11-24T21:26:44+00:00","remoteAddr":"X.X.X.X","user":"--","app":"core","method":"PROPFIND","url":"\/nextcloud\/remote.php\/dav","message":"Login failed: 'david' (Remote IP: 'X.X.X.X')","userAgent":"DAVdroid\/2.0.5-ose (2018\/11\/07; dav4android; okhttp\/3.11.0) Android\/8.0.0","version":"14.0.4.2"}

Browser log

Not relevant.

@nextcloud-bot
Copy link
Member

GitMate.io thinks possibly related issues are #3158 (authentication prompt seems not to work), #1537 (CardDAV / DAVdroid / Contacts-App issue), #5189 (Updater app does not work), #7063 (Sync via DavDroid broken), and #1421 (Sharing via Document-App does not work when using LDAP).

@ChristophWurst
Copy link
Member

The app responds with a message that no Card-/CalDav service could be discovered.

Sounds like your server is not correctly configured. You have to make sure "well known" URLs work. See https://docs.nextcloud.com/server/14/admin_manual/issues/general_troubleshooting.html#service-discovery.

@dartmann
Copy link
Author

Ok, sorry to not let this one die: then why am I able to connect with one device (OnePlus 2) but not with an other (Samsung Galaxy S8)?

@ChristophWurst
Copy link
Member

Was the Samsung phone connected before? Are you still able to set it up?

@dartmann
Copy link
Author

dartmann commented Dec 5, 2018

@ChristophWurst yes the Samsung phone was connected before. Then one day it began to make trouble again (did this also at the beginning when setting it up and worked after some attempts). I suggest that I first check out your link about service discovery and double check that I configured everything correct and afterwards I provide feedback. Thank you for your support 👍

@dartmann
Copy link
Author

dartmann commented Dec 7, 2018

@ChristophWurst thank you for your help. After adding two missing lines to my .htaccess file it works again.
Am I wrong that this file gets overridden with the next update?

@ChristophWurst
Copy link
Member

I'm not sure. Just save a copy and run php occ maintenance:update:htaccess to verify your changes persist.

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

4 participants