Notes doesn't work with TLS 1.2
I've been unable to use Notes since I was constantly getting "Server connection is broken" errors on Android. I've only recently upgraded from ownCloud to Nextcloud so I've only just discovered this issue.
I'm running Apache 2.4.27, PHP 5.6.31, OpenSSL 1.0.2l, on FreeBSD 11.1 and my phone is Cyanogenmod 11 (Android 4.4) and Notes 0.11.0 from F-Droid.
Everything else (Nextcloud app, Contacts and Calendar sync) is connecting to my server just fine.
Apache was originally configured with:
SSLProtocol all -SSLv2 -SSLv3 -TLSv1 -TLSv1.1
But I kept getting errors about the server connection being broken, an instant error without any delay.
Once I changed that setting to:
SSLProtocol all -SSLv2 -SSLv3
Notes now works.
This is really not ideal. TLS 1.2 has been out for around a decade, and I'd really prefer not to lower my server's security if I can help it!
Same here, I cannot connect to my server anymore using the Notes android app, and I think it could be related to my server using TLS1.2 for https (not sure though, I don't have anything more than an "Error" message)
I don't have anything more than an "Error" message
Let me guess, it's something like "Server connection broken" :-)
Have you tried enabling TLS 1.0 and 1.1? It would be good to have somebody else independently confirm what I found!
My bad, seems to work fine now and still using TLS1.2I believe. -> I changed my let's encrypt config to use fullchain.pem instead of cert.pem, in order to include the full chain of certs. Maybe this had an impact ?
@DarkSteve Do you use the full certificate chain in your Apache config?
@korelstar I'd already made that mistake and corrected it! I was getting errors in odd places that I traced back to using cert instead of fullchain. I've already corrected it in Apache, Postfix, and Dovecot.
From my httpd-ssl.conf:
SSLCertificateFile "/usr/local/etc/letsencrypt/live/darksteve.tk/fullchain.pem"
And from my httpd-vhosts.conf (for my cloud.darksteve.tk entry):
SSLCertificateFile /usr/local/etc/letsencrypt/live/darksteve.tk/fullchain.pem
But Notes still fails. Is there something else that could cause issues? OCSP stapling or HSTS?
@parquetn Are you sure you're only using TLS 1.2? If it's ok, can you provide what ciphers you're using - maybe I'm missing a cipher or using ciphers that Notes can only use with TLS 1.0 and 1.1? I'll try using your ciphers and see if I can get Notes working.
Ok, it's not the ciphers. I didn't think it was, but I just tried some older ciphers (as recommended by Mozilla) and still it seems it's the protocol that's the problem.
Still, the Notes mobile app requires TLS 1.0. It's not even compatible with TLS 1.1.
After getting the "server connection broken" error, it displays a second fuller error:
https://i.imgur.com/iJMtGdM.png
@parquetn Can you recheck your protocols? Mine is:
SSLProtocol all -SSLv2 -SSLv3 -TLSv1 -TLSv1.1
It appears that TLS 1.2 is activated only on Android 5.0+. I think, that's the reason, why this doesn't work for you.
Hence, you should update your phone (and TLS 1.2 is the smallest problem on such an old OS ;-) !
@korelstar Thank you!
That explains why the problem is so obvious and repeatable for me, but not many others seem to have noticed. I'm currently running Cyanogenmod, but Lineage OS has nightlies based on Android 7 that I can try out.
The main reason I haven't yet upgraded is because it took me ages to find an appropriate Xposed Framework for my phone and its associated modules, and it's currently working just right, so I didn't want to change it.
I guess it's time to bite the bullet and jump through all those hoops again!