JBoss-4.2.2.GA安全机制
来源:互联网 发布:数组pop push shift 编辑:程序博客网 时间:2024/06/06 01:41
JBoss-
1. 设置jmx-console安全机制
a) 编辑deploy/jmx-console.war/WEB-INF/jboss-web.xml,搜寻到如下内容,并取消注释
<security-domain>java:/jaas/jmx-console</security-domain>
b) 编辑deploy/jmx-console.war/WEB-INF/web.xml,搜寻到如下内容,并取消注释
<security-constraint>
<web-resource-collection>
<web-resource-name>HtmlAdaptor</web-resource-name>
<description>An example security config that only allows users with the role JBossAdmin to access the HTML JMX console web application
</description>
<url-pattern>/*</url-pattern>
<http-method>GET</http-method>
<http-method>POST</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>JBossAdmin</role-name>
</auth-constraint>
</security-constraint>
c) 打开conf/login-config.xml,搜寻到如下内容,检查usersProperties 和rolesProperties 对应的文件路径,默认是conf/props/jmx-console-users.properties和conf/props/jmx-console-roles.properties
<application-policy name = "jmx-console">
<authentication>
<login-module code="org.jboss.security.auth.spi.UsersRolesLoginModule"
flag = "required">
<module-option name="usersProperties">props/jmx-console-users.properties</module-option>
<module-option name="rolesProperties">props/jmx-console-roles.properties</module-option>
</login-module>
</authentication>
</application-policy>
d) 编辑conf/props/jmx-console-users.properties,设置有权限访问jmx-console的用户和密码,格式为“用户名=密码”,默认该文件内容为admin=admin
e) 编辑conf/props/jmx-console-roles.properties,设置上一步定义的用户角色,格式为“用户名=角色1,角色
2. 设置web-console安全机制
a) 编辑deploy/management/console-mgr.sar/web-console.war/WEB-INF/jboss-web.xml,搜寻到如下内容,并取消注释
<security-domain>java:/jaas/web-console</security-domain>
b) 编辑deploy/management/console-mgr.sar/web-console.war/WEB-INF/web.xml,搜寻到如下内容,并取消注释
<security-constraint>
<web-resource-collection>
<web-resource-name>HtmlAdaptor</web-resource-name>
<description>An example security config that only allows users with the role JBossAdmin to access the HTML JMX console web application
</description>
<url-pattern>/*</url-pattern>
<http-method>GET</http-method>
<http-method>POST</http-method>
</web-resource-collection>
<auth-constraint>
<role-name>JBossAdmin</role-name>
</auth-constraint>
</security-constraint>
c) 打开conf/login-config.xml,搜寻到如下内容,检查usersProperties 和rolesProperties 对应的文件路径,默认是deploy/management/console-mgr.sar/web-console.war/WEB-INF/classes/web-console-users.properties和deploy/management/console-mgr.sar/web-console.war/WEB-INF/classes/props/web-console-roles.properties
<application-policy name = "web-console">
<authentication>
<login-module code="org.jboss.security.auth.spi.UsersRolesLoginModule"
flag = "required">
<module-option name="usersProperties">web-console-users.properties</module-option>
<module-option name="rolesProperties">web-console-roles.properties</module-option>
</login-module>
</authentication>
</application-policy>
d) 编辑deploy/management/console-mgr.sar/web-console.war/WEB-INF/classes/web-console-users.properties,设置有权限访问web-console的用户和密码,格式为“用户名=密码”,默认该文件内容为admin=admin
e) 编辑deploy/management/console-mgr.sar/web-console.war/WEB-INF/classes/web-console-roles.properties,设置上一步定义的用户角色,格式为“用户名=角色1,角色
配置完成,重启JBoss
- JBoss-4.2.2.GA安全机制
- jboss-4.2.2.GA中配置数据源详细步骤
- jboss-4.2.2.GA的发端口的配置文件
- 关于jboss-4.2.2.GA的连接端口更改――Alter the Connector Port of jboss-4.2.2.GA
- jboss 4.2GA Ip无法访问的问题
- jboss-4.2.3.GA 配置JMS集群
- 在JBoss AS 4.2.2.GA上部署JBPM3.2.2 web console
- 在JBoss AS 4.2.2.GA上部署JBPM3.2.2 web console
- java.lang.OutOfMemoryError: PermGen space(jboss 4.2.3.GA)
- JBoss Application Server 4.2.1 GA启动顺序
- JBoss-4.2.3 GA 部署的时候注意jdk版本
- JBoss Application Server 4.2.1 GA启动顺序 (转)
- Jboss 4.2.2.GA启动后只能从本机访问,不能从远程访问的解决办法
- jboss 4.2.3.GA端口号修改,同一台机器上运行多个jboss
- JBoss Portal 2.4GA发布
- Jboss 5.1.0.GA下载
- JBOSS 5.0GA 配置布署
- JBoss调优(jboss-5.1.0.GA)
- BEA WebLogic Server 学习笔记(2)
- 学java得这样学,学习东西确实也得这样
- 如何通过使用 VisualC # .NET /VB.NET 向打印机发送数据/控制命令
- [程序员必看]请不要做浮躁的人
- .NET中class和struct的区别
- JBoss-4.2.2.GA安全机制
- 在J2EE环境中使用Quartz企业级计划调度器(1)
- 在J2EE环境中使用Quartz企业级计划调度器(2)
- 使用JOTM为Servlets增加事务支持(4)
- 大家好
- jsp系列学习:jsp与javaBean的使用,用javaBean来封装
- struts开发实践—实用小贴士(上)
- struts开发实践—实用小贴士(下)
- WinCVS简明操作指南