Add secure communication between gui and server 1/2

This adds ssl to the websocket connection between the gui and server.

The next PR contains improvement to this base.