0

JBosss AS 7 をドメイン モードで実行しています。変更を host.xml に適用すると、次のエラーが表示されました。

[Host Controller] Message: JBAS014789: Unexpected element '{urn:jboss:domain:1.2}socket-binding' が見つかりました

このリファレンスガイドに従いました。

https://community.jboss.org/wiki/SecuringAdministrationConsoleWithHttps

ホスト.xml

<management>
        <security-realms>
            <security-realm name="ManagementRealm">
                <authentication>
                    <properties path="mgmt-users.properties" relative-to="jboss.domain.config.dir"/>
                </authentication>
<server-identities>
<ssl>
<keystore path=".keystore" relative-to="jboss.home.dir" password="changeit"/>
</ssl>
</server-identities>
            </security-realm>
            <security-realm name="ApplicationRealm">
                <authentication>
                    <properties path="application-users.properties" relative-to="jboss.domain.config.dir" />
                </authentication>
            </security-realm>
        </security-realms>
        <management-interfaces>
            <native-interface security-realm="ManagementRealm">
                <socket interface="management" port="${jboss.management.native.port:9999}"/>
            </native-interface>
            <http-interface security-realm="ManagementRealm">
                <socket interface="management" port="${jboss.management.http.port:9990}"/>
                <socket-binding https="management-https"/>
            </http-interface>
        </management-interfaces>
    </management>

ありがとう!

4

2 に答える 2

0

スタック トレース ParseError at に示されているように、特定の行と列の構成ファイルを正しく変更します。[row,col]:[x,y]

于 2013-12-26T00:26:00.250 に答える
0

私は同じ問題に対処してきましたが、いくつかの理由で注意が必要です。私を動かしたstandalone.xmlへの変更点をリストしました。参照するキーストアを作成する必要があることは言うまでもありません。

この設定で最も問題となる部分は<ssl>management.security-realms.security-realm<ssl>の要素が で要素を設定する場合とは異なる構文を使用すること<subsystem xmlns="urn:jboss:domain:web:1.1" default-virtual-server="default-host">です。対比を示すために、ここに両方の​​要素をリストしました。コンソールを保護するために Web サービスの SSL を実際に構成する必要はありません。それらがどのように異なるかを示すために、詳細を追加しました。


    <management>
    <security-realms>
        <security-realm name="ManagementRealm">
            <server-identities>
                <ssl protocol="TLS">
                  <keystore path="/my/path/to/certs/my_cert.jks" keystore-password="mypass"/>
                </ssl>
            </server-identities>
            <authentication>
                <properties path="mgmt-users.properties" relative-to="jboss.server.config.dir"/>
            </authentication>
        </security-realm>
    </security-realms>
    <management-interfaces>
        <native-interface security-realm="ManagementRealm">
            <socket-binding native="management-native"/>
        </native-interface>
        <http-interface security-realm="ManagementRealm">
            <socket-binding http="management-console-https"/>
        </http-interface>
    </management-interfaces>
</management>
.
.
.
<profile>
.
.
.
<subsystem xmlns="urn:jboss:domain:web:1.1" default-virtual-server="default-host">
    <connector name="http" protocol="HTTP/1.1" scheme="http" socket-binding="http"/>
    <connector name="https" protocol="HTTP/1.1" scheme="https" socket-binding="https" enable-lookups="false" secure="true">
        <ssl password="mypass" certificate-key-file="/my/path/to/certs/my_cert.jks" protocol="TLSv1" verify-client="false" certificate-file="/my/path/to/certs/my_cert.jks"/>
    </connector>
    <virtual-server name="default-host" enable-welcome-root="true">
        <alias name="localhost"/>
        <alias name="example.com"/>
    </virtual-server>
</subsystem>
.
.
.
<socket-binding-group name="standard-sockets" default-interface="public" port-offset="${jboss.socket.binding.port-offset:0}">
    <socket-binding name="http" port="8080"/>
    <socket-binding name="https" port="8443"/>
.
.
.
    <socket-binding name="management-native" interface="management" port="${jboss.management.native.port:9999}"/>
    <socket-binding name="management-console-https" interface="management" port="${jboss.management.console.https.port:9991}"/>


また、使用しないため、古いソケット バインディングを削除します。


<socket-binding name="management-http" interface="management" port="${jboss.management.http.port:9990}"/>



これが役立つことを願っています。

于 2014-01-04T02:34:02.407 に答える