0

我正在使用 Jboss4.2.2 配置使用基于密码的加密 (PBE) 的配置身份,你能告诉我 server.password 的用途以及如何创建它。

项目产品-ds.xml

<local-tx-datasource>
    <jndi-name>mobeeadminDatasource</jndi-name>
            <use-java-context>false</use-java-context>
            <connection-url>jdbc:oracle:thin:@localhost:1521:xe</connection-url>
            <driver-class>oracle.jdbc.OracleDriver</driver-class>

             <security-domain>EncryptedOracleDbRealm</security-domain>
            </local-tx-datasource>
         <mbean code="org.jboss.security.plugins.JaasSecurityDomain"
                     name="jboss.security:service=JaasSecurityDomain,domain=ServerMasterPassword">
          <constructor>
             <arg type="java.lang.String" value="ServerMasterPassword"></arg>
          </constructor>
          <!-- The opaque master password file used to decrypt the encrypted
          database password key -->
          <attribute name="KeyStorePass">{CLASS}org.jboss.security.plugins.FilePassword:${jboss.server.home.dir}/conf/server.password</attribute>
          <attribute name="Salt">mobeeadm</attribute>
          <attribute name="IterationCount">13</attribute>
        </mbean>
        <mbean code="org.jboss.jdbc.HypersonicDatabase"
          name="jboss:service=Hypersonic,database=mobeeadminDatasource">
          <attribute name="Database">mobeeadminDatasource</attribute>
          <attribute name="InProcessMode">true</attribute>
       </mbean>

登录-config.xml

<application-policy name="EncryptedOracleDbRealm">
   <authentication>
      <login-module code= "org.jboss.resource.security.JaasSecurityDomainIdentityLoginModule"
         flag = "required">
         <module-option name="username">kcbuser</module-option>
         <module-option name="password">29gsr5RGZ9cUs5/sDXk81r</module-option>
         <module-option name="managedConnectionFactoryName">
            jboss.jca:service=LocalTxCM,name=mobeeadminDatasource
         </module-option>
         <module-option name="jaasSecurityDomain">
            jboss.security:service=JaasSecurityDomain,domain=ServerMasterPassword
         </module-option>
      </login-module>
   </authentication>
</application-policy>
4

1 回答 1

0

您可以在此处找到 PBE 设置的详细说明和说明

于 2012-10-03T18:30:35.887 回答