WSSecurity 原則和連結內容

在 setPolicyType 和 setBinding 指令中使用 attributes 參數,指定 WSSecurity 原則和連結配置的其他配置資訊。應用程式和系統原則集可以使用 WSSecurity 原則和連結配置。

在使用這個主題中的指令之前,請確認您使用 wsadmin 工具的最新版本。 在舊版的 wsadmin 工具中,不支援接受內容物件作為 attributesbindingLocation 參數值的原則集管理指令。 例如,在 6.1.0.x 版節點上,不執行這些指令。

請利用 AdminTask 物件 PolicySetManagement 群組中的下列指令和參數來自訂您的原則集配置。
  • 利用 getPolicyType 和 getBinding 指令的 -attributes 參數來檢視原則和連結配置的內容。 如果要取得屬性,請將內容名稱傳給 getPolicyType 或 getBinding 指令。
  • 利用 setPolicyType 和 setBinding 指令的 -attributes 參數來新增、更新或移除原則和連結配置中的內容。 如果要新增或更新屬性,請指定內容名稱和值。 如果屬性存在,setPolicyType 和 setBinding 指令會更新值,如果屬性不存在,會新增屬性和值。 如果要移除屬性,請將值指定為空字串 ("")。 -attributes 參數會接受內容物件。
註: 如果 -attributes 參數提供的內容名稱或值無效,setPolicyType 和 setBinding 指令會發生失敗,且出現異常狀況。 無效的內容會在 SystemOut.log 檔中,記載為錯誤或警告。 不過,指令異常狀況不一定包含造成異常狀況之內容的詳細資訊。 當 setPolicyType 和 setBinding 指令失敗時,請檢查 SystemOut.log 檔中,是否有任何錯誤和警告訊息指出 -attributes 參數的輸入包含一或多個無效的內容。
註: 這個主題參照一或多個應用程式伺服器日誌檔。 此外,在分散式和 IBM® i 系統上,另外也建議您可以配置伺服器來使用「高效能可延伸記載 (HPEL)」日誌和追蹤基礎架構,而不使用 SystemOut.logSystemErr.log, trace.logactivity.log 檔案。HPEL 與原生 z/OS® 記載機能也可以一起使用。如果您使用 HPEL,則可以從伺服器設定檔 bin 目錄,利用 LogViewer 指令行工具來存取您所有的日誌和追蹤資訊。請參閱有關利用 HPEL 疑難排解應用程式的資訊,以取得更多使用 HPEL 的相關資訊。
適用於轉換使用者 適用於轉換使用者: 在 WebSphere Application Server 7.0 版及更新的版本中,安全模型已加強為以網域為中心的安全模型,而不是基於伺服器的安全模型。 另外,本產品的這個版本也變更了預設廣域安全 (Cell) 層次和預設伺服器層次連結的配置。 在 WebSphere Application Server 6.1 版 Feature Pack for Web Services 中,您可以為 Cell 配置一組預設連結,也可以選擇性地為每部伺服器配置一組預設連結。在 7.0 版及更新的版本中,您可以配置一或多個一般服務提供者連結,以及一或多個一般服務用戶端連結。 在配置一般連結之後,您可以指定其中一個連結作為廣域預設連結。您也可以選擇性指定作為應用程式伺服器或安全網域預設值的一般連結。trns

為了支援混合 Cell 的環境,WebSphere Application Server 支援 7.0 版和 6.1 版連結。 一般的 Cell 層次連結專用於 7.0 版及更新的版本,應用程式特定連結保持應用程式所需要版本。 當使用者建立應用程式專用連結時,應用程式伺服器會判斷供應用程式使用所需要的連結版本。

如果 getPolicyType 或 getBinding 指令中未指定 attributes 參數,指令會傳回所有內容。 如果將局部內容名稱傳給 getPolicyType 或 getBinding 指令,指令會傳回名稱以該局部內容名稱開頭的所有內容。 比方說,如果將 SignatureProtection 傳給 getPolicyType 指令,指令會傳回名稱以 "SignatureProtection" 開頭的所有內容,可能包括:
SignatureProtection.response:
   int_body.SignedParts.Body,SignatureProtection.response:int_body.SignedParts.Header_0.Name
