SSL Redirect

darkware.org PHP, Projects SSL Redirect
SSL Redirect

PHP Projects

SSL Redirect

Posted By darkware

SSL Redirect is a fairly simple WordPress plugin designed to redirect HTTP connections to an equivalent HTTPS URL in an efficient way with minimal external configuration required.

Features / Functionality

  • Requires no modifications to server configuration.
  • Functions on individual sites in a multisite installation without impacting other sites.
  • Performs SEO-friendly HTTP 301 redirections, rather than relying on Javascript or <META> tag interpretation.
  • Supports a strict opt-in list of domains where SSL redirection is applied.
  • Detects direct SSL connections as well as connections proxied through a remote SSL termination service.

Download / Browse / Clone

Git @ Darkware: darkware:/projects/WPT/repos/ssl-redirect

This is the development repository for SSL Redirect. It is the most likely to contain the most recent code changes. It’s also the most likely to include minor bugs.

Github: github:darkware-dev/ssl-redirect

This is a more stable version of the Darkware git repository. It receives pushes from the same source, but the most recent versions are likely to see more testing.

Motivation

Does the world really need another plugin to handle SSL redirections in WordPress. Maybe. In searching for something simple to handle HTTP-to-HTTPS migration for another site, I ran across a number of plugins that seemed to accomplish what I wanted. However, none of them seemed to miss the mark in one place or another.

Most wanted to use Apache mod_rewrite to do the redirection. That’s a fantastic solution … if you’re using Apache. My server is running Nginx with php-fpm. Of the plugins that didn’t rely on mod_rewrite, many of them opted for Javascript redirection. That does work, but it’s not the clean, transparent solution that I wanted. And finally, the couple I found that covered both of those, still required a little tweaking to detect the SSL connection since the site I was working with was behind an SSL-terminating cache.

While it did seem like a rather low-probability situation, the problem didn’t feel complex and there was no reason why the solution for this minor case wouldn’t be applicable to the much larger audience. A few hours of work later, I had something that covered most of what I wanted.

Tagged , , ,

Written by darkware