19.11.2. シングルサインオン用に Cookie ドメインを設定する
SSO バルブが SSO コンテキストを共有できるようにするには、バルブ設定で Cookie ドメインを設定します。次の設定では、
http://app1.xyz.com と http://app2.xyz.comの アプリケーションが、クラスター内の異なるサーバーまたはそれらが使用する仮想ホストで実行されている場合でも、SSO コンテキストを共有できます。関連付けられている複数のエイリアスがあります。
クラスター化された SSO(クラスター化された JBoss EAP インスタンスに対して共有)
CLI の使用 (スタンドアロンモード):
/subsystem=web/virtual-server=default-host/sso=configuration:add(cache-container="web",cache-name="sso")
Standlone.xml または domain.xml を編集し、関連する Web サブシステムに以下を追加します。
<subsystem xmlns="urn:jboss:domain:web:1.1" default-virtual-server="default-host" native="false">
<connector name="http" protocol="HTTP/1.1" scheme="http" socket-binding="http"/>
<virtual-server name="default-host" enable-welcome-root="true">
<alias name="localhost"/>
<alias name="example.com"/>
<sso cache-container="web" cache-name="sso"/> <!--FIXME: ADD this Line-->
</virtual-server>
</subsystem>
非クラスター化 SSO(SSO は Jboss EAP インスタンス内のインスタンスに対してのみ共有されます)
CLI の使用 (スタンドアロンモード):
/subsystem=web/virtual-server=default-host/sso=configuration:add()
Standlone.xml または domain.xml を編集し、関連する Web サブシステムに以下を追加します。
<subsystem xmlns="urn:jboss:domain:web:1.1" default-virtual-server="default-host" native="false">
<connector name="http" protocol="HTTP/1.1" scheme="http" socket-binding="http"/>
<virtual-server name="default-host" enable-welcome-root="true">
<alias name="localhost"/>
<alias name="example.com"/>
<sso/> <!--FIXME: ADD this Line-->
</virtual-server>
</subsystem>
JBoss EAP 6 のシングルサインオン (SSO) 設定には、指定可能なドメイン属性が含まれています。以下に例を示します。
/subsystem=web/virtual-server=default-host/sso=configuration:add(domain="example.com",...)
これにより、次の SSO 設定が追加されます。
<sso domain="example.com"/>