Thanks for the contribution. The Addon earlier already hat its own HTTP-Client implementation and this has been removed in favor of the CURL implementation provided by Kodi. The drawback of this is that the control over the cookies is not in the Addon anymore which caused quite a bunch of login problems. If possible, I would prefer to keep the Kodi Implementation and fix the problems that still exist there. What problems were you having with versions after 0.1.16? Is it possible to fix them without having to use an own HTTP-Client?
The main problem is the "ERROR: Open - Unhandled exception" that are present almost every time the epg update thread is launched. I think those errors are caused by the responses with status code 0 from zattoo. With C++ Request I can handle them easily by pausing the addon for 100ms before retrying to make the request. I think with Kodi CURL it's possible to handle them with a try/catch but I don't know what to catch.
I can also handle responses with status code 403 and send again an session/hello request to renew the session.
With your implementation if the session expire it will not be renewed until you restart the addon and if you use a raspberry pi you let it on 24/24h because it's not convenient to unplug it from the power and plug it in again to make it start.
I have also noticed that in the cookies.dat of Kodi curl there is only the "beaker.session.id" session cookie but it's the "pzuid" cookie which keep the session really alive in zattoo.
loadAppId() will also always fail after the first launch because Zattoo doesn't send the appToken if there is the "beaker.session.id" cookie in the request but Kodi curl alway send it.