Ask / Submit
87

New CardDav/CalDav support got to it working with owncloud?

asked 2014-10-24 20:19:56 +0300

FloR707 gravatar image

updated 2015-11-21 10:20:34 +0300

Hi does anyone got the new CalDav/CardDav support working with owncloud? I am not sure what URLs to enter. I also do not like that you do not see if the system is trying to sync. Is there a log file I could check?

I am using OC 8.0.2 on a hosted server with a self signed SSL certificate.

I also dislike that it is not possible to edit the server information after the account was set up. I always have to delete the account and start from scratch. =(

[edit]

I spend another two days looking at OC to get it working. Finally I gave up. The Jolla functions do not work for me and I do not know why. SyncEvolution gives me a 403 error.

I think it is a problem on several sides. 1. The Jolla client is not ready, 2. OC is not working if self-singed certificates are used. I will wait for updates on both sides and hope that it will work at some point in the future...

[edit 2014-12-12] The last days I spend some more time trying to get this working. I updated to OC 7.0.4 but with Syncevolution I still get an 403 access denied error and CalDav account still does nothing. Is it possible to see in an OC log if there was a sync attempt?

[edit 2014-12-13] I downgraded to OC 6.0.6 and switched to a MySQL DB and now the CalDav works for me as well with cdv's settings. At last =)

[edit 2015-01-04] Looks like the problem was not with the OC version but with the database. I did a new setup with OC 7.0.4 and MySQL (first try was SQLite) and it works for me with a self-signed certificate. What I did prior to setting up the account is to open the OC web interface with a browser to "install" the SSL certificates. Looks like the CalDav client is not capable of doing that.

[edit 2015-04-18] Calendar still works with OC 8.0.2 on a hosted server with self-signed SSL certificate. Looks like people got contacts so sync as well as long they do not use SSL and OC 8.x. I hope that the SSL issue with contacts will be solved in the next update.

[edit 2015-11-21] Since the update to 2.0 I think owncloud is working fine. Both caldav and carddav with a self-signed cert.

edit retag flag offensive close delete

Comments

8

Agreed -some kind of sync notification or progress would certainly be helpful.

Malakim ( 2014-10-24 21:03:40 +0300 )edit
3

I got CalDav to work with path: /owncloud/remote.php/caldav/calendars/-username- Still no luck with CardDav though.

Maldela ( 2014-10-24 21:17:30 +0300 )edit

I got the error message from dbus-monitor.

gehowa ( 2014-10-25 00:12:08 +0300 )edit

The contact addressbook set path is determined using DAV discovery (ie, automatically during sync). If that is not working, can you get the log of the sync (see raven24's answer below) which may help you determine what is going wrong for CardDAV sync?

chris.adams ( 2014-10-28 03:46:34 +0300 )edit

I am still getting nowhere here. I followed raven's instructions but I cannot set up the service. I always get an error after accepting the login and server details. The log says the following:

caldav-client[16157]: [D] main:70 - attempting to register dbus service: "com.buteo.msyncd.plugin.caldav-sync-100" 
caldav-client[16157]: [D] main:77 - Plugin  "caldav"  with profile  "caldav-sync-100"  registered at dbus  "com.buteo.msyncd.plugin.caldav-sync-100"  and path  /
caldav-client[16157]: [D] Buteo::ProfileManagerPrivate::loadLog:167 - No sync log found for profile: "caldav-sync-100"

OC gives me a warning after each try:

Warning core    isWebDAVWorking: NO - Reason: [CURL] Error while making request: error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol (error code: 35) (Sabre\DAV\Exception)

I guess that is due to the fact that I am using a self signed SSL certificate. I also found a solution for that warning but that did not work. The warning is still there and I cannot connect.

I used to be able to sync using SyncEvolution but only until I upgraded to 7.0.0

FloR707 ( 2014-10-28 19:06:37 +0300 )edit

12 Answers

Sort by » oldest newest most voted
28

answered 2015-04-16 17:19:50 +0300

this post is marked as community wiki

This post is a wiki. Anyone with karma >75 is welcome to improve it.

updated 2015-05-03 23:30:59 +0300

Andy Branson gravatar image

CardDAV works with ownCloud 1.1.4 (Update 13 , provided you don't use a self-signed SSL cert...)!

The ownCloud .htaccess file already handles the RFC5785 'well-known' URLs for both CardDAV and CalDAV, so you don't have to set up any paths. Leave the 'calendar path' blank, and it'll work fine for both calendar and contacts.

NOTE: Do not use the CardDav or CalDav paths you get from the Owncloud web interface, just the owncloud root URL, which is the part you see before the 'index.php' on your owncloud website address.

Even more thanks, Chris!

Example (brackets are comments):

Username: (your owncloud username)
Password: (your owncloud password)
Server address:http://your.owncloud.server/
Calendar path: (blank) (yes, completely blank)

CardDAV and CalDAV enabled.

If your owncloud is NOT installed on the root directory:

  • Include the installation path + remote.php in the server address, e.g. ''http://example.org/owncloud/remote.php/".
  • If that doesn't work: make separate CardDAV/CalDAV accounts.
    • For CalDAV put the following to server path "http://example.org/owncloud/remote.php/caldav/"
    • For CardDAV use "http://example.org/owncloud/remote.php/carddav/"

As an alternative you may also do redirecting of the ./well-known-URL from within the server root in an .htaccess-file, like so:

<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule ^\.well-known/carddav /owncloud/remote.php/carddav/ [R]
RewriteRule ^\.well-known/caldav /owncloud/remote.php/caldav/ [R]
</IfModule>

If you must use self-signed SSL certificate, you must add your server certificate to your phone's trusted cert list.

Update 2015-04-22 - Chris (from Jolla) is working on both last issues: Ignoring SSL certificate errors and the trailing slash '/'. He is aware of the problems and working on them. Ignoring SSL errors is working from buteo-sync-plugin-carddav-0.0.10 on. Unfortunately the current version did not make it into the latest update (1.1.4, u13) leaving us with buteo-sync-plugin-carddav-0.0.9-1.4.1.

edit flag offensive delete publish link more

Comments

Hi Andy,

could you be so nice and explain a litte more in detail what you did?

  1. What is 1.1.4?
  2. Where did you setup the redirect rule?
  3. What did you put in the server path?

Thanks

FloR707 ( 2015-04-16 18:19:37 +0300 )edit

In my case it working too, but only if I don't use ssl. Ignoring ssl-errors didn't help. I'm using a local owncloud 8.03 server with no internet access on a synology nas.

As URL I used the given address from owncloud only with http instead of https.

LordRooster ( 2015-04-16 19:53:25 +0300 )edit
1

For me it also seems to work without https. Syncing with https produces following error on the log: Apr 16 22:23:04 Jolla carddav-client[10726]: [W] CardDav::userInformationResponse:342 - void CardDav::userInformationResponse() error: 6 ( 0 ) to request "..."

As I understand it, error 6 is SslHandshakeFailedError, so it seems 'ignore ssl errors' still doesn't work on all cases.

JPS ( 2015-04-16 22:28:17 +0300 )edit

Could somebody give some instructions? Just the fields and dummyvalues?

lispy ( 2015-04-17 12:02:52 +0300 )edit

What type of server are you using? In case of owncloud, just log in, go to your calendar and it will give you the url in the settings-section like shown in this picture.

LordRooster ( 2015-04-17 12:06:49 +0300 )edit
13

answered 2014-10-28 13:12:33 +0300

Sailor gravatar image

updated 2015-04-06 00:34:52 +0300

I just got carddav support to work with Jolla. It's a bit of hacky thing but it works right now ;)

set $request_url $request_uri;
    if ($request_uri ~ /owncloud/remote\.php/carddav///owncloud/remote\.php/carddav/(.*)$) {
            set $request_url /owncloud/remote.php/carddav/$1;
    }

   if ($request_uri ~ /owncloud/remote\.php/carddav/principals/(.*)/owncloud/remote\.php/carddav/addressbooks(.*)$) {
                set $request_url /owncloud/remote.php/carddav/addressbooks$2;
        }
           location ~ /owncloud/remote\.php/carddav/principals/(.*)/owncloud/remote\.php/carddav/addressbooks(.*)$ {
                rewrite ^/owncloud/remote\.php/carddav/principals/(.*)/owncloud/remote\.php/carddav/addressbooks(.*)$ /owncloud/remote.php/carddav/addressbooks$2 last;
        }

    location  ~ /owncloud/remote\.php/carddav///owncloud/remote\.php/carddav/(.*)$ {
            rewrite ^/owncloud/remote\.php/carddav///owncloud/remote\.php/carddav/(.*)$ /owncloud/remote.php/carddav/principals$1 last;
    }

    location ~ ^(.+?\.php)(/.*)?$ {
            try_files $1 = 404;

            include fastcgi_params;
            fastcgi_param REQUEST_URI $request_url;
            fastcgi_param SCRIPT_FILENAME $document_root$1;
            fastcgi_param PATH_INFO $2;
            fastcgi_pass 127.0.0.1:9025;
    }

The solution was to rewrite Jollas requests to the right format on nginx level. Added another rule so you can configure https://myserver.com/owncloud/remote.php/carddav/ to your Jolla.

edit flag offensive delete publish link more

Comments

1

First of all: thanks for the detailed answer! Could you clarify what you put where in the Jolla interface as I have owncloud+nginx and didn't get it to work in the last few hours?

Also, did you mark this account CardDAV only or do you also sync CalDAV (which worked for me before)?

I see these kind of entries in my nginx-access log:

"PROPFIND /owncloud/remote.php/carddav/ HTTP/1.1" 401 304 "-" "Mozilla/5.0"
sidv ( 2014-10-28 22:50:04 +0300 )edit
2

I have added two accounts on my Jolla. One with only Carddav enabled and as server url: https://myserver.com/owncloud/remote.php/carddav and one with only caldav enabled with serverpath and serverurl https://myserver.com. The combined option does not work at the moment.

Sailor ( 2014-10-28 22:57:32 +0300 )edit

Thanks! Still doesn't work:

"PROPFIND /owncloud/remote.php/carddav HTTP/1.1" 401 304 "-" "Mozilla/5.0"
"PROPFIND /owncloud/remote.php/carddav HTTP/1.1" 207 443 "-" "Mozilla/5.0"
"PROPFIND /owncloud/remote.php/carddav//owncloud/remote.php/carddav/principals/MYUSER/ HTTP/1.1" 404 288 "-" "Mozilla/5.0"

when manually triggering sync. Well, guess there is something wrong w/ my nginx.conf.

sidv ( 2014-10-28 23:14:50 +0300 )edit

If anyone should run into the same problem with an existing nginx.conf: the

fastcgi_param REQUEST_URI $request_url;

is really important. Works! :-)

sidv ( 2014-10-29 00:07:31 +0300 )edit
1

I got the CalDAV sync to work with ownCloud quite easily by adding a CalDAV account (Settings -> Accounts). All of my calendars are synced bidirectionally.

I cannot figure what you did to get CardDAV working. Are you using an app for that? I can only recommend to put that much information there that also a newbie can figure it out without asking strange questions... :-)

