Environment Context :
Application is installed on :
https://server.domain/my/application/
But accessed via reverse proxy by :
https://app.domain/
Problem :
The library, on server.domain returns :
The response was received at https://app.domain/my/application/login_sso instead of https://app.domain/login_sso
It seems that there's no way to shift installation directory (or a part of it) from $_SERVER['SCRIPT_NAME'] or $_SERVER['REQUEST_URI'] so $currentURL (in Response::isValid()) is wrong.
Solution :
- add a setting "localUrlPath" (with getter and setter)
- add attribute, getter and setter for localpath in Utils
- add a function buildWithLocalURLPath($info) in Utils which shift local path from $info
- call self::buildWithLocalURLPath(...) in Utils::getSelfURLNoQuery() and Utils::getSelfRoutedURLNoQuery() before calling self::buildWithBaseURLPath(...)
- call Utils::setLocalPath($this->_settings->getLocalUrlPath()) in Response constructor
Thanks for your attention