SignatureProtection.response:int_body.SignedParts.Header_0.Namespace
有非常多的設定組合可用來保護 Web 服務應用程式。 由於 WS-Security 1.0 版規格中的屬性和配置選項太多,本主題未能完全定義所有屬性。 下列各節說明 WSSecurity 原則和連結屬性的階層結構:

WSSecurity 原則內容

使用 getPolicyType 指令檢閱已在現行 WSSecurity 原則檔中配置內容的內容物件。 安全原則綱目定義安全主張。因為綱目中的元素之間存在階層式關係,安全原則的內容名稱也有類似的階層。 安全原則中的內容名稱之間的階層式關係以兩個層次之間的一點 (.) 表示,連結母屬性和子屬性。 內容的例子包括(但不限於)IncludeToken、Name、Namespace、XPath、XPathVersion。下列清單說明 WSSecurity 原則檔的最上層主張原則內容名稱:
AsymmetricBinding
您可以不指定或最多指定一個連結主張。
SymmetricBinding
您可以不指定或最多指定一個連結主張。AsymmetricBinding 和 SymmetricBinding 不能共存於安全原則檔中。
Wss11
您可以不指定或最多指定一個 Wss11 主張。
Wss10
您可以不指定或最多指定一個 Wss10 主張。
Trust10
您可以不指定或最多指定一個 Trust10 主張。
SignatureProtection
您可以不指定或指定任意數目的簽章保護主張。
EncryptionProtection
您可以不指定或指定任意數目的加密保護主張
SupportingTokens
您可以不指定或指定任意數目的支援記號主張。
例如,下列原則檔範例顯示 AsymmetricBinding 主張:
    <sp:AsymmetricBinding>
      <wsp:Policy>
        <sp:InitiatorSignatureToken>
          <wsp:Policy>
            <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy
						/200512/IncludeToken/AlwaysToRecipient">
              <wsp:Policy>
                <sp:WssX509V3Token10 />
              </wsp:Policy>
            </sp:X509Token>
          </wsp:Policy>
        </sp:InitiatorSignatureToken>
        <sp:RecipientSignatureToken>
          <wsp:Policy>
            <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy
						/200512/IncludeToken/AlwaysToInitiator">
              <wsp:Policy>
                <sp:WssX509V3Token10 />
              </wsp:Policy>
            </sp:X509Token>
          </wsp:Policy>
        </sp:RecipientSignatureToken>
        <sp:AlgorithmSuite>
          <wsp:Policy>
            <sp:Basic256/>
          </wsp:Policy>
        </sp:AlgorithmSuite>
        <sp:Layout>
          <wsp:Policy>
            <sp:Strict/>
          </wsp:Policy>
        </sp:Layout>
      </wsp:Policy>
    </sp:AsymmetricBinding><sp:AsymmetricBinding>
      <wsp:Policy>
        <sp:InitiatorSignatureToken>
          <wsp:Policy>
            <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy
						/200512/IncludeToken/AlwaysToRecipient">
              <wsp:Policy>
                <sp:WssX509V3Token10 />
              </wsp:Policy>
            </sp:X509Token>
          </wsp:Policy>
        </sp:InitiatorSignatureToken>
        <sp:RecipientSignatureToken>
          <wsp:Policy>
            <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy
						/200512/IncludeToken/AlwaysToInitiator">
              <wsp:Policy>
                <sp:WssX509V3Token10 />
              </wsp:Policy>
            </sp:X509Token>
          </wsp:Policy>
        </sp:RecipientSignatureToken>
      </wsp:Policy>
      <sp:AlgorithmSuite>
        <wsp:Policy>
          <sp:Basic256/>
        </wsp:Policy>
      </sp:AlgorithmSuite>
      <sp:Layout>
        <wsp:Policy>
          <sp:Strict/>
        </wsp:Policy>
      </sp:Layout>
    </sp:AsymmetricBinding>
