CalDAV/CardDAV service discovery broken possibly because of preexisting .well-known directory?

Hello everybody,

I upgraded from owncloud 10.0 to nextcloud 12.0.4. Everything works fine. I can sync my calendar using thunderbird. However, when I try to use davdroid to discover my calendar, I get an error message. Because of this old ownloud issue and the error log, I suspect my old .well-known folder might have caused the problem. (I do understand everything.) I did not delete this folder prior to upgrading, because it contains the files for lets-encrypt acme-challenge. Is my suspicion correct? What can I do to fix my installation?

Thanks,
Andreas

Logs from davdroid, shortend and links changed :

— BEGIN DEBUG INFO —

— BEGIN DEBUG INFO —

LOGS:
2017-12-23 15:36:16 2 [ui.setup.DavResourceFinder] Finding initial carddav service configuration
2017-12-23 15:36:16 2 [ui.setup.DavResourceFinder] Checking user-given URL: Xhttps://s.myurl.net/remote.php/dav/
2017-12-23 15:36:16 2 [HttpClient] --> PROPFIND Xhttps://s.myurl.net/remote.php/dav/
2017-12-23 15:36:16 2 [HttpClient] Content-Type: application/xml; charset=utf-8
2017-12-23 15:36:16 2 [HttpClient] Content-Length: 290
2017-12-23 15:36:16 2 [HttpClient] Depth: 0
2017-12-23 15:36:16 2 [HttpClient]
2017-12-23 15:36:16 2 [HttpClient] <?xml version='1.0' encoding='UTF-8' ?><CARD:addressbook-description /><CARD:addressbook-home-set />
2017-12-23 15:36:17 2 [HttpClient] --> END PROPFIND (290-byte body)
2017-12-23 15:36:18 2 [HttpClient] <-- 207 Multi-Status Xhttps://s.myurl.net/remote.php/dav/ (1015ms)
2017-12-23 15:36:18 2 [HttpClient] Date: Sat, 23 Dec 2017 14:36:18 GMT
2017-12-23 15:36:18 2 [HttpClient] Content-Type: application/xml; charset=utf-8
2017-12-23 15:36:18 2 [HttpClient] Content-Length: 752
2017-12-23 15:36:18 2 [HttpClient] Connection: keep-alive
2017-12-23 15:36:18 2 [HttpClient] Server: Apache
2017-12-23 15:36:18 2 [HttpClient] Set-Cookie: ochr1revegbn=p8m550moh3f2kq415cjd1p5c06; path=/; HttpOnly
2017-12-23 15:36:18 2 [HttpClient] Expires: Thu, 19 Nov 1981 08:52:00 GMT
2017-12-23 15:36:18 2 [HttpClient] Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
2017-12-23 15:36:18 2 [HttpClient] Pragma: no-cache
2017-12-23 15:36:18 2 [HttpClient] Set-Cookie: oc_sessionPassphrase=mq5fEzMiNH46ztgBb%2FNPqkBnrXfl7rQpnrPjFKxOSMiPdwVSCtmvXJETNqsx6MaAIvclx1khJ7EQmpZhLbWRrPF0YWhB%2B7I0G4RExLTCZWtDlbbzu36st6u3PNxXSHc2; path=/; secure; Xhttponly
2017-12-23 15:36:18 2 [HttpClient] Content-Security-Policy: default-src ‘none’;
2017-12-23 15:36:18 2 [HttpClient] X-Frame-Options: SAMEORIGIN
2017-12-23 15:36:18 2 [HttpClient] Set-Cookie: __Host-nc_sameSiteCookielax=true; path=/; Xhttponly;secure; expires=Fri, 31-Dec-2100 23:59:59 GMT; SameSite=lax
2017-12-23 15:36:18 2 [HttpClient] Set-Cookie: __Host-nc_sameSiteCookiestrict=true; path=/; Xhttponly;secure; expires=Fri, 31-Dec-2100 23:59:59 GMT; SameSite=strict
2017-12-23 15:36:18 2 [HttpClient] Set-Cookie: ochr1revegbn=nqki6tcsgltf492c8fitnf2574; path=/; secure; HttpOnly
2017-12-23 15:36:18 2 [HttpClient] Set-Cookie: cookie_test=test; expires=Sat, 23-Dec-2017 15:36:18 GMT; Max-Age=3600
2017-12-23 15:36:18 2 [HttpClient] Vary: Brief,Prefer
2017-12-23 15:36:18 2 [HttpClient] DAV: 1, 3, extended-mkcol, access-control, calendarserver-principal-property-search, calendar-access, calendar-proxy, calendar-auto-schedule, calendar-availability, calendarserver-subscribed, oc-resource-sharing, oc-calendar-publishing, calendarserver-sharing, addressbook, nc-calendar-search
2017-12-23 15:36:18 2 [HttpClient] X-Content-Type-Options: nosniff
2017-12-23 15:36:18 2 [HttpClient] X-XSS-Protection: 1; mode=block
2017-12-23 15:36:18 2 [HttpClient] X-Robots-Tag: none
2017-12-23 15:36:18 2 [HttpClient] X-Download-Options: noopen
2017-12-23 15:36:18 2 [HttpClient] X-Permitted-Cross-Domain-Policies: none
2017-12-23 15:36:18 2 [HttpClient]
2017-12-23 15:36:18 2 [HttpClient] <?xml version="1.0"?>
<d:multistatus xmlns:d=“DAV:” xmlns:s=“Xhttp://sabredav.org/ns” xmlns:cal=“urn:ietf:params:xml:ns:caldav” xmlns:cs=“Xhttp://calendarserver.org/ns/” xmlns:card=“urn:ietf:params:xml:ns:carddav” xmlns:oc=“Xhttp://owncloud.org/ns” xmlns:nc=“Xhttp://nextcloud.org/ns”><d:response><d:href>/remote.php/dav/</d:href><d:propstat><d:prop><d:resourcetype><d:collection/></d:resourcetype><d:current-user-principal><d:href>/remote.php/dav/principals/users/andreas/</d:href></d:current-user-principal></d:prop><d:status>HTTP/1.1 200 OK</d:status></d:propstat><d:propstat><d:prop><d:displayname/>card:addressbook-description/card:addressbook-home-set/</d:prop><d:status>HTTP/1.1 404 Not Found</d:status></d:propstat></d:response></d:multistatus>
2017-12-23 15:36:18 2 [HttpClient] <-- END HTTP (752-byte body)
2017-12-23 15:36:18 2 [DavResource] Ignoring unknown property resourcetype(DAV:)
2017-12-23 15:36:18 2 [DavResource] Ignoring unknown property current-user-principal(DAV:)
2017-12-23 15:36:18 2 [DavResource] Ignoring unknown property displayname(DAV:)
2017-12-23 15:36:18 2 [DavResource] Ignoring unknown property addressbook-description(urn:ietf:params:xml:ns:carddav)
2017-12-23 15:36:18 2 [DavResource] Ignoring unknown property addressbook-home-set(urn:ietf:params:xml:ns:carddav)
2017-12-23 15:36:18 2 [DavResource] Received for Xhttps://s.myurl.net/remote.php/dav/
PARAMETER #0 = []
2017-12-23 15:36:18 2 [HttpClient] --> PROPFIND Xhttps://s.myurl.net/.well-known/carddav
2017-12-23 15:36:18 2 [HttpClient] Content-Type: application/xml; charset=utf-8
2017-12-23 15:36:18 2 [HttpClient] Content-Length: 198
2017-12-23 15:36:18 2 [HttpClient] Depth: 0
2017-12-23 15:36:18 2 [HttpClient]
2017-12-23 15:36:18 2 [HttpClient] <?xml version='1.0' encoding='UTF-8' ?>
2017-12-23 15:36:18 2 [HttpClient] --> END PROPFIND (198-byte body)
2017-12-23 15:36:18 2 [HttpClient] <-- 301 Moved Permanently Xhttps://s.myurl.net/.well-known/carddav (123ms)
2017-12-23 15:36:18 2 [HttpClient] Date: Sat, 23 Dec 2017 14:36:18 GMT
2017-12-23 15:36:18 2 [HttpClient] Content-Type: text/html; charset=iso-8859-1
2017-12-23 15:36:18 2 [HttpClient] Content-Length: 251
2017-12-23 15:36:18 2 [HttpClient] Connection: keep-alive
2017-12-23 15:36:18 2 [HttpClient] Server: Apache
2017-12-23 15:36:18 2 [HttpClient] Location: Xhttps://s.myurl.net/remote.php/dav/
2017-12-23 15:36:18 2 [HttpClient]
2017-12-23 15:36:18 2 [HttpClient]

