Requests without any Drupal path, such as http://mydomain.com/index.php, are currently rejected.
It works without the "index.php", but I think this behavior is not desired.

The same problem is maybe more severe for "http://mydomain.com/cron.php?cron_key=..."
(Note that this script is supposed to be executed from curl without a login.)

The solution is actually very simple:

function fast_404_path_check() {
  $valid = TRUE;

  //if (variable_get('fast_404_path_check', FALSE) && isset($_GET['q'])) { //old
  if (variable_get('fast_404_path_check', FALSE) && !empty($_GET['q'])) { //new

This is also blocking me from executing other scripts from shell, so I would really appreciate a fix.

Comments

soyarma’s picture

Status: Active » Closed (fixed)

Agreed, that's a significant issue. I've updated it in the 7.x dev branch and will be cutting a new release for 6.x and 7.x shortly.

acrollet’s picture

Status: Closed (fixed) » Needs review
StatusFileSize
new523 bytes

I hate to say it, but this fix seems not to have made it into -dev - perhaps it was never pushed? At any rate, I'm attaching the fix in #1 as a patch.

mr.baileys’s picture

Status: Needs review » Fixed

It looks like the 7.x-1.x-dev branch is unused, and new releases (and the dev release on the project page) are instead tagged on the 7.x-1.x branch (no -dev). The fix does seem to be present in that branch, and in the downloadable dev snapshot, so tentatively moving back to fixed.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

  • Commit d9c99c0 on 7.x-1.x, 8.x-1.x by soyarma:
    #1297098 - Change checking of $_GET['q'] in path check function to look...