此 AsymmetricBinding 主張會傳回下列內容名稱/值配對。 傳回的內容中不顯示巢狀 wsp:Policy 層。另外,部分內容傳回 true,表示 WSSecurity 配置包含相關的 XML 元素。如果要編輯這些內容,將值設為 true 可包含內容,設為空字串 "" 可移除內容。
AsymmetricBinding.Layout = Strict
AsymmetricBinding.AlgorithmSuite.Basic256 = true
AsymmetricBinding.RecipientSignatureToken.X509Token_0.IncludeToken = http://docs.oasis-open.org
/ws-sx/ws-securitypolicy/200512/IncludeToken/AlwaysToInitiator
AsymmetricBinding.InitiatorSignatureToken.X509Token_0.WssX509V3Token10 = true
AsymmetricBinding.InitiatorSignatureToken.X509Token_0.IncludeToken = http://docs.oasis-open.org
/ws-sx/ws-securitypolicy/200512/IncludeToken/AlwaysToRecipient
AsymmetricBinding.RecipientSignatureToken.X509Token_0.WssX509V3Token10 = true
另外,下列原則檔範例顯示 SupportingTokens 主張:
<sp:SupportingTokens>
        <wsp:Policy wsu:Id="request:custom_auth">
            <spe:CustomToken sp:IncludeToken="http://docs.oasis-open.org/ws-sx/
							ws-securitypolicy/200512/IncludeToken/AlwaysToRecipient">
                <wsp:Policy>
                    <spe:WssCustomToken uri=http://bar.com/MyCustomToken localname="tokenv1">
                    </spe:WssCustomToken>
                </wsp:Policy>
            </spe:CustomToken>
        </wsp:Policy>
    </sp:SupportingTokens
此 SupportingTokens 主張會傳回下列內容名稱/值配對。 傳回的內容中不顯示巢狀 wsp:Policy 層。
SupportingTokens.request:custom_auth.CustomToken_0.WssCustomToken.uri=http://bar.com
/MyCustomToken
SupportingTokens.request:custom_auth.CustomToken_0.IncludeToken=http://docs.oasis-open.org
/ws-sx/ws-securitypolicy/200512/IncludeToken/AlwaysToRecipient
SupportingTokens.request:custom_auth.CustomToken_0.WssCustomToken.localname=tokenv1
註: CustomToken 內容包含下標零表示法 ( _0 ),因為相同類型的記號可能會顯示此內容多次,例如 RecipientSignatureToken 或 InitiatorSignatureToken 記號。
雖然大部分內容名稱都遵循前述的階層式關係格式,但仍有下列例外:
  • wsu:Id 元素
    這個元素使用 ID 的實際值作為屬性名稱,而不是使用 Id。 下列原則檔範例內容:
    <wsp:Policy wsu:Id="response:int_body">
      <sp:SignedParts>
        <sp:Body/>
      </sp:SignedParts>
    </wsp:Policy>
    上面的 wsu:Id 範例會傳回下列內容:
    SignatureProtection.response:int_body.SignedParts.Body = true
  • Header 元素
    因為可能有多個 Header 元素,所以使用 Header_n 表示法代表這個內容。請參閱下列原則檔範例:
     <wsp:Policy wsu:Id="request:conf_body">
         <sp:EncryptedParts>
           <sp:Body/>
           <sp:Header Name="MyElement" Namespace="http://foo.com/MyNamespace" />
         </sp:EncryptedParts>
       </wsp:Policy>
    上面的 Header 範例會傳回下列內容:
    EncryptionProtection.request:conf_body.EncryptedParts.Header_0.Name=MyElement
    EncryptionProtection.request:conf_body.EncryptedParts.Header_0.Namespace=http://
    foo.com/MyNamespace
  • XPath 元素
    因為可能有多個 XPath 元素,所以使用 XPath_n 表示法代表這個內容。請參閱下列原則檔範例:
    <wsp:Policy wsu:Id="request:int_body">
          <sp:SignedElements>
            <sp:XPath>SomeXPathExpression</sp:XPath>
            <sp:XPath>SomeOtherXPathExpression</sp:XPath>
          </sp:EncryptedElements>
        </wsp:Policy>
    上面的 XPath 範例會傳回下列內容:
    SignatureProtection.request:int_body.SignedElements.XPath_0=SomeXPathExpression
    SignatureProtection.request:int_body.SignedElements.XPath_1=SomeOtherXPathExpression
  • X509Token 元素

    因為可能存在多個 X509Token 元素,所以使用 X509Token_n 表示法代表這個內容。 相關範例請參閱 AsymmetricBinding 主張。

  • CustomToken 元素

    因為可能存在多個 CustomToken 元素,所以使用 CustomToken_n 表示法代表這個內容。 相關範例請參閱 SupportingTokens 主張。