ABeam ( 2014-12-15 13:16:53 +0300 )edit
10

answered 2014-10-25 03:11:53 +0300

raven24 gravatar image

updated 2014-10-25 13:52:17 +0300

CalDAV is working fine (so far) with OwnCloud 7.0.2 on Sailfish 1.1.0.39, I got all my calendars to sync.

CalDAV with OwnCloud (works for me)

user: username
pass: password
server address: https://your.cloud.tld
calendar path: /remote.php/caldav/calendars/[username]
de-select CardDAV

CardDAV?

Unfortunately, when I tried the same for CardDAV (on a separate account) I never got any results. I tried entering many combinations of server addresses, with port/path but for some reason I never even get any requests to show up in the OwnCloud server logs. In the phone logs it says "CardDAV sync failed: 401" ... but that's not something I can find anywhere in my owncloud servers log.

CardDAV Sync Logs

You can watch the sync process on the Jolla as described in this post but I had to change the command that starts msyncd. So here is what I did (via SSH on the phone):

systemctl --user stop msyncd
devel-su killall msyncd
MSYNCD_LOGGING_LEVEL=9 devel-su --privileged msyncd

and then in another terminal:

devel-su journalctl -a -f | grep carddav

The journal of the Jolla for one of the sync attempts with carddav is as follows (url redacted)


