码迷,mamicode.com
首页 > 其他好文 > 详细

jboss7-用户管理

时间:2015-11-14 11:12:55      阅读:455      评论:0      收藏:0      [点我收藏+]

标签:

1、在bin下找到add-user.sh和add-user.bat这分别对应windows和linux系统下的文件

2、用户安全作用域默认有两个,作用域理解为用户组就可以了:ManagementRealm和ApplicationRealm,运行上面提到的脚本会提示你使用那个作用域

3、jboss默认是启动standalone,所以在standalone.xml也能找到如上的两个作用域,如下

<security-realms>
            <security-realm name="ManagementRealm">
                <server-identities>
                    <ssl protocol="TLSv1">
                        <keystore keystore-password="online23" path="wildfly.keystore"/>
                    </ssl>
                </server-identities>
                <authentication>
                    <local default-user="$local" skip-group-loading="true"/>
                    <properties path="mgmt-users.properties" relative-to="jboss.server.config.dir"/>
                </authentication>
                <authorization map-groups-to-roles="false">
                    <properties path="mgmt-groups.properties" relative-to="jboss.server.config.dir"/>
                </authorization>
            </security-realm>
            <security-realm name="ApplicationRealm">
                <authentication>
                    <local allowed-users="*" default-user="$local" skip-group-loading="true"/>
                    <properties path="application-users.properties" relative-to="jboss.server.config.dir"/>
                </authentication>
                <authorization>
                    <properties path="application-roles.properties" relative-to="jboss.server.config.dir"/>
                </authorization>
            </security-realm>
        </security-realms>
4、观察上面配置我们能看到文件
mgmt-users.properties和mgmt-users.properties
如果我们已经添加了用户,会发现这文件里面有我们添加的用户组和用户姓名,但是密码是加密的

5、修改,修改怎么办呢?同样运行如上脚本,就会找到修改办法

技术分享

6、另外,其实有多种方案可以管理用户,也可以直接修改standalone.xml文件,或者启动后登陆也可以管理用户,非推荐方法,自己研究下吧

jboss7-用户管理

标签:

原文地址:http://my.oschina.net/fir01/blog/530268

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!