run service proxy auth after the HTML page was rendered, and make it configurable