on 2018 Feb 21 10:24 PM
We're doing a migration to Hybris 6.5, and while trying to login in the storefront, we are redirected to the path https://urreab2b.local:9002/urreab2bstorefront/urreab2b/es/USD/null instead of https://urreab2b.local:9002/urreab2bstorefront/urreab2b/es/USD/j_spring_security_check.
Due to this we get a error message "[hybrisHTTP3] [PageNotFound] Request method 'POST' not supported", which makes sense since the login page in the storefront isn't mapped to null.
We checked in accountReturningCustomerLogin.jsp and the value for loginActionUrl is set like this:
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="user" tagdir="/WEB-INF/tags/responsive/user"%>
<c:url value="/j_spring_security_check" var="loginActionUrl" />
<div class="login-section">
<user:login actionNameKey="login.login" action="${loginActionUrl}" />
</div>
But whenever we open the login page in the storefront the action value for the login form is set to null:
We don't understand why the value for the login action url is being overwritten nor who is responsible for this, we've even tried to modify directly the action inside login.tag to /j_spring_security_check but even modifying the tag directly doesn't stop the action from being set to null.
Another thing we tried was to modify the action value using Chrome Developer Console, and although we are redirected to the URL https://urreab2b.local:9002/urreab2bstorefront/urreab2b/es/USD/j_spring_security_check, only then the login page is redirected correctly.
We printed on the JSP the value for action and the value it has is /urreab2bstorefront/urreab2b/es/USD/j_spring_security_check, so the value is arriving to the JSP correctly but the form is not taking it.
Does anyone know what might be the cause? Is it something Spring related or something related to Hybris configuration or something else?
Request clarification before answering.
I resolved this issue by correction to class DefaultRequestDataProcessor - where by removing accidental override of the processAction() method and also wrong implementation of method processAction() where i was returning null.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Agustin, I got exactly same issue while migrating from v5.4 to v6.6. did you find any solution.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you just verify one small thing if you make any changes in login.tag then is it reflecting on UI as well. Because I remember making a stupid mistake of changing in desktop jsp and verifying in responsive view.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Agustin - please let me know which version you are migrating from and which version to
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Agustin,
Depending on your previous hybris version and whether performing either a technical upgrade (core only) or functional upgrade (core + accelerator) - you could be still using Spring Version 3.x.x.
Please check that you are making use of Spring 4.x.x. and retest if that resolves the issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
how can we verify the spring version our enviroment is using? this migration is something another company started but was passed on to us so probably they didn't update the spring version.
I just checked the lib folder in storefront and there's a spring-security-taglibs-3.1.1.RELEASE.jar, how can we update it?
I tried deleting spring-security-taglibs-3.1.1.RELEASE.d after an ant clean all and restarting my Hybris server I got several JasperException errors, with messages like org.apache.jasper.JasperException: /WEB-INF/tags/desktop/common/header/header.tag (lÃnea: 42, columna: 3) Attribute ifAnyGranted invalid for tag according to TLD. We checked the tag and indeed it was using deprecated attribute, we replaced it with the latest header.tag but still the action is being set to null.
User | Count |
---|---|
12 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.