WSSecurity 連結內容

使用 getBinding 指令檢閱已在現行 WSSecurity 連結配置中配置內容的內容物件。 您也可以使用管理主控台來配置 WSSecurity 連結。如需相關資訊,請參閱資訊中心裡有關使用管理主控台來配置 WSSecurity 連結的主題。

本節中定義的內容反映連結綱目的階層。內容名稱的每個部分都是綱目類型的小寫。例如,application.securityinboundbindingconfig.tokenconsumer_0.jaasconfig.configname 內容遵循階層式格式。屬性以 applicationbootstrap 開頭。以 application 開頭的屬性代表與主要 WS-Security 原則相關聯的連結。 以 bootstrap 開頭的屬性代表與 WS-Security 引導原則相關聯的連結,而 WS-Security 原則使用「安全對話」。

部分內容名稱後面可能會附加 _n 表示法。此表示法代表項目的清單。例如,有多個 tokenconsumer 內容存在,從 tokenconsumer_0tokenconsumer_n 列出,其中 tokenconsumer 值的設定為:
application.securityinboundbindingconfig.tokenconsumer_0.callbackhandler.
certpathsettings.certstoreref.reference
application.securityinboundbindingconfig.tokenconsumer_0.callbackhandler.
certpathsettings.trustanchorref.reference
application.securityinboundbindingconfig.tokenconsumer_0.callbackhandler.classname
application.securityinboundbindingconfig.tokenconsumer_0.classname
application.securityinboundbindingconfig.tokenconsumer_0.jaasconfig.configname
application.securityinboundbindingconfig.tokenconsumer_0.name
application.securityinboundbindingconfig.tokenconsumer_0.valuetype.localname
application.securityinboundbindingconfig.tokenconsumer_0.valuetype.uri

另外,在查詢時,安全連結檔案中的部分內容會傳回 true 值。如果要設定這些內容,將值設定為 true 可包含內容,將值設定為空字串 ("") 可移除內容。 例如,時間戳記、暫時值和 trustAnyCertificate 內容都遵循此型樣。

使用 setBinding 指令和 attributes 參數,在 WSSecurity 連結配置中新增或移除內容。
  • 如果要新增內容,請使用 setBinding 指令傳遞非零長度字串值的內容名稱。如果要新增清單項目,請使用 _n 表示法代表一個數值,此數值大於內容的任何現行數值。 比方說,如果您的配置中有 tokenconsumer_0tokenconsumer_1 內容,請將新的 tokenconsumer 內容指定為 tokenconsumer_2。新增內容之後,使用 getBinding 指令來檢視最近配置的內容清單。
  • 如果要移除內容,請使用 setBinding 指令為傳遞具有空字串 ("") 的內容名稱。例如,如果要移除所有 tokenconsumer_0 內容,請使用 attributes 參數指定下列內容:
    application.securityinboundbindingconfig.tokenconsumer_0=""
    上面的範例會移除所有以 application.securityinboundbindingconfig.tokenconsumer_0 內容名稱開頭的內容。

