I am trying to force all pages in drupal to be over HTTPS.

In order to do this at present, here is my current config:

drush vget securepages_

securepages_switch: 0
securepages_basepath: ""
securepages_basepath_ssl: ""
securepages_secure: "0"
securepages_pages: ""
securepages_ignore: ""
securepages_roles: Array
(
    [2] => 2
    [4] => 0
    [7] => 0
    [3] => 0
    [10] => 0
    [8] => 0
    [11] => 0
)

securepages_enable: 1

So as you can see above, I set "Make secure every page except the listed pages." to true and then left "Pages" empty. There is a flaw in the logic of securepages.module that will cause $pages to be empty, and thus the rule never matches.

Attached is a patch that goes someway to making the text labels of the radio buttons match the functionality

CommentFileSizeAuthor
securepages-ssl-all-the-things.patch1.11 KBwiifm

Comments

acbramley’s picture

+1 confirming this patch fixes the issue, the only way previously to make all pages ssl was to put something in the pages setting.

donwinchell’s picture

when trying this patch as per below I get the following:

patch securepages.module  < securepages-ssl-all-the-things_0.patch 
patching file securepages.module
Hunk #1 FAILED at 43.
1 out of 1 hunk FAILED -- saving rejects to file securepages.module.rej
patching file securepages.module

Anyone else get this or can explain what is taking place ?
(thanks for the module and the work on patching)

wiifm’s picture

@donwinchell you need to use

patch -p1 < securepages-ssl-all-the-things_0.patch

As the path is prefixed

dxx’s picture

Issue summary: View changes

Patch solved my issue! (in case of forcing all pages to HTTPS)

joelcollinsdc’s picture

Took me forever to figure out why securepages stopped working after upgrading to beta2. Please commit this!!!

joelcollinsdc’s picture

Status: Needs review » Reviewed & tested by the community
joelcollinsdc’s picture

Status: Reviewed & tested by the community » Needs work

Actually I think this patch should be modified to handle multiple line empty strings. We had been on securepages beta 1 and securepages_pages is set to a single line return character

(shows up as

securepages_pages: '
'
in drush...)

This causes this patch to be ineffictive.

joelcollinsdc’s picture

This issue is attempting to resolve the same issue: #566632: "Make secure every page" does not work when empty

hussainweb’s picture