Im trying to connecting LDAP from my loginPage but i always get the errorPage immediately after login. Im using liberty profile 8.5.5.5 and eclipse luna
This is my form
<form id="formGeneral" class="centered" method="post" action="j_security_check"> ....
This is my web xml
....
<welcome-file-list>
<welcome-file>/loginPage.jsf</welcome-file>
</welcome-file-list>
<security-constraint>
<web-resource-collection>
<web-resource-name>
GestionArchivosSecurityConstraint
</web-resource-name>
<url-pattern>/pages/*</url-pattern>
<http-method>GET</http-method>
<http-method>POST</http-method>
</web-resource-collection>
<auth-constraint>
<description>
Sólo usuarios con rol "*" pueden entrar a la aplicación
</description>
<role-name>*</role-name>
</auth-constraint>
</security-constraint>
<security-role>
<role-name>*</role-name>
</security-role>
<login-config>
<auth-method>FORM</auth-method>
<realm-name>ldap</realm-name>
<form-login-config>
<form-login-page>/loginPage.jsf</form-login-page>
<form-error-page>/loginPage.jsf?error=true</form-error-page>
</form-login-config>
</login-config>
.....
And this is my server.xml`
<ldapRegistry
baseDN="DC=rimacdemo,DC=com,DC=pe"
bindDN="CN=xxxxxxxxxxx,OU=Cuentas Servicio,DC=rimacdemo,DC=com,DC=pe"
bindPassword="xxxxxxxx"
connectTimeout="15m"
host="xxxxxxxxx"
id="ldap"
ignoreCase="true"
ldapType="Microsoft Active Directory"
port="xxx"
realm="SampleLdapADRealm"
returnToPrimaryServer="false"
searchTimeout="20m">
</ldapRegistry>
And i always get the error page setting in the web.xml configuration So please somene explain me what does the "j_security_check".. I dont know exactly how it connects with the LDAP to get the error page and i don't know if im making the correct configuration
And please, explain me all the meanings of the tags in the web.xml, because im reading but i don't understanding the most of the tags.
If someone can help me with the entire flow to follow i'll be more than grateful. Im only need to authenticate no more than that, i dont need to read properties and dont need to validate groups, only check if the user and password are corrects.
Aucun commentaire:
Enregistrer un commentaire