下列範例顯示可以為連結配置的幾組內容。此清單未完整包含可以為 WSSecurity 連結配置的所有內容。請參考資訊來決定如何建構特定的內容名稱。

signinginfo 元素
使用此內容來配置簽署資訊。對於自訂連結,securityoutboundbindingconfigsecurityinboundbindingconfig 主張可以有無限多個 signinginfo 元素。在預設連結中,系統容許 securityoutboundbindingconfigsecurityinboundbindingconfig 主張最多有兩個 signinginfo 元素。下列範例顯示兩個 signinginfo 元素的格式:
application.securityinboundbindingconfig.signinginfo_0.signingkeyinfo_0
.reference=con_signkeyinfo
application.securityinboundbindingconfig.signinginfo_0.signingpartreference_0
.reference=request:int_body
application.securityoutboundbindingconfig.signinginfo_0.signingpartreference_0
.reference=response:int_body
application.securityoutboundbindingconfig.signinginfo_0.signingpartreference_0.timestamp=true
encryptioninfo 元素
使用此內容來配置加密資訊。對於自訂連結,securityoutboundbindingconfigsecurityinboundbindingconfig 主張可以有無限多個 encryptioninfo 元素。在預設連結中,系統接受 securityoutboundbindingconfigsecurityinboundbindingconfig 主張最多有兩個 encryptioninfo 元素。下列範例顯示兩個 encryptioninfo 內容的格式:
application.securityinboundbindingconfig.encryptioninfo_0.encryptionpartreference
.nonce=true
application.securityinboundbindingconfig.encryptioninfo_0.encryptionpartreference
.reference=request:conf_body
application.securityoutboundbindingconfig.encryptioninfo_0.encryptionpartreference
.nonce=true
application.securityoutboundbindingconfig.encryptioninfo_0.encryptionpartreference
.timestamp=true
tokengenerator 元素
在預設連結中,signinginfoencryptioninfo 元素未參照的 tokengenerator 元素視為鑑別記號產生者。每個鑑別記號產生者都必須具有唯一的 valuetype 元素。下列範例顯示 X.509 保護記號的產生者範例:
application.securityoutboundbindingconfig.tokengenerator_0.name=gen_signtgen
application.securityoutboundbindingconfig.tokengenerator_0.classname=com.ibm.ws.wssecurity.wssapi.token
.impl.CommonTokenGenerator
application.securityoutboundbindingconfig.tokengenerator_0.valuetype.uri=
application.securityoutboundbindingconfig.tokengenerator_0.valuetype.localname=http://docs.oasis-open.org
/wss/2004/01/oasis-200401-wss-x509-token-profile-1.0#X509v3
application.securityoutboundbindingconfig.tokengenerator_0.callbackhandler.classname=com.ibm.websphere.wssecurity
.callbackhandler.X509GenerateCallbackHandler
application.securityoutboundbindingconfig.tokengenerator_0.callbackhandler.key.alias=soaprequester
application.securityoutboundbindingconfig.tokengenerator_0.callbackhandler.key.keypass={xor}PDM2OjEr
application.securityoutboundbindingconfig.tokengenerator_0.callbackhandler.key.name=CN=SOAPRequester, 
OU=TRL, O=IBM, ST=Kanagawa, C=JP
application.securityoutboundbindingconfig.tokengenerator_0.callbackhandler.keystore.path=${USER_INSTALL_ROOT}
/etc/ws-security/samples/dsig-sender.ks
application.securityoutboundbindingconfig.tokengenerator_0.callbackhandler.keystore.storepass={xor}PDM2OjEr
application.securityoutboundbindingconfig.tokengenerator_0.callbackhandler.keystore.type=JKS
application.securityoutboundbindingconfig.tokengenerator_0.jaasconfig.configname=system.wss.generate.x509
下列範例顯示使用者名稱鑑別記號的產生者:
application.securityoutboundbindingconfig.tokengenerator_1.name=gen_usernametoken
application.securityoutboundbindingconfig.tokengenerator_1.classname=com.ibm.ws.wssecurity
.wssapi.token.impl.CommonTokenGenerator
application.securityoutboundbindingconfig.tokengenerator_1.valuetype.uri=
application.securityoutboundbindingconfig.tokengenerator_1.valuetype.localname=http://docs
.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#UsernameToken
application.securityoutboundbindingconfig.tokengenerator_1.callbackhandler.classname=com.ibm
.websphere.wssecurity.callbackhandler.UNTGenerateCallbackHandler
application.securityoutboundbindingconfig.tokengenerator_1.callbackhandler.basicAuth.userid=user1
application.securityoutboundbindingconfig.tokengenerator_1.callbackhandler.basicAuth.password=myPassword
application.securityoutboundbindingconfig.tokengenerator_1.securityTokenReference.reference=request:uname_token
application.securityoutboundbindingconfig.tokengenerator_1.jaasconfig.configname=system.wss.generate.unt
tokenconsumer 元素
在預設連結中,signinginfoencryptioninfo 元素未參照的 tokenconsumer 元素是鑑別記號消費者。每個鑑別記號消費者都必須具有唯一的 valuetype 元素。下列範例顯示一組 tokenconsumer 元素的格式:
application.securityinboundbindingconfig.tokenconsumer_0.name=con_unametoken
application.securityinboundbindingconfig.tokenconsumer_0.classname=com.ibm.ws.wssecurity.wssapi
.token.impl.CommonTokenConsumer
application.securityinboundbindingconfig.tokenconsumer_0.valuetype.localname=http://docs.oasis-open.org
/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#UsernameToken
application.securityinboundbindingconfig.tokenconsumer_0.valuetype.uri=
application.securityinboundbindingconfig.tokenconsumer_0.callbackhandler.classname=com.ibm.websphere
.wssecurity.callbackhandler.UNTConsumeCallbackHandler
application.securityinboundbindingconfig.tokenconsumer_0.jaasconfig.configname=system.wss.consume.unt
application.securityinboundbindingconfig.tokenconsumer_0.securitytokenreference.reference=request:uname_token
actor 元素
定義要在產生的訊息的 WSSecurity 標頭中包含的動作者統一資源識別碼 (URI),如下列範例所示:
application.securityinboundbindingconfig.actor=http://myActor.com
application.securityoutboundbindingconfig.actor=http://myActor.com
certstorelist 元素
定義憑證儲存庫配置和簽署資訊,如下列範例所示:
application.securityinboundbindingconfig.certstorelist.collectioncertstores_0
.name=DigSigCertStore
application.securityinboundbindingconfig.certstorelist.collectioncertstores_0
.provider=IBMCertPath
application.securityinboundbindingconfig.certstorelist.collectioncertstores_0
.x509certificates_0.path=${USER_INSTALL_ROOT}/etc/ws-security/samples/intca2.cer
keyinfo 元素
定義用於簽署和加密配置的金鑰資訊,如下列範例所示:
application.securityinboundbindingconfig.keyinfo_0.classname=com.ibm.ws.wssecurity.wssapi
.CommonContentConsumer
application.securityinboundbindingconfig.keyinfo_0.name=con_signkeyinfo
application.securityinboundbindingconfig.keyinfo_0.tokenreference.reference=con_tcon
application.securityinboundbindingconfig.keyinfo_0.type=STRREF
trustanchor 內容
定義用於驗證簽章者憑證是否值得信任的配置資訊,如下列範例所示:
application.securityinboundbindingconfig.trustanchor_0.keystore.path=${USER_INSTALL_ROOT}
/etc/ws-security/samples/dsig-receiver.ks
application.securityinboundbindingconfig.trustanchor_0.keystore.storepass={xor}LDotKTot
application.securityinboundbindingconfig.trustanchor_0.keystore.type=JKS
application.securityinboundbindingconfig.trustanchor_0.name=DigSigTrustAnchor
timestampexpires 元素
定義配置的到期日,如下列範例所示:
application.securityoutboundbindingconfig.timestampexpires.expires=5
application.securityinboundbindingconfig.caller_X.order
指定使用 wsadmin Script 時的呼叫端順序,其中 X 是用於識別呼叫端實例的唯一字串:
-attributes [[application.securityinboundbindingconfig.caller_0.order 2]]

