<?xml version="1.0" encoding="utf-8"?>
<!--

    Copyright (c) 2010, 2018 Oracle and/or its affiliates. All rights reserved.

    This program and the accompanying materials are made available under the
    terms of the Eclipse Distribution License v. 1.0, which is available at
    http://www.eclipse.org/org/documents/edl-v10.php.

    SPDX-License-Identifier: BSD-3-Clause

-->

<wsdl:definitions name="PingService" targetNamespace="http://tempuri.org/"
                                     xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" 
                                     xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" 
                                     xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" 
                                     xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" 
                                     xmlns:wsap10="http://www.w3.org/2006/05/addressing/wsdl" 
                                     xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing" 
                                     xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" 
                                     xmlns:i0="http://xmlsoap.org/Ping" 
                                     xmlns:wsap="http://schemas.xmlsoap.org/ws/2004/09/policy/addressing" 
                                     xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
                                     xmlns:msc="http://schemas.microsoft.com/ws/2005/12/wsdl/contract" 
                                     xmlns:tns="http://tempuri.org/" 
                                     xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" 
                                     xmlns:wsx="http://schemas.xmlsoap.org/ws/2004/09/mex" 
                                     xmlns:wsa10="http://www.w3.org/2005/08/addressing">
    <wsp:Policy wsu:Id="Scenario_5_IssuedTokenForCertificate_MutualCertificate11_policy">
        <wsp:ExactlyOne>
            <wsp:All>
                <sp:SymmetricBinding xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702">
                    <wsp:Policy>
                        <sp:ProtectionToken>
                            <wsp:Policy>
                                <sp:X509Token sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702/IncludeToken/Never">
                                    <wsp:Policy>
                                        <sp:RequireDerivedKeys/>
                                        <sp:RequireThumbprintReference/>
                                        <sp:WssX509V3Token10/>
                                    </wsp:Policy>
                                </sp:X509Token>
                            </wsp:Policy>
                        </sp:ProtectionToken>
                        <sp:AlgorithmSuite>
                            <wsp:Policy>
                                <sp:Basic256/>
                            </wsp:Policy>
                        </sp:AlgorithmSuite>
                        <sp:Layout>
                            <wsp:Policy>
                                <sp:Strict/>
                            </wsp:Policy>
                        </sp:Layout>
                        <sp:IncludeTimestamp/>
                        <sp:EncryptSignature/>
                        <sp:OnlySignEntireHeadersAndBody/>
                    </wsp:Policy>
                </sp:SymmetricBinding>
                <sp:EndorsingSupportingTokens xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702">
                    <wsp:Policy>
                        <sp:IssuedToken sp:IncludeToken="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702/IncludeToken/AlwaysToRecipient">
                            <!--sp:Issuer>
                                 <Address xmlns="http://www.w3.org/2005/08/addressing">
                                        http://localhost:8080/jaxws-fs-sts/sts
                                 </Address>
                            </sp:Issuer-->
                            <sp:RequestSecurityTokenTemplate>
                                <t:TokenType xmlns:t="http://docs.oasis-open.org/ws-sx/ws-trust/200512">http://docs.oasis-open.org/wss/oasis-wss-saml-token-profile-1.1#SAMLV1.1</t:TokenType>
                                <t:KeyType xmlns:t="http://docs.oasis-open.org/ws-sx/ws-trust/200512">http://docs.oasis-open.org/ws-sx/ws-trust/200512/SymmetricKey</t:KeyType>
                                <!--t:KeyType xmlns:t="http://docs.oasis-open.org/ws-sx/ws-trust/200512">http://docs.oasis-open.org/ws-sx/ws-trust/200512/PublicKey</t:KeyType-->
                                <t:KeySize xmlns:t="http://docs.oasis-open.org/ws-sx/ws-trust/200512">256</t:KeySize>
                            </sp:RequestSecurityTokenTemplate>
                            <wsp:Policy>
                                <sp:RequireDerivedKeys/>
                                <sp:RequireInternalReference/>
                            </wsp:Policy>
                        </sp:IssuedToken>
                    </wsp:Policy>
                </sp:EndorsingSupportingTokens>
                <sp:Wss11 xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702">
                    <wsp:Policy>
                        <sp:MustSupportRefKeyIdentifier/>
                        <sp:MustSupportRefIssuerSerial/>
                        <sp:MustSupportRefThumbprint/>
                        <sp:MustSupportRefEncryptedKey/>
                        <sp:RequireSignatureConfirmation/>
                    </wsp:Policy>
                </sp:Wss11>
                <sp:Trust13 xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702">
                    <wsp:Policy>
                        <sp:MustSupportIssuedTokens/>
                        <sp:RequireClientEntropy/>
                        <sp:RequireServerEntropy/>
                    </wsp:Policy>
                </sp:Trust13>
                <sc:KeyStore xmlns:sc="http://schemas.sun.com/2006/03/wss/server" location="$WSIT_HOME/xws-security/etc/server-keystore.jks" storepass="changeit" alias="bob"/>
                <sc:TrustStore xmlns:sc="http://schemas.sun.com/2006/03/wss/server" location="$WSIT_HOME/xws-security/etc/server-truststore.jks" storepass="changeit"/>
                <sc:ValidatorConfiguration xmlns:sc="http://schemas.sun.com/2006/03/wss/server">
                    <sc:Validator name="samlAssertionValidator" classname="common.SampleSamlValidator"/>
                </sc:ValidatorConfiguration>
                <wsap10:UsingAddressing/>
            </wsp:All>
        </wsp:ExactlyOne>
    </wsp:Policy>
    
    <wsp:Policy wsu:Id="Scenario_5_IssuedTokenForCertificate_MutualCertificate11_Ping_Input_policy">
        <wsp:ExactlyOne>
            <wsp:All>
                <sp:SignedParts xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702">
                    <sp:Body/>
                    <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing"/>
                </sp:SignedParts>
                <sp:EncryptedParts xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702">
                    <sp:Body/>
                </sp:EncryptedParts>
            </wsp:All>
        </wsp:ExactlyOne>
    </wsp:Policy>
    
    <wsp:Policy wsu:Id="Scenario_5_IssuedTokenForCertificate_MutualCertificate11_Ping_output_policy">
        <wsp:ExactlyOne>
            <wsp:All>
                <sp:SignedParts xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702">
                    <sp:Body/>
                    <sp:Header Name="To" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing"/>
                    <sp:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing"/>
                </sp:SignedParts>
                <sp:EncryptedParts xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702">
                    <sp:Body/>
                </sp:EncryptedParts>
            </wsp:All>
        </wsp:ExactlyOne>
    </wsp:Policy>    
        
    <wsdl:types>
        <xsd:schema targetNamespace="http://xmlsoap.org/Ping/Imports">
            <xsd:import schemaLocation="Service_schema.xsd" namespace="http://xmlsoap.org/Ping"/>
        </xsd:schema>
    </wsdl:types>
	
    <wsdl:message name="PingRequest">
        <wsdl:part name="Ping" element="q:Ping" xmlns:q="http://xmlsoap.org/Ping"/>
    </wsdl:message>
    
    <wsdl:message name="PingResponse">
        <wsdl:part name="PingResponse" element="q:PingResponse" xmlns:q="http://xmlsoap.org/Ping"/>
    </wsdl:message>

    <wsdl:portType msc:usingSession="false" name="IPingService">
        <wsdl:operation name="Ping">
            <wsdl:input wsap10:Action="http://xmlsoap.org/Ping" name="PingRequest" message="tns:PingRequest"/>
            <wsdl:output wsap10:Action="http://xmlsoap.org/Ping" name="PingResponse" message="tns:PingResponse"/>
        </wsdl:operation>
    </wsdl:portType>
	
    <wsdl:binding name="Scenario_5_IssuedTokenForCertificate_MutualCertificate11" type="tns:IPingService">
        <wsp:PolicyReference URI="#Scenario_5_IssuedTokenForCertificate_MutualCertificate11_policy"/>
        <soap12:binding transport="http://schemas.xmlsoap.org/soap/http"/>
        <wsdl:operation name="Ping">
            <soap12:operation soapAction="http://xmlsoap.org/Ping" style="document"/>
            <wsdl:input name="PingRequest">
                <wsp:PolicyReference URI="#Scenario_5_IssuedTokenForCertificate_MutualCertificate11_Ping_Input_policy"/>
                <soap12:body use="literal"/>
            </wsdl:input>
            <wsdl:output name="PingResponse">
                <wsp:PolicyReference URI="#Scenario_5_IssuedTokenForCertificate_MutualCertificate11_Ping_output_policy"/>
                <soap12:body use="literal"/>
            </wsdl:output>
        </wsdl:operation>
    </wsdl:binding>
    
    <wsdl:service name="PingService">        
        <wsdl:port name="CustomBinding_IPingService" binding="tns:Scenario_5_IssuedTokenForCertificate_MutualCertificate11">
            <soap12:address location="REPLACE_WITH_ACTUAL_URL"/>
            <wsa10:EndpointReference>
                <wsa10:Address>http://131.107.72.15/Security_Federation_FederatedService_Indigo/Symmetric.svc/Scenario_5_IssuedTokenForCertificate_MutualCertificate11</wsa10:Address>
                <Identity>
                    <KeyInfo>
                        <X509Data>
                            <X509Certificate>
                                MIIDCjCCAfKgAwIBAgIQYDju2/6sm77InYfTq65x+DANBgkqhkiG9w0BAQUFADAwMQ4wDAYDVQQKDAVPQVNJUzEeMBwGA1UEAwwVT0FTSVMgSW50ZXJvcCBUZXN0IENBMB4XDTA1MDMxOTAwMDAwMFoXDTE4MDMxOTIzNTk1OVowQDEOMAwGA1UECgwFT0FTSVMxIDAeBgNVBAsMF09BU0lTIEludGVyb3AgVGVzdCBDZXJ0MQwwCgYDVQQDDANCb2IwgZ8wDQYJKoZIhvcNAQEBBQADgY0AMIGJAoGBAMCquMva4lFDrv3fXQnKK8CkSU7HvVZ0USyJtlL/yhmHH/FQXHyYY+fTcSyWYItWJYiTZ99PAbD+6EKBGbdfuJNUJCGaTWc5ZDUISqM/SGtacYe/PD/4+g3swNPzTUQAIBLRY1pkr2cm3s5Ch/f+mYVNBR41HnBeIxybw25kkoM7AgMBAAGjgZMwgZAwCQYDVR0TBAIwADAzBgNVHR8ELDAqMCiiJoYkaHR0cDovL2ludGVyb3AuYmJ0ZXN0Lm5ldC9jcmwvY2EuY3JsMA4GA1UdDwEB/wQEAwIEsDAdBgNVHQ4EFgQUXeg55vRyK3ZhAEhEf+YT0z986L0wHwYDVR0jBBgwFoAUwJ0o/MHrNaEd1qqqoBwaTcJJDw8wDQYJKoZIhvcNAQEFBQADggEBAIiVGv2lGLhRvmMAHSlY7rKLVkv+zEUtSyg08FBT8z/RepUbtUQShcIqwWsemDU8JVtsucQLc+g6GCQXgkCkMiC8qhcLAt3BXzFmLxuCEAQeeFe8IATr4wACmEQE37TEqAuWEIanPYIplbxYgwP0OBWBSjcRpKRAxjEzuwObYjbll6vKdFHYIweWhhWPrefquFp7TefTkF4D3rcctTfWJ76I5NrEVld+7PBnnJNpdDEuGsoaiJrwTW3Ixm40RXvG3fYS4hIAPeTCUk3RkYfUkqlaaLQnUrF2hZSgiBNLPe8gGkYORccRIlZCGQDEpcWl1Uf9OHw6fC+3hkqolFd5CVI=
                            </X509Certificate>
                        </X509Data>
                    </KeyInfo>
                </Identity>
            </wsa10:EndpointReference>
        </wsdl:port>
    </wsdl:service>
</wsdl:definitions>
