Fixes for HTTPS