301 Moved Permanently

Moved Permanently

The document has moved here.

2017-12-23 15:36:18 2 [HttpClient] <-- END HTTP (251-byte body)
2017-12-23 15:36:18 2 [DavResource] Redirected, new location = Xhttps://s.myurl.net/remote.php/dav/
2017-12-23 15:36:18 2 [HttpClient] --> PROPFIND Xhttps://s.myurl.net/remote.php/dav/
2017-12-23 15:36:18 2 [HttpClient] Content-Type: application/xml; charset=utf-8
2017-12-23 15:36:18 2 [HttpClient] Content-Length: 198
2017-12-23 15:36:18 2 [HttpClient] Depth: 0
2017-12-23 15:36:18 2 [HttpClient]
2017-12-23 15:36:18 2 [HttpClient] <?xml version='1.0' encoding='UTF-8' ?>
2017-12-23 15:36:18 2 [HttpClient] --> END PROPFIND (198-byte body)
2017-12-23 15:36:19 2 [HttpClient] <-- 207 Multi-Status Xhttps://s.myurl.net/remote.php/dav/ (617ms)
2017-12-23 15:36:19 2 [HttpClient] Date: Sat, 23 Dec 2017 14:36:19 GMT
2017-12-23 15:36:19 2 [HttpClient] Content-Type: application/xml; charset=utf-8
2017-12-23 15:36:19 2 [HttpClient] Content-Length: 544
2017-12-23 15:36:19 2 [HttpClient] Connection: keep-alive
2017-12-23 15:36:19 2 [HttpClient] Server: Apache
2017-12-23 15:36:19 2 [HttpClient] Expires: Thu, 19 Nov 1981 08:52:00 GMT
2017-12-23 15:36:19 2 [HttpClient] Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
2017-12-23 15:36:19 2 [HttpClient] Pragma: no-cache
2017-12-23 15:36:19 2 [HttpClient] Content-Security-Policy: default-src ‘none’;
2017-12-23 15:36:19 2 [HttpClient] X-Frame-Options: SAMEORIGIN
2017-12-23 15:36:19 2 [HttpClient] Set-Cookie: nc_username=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT; Max-Age=0; secure; Xhttponly
2017-12-23 15:36:19 2 [HttpClient] Set-Cookie: nc_token=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT; Max-Age=0; secure; Xhttponly
2017-12-23 15:36:19 2 [HttpClient] Set-Cookie: nc_session_id=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT; Max-Age=0; secure; Xhttponly
2017-12-23 15:36:19 2 [HttpClient] Set-Cookie: nc_username=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT; Max-Age=0; path=/; secure; Xhttponly
2017-12-23 15:36:19 2 [HttpClient] Set-Cookie: nc_token=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT; Max-Age=0; path=/; secure; Xhttponly
2017-12-23 15:36:19 2 [HttpClient] Set-Cookie: nc_session_id=deleted; expires=Thu, 01-Jan-1970 00:00:01 GMT; Max-Age=0; path=/; secure; Xhttponly
2017-12-23 15:36:19 2 [HttpClient] Set-Cookie: ochr1revegbn=7qq3fd8qt0n8ckj96dg01f26v1; path=/; secure; HttpOnly
2017-12-23 15:36:19 2 [HttpClient] Set-Cookie: ochr1revegbn=vhhmac2428dvojrsdlj25sojs2; path=/; secure; HttpOnly
2017-12-23 15:36:19 2 [HttpClient] Vary: Brief,Prefer
2017-12-23 15:36:19 2 [HttpClient] DAV: 1, 3, extended-mkcol, access-control, calendarserver-principal-property-search, calendar-access, calendar-proxy, calendar-auto-schedule, calendar-availability, calendarserver-subscribed, oc-resource-sharing, oc-calendar-publishing, calendarserver-sharing, addressbook, nc-calendar-search
2017-12-23 15:36:19 2 [HttpClient] X-Content-Type-Options: nosniff
2017-12-23 15:36:19 2 [HttpClient] X-XSS-Protection: 1; mode=block
2017-12-23 15:36:19 2 [HttpClient] X-Robots-Tag: none
2017-12-23 15:36:19 2 [HttpClient] X-Download-Options: noopen
2017-12-23 15:36:19 2 [HttpClient] X-Permitted-Cross-Domain-Policies: none
2017-12-23 15:36:19 2 [HttpClient]
2017-12-23 15:36:19 2 [HttpClient] <?xml version="1.0"?>
<d:multistatus xmlns:d=“DAV:” xmlns:s=“Xhttp://sabredav.org/ns” xmlns:cal=“urn:ietf:params:xml:ns:caldav” xmlns:cs=“Xhttp://calendarserver.org/ns/” xmlns:card=“urn:ietf:params:xml:ns:carddav” xmlns:oc=“Xhttp://owncloud.org/ns” xmlns:nc=“Xhttp://nextcloud.org/ns”><d:response><d:href>/remote.php/dav/</d:href><d:propstat><d:prop><d:current-user-principal><d:href>/remote.php/dav/principals/users/andreas/</d:href></d:current-user-principal></d:prop><d:status>HTTP/1.1 200 OK</d:status></d:propstat></d:response></d:multistatus>
2017-12-23 15:36:19 2 [HttpClient] <-- END HTTP (544-byte body)
2017-12-23 15:36:19 2 [DavResource] Ignoring unknown property current-user-principal(DAV:)
2017-12-23 15:36:19 2 [DavResource] Received for Xhttps://s.myurl.net/remote.php/dav/
PARAMETER #0 = []
2017-12-23 15:36:19 2 [ui.setup.DavResourceFinder] No principal found at user-given URL, trying to discover
2017-12-23 15:36:19 2 [ui.setup.DavResourceFinder] Looking up SRV records for _carddavs._tcp.s.myurl.net
2017-12-23 15:36:19 2 [ui.setup.DavResourceFinder] Didn’t find carddav service, trying at Xhttps://s.myurl.net:443
2017-12-23 15:36:19 2 [ui.setup.DavResourceFinder] Trying to determine principal from initial context path=Xhttps://s.myurl.net/.well-known/carddav
2017-12-23 15:36:19 2 [HttpClient] --> PROPFIND Xhttps://s.myurl.net/.well-known/carddav
2017-12-23 15:36:19 2 [HttpClient] Content-Type: application/xml; charset=utf-8
2017-12-23 15:36:19 2 [HttpClient] Content-Length: 198
2017-12-23 15:36:19 2 [HttpClient] Depth: 0
2017-12-23 15:36:19 2 [HttpClient]
2017-12-23 15:36:19 2 [HttpClient] <?xml version='1.0' encoding='UTF-8' ?>
2017-12-23 15:36:19 2 [HttpClient] --> END PROPFIND (198-byte body)
2017-12-23 15:36:19 2 [HttpClient] <-- 301 Moved Permanently Xhttps://s.myurl.net/.well-known/carddav (125ms)
2017-12-23 15:36:19 2 [HttpClient] Date: Sat, 23 Dec 2017 14:36:20 GMT
2017-12-23 15:36:19 2 [HttpClient] Content-Type: text/html; charset=iso-8859-1
2017-12-23 15:36:19 2 [HttpClient] Content-Length: 251
2017-12-23 15:36:19 2 [HttpClient] Connection: keep-alive
2017-12-23 15:36:19 2 [HttpClient] Server: Apache
2017-12-23 15:36:19 2 [HttpClient] Location: Xhttps://s.myurl.net/remote.php/dav/
2017-12-23 15:36:19 2 [HttpClient]
2017-12-23 15:36:19 2 [HttpClient]

301 Moved Permanently

Moved Permanently

The document has moved here.

It turned out to be primarily a davdroid update issue. I’m still not sure about the the /.well-known directory and lets encrypt.

Thanks,

Andreas