Allow Rock to use HTTPS Schema WITHOUT enabling encryption

Allow Rock to use HTTPS Schema WITHOUT enabling encryption


Currently, the only way to make RockRMS use the https schema in generated urls is to check the box in the config screens to "Require Encryption;" however, this change also forces the IIS server to require encryption.

In many cases, though, it is advantageous to run the Windows Server behind a reverse proxy such as nginx. In such a case, nginx could handle the encryption once for many different servers.

With a setup like this, enabling encryption on the IIS is redundant and unnecessary. I have tested RockRMS behind such a proxy and everything works perfectly with two problems:

  1. Without "Require Encryption," Rock still defaults to using the http schema for generated urls instead of https.
  2. With "Require Encryption," Rock/IIS creates an endless redirect loop because even though the initial request came in over https, the proxied request arrived over standard http and Rock responds with a 302 redirect.

In the Linux world, this problem is solved by simply allowing the app to generate urls using the https schema.

I'm asking for a config option allowing Rock to generate https urls without requiring encryption on the IIS instance.

I'm willing to do a pull request if someone could point me in the right direction.

Photo of Jeff Mikels Submitted by Jeff Mikels, Lafayette Community Church  ·   ·  Core
Login to add a comment...