Skip to content

Internal Server Error when mod_shib is not installed #60

Closed

Description

@jrchamp

This came up on the WordPress plugin support forum: https://wordpress.org/support/topic/sibboleth-installation-internal-server-error/

It's fair to say that we do expect people to install the mod_shib package before installing our plugin, but it might also be good to not take their site offline. In that ticket, I suggest wrapping the Shibboleth configuration directives in an IfModule block, as in:

<IfModule mod_shib>
    AuthType shibboleth
    Require shibboleth
</IfModule>

Is this something that we would be interested in adding to the core plugin? If so, I'd be happy to create a pull request.

Activity

  1. michaelryanmcneill commented on May 28, 2020

    @michaelryanmcneill
    Owner

    I think that is a great idea and is something we probably should do in the first place. If you have time @jrchamp and want to put this into a quick PR, that'd be great. If not, I'll try to take care of it next week during my routine maintenance work.

  2. added a commit that references this issue on Jun 17, 2020
    b4ecfbb
  3. michaelryanmcneill commented on Jun 17, 2020

    @michaelryanmcneill
    Owner

    This will be implemented in the pending 2.2 release. Thanks for the suggestion @jrchamp!

  4. added this to the 2.2 milestone on Jun 17, 2020
  5. michaelryanmcneill commented on Jun 18, 2020

    @michaelryanmcneill
    Owner

    Reopened because of the issues found in #64. Once we hear back from the reporters, we can attempt to resolve the issue in cPanel environments.

  6. modified the milestones: 2.2, 2.2.2 on Jun 18, 2020
  7. jdpurdyvi commented on Jun 18, 2020

    @jdpurdyvi

    From my sysadmin

    Shibboleth runs as a daemon, outside of apache.

    That said, php is also running with fcgi and not mod_php

  8. 1 remaining item

  9. jdpurdyvi commented on Jun 18, 2020

    @jdpurdyvi

    PHP is running with fcgi so apache_get_modules() is not available e.g.
    [18-Jun-2020 20:39:34 UTC] PHP Fatal error: Uncaught Error: Call to undefined function apache_get_modules() in /my/wp/path:57

  10. michaelryanmcneill commented on Jun 18, 2020

    @michaelryanmcneill
    Owner

    Haha, of course it is. Can you try seeing if the module name shows up in phpinfo()?

  11. jdpurdyvi commented on Jun 19, 2020

    @jdpurdyvi

    Short answer is no. But I sent you the full output of phpinfo() privately @michaelryanmcneill in case you want to verify.

  12. dandalpiaz commented on Jun 20, 2020

    @dandalpiaz
    Contributor

    The admins for our cPanel host said that they were able to make things work by using the filename instead of the identifier for the module: <IfModule mod_shib.cpp>

    Not sure if that will be the case for all cPanel environments though.

  13. jrchamp commented on Jun 21, 2020

    @jrchamp
    CollaboratorAuthor

    mod_shib.cpp makes sense because the Shibboleth SP module is written in C++.

  14. added a commit that references this issue on Jun 21, 2020
    7affc23
  15. michaelryanmcneill commented on Jun 21, 2020

    @michaelryanmcneill
    Owner

    Just to be safe, I've gone ahead and added mod_shib.c and mod_shib.cpp in addition to mod_shib. I've committed it with 7affc23 and I've created a draft release. If @dandalpiaz, @jdpurdyvi, and @jrchamp (and others) could test it out before I release it to the WordPress.org repository, that would be wonderful. I want to try and avoid breaking things for others again if possible. If I don't hear anything back I'll release it on Tuesday afternoon.

  16. jrchamp commented on Jun 21, 2020

    @jrchamp
    CollaboratorAuthor

    I tested this configuration on my test system and it's working for me, but the previous change did also.

  17. michaelryanmcneill commented on Jun 21, 2020

    @michaelryanmcneill
    Owner

    Thanks @jrchamp!

  18. jdpurdyvi commented on Jun 21, 2020

    @jdpurdyvi

    mod_shib.cpp is what works on my host. Thanks!

  19. dandalpiaz commented on Jun 22, 2020

    @dandalpiaz
    Contributor

    The mod_shib.cpp conditional is working on our cPanel host as well. Thanks @michaelryanmcneill !

  20. michaelryanmcneill commented on Jun 22, 2020

    @michaelryanmcneill
    Owner

    Great, with these confirmations, I'll merge these changes and push the release out.

  21. added a commit that references this issue on Jun 22, 2020
    0c0f711
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions