Use openhab1 through myopenhab.org with active authentication

Dear Community,
I just had a hard time to find out why my local openhab installation is not possible to been accessed through https://myopenhab.org/openhab.app?sitemap=mySiteMap, even though the instance already showed online in the Cloud Portal and was also sending notifications. Everytime when I tried to load the URL above I got an unauthorized exception even with fully correct cloud portal credentials.

The issue resulted from the fact that I am a little conservative in means of security and therefore I configured my local openhab runtime for security to be always on, even on local network, which also includes the local loopback 127.0.0.1. This loopback is used when accessed through myopenhab and so I created a two layer authentication, first was myopenhab auth and second my local auth. The code is not designed for that, so the authentication always failed. To get arround this issue, change the setting in configurations\openhab.cfg:

My old config that is not working:

security:option=ON

My new config that is working and keeping authentification from everywhere besides localhost:

security:option=EXTERNAL
security:netmask=127.0.0.1/32

Maybe the author of https://github.com/openhab/openhab1-addons/wiki/openHAB-Cloud-Connector could add this to the page.

best regards,
Klaus

It’s a wiki. It is intended to be edited by anyone. Please go and make the update. It is greatly appreciated.