Reorder/rewrite HTTPS section