-
Type:
Bug
-
Status: Closed
-
Resolution: Fixed
-
Affects Version/s: 6.2.X EE, 7.0.0 M5
-
Fix Version/s: 6.2.X EE, 7.0.0 Beta 7
-
Component/s: Pages > Page Administration, Sites Administration > Sites
-
Branch Version/s:6.2.x
-
Backported to Branch:Committed
-
Fix Priority:3
-
Liferay Contributor's Agreement:Accept
-
Git Pull Request:
- Create a page called 'pathproxy_sitename'
- Access the page via its friendly url: http://localhost:8080/pathproxy_sitename, see it is working
- Stop portal
- Set portal.proxy.path=/pathproxy
- Set up apache 2.2 virtualhost:
<VirtualHost *> ProxyPreserveHost On ProxyPass /pathproxy ajp://localhost:8009 ProxyPassReverse /pathproxy ajp://localhost:8009 </VirtualHost>
- Run apache httpd
- Restart portal
- Try to access http://localhost/pathproxy/pathproxy_sitename
Expected result: Browser loads test page
Details:
VirtualHostFilter.java
if (Validator.isNotNull(contextPath) &&
friendlyURL.contains(contextPath)) {
friendlyURL = friendlyURL.substring(contextPath.length());
}
if friendlyURL is "/company_", and contextPath is "/company" friendlyURL.contains(contextPath) is true
and so the friendlyURL gets shortened to _ which is wrong.