setPolicyType 和 setBinding 指令範例

搭配上述的參照資訊,使用 setPolicyType 和 setBinding 指令來修改原則和連結配置資料。

避免困難 避免困難: 管理主控台指令協助針對 setPolicyType 指令提供的 Jython 語法不正確。 對於使用者名稱 WSSecurity 原則集的回應訊息組件保護,XPath 表示式在每一個 XPath 內容值內都包含單引號 ('),但 Jython 並不支援如此。 如果要從管理主控台指令協助中修正指令,請在每一個單引號前面加上反斜線字元 (\),將單引號轉義。gotcha
下列範例使用 setBinding 指令來設定 enabled,並提供 myCustomSecurityPS 自訂原則集(包含 ReliableMessaging 原則)的內容:
AdminTask.setBinding('[-bindingLocation "" -bindingName cellWideBinding2 -policyType
 WSSecurity
 -attributes [[application.securityinboundbindingconfig.caller_0.order 2][inResponsewithSSL:configAlias 
NodeDefaultSSLSettings]
[inResponsewithSSL:config properties_directory/ssl.client.props]
[outAsyncResponsewithSSL:configFile properties_directory/ssl.client.props]
[outAsyncResponsewithSSL:configAlias NodeDefaultSSLSetings]
[outRequestwithSSL:configFile properties_directory/ssl.client.props]
[outRequestwithSSL:configAlias NodeDefaultSSLSettings]]]')
下列 setPolicyType 指令啟用 WSSecurity 原則並建立簽章保護主張:
AdminTask.setPolicyType('-policySet myPolicySet -policyType WSSecurity -attributes 
"[[enabled true][provides 
Some_amount_of_security][SignatureProtection.request:app_signparts.SignedElements.XPath_0 
SignatureProtectionV2]]"')
下列 setBinding 指令為伺服器專用連結指定金鑰資訊:
AdminTask.setBinding('-policyType WSSecurity -bindingLocation "[[server server1][node
node01]]" 
-attributes "[[application.securityinboundbindingconfig.keyinfo_0.name dec_server_keyinfo]
[application.securityinboundbindingconfig.keyinfo_0.classname 
com.ibm.ws.wssecurity.wssapi.CommonContentGenerator]
[application.securityinboundbindingconfig.keyinfo_0.type STRREF]]"')
下列 setBinding 指令為附件專用連結指定金鑰資訊:
AdminTask.setBinding('-policyType WSSecurity -bindingLocation "[[application PolicySet]
[attachmentId 999]]" 
-attributes "[[application.securityinboundbindingconfig.keyinfo_0.name dec_app_keyinfo]
[application.securityinboundbindingconfig.keyinfo_0.classname 
com.ibm.ws.wssecurity.wssapi.CommonContentGenerator]
[application.securityinboundbindingconfig.keyinfo_0.type STRREF]]" -attachmentType application 
 -bindingName myBindingName')
下列 setBinding 指令為 Cell 層面連結指定信任錨點資訊:
AdminTask.setBinding('-policyType WSSecurity -bindingLocation "" -attributes
"[application.securityinboundbindingconfig.trustanchor_0.name DigSigTrustAnchor2]"')

指出主題類型的圖示 參照主題



時間戳記圖示 前次更新: last_date
http://www14.software.ibm.com/webapp/wsbroker/redirect?version=cord&product=was-nd-mp&topic=rxml_wsfpwssecurity
檔名:rxml_wsfpwssecurity.html