Bring back proper ssl handling