-
1. Re: Migrating from Weblogic to JBoss : problem with weapp au
djeanprost Aug 2, 2005 11:01 AM (in response to djeanprost)I made a dump of the request.getUserPrincipal(). Here it is :
14:53:46,846 INFO [STDOUT] <debut de org.jboss.web.tomcat.security.JBossGenericPrincipal>
name = djeanprost
password = null
realm = org.jboss.web.tomcat.security.JBossSecurityMgrRealm@1a847df
roles =
<debut de tableau>
EPArchitectureSI
EPEncadrementIntermediaire
EPPoleCompetences
LorisIntranet
absenteismeIntranet
ameliorationpermanenteIntranet
barGEDIntranet
basedocCMECDPIntranet
basedocCMEIntranet
basedocGRHIntranet
basedocPHSIntranet
basedocPSOIntranet
basedocQCOIntranet
collaborateur
collaborateurUtilisateurVersions
declarationAbsenteismeIntranet
dossiersStatistiquesIntranet
ficheAbsenteisme
intendance
outilsCommerciaux
outilsPedagogiquesIntranet
utilisateurRelancesIntranet
<fin de tableau>
authPrincipal = djeanprost
callerPrincipal = djeanprost
credentials = password1
subject = Objet :
Principal : djeanprost
Principal : Roles(members:absenteismeIntranet,basedocCMECDPIntranet,utilisateurRelancesIntranet,outilsCommerciaux,collaborateurUtilisateurVers
ions,outilsPedagogiquesIntranet,ficheAbsenteisme,basedocPHSIntranet,basedocCMEIntranet,intendance,dossiersStatistiquesIntranet,EPEncadrementIntermedia
ire,basedocGRHIntranet,basedocPSOIntranet,declarationAbsenteismeIntranet,barGEDIntranet,EPPoleCompetences,EPArchitectureSI,LorisIntranet,ameliorationp
ermanenteIntranet,collaborateur,basedocQCOIntranet)
userRoles =
<debut de liste>
absenteismeIntranet
basedocCMECDPIntranet
utilisateurRelancesIntranet
outilsCommerciaux
collaborateurUtilisateurVersions
outilsPedagogiquesIntranet
ficheAbsenteisme
basedocPHSIntranet
basedocCMEIntranet
intendance
dossiersStatistiquesIntranet
EPEncadrementIntermediaire
basedocGRHIntranet
basedocPSOIntranet
barGEDIntranet
declarationAbsenteismeIntranet
EPPoleCompetences
EPArchitectureSI
LorisIntranet
ameliorationpermanenteIntranet
basedocQCOIntranet
collaborateur
<fin de liste>
<fin de org.jboss.web.tomcat.security.JBossGenericPrincipal>
You can see that my principal doesn't have the role utilisateurCollaborateur although I specified role-mapping with jboss-web.xml which is below :
<jboss-web>
<security-domain>java:/jaas/djp</security-domain>
<context-root>accueil</context-root>
<security-role>
<role-name>utilisateurCollaborateur</role-name>
<principal-name>collaborateur</principal-name>
</security-role>
</jboss-web>
Here is my web.xml (a subset)
<web-app>
<servlet-name>mainServlet</servlet-name>
<servlet-class>com.dexia.common.gui.WebServlet</servlet-class>
<init-param>
<param-name>webAppClassName</param-name>
<param-value>com.dexia.sofaxis.accueil.gui.AccueilGUI</param-value>
</init-param>
<servlet-mapping>
...
</servlet-mapping>
<security-constraint>
<web-resource-collection>
<web-resource-name>protected</web-resource-name>
<url-pattern>/services</url-pattern>
<url-pattern>/main.jsp</url-pattern>
<http-method>GET</http-method>
<http-method>POST</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>utilisateurCollaborateur</role-name>
</auth-constraint>
</security-constraint>
<login-config>
<auth-method>FORM</auth-method>
<form-login-config>
<form-login-page>/connexion.jsp</form-login-page>
<form-error-page>/echecConnexion.jsp</form-error-page>
</form-login-config>
</login-config>
<security-role>
<role-name>utilisateurCollaborateur</role-name>
</security-role>
...
Does anyone has a clue ? -
2. Re: Migrating from Weblogic to JBoss : problem with weapp au
starksm64 Aug 3, 2005 12:42 PM (in response to djeanprost)Ignored due to duplicate posting.