jboss7.x - JBoss7 Web SSO (Non-Clustered) -


i trying configure single-sign-on in jboss7.

security-domain in standalone.xml:

<security-domain name="my_auth">    <authentication>       <login-module code="database" flag="required">          <module-option name="dsjndiname" value="java:/comp/env/myds"/>          <module-option name="principalsquery"              value="select password usertable login_id=?"/>          <module-option name="rolesquery"              value="select user_role usertable login_id=?"/>          <module-option name="hashalgorithm" value="md5"/>          <module-option name="hashencoding" value="hex"/>        </login-module>    </authentication> </security-domain> 

virtual-server in standalone.xml

<virtual-server name="default-host" enable-welcome-root="true">    <alias name="localhost"/>    <sso/> </virtual-server> 

my webapp1 , webapp2's jboss-web.xml

<?xml version="1.0" encoding="iso-8859-1"?> <jboss-web>   <security-domain>my_auth</security-domain> </jboss-web> 

it works fine after configure. has little problem:

when start server , first time login webapp1 or webapp2, webapp not logined. logout first webapp, , login again, works fine.

i tried add attribute reauthenticate="false" , still have same problem.

i have no idea problem, have suggestions?

i think have add sso valve jboss-web.xml also.

the following worked me (jboss 7.1.1)

standalone.xml

<security-domain name="my_auth">    <authentication>       <login-module code="database" flag="required">          <module-option name="dsjndiname" value="java:/comp/env/myds"/>          <module-option name="principalsquery"              value="select password usertable login_id=?"/>          <module-option name="rolesquery"              value="select user_role usertable login_id=?"/>          <module-option name="hashalgorithm" value="md5"/>          <module-option name="hashencoding" value="hex"/>        </login-module>    </authentication>  </security-domain>   ...   <virtual-server name="default-host" enable-welcome-root="false">       ...       <sso reauthenticate="false"/>   </virtual-server> 

jboss-web.xml:

<jboss-web>      <security-domain flushonsessioninvalidation="true">java:/jaas/my_auth</security-domain>     <valve>         <class-name>org.apache.catalina.authenticator.singlesignon</class-name>     </valve>  </jboss-web> 

Comments

Popular posts from this blog

sql - VB.NET Operand type clash: date is incompatible with int error -

SVG stroke-linecap doesn't work for circles in Firefox? -

python - TypeError: Scalar value for argument 'color' is not numeric in openCV -