Summary

In the 1.x version of simplesamlphp/simplesamlphp, the publicly accessible directory is "www" (see https://simplesamlphp.org/docs/1.16/simplesamlphp-modules.html).

Per a change in the master branch of 2.x on January 27, 2023, the directory will now be "public":

Impact

Sites that try to update to simplesamlphp_auth 4.x without changing their configuration will get an authentication failure at the url simplesaml/module.php/saml/sp/saml2-acs.php/default-sp, with the message "File not found."

Proposed change

Although this change is part of the simplesamlphp library, rather than the simplesamlphp_auth module, Drupal sites transitioning from the 3.x version of simplesamlphp_auth to 4.x (in conjunction with the transition from Drupal 9 to Drupal 10) will likely need to make a change to their configuration.

This module should call out this change as part of documentation on updating from simplesamlphp_auth 3.x to 4.x, and it should link to the relevant documentation in https://github.com/simplesamlphp/simplesamlphp/blob/master/docs/simplesa...

This issue will be relevant for most sites that use Composer to retrieve this module (which should be most sites these days). Discussion of using a symlink to point to the (previously) www (now) public directory is found in the current README at https://git.drupalcode.org/project/simplesamlphp_auth/-/blob/8.x-3.x/REA... and, for example, can be found in #2915568: Installing the module causes exception and Drupal whitescreen.

Comments

mark_fullmer created an issue. See original summary.

mark_fullmer’s picture

Title: Document that simplesamlphp 2.x directory change (www to public) » Document simplesamlphp 2.x directory change (www to public)
mark_fullmer’s picture

Issue summary: View changes
mark_fullmer’s picture

Issue summary: View changes
mark_fullmer’s picture

Issue summary: View changes
robbdavis’s picture

I'm getting this 'file not found' errror at simplesaml/module.php/saml/sp/saml2-acs.php/default-sp.

But the docs above are not clear on how or where to fix this in config.

What needs to change exactly?

drupalgreenhorn’s picture

Hi, I have exactly the same issue,
1.I'm getting this 'file not found' errror at
"simplesaml/module.php/saml/sp/saml2-acs.php/default-sp", this is the endpoints my simplesamlphp SPprovided to my shibboleth IDP.
2. I am getting 'file not found' errror at
simplesaml/admin/
3. In my local development instance, when I try to pull out the simplesamlphp web interface at /simplesaml/
I am getting "Forbidden You don't have permission to access this resource."

I have read the links that Mark provided a couple of times. The docs above are not clear on how or where to fix this in config.

What needs to change exactly? Seems like I need to add some config parameters in setting.php file per this www to public folder change.

Will you please further clarify what paramaters are needed per this change?

Thank you

justcaldwell’s picture

This can vary depending on where/how the simplesamlphp lib is installed but, given a typical drupal project structure like:

  project_root
    ...
    /docroot
    ...
    /vendor
      /simplesamlphp

where /docroot (or /www, /web, etc.) is your public web folder. For previous versions you have a symlink named simplesaml that points to the www directory in the simplesamlphp vendor lib:

project_root/docroot/simplesaml -> ../vendor/simplesamlphp/simplesamlphp/www

In the latest version, www has been renamed to public, so your symlink must be updated accordingly:

project_root/docroot/simplesaml -> ../vendor/simplesamlphp/simplesamlphp/public

Again, this is a typical setup — adjust according to your project structure — and there are other ways as well.

Hope that helps!

drupalgreenhorn’s picture

justcaldwell

Thank you so much for such detailed infor.

per this https://github.com/simplesamlphp/simplesamlphp/blob/master/docs/simplesa...
I found that in my drupal project, I do have a symlink under
/web/
and I modified it as
/web% ln -sf ../vendor/simplesamlphp/simplesamlphp/public simplesaml

which works!

Thank you again!

robbdavis’s picture

Yes. Thanks @justcladwell!

For those on Pantehon, fyi, in the config.php, you'll need to set the 'loggingdir' to null.
'loggingdir' => NULL,

swetaranjan’s picture

I am also getting the same issue. However after changing to WWW , still its not working. Any help ??