[jboss-user] [Security & JAAS/JBoss] - Re: Where the customized login module should be deployed
piotr.koper
do-not-reply at jboss.com
Mon Oct 29 10:51:25 EDT 2007
If you have JAR with your own LoginModule you can put it in $JBOSS_HOME/server/default/lib and modify login-config.xml from $JBOSS_HOME/server/default/conf. This is first method i know. Ofcourse each modyfications requires server restart.
You can also in EAR file.
| EAR
| |
| +-- [lib]
| +-- [META-INF]
| | |
| | +-- application.xml
| | +-- jboss-app.xml
| |
| +-- login-config.xml
| +-- login-service.xml
|
application.xml
| <?xml version="1.0" encoding="UTF-8"?>
| <application version="1.5">
| <!-- put jar with your own LoginModule in this directory -->
| <library-directory>lib</library-directory>
|
| <!-- do some other stuff -->
| </application>
|
jboss-app.xml:
| <jboss-app>
| <module>
| <service>login-service.xml</service>
| </module>
| </jboss-app>
|
login-config.xml
| <?xml version="1.0" encoding="UTF-8"?>
| <policy>
| <!-- Your domain -->
| <application-policy name="my-domain">
| <authentication>
| <login-module code="my.domain.com.LM" flag="required">
| </login-module>
| </authentication>
| </application-policy>
| </policy>
|
login-service.xml
| <?xml version="1.0" encoding="UTF-8"?>
| <server>
| <mbean code="org.jboss.security.auth.login.DynamicLoginConfig"
| name="MyLogin:service=ExampleREOLoginConfigService">
| <attribute name="AuthConfig">login-config.xml</attribute>
| <depends optional-attribute-name="LoginConfigService">
| jboss.security:service=XMLLoginConfig
| </depends>
| <depends optional-attribute-name="SecurityManagerService">
| jboss.security:service=JaasSecurityManager
| </depends>
| </mbean>
| </server>
|
I hope this helps :-)
piotr.koper
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4099862#4099862
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4099862
More information about the jboss-user
mailing list