Oct 25 02:01:00 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "virtual bool CardDavClient::init()" :Entry 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "virtual bool CardDavClient::init()" :Exit, execution time: 0 ms 
Oct 25 02:01:00 Jolla carddav-client[11638]: [W] ContactsEngine::ContactsEngine:803 - The 'mergePresenceChanges' option has not been configured - presence changes will only be reported via ContactManagerEngine::contactsPresenceChanged()
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "bool PluginServiceObj::startSync()" :Entry 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "bool PluginServiceObj::startSync()" :Exit, execution time: 0 ms 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "virtual bool CardDavClient::startSync()" :Entry 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "virtual bool CardDavClient::startSync()" :Exit, execution time: 0 ms 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] Syncer::startSync:83 - void Syncer::startSync(int) starting carddav sync with account 18 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] SignOn::IdentityImpl::updateState:103 - identityimpl.cpp 103 updateState Updating state:  PendingRegistration 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] SignOn::AuthSessionImpl::initInterface:174 - authsessionimpl.cpp 174 initInterface 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] SignOn::AuthSessionImpl::process:270 - authsessionimpl.cpp 270 process sending to queue 
Oct 25 02:01:00 Jolla carddav-client[11638]: [D] SignOn::IdentityImpl::updateState:103 - identityimpl.cpp 103 updateState Updating state:  Ready 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] SignOn::DBusOperationQueueHandler::execQueuedOperations:137 - dbusoperationqueuehandler.cpp 137 execQueuedOperations Executing cached oparation: SIGNATURE: "process(SessionData,QString)" 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] SignOn::DBusOperationQueueHandler::execQueuedOperations:149 - dbusoperationqueuehandler.cpp 149 execQueuedOperations 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] SignOn::AuthSessionImpl::process:265 - authsessionimpl.cpp 265 process sending to daemon 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] CardDav::fetchUserInformation:290 - void CardDav::fetchUserInformation() requesting principal urls for user 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] RequestGenerator::generateRequest:88 - generateRequest(): "" "https://your.cloud.tld/remote.php/carddav" "" "0" "PROPFIND" "<d:propfind xmlns:d="DAV:"><d:prop><d:current-user-principal /></d:prop></d:propfind>" 
Oct 25 02:01:01 Jolla carddav-client[11638]: [W] CardDav::userInformationResponse:306 - void CardDav::userInformationResponse() error: 6 ( 0 ) 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "void CardDavClient::syncFinished(int, const QString&)" :Entry 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "void CardDavClient::syncFinished(int, const QString&)" :Exit, execution time: 0 ms 
Oct 25 02:01:01 Jolla carddav-client[11638]: [C] CardDavClient::syncFinished:137 - CardDAV sync failed: 401 "" 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "QString PluginServiceObj::getSyncResults()" :Entry 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "QString PluginServiceObj::getSyncResults()" :Exit, execution time: 1 ms 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "virtual Buteo::SyncResults CardDavClient::getSyncResults() const" :Entry 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "virtual Buteo::SyncResults CardDavClient::getSyncResults() const" :Exit, execution time: 0 ms 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "QString PluginServiceObj::getSyncResults()" :Entry 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "QString PluginServiceObj::getSyncResults()" :Exit, execution time: 0 ms 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "virtual Buteo::SyncResults CardDavClient::getSyncResults() const" :Entry 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "virtual Buteo::SyncResults CardDavClient::getSyncResults() const" :Exit, execution time: 0 ms 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "bool PluginServiceObj::uninit()" :Entry 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "bool PluginServiceObj::uninit()" :Exit, execution time: 1 ms 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::LogTimer:72 - "virtual bool CardDavClient::uninit()" :Entry 
Oct 25 02:01:01 Jolla carddav-client[11638]: [D] Buteo::LogTimer::~LogTimer:83 - "virtual bool CardDavClient::uninit()" :Exit, execution time: 0 ms
edit flag offensive delete publish link more

Comments

Where did you find the log file?

That does not work for me. I do net get a connection. The setup tells me that there was an error while trying to find a calendar. =(

FloR707 ( 2014-10-25 09:47:25 +0300 )edit

sorry, it was a little late yesterday. I updated my answer

raven24 ( 2014-10-25 13:52:51 +0300 )edit

From http://qt-project.org/doc/qt-5/qnetworkreply.html#NetworkError-enum the error code 6 is an SSL Handshake error. Are you certain that your system date/time is set up correctly on your device? Are you certain that your server is responding to https requests properly?

QNetworkReply::SslHandshakeFailedError 6 the SSL/TLS handshake failed and the encrypted channel could not be established. The sslErrors() signal should have been emitted.

chris.adams ( 2014-10-28 03:42:32 +0300 )edit
1

I use the same self-signed cert for CalDAV as for CardDAV... but I can also try it again without SSL (just for gathering information, I'd actually really like my traffic encrypted) and report the results later.

raven24 ( 2014-10-28 17:30:04 +0300 )edit
8

answered 2014-10-24 20:39:16 +0300

cvp gravatar image

updated 2014-10-25 15:12:18 +0300

damourti gravatar image

CalDav (Calendar) work! CardDAV can connecting but no sync! :(

CalDav

  • Username = username
  • Password = password
  • Serveradress: https://myserver.de:PORT
  • Calendar path: /owncloud/remote.php/caldav/calendars/-username-/defaultcalendar

CardDav

  • Username = username
  • Password = password
  • Serveradress: https://myserver.de:PORT
  • Server path: /owncloud/remote.php/carddav/addressbooks/-username-/kontakte

"kontakte" is by me, because i use it in german lang. in english you use "contacs"

edit flag offensive delete publish link more

Comments

1

It's a pity that buteo caldav sync still does not work in 1.1.0.39. When I manually trigger a sync run an error message pops up on dbus:

 signal sender=:1.116 -> dest=(null destination) serial=17 path=/; interface=com.buteo.msyncd.baseplugin; member=error
           string "caldav-sync-22"
           string "Network request failed with QNetworkReply::NetworkError: 203"
           int32 401
    method call sender=:1.19 -> dest=com.buteo.msyncd.plugin.caldav-sync-22 serial=336 path=/; interface=com.buteo.msyncd.baseplugin; member=getSyncResults
        method return sender=:1.116 -> dest=:1.19 reply_serial=336
           string "<?xml version="1.0" encoding="UTF-8"?>
        <syncresults majorcode="1" time="2014-10-24T10:34:18Z" minorcode="401" scheduled="false"/>

Any ideas?

gehowa ( 2014-10-24 21:11:42 +0300 )edit

For me caldav works well enough (except it insists in creating a new calendar on the phone, and does not let me decide which calendar to sync).

I'm not sure how to read the error codes, but 401 is an http authorization error, are your username / password correct ?

Kim ( 2014-10-24 21:25:37 +0300 )edit

The initial import from the server works, but subsequent sync runs don't, so user/pwd and connection details should be okay.

gehowa ( 2014-10-24 21:45:31 +0300 )edit

How did you get the error message? Did I get this right? I have to set up two accounts one for CalDav and one for CardDav? I think I got the CalDav right, at least I passed the testing and could select an sync interval but there is no syncing. I cannot see any activity in my owncloud account. For the path I used the one I use with iCal: /owncloud/remote.php/caldav/principals/-username-/ The CardDav account was accepted, too but here I got no sync options. Is this normal? Also I do not think that syncing works for me.

FloR707 ( 2014-10-24 23:55:35 +0300 )edit

Here is what dbus-monitor told me:

    method call sender=:1.32 -> dest=org.freedesktop.DBus serial=547 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=AddMatch
   string "type='signal',sender='com.buteo.msyncd.plugin.caldav-sync-52',path='/',interface='com.buteo.msyncd.baseplugin',member='success'"
method call sender=:1.32 -> dest=org.freedesktop.DBus serial=548 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=AddMatch
   string "type='signal',sender='com.buteo.msyncd.plugin.caldav-sync-52',path='/',interface='com.buteo.msyncd.baseplugin',member='accquiredStorage'"
method call sender=:1.32 -> dest=org.freedesktop.DBus serial=549 path=/org/freedesktop/DBus; interface=org.freedesktop.DBus; member=AddMatch
   string "type='signal',sender='com.buteo.msyncd.plugin.caldav-sync-52',path='/',interface='com.buteo.msyncd.baseplugin',member='syncProgressDetail'"
signal sender=:1.35 -> dest=(null destination) serial=234 path=/synchronizer; interface=com.meego.msyncd; member=syncStatus
   string "caldav-sync-52"
   int32 1
   string ""
   int32 0
method call sender=:1.32 -> dest=com.buteo.msyncd.plugin.caldav-sync-52 serial=550 path=/; interface=com.buteo.msyncd.baseplugin; member=init
signal sender=org.freedesktop.DBus -> dest=(null destination) serial=88 path=/org/freedesktop/DBus;

[...] So looks like it was successful but no dates are updated...

FloR707 ( 2014-10-25 00:37:55 +0300 )edit
5

answered 2014-12-21 21:48:08 +0300

anyc gravatar image

updated 2014-12-21 21:48:26 +0300

I wrote a patch that results in one successful CardDav sync with owncloud. A guide, the patch (and a RPM) is available here: https://github.com/nemomobile/buteo-sync-plugin-carddav/pull/5

Unfortunately, further syncs fail so far but at least I get my current contacts. I will look into this.

edit flag offensive delete publish link more
3

answered 2015-08-26 11:31:32 +0300

stateoftheart gravatar image

updated 2015-08-26 12:55:59 +0300

Just wanted to update this four months old thread with the following Info.

(I hope it's helpfull for those people who got problems setting up a caldav/carddav account like me...)

caldav & carddav works for me with the following set-up: (except the caldav bug as stated here: https://together.jolla.com/question/60486/all-dates-shifted-by-one-hour-in-calendar-after-updating-to-11038/)


Testing Environment:

  • Sailfish OS 1.1.6.27
  • owncloud 8.1.1 (with self-signed certificate)

owncloud setup:

http -> https fix after upgrade from oc7 to oc8 (forcessl=true was removed from config file)

add this at the top of the .htaccess file in the owncloud web directory: (Please note that the following code should be used if the owncloud installation is under "/owncloud". If you set-up owncloud in the webroot directory, remove the "/owncloud".)

<IfModule mod_rewrite.c>
#rewrites owncloud http request to https
RewriteEngine on
RewriteCond %{HTTPS} !=on
RewriteRule ^/?(.*) https://%{SERVER_NAME}/owncloud/$1 [R,L]
</IfModule>

Jolla certificate import:

Steps to import a self-signed certificate:

1.create a hash from your self-signed certificate:

$ openssl x509 -in {your_certificate}.crt -noout -hash

2.copy your self-signed certificate into the trusted certs folder

$ cp {path_to_your_certificate}/{your_certificate}.crt /etc/pki/tls/certs/

3.create a link inside the same directory to your self-signed certificate with the previously generated hash:

$ ln -s {your_certificate}.crt {your_certificate_hash}.0

4.now you are ready to connect to owncloud without activating the "Ignore SSL errors" button

Jolla caldav/carddav setup:

Account Settings: (Please note that the following links should be used if the owncloud installation is under "/owncloud". If you set-up owncloud in the webroot directory, remove the "/owncloud".)


[edit 2015-08-26]

Carddav doesn't automatically start the sync process after triggering the contact sync. The sync only starts if I manually start it from the account settings.

Jolla [1232]: [W] CDExporterController::onSyncTimeout:1067 - CDExport: triggering contacts sync "carddav"

(caldav syncs is not affected, it has it's own timeout setting which operates normally)

edit flag offensive delete publish link more

Comments

That last issue was fixed a little while ago, but apparently wasn't released in the most update. See https://github.com/nemomobile/contactsd/commit/8151c16ff37f22a5d7f4a0ef902eecae4b0b7bb7 for that one.

chris.adams ( 2015-08-26 16:08:52 +0300 )edit

Thanks a lot for your reply. Let's hope the daemon will be updated in the next Sailfish OS release. :-)

stateoftheart ( 2015-08-26 17:03:40 +0300 )edit

Hi stateoftheheart,

I'm running oC 7 and SFOS 1.1.7.28, and on the Jolla I set up separate accounts for CalDAV and CardDAV using your suggestions. It seems to be working perfectly.

Before using your settings, I used some that were suggested earlier in the thread, and they were fine on 1.1.6. On 1.1.7 CardDAV would work alright, but after the initial sync, the calendars wouldn't update any further, no matter if events were added/modified from oC or the Jolla.

So many thanks for sharing your findings :)

Piero ( 2015-09-05 21:26:43 +0300 )edit

I am still struggling with OC. I tried to follow your description but I already get lost at the first step. openssl does not work on my Jolla bash: openssl: command not found Also I do not understand where the crt file needs to be. On the server, on the phone or on a computer?

The path for calendar and contacts has been changed with the latest update. What settings do you use now?

FloR707 ( 2015-09-10 23:15:38 +0300 )edit

@Piero

I am glad I could help you out.

@FloR707

1.you can install openssl with the following commands:

//this command refreshes/updates the package managers software list
$ pkcon refresh
//this command installs openssl
$ pkcon install openssl

just fyi:

//this command will update all installed packages to the newest version
$ pkcon update

2.the crt file needs the be on the phone (under: /etc/pki/tls/certs/). You should already have the certificate file from your webserver.

3.with the latest update you mean sailfish 1.1.7.28, right? I haven't changed the settings and it still works for me with this version.

stateoftheart ( 2015-09-11 14:56:45 +0300 )edit
2

answered 2014-10-24 21:18:55 +0300

Fellfrosch gravatar image

For me CalDav is working with OwnCloud. I've written the whole path into the field Serveradress and left the calendar path free. I'm just using http (I'm just using owncloud at home in my own network)

edit flag offensive delete publish link more

Comments

Just tried it that way (whole path in server address, http only), but no success -- but my server's not in my home network.

gehowa ( 2014-10-24 22:10:11 +0300 )edit

What version of OC do you use?

FloR707 ( 2014-10-25 00:00:06 +0300 )edit

I'm on 7.0.2.

gehowa ( 2014-10-25 00:12:11 +0300 )edit

I have the same version

Fellfrosch ( 2014-10-25 09:00:09 +0300 )edit
2

answered 2014-10-25 12:42:12 +0300

cy8aer gravatar image

updated 2014-10-25 12:43:29 +0300

I stated in two threads allready (moderators: help!) and this will be the main thread for me https://together.jolla.com/question/59893/wiki-11038-first-hiccups/

  • For carddav I needed to write the full url into the server address section and nothing into the server path section (and caldav switched off). The server path seems to be ignored (someone mentioned it in some ot the other Carddav threads)
  • then (and only then) I can see connections from my device to my owncloud server. It fetches the address list and tries to connect to the principals-url but creates a double server path entry owncloud/remote.php/carddav/principals/blaablaa//owncloud/principals/blaablaa which creates a 404 on the owncloud server.

Maybe it would work if you try to redirect the double url path to a single one on the server's apache/lighty/nginx/whatever if you are brave enough

edit flag offensive delete publish link more

Comments

The server address for CardDAV should just be the host. The CardDAV sync adapter performs DAV discovery to determine what the addressbook path should be. So, you need to omit the addressbook path from your server path.

chris.adams ( 2014-10-28 03:37:42 +0300 )edit

In short, let's say you have an owncloud server at https://your.owncloud.tld And let us say that it hosts two DAV resources: a calendar set and an addressbook set, at: /carddav/principals/user_id/ and /caldav/principals/user_id respectively, then you should set up your account so that the server path is https://your.owncloud.tld and the calendar path is /caldav/principals/user_id

Then both CalDAV and CardDAV synchronization should work (assuming that OwnCloud is RFC compliant...)

chris.adams ( 2014-10-28 03:39:57 +0300 )edit
3

https://myserver/owncloud/remote.php/carddav is the corresponding URL for owncloud. But Jolla does not handle the url right if I insert it this way :-/. It always appends https://myserver/owncloud/remote.php/carddav///owncloud/remote.php/carddav/principals/user which is wrong.

Sailor ( 2014-10-28 10:03:00 +0300 )edit

Definitely sounds like a bug in the sync plugin. Can you file an issue at https://github.com/nemomobile/buteo-sync-plugin-carddav/issues for this one? It seems as if it only subtracts the host rather than the host+basepath from the returned URL, when building the new path.

chris.adams ( 2014-10-30 05:39:17 +0300 )edit
1

I don't think it's a bug of the buteo sync plugin. But rather the accounts tool which does not provide a field for the carddav path. Eg calendar path is provided.

Sailor ( 2014-10-30 11:31:42 +0300 )edit
2

answered 2015-01-04 23:43:49 +0300

frisskiss gravatar image

Hi! I've got a Jolla phone since 1 week and I updated to 1.1.1.27. With Openmailbox service, I can set my caldav acount with:

USER: PASS: SERV: https://cloud.openmailbox.org PATH: /remote.php/caldav/calendars/user@openmailbox.org/calendarname

At the moment I can't sync the carddav account

edit flag offensive delete publish link more

Comments

There was a bug in the account creation code. Attempting to enable both caldav and carddav with one account does not work. Instead, you need to create one account for caldav, and a separate one for carddav. This bug has been fixed internally and will be released in an upcoming update.

chris.adams ( 2015-03-13 03:52:52 +0300 )edit

Hi Chris, can you please write down the explicit credentials for CardDAV on Owncloud? I have true trouble with setting up CardDAV on my OwnCloud.

ds1979 ( 2015-03-24 15:46:40 +0300 )edit

You need to wait for the upcoming update. It contains fixes in the jolla-accounts code and in the buteo-sync-plugin-carddav code which fixes all of the known issues when connecting to OwnCloud CardDAV endpoints.

chris.adams ( 2015-04-07 10:28:01 +0300 )edit
1

answered 2014-11-05 12:19:24 +0300

sidv gravatar image

Unfortunately, self-signed certificates are always a bit troublesome. Also those shady buttons to accept them labelled "ignore SSL errors" and "trust all certificates" personally made me a bit uncomfortable. That is why I gave in, got myself a signed certificate (they retail starting at $9/year, so it is not that much money) and all my issues went away. Honestly, I can only recommend that.

I should add, that OC7.2 w/ contacts and calendar sync works for me (w/ the Nginx workaround discussed above) on the Jolla w/o SyncEvolution.

edit flag offensive delete publish link more
Login/Signup to Answer

Question tools

Follow
62 followers

Stats

Asked: 2014-10-24 20:19:56 +0300

Seen: 16,409 times

Last updated: Nov 26 '15