It was a bug. We have a function SiteUtils.IsSecureRequest that can check the those proxy server variable settings. But our other function SiteUtils.ForceSSL was not checking IsSecureRequest before redirecting so it was in a redirect loop. The patch simply adds the missing check and if it is already a secure request based on the proxy settings then it doesn't redirect so it prevents the redirect loop. I've also added the patch to our codeplex download page for version 2.4.0.8 with a note about it.
Your host does not need to do anything since the proxy server is already adding the needed server variables. If you upgrade and apply the patch you will not need the javascript to redirect to https, you will be able to set SSLIsAvailable back to true and the server side code can do the redirect to https without getting stuck in a loop.