Forum for iCal4OL, Print4OL and ICS4OL

Exchange of experiences / Erfahrungsaustausch / Get Help

You are not logged in.

Announcement

Verkauf von iCal4OL an Neukunden ist eingestellt! Keine Demo mehr verfügbar..
Diese Seite ist ausschliesslich für Kunden, welche auch noch zusätzliche Lizenzen kaufen können.
The selling of iCal4OL has ended! No trial available anymore..
This site is exclusively for customers, which can still buy additional licenses.

iCal4OL Version 2.17.0 is now available. See Announcements / Ankündigungen


#1 2016-06-11 09:31:58

Roland
Administrator
Registered: 2007-11-25
Posts: 1520

iCal4OL with stunnel (for .e.g. iCloud)

About stunnel see https://www.stunnel.org/

In 2.16.3 a special Winsock HTTP interface was implemented for use with stunnel.

You may wonder, why this is necessary.
If you want to use stunnel to connect to e.g. iCloud, it won't work with "normal" stunnel configuration:
- iCloud rotates IP addresses. Therefore it's not possible to use an IP address in the "connect=" line.
- iCloud will anyway return a "HTTP 400 Bad request", because it's testing the URL and the HOST-Header of every request (can't use e.g. URL "http://localhost[:Port]/.." in iCal4OL).

And:
- A stunnel configuration can also help, to mask HTTP traffic to your own server (at home).
- stunnel can be started without admin rights. It may even help to cross company firewalls.
- This winsock implementation doesn't need a modification of the "hosts" file (C:\Windows\System32\drivers\etc\hosts)

But:
- It may not help with blocked DNS by a firewall (right-click stunnel tasktray icon and check "Show Log Window" if DNS resolution was successful).
  Note: firewalls may block winsock traffic indirectly by blocking DNS. In this case your only chance to use iCal4OL is with "Options-HTTP_DLL => WinInet.dll". 

Setup stunnel (examples for iCloud and Google):

Code:

[icloud-caldav]
client = yes
accept = 127.0.0.1:9006
CAfile = ca-certs.pem
connect = p05-caldav.icloud.com:443
checkHost = p05-caldav.icloud.com
verify = 2

[icloud-carddav]
client = yes
accept = 127.0.0.1:9007
CAfile = ca-certs.pem
connect = p05-contacts.icloud.com:443
checkHost = p05-contacts.icloud.com
verify = 2


[google-sync]
client = yes
accept = 127.0.0.1:9008
CAfile = ca-certs.pem
connect = www.googleapis.com:443
checkHost = www.googleapis.com
verify = 2

[google-oauth]
client = yes
accept = 127.0.0.1:9009
CAfile = ca-certs.pem
connect = accounts.google.com:443
checkHost = accounts.google.com
verify = 2

Note: For iCloud you should check your "pNN-" server number on your smartphone, or use (e.g. on another OS/machine) a "Collection Finder for iCloud".

Configuration in iCal4OL:
- On tab "Options - HTTP_DLL" you must activate "[X] Use LibCurl.dll instead of WinXXXX.dll" (and "[X] Debug" if you wish)
  (Actually, LibCurl will not be used in this case (WinInet/WinHttp can't use localhost proxy settings))
- On tab "Options - Proxy" do not activate "[ ] Manual Proxy Configuration"!
  Only enter in "Name:Port (myProxy:8080)":  stunnel[=localhost[:port]]
- For auto configuration use later in the assistant [Other] on tab "Who" the URL: https://p05-caldav.icloud.com:443
  ==> No need to change the URL to point to stunnel! Use original URLs  in iCal4OL!

http://ical.gutentag.ch/forum/img/greenshot_2016-06-11_08-54-50.png

Note:
- CalDAV: If you write only "stunnel", "=localhost:9006" is default!
  The CardDAV port is +1 = 9007
- Google Calendar/Contact API v3: If you write only "stunnel", "=localhost:9008" is default!
  For Authorization the port + 1 will be used = 9009

Offline

 

Board footer