I noticed I was consistently getting 404 errors from the Soap exchange on the shibboleth side. As far as I can read the code, there are multiple problems with the code:
a) line 34: the use of HTTP_RAW_POST_DATA most probably needs always_populate_raw_post_data in php.ini . And using HTTP_RAW_POST_DATA is deprecated in favour of using php://input
b) from line 168: the database session handling has to get rewritten (there's a TODO tag there)
There might be other issues but all-in-all, the current status on our side is that I can't have this code working with shibboleth 2.4.