force authenticated users to use ssl
tweak ssl code for nginx