API gateway for REST and SOAP written in Java.

Overview

Membrane Service Proxy

GitHub release Hex.pm

Reverse HTTP proxy (framework) written in Java, that can be used

  • as an API gateway
  • as a security proxy
  • for HTTP based integration
  • as a WebSockets and STOMP router

Get Started

Download the binary.

Unpack.

Start service-proxy.sh or service-proxy.bat.

Have a look at the main configuration file conf/proxies.xml. Changes to this file are instantly deployed.

Run the samples in the examples folder, follow the REST or SOAP tutorials, see the Documentation or the FAQ.

Samples

REST

Routing requests from localhost:80 to localhost:8080 :

<serviceProxy port="80">
    <target host="localhost" port="8080" />
serviceProxy>

Routing only requests with path /foo :

<serviceProxy port="80">
    <path>/foopath>
    <target host="localhost" port="8080" />
serviceProxy>

SOAP

SOAP proxies configure themselves by analysing WSDL:

<soapProxy wsdl="http://thomas-bayer.com/axis2/services/BLZService?wsdl">
soapProxy>

Add features like logging or XML Schema validation against a WSDL document:

<soapProxy wsdl="http://thomas-bayer.com/axis2/services/BLZService?wsdl">
	<validator />
	<log />
soapProxy>

Limit the number of requests in a given time frame:

<serviceProxy port="80">
    <rateLimiter requestLimit="3" requestLimitDuration="PT30S"/>
    <target host="localhost" port="8080" />
serviceProxy>

Rewrite URLs:

<serviceProxy port="2000">
    <rewriter>
    	<map from="^/goodlookingpath/(.*)" to="/backendpath/$1" />
    rewriter>
    <target host="my.backend.server" port="80" />
serviceProxy>

Monitor HTTP traffic:

<serviceProxy port="2000">
    <log/>
    <target host="localhost" port="8080" />
serviceProxy>

Monitoring and manipulation

Dynamically manipulate and monitor messages with Groovy and JavaScript (Nashorn):

<serviceProxy port="2000">
  	<groovy>
    	exc.request.header.add("X-Groovy", "Hello from Groovy")
    	CONTINUE
  	groovy>
	<target host="localhost" port="8080" />
serviceProxy>
<serviceProxy port="2000">
  	<javascript>
    	exc.getRequest().getHeader().add("X-Javascript", "Hello from JavaScript");
   		CONTINUE;
  	javascript>
	<target host="localhost" port="8080" />
serviceProxy>

Route and intercept WebSocket traffic:

<serviceProxy port="2000">
        <webSocket url="http://my.websocket.server:1234">
            <wsLog/>
        webSocket>
    <target port="8080" host="localhost"/>
serviceProxy>

(Find an example on membrane-soa.org)

Security

Use the widely adopted OAuth2/OpenID Framework to secure endpoints:

<serviceProxy name="Resource Service" port="2001">
    <oauth2Resource>
        <membrane src="https://accounts.google.com" clientId="INSERT_CLIENT_ID" clientSecret="INSERT_CLIENT_SECRET" scope="email profile" subject="sub"/>
    oauth2Resource>    
    <groovy>
        def oauth2 = exc.properties.oauth2
        exc.request.header.setValue('X-EMAIL',oauth2.userinfo.email)
        CONTINUE
    groovy>
    <target host="thomas-bayer.com" port="80"/>
serviceProxy>

(Find an example on membrane-soa.org)

Operate your own OAuth2/OpenID AuthorizationServer/Identity Provider:

<serviceProxy name="Authorization Server" port="2000">
    <oauth2authserver location="logindialog" issuer="http://localhost:2000" consentFile="consentFile.json">
        <staticUserDataProvider>
        	<user username="john" password="password" email="[email protected]" />
        staticUserDataProvider>
        	<staticClientList>
        <client clientId="abc" clientSecret="def" callbackUrl="http://localhost:2001/oauth2callback" />
        staticClientList>
    	<bearerToken/>
        <claims value="aud email iss sub username">
        	<scope id="username" claims="username"/>
        	<scope id="profile" claims="username email password"/>
        claims>
    oauth2authserver>
serviceProxy>

(Find an example on membrane-soa.org)

Secure an endpoint with basic authentication:

<serviceProxy port="2000">
    <basicAuthentication>
        <user name="bob" password="secret" />
    basicAuthentication>
    <target host="localhost" port="8080" />
serviceProxy>

Route to SSL/TLS secured endpoints:

<serviceProxy port="8080">
	<target host="www.predic8.de" port="443">
		<ssl/>
	target>
serviceProxy>

Secure endpoints with SSL/TLS:

<serviceProxy port="443">
	<ssl>
		<keystore location="membrane.jks" password="secret" keyPassword="secret" />
		<truststore location="membrane.jks" password="secret" />
	ssl>
	<target host="localhost" port="8080"  />
serviceProxy>

Limit the number of incoming requests:

<serviceProxy port="2000">
    <rateLimiter requestLimit="3" requestLimitDuration="PT30S"/>
    <target host="localhost" port="8080" />
serviceProxy>

Clustering

Distribute your workload to multiple nodes:

<serviceProxy name="Balancer" port="8080">
    <balancer name="balancer">
        <clusters>
            <cluster name="Default">
                <node host="my.backend.service-1" port="4000"/>
                <node host="my.backend.service-2" port="4000"/>
                <node host="my.backend.service-3" port="4000"/>
            cluster>
        clusters>
    balancer>
serviceProxy>

See configuration reference for much more.

Issues
  • SSLHandshakeException using a Proxy Config

    SSLHandshakeException using a Proxy Config

    See:

    https://groups.google.com/forum/#!topic/membrane-monitor/Q53ewuB6ZFg

    Hi,

    More news today. I've try to make a test with a java core batch in the same context (same server, same proxy...) :

        public static void main(String[] args) throws Exception {
    
        CloseableHttpClient httpclient = HttpClients.createDefault();
    
        try {
    
        HttpHost target = new HttpHost("www.google.de", 443, "https");
    
        HttpHost proxy = new HttpHost("gateway.xxxx.zzzzz.net", 80, "http");
    
    
        RequestConfig config = RequestConfig.custom().setProxy(proxy).build();
    
        HttpGet request = new HttpGet("/");
    
        request.setConfig(config);
    
    
        CloseableHttpResponse response = httpclient.execute(target, request);
    
        try {
    
        System.out.println(response.getStatusLine());
    
        EntityUtils.consume(response.getEntity());
    
        } 
    
        } 
    
        }
    

    --> It's work : HTTP/1.1 200 OK

    If I switch "http" by "https" in this line

    HttpHost proxy = new HttpHost("gateway.xxxx.zzzzz.net", 80, "https");
    

    I get the same error than with membrane :

    Exception in thread "main" javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake [...]
    

    --> It's sounds like membrane try to access to my proxy server with HTTPS protocol instead HTTP.

    Do you know how can I force membrane to access to my proxy with HTTP protocol ?

    Best Regards.

    bug 
    opened by predic8 17
  • wsdl files fail to load if they contain schemas that have complexType elements with restriction elements that reference built in types

    wsdl files fail to load if they contain schemas that have complexType elements with restriction elements that reference built in types

    The presence of a schema containing a complexType element that has a restriction element child with a base of anyType, boolean or string or other built in primitive type causes membrane to fail to start. If the schema is moved to an external file and imported into the wsdl then it works as expected.

    Having a restriction element as a child of a simpleType seems to work OK.

    Caused by: org.xml.sax.SAXParseException; systemId: file:///membrane-service-proxy-4.0.17/examples/validation/soap-Proxy/test.wsdl; lineNumber: 4; columnNumber: 41; src-resolve.4.1: Error resolving component 'anyType'. It was detected that 'anyType' has no namespace, but components with no target namespace are not referenceable from schema document 'file:///membrane-service-proxy-4.0.17/examples/validation/soap-Proxy/test.wsdl'. If 'anyType' is intended to have a namespace, perhaps a prefix needs to be provided. If it is intended that 'anyType' has no namespace, then an 'import' without a "namespace" attribute should be added to 'file:///membrane-service-proxy-4.0.17/examples/validation/soap-Proxy/test.wsdl'.

    Consider this schema (schema.xsd)

    <schema targetNamespace="http://www.example.com/IPO"
                    attributeFormDefault="unqualified"
                    elementFormDefault="unqualified"
            xmlns="http://www.w3.org/2001/XMLSchema">
    
    <!-- this is OK -->
      <simpleType name="SKU2">
        <restriction base="string"/>
      </simpleType>
    
    <!-- as is this externally -->
      <complexType name="SKU">
        <complexContent>
          <restriction base="anyType"/>
        </complexContent>
      </complexType>
    
    </schema>
    

    If I embed it into test.wsdl then membrane won't start. If I import it instead it's ok (adjust the data below to uncomment the import and comment the embedded schema to test).

    <definitions name="HelloService"
       targetNamespace="http://www.examples.com/wsdl/HelloService.wsdl"
       xmlns="http://schemas.xmlsoap.org/wsdl/"
       xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
       xmlns:tns="http://www.examples.com/wsdl/HelloService.wsdl"
       xmlns:xsd="http://www.w3.org/2001/XMLSchema">
    
       <types>
    
    <!--
         <import namespace="http://www.example.com/IPO" schemaLocation="schema.xsd"/>
    -->
    
        <schema targetNamespace="http://www.example.com/IPO"
                            attributeFormDefault="unqualified"
                    elementFormDefault="unqualified"
                xmlns="http://www.w3.org/2001/XMLSchema">
    
    <!-- this is OK too -->
          <simpleType name="SKU2">
            <restriction base="string"/>
          </simpleType>
    
    <!-- but this is not! -->
          <complexType name="SKU">
            <complexContent>
              <restriction base="anyType"/>
            </complexContent>
          </complexType>
    
       </schema>
    
       </types>
    
       <!-- all of this is boilerplate to make the wsdl syntactically correct -->
       <message name="SayHelloRequest">
          <part name="firstName" type="SKU"/>
       </message>
    
       <message name="SayHelloResponse">
          <part name="greeting" type="string"/>
       </message>
    
       <portType name="Hello_PortType">
          <operation name="sayHello">
             <input message="tns:SayHelloRequest"/>
             <output message="tns:SayHelloResponse"/>
          </operation>
       </portType>
    
       <binding name="Hello_Binding" type="tns:Hello_PortType">
          <soap:binding style="rpc"
             transport="http://schemas.xmlsoap.org/soap/http"/>
          <operation name="sayHello">
             <soap:operation soapAction="sayHello"/>
             <input>
                <soap:body
                   encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
                   namespace="urn:examples:helloservice"
                   use="encoded"/>
             </input>
    
             <output>
                <soap:body
                   encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
                   namespace="urn:examples:helloservice"
                   use="encoded"/>
             </output>
          </operation>
       </binding>
    
       <service name="Hello_Service">
          <documentation>WSDL File for HelloService</documentation>
          <port binding="tns:Hello_Binding" name="Hello_Port">
             <soap:address
                location="http://www.examples.com/SayHello/" />
          </port>
       </service>
    </definitions>
    

    proxies.xml

    <spring:beans xmlns="http://membrane-soa.org/proxies/1/"
        xmlns:spring="http://www.springframework.org/schema/beans"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://www.springframework.org/schema/beans     http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
                            http://membrane-soa.org/proxies/1/ http://membrane-soa.org/schemas/proxies-1.xsd">
    
        <router>
            <soapProxy port="20009" wsdl="test.wsdl">
                        <validator />
                    </soapProxy>
        </router>
    </spring:beans>
    
    bug 
    opened by longsonr 13
  • EOFWhileReadingLineException

    EOFWhileReadingLineException

    We receive random EOFWhileReadingLineExceptions while proxying a webpage. We do this for rapid prototyping (enhance the html with custom css, js, content). We're using membrane 4.0.2

    This is the full exception:

    An exception occured while handling a request: com.predic8.membrane.core.transport.http.EOFWhileReadingLineException at com.predic8.membrane.core.util.HttpUtil.readLine(HttpUtil.java:63) at com.predic8.membrane.core.http.Response.parseStartLine(Response.java:253) at com.predic8.membrane.core.http.Response.read(Response.java:267) at com.predic8.membrane.core.transport.http.HttpClient.doCall(HttpClient.java:211) at com.predic8.membrane.core.transport.http.HttpClient.call(HttpClient.java:146) at com.predic8.membrane.core.interceptor.HTTPClientInterceptor.handleRequest(HTTPClientInterceptor.java:55) at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeRequestHandlers(InterceptorFlowController.java:106) at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:71) at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:69) at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:182) at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:87) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) at java.lang.Thread.run(Thread.java:680)

    Any ideas?

    possible bug question 
    opened by niklasbulitta 11
  • soap ssl tunel

    soap ssl tunel

    Hi. It is my first try with membrane service proxy and i want configure a SSL Tunnel to the Server in soap service. This is my proxy configuratin:

       <soapProxy port="9090" wsdl="https://estelam.nibn.net:443/IBANSpecEnquiry/IBANSpec?wsdl">    
            <ssl ignoreTimestampCheckFailure="true">
                <keystore    location="C:/java/membrane-service-proxy-4.0.18/conf/iban.jks"    password="password" />
                <truststore  location="C:/java/membrane-service-proxy-4.0.18/conf/iban.jks" password="password" />
            </ssl>
    
        </soapProxy>
    

    But when i starting service this error was occured:

      org.springframework.context.ApplicationContextException: Failed to start bean 'r
      outer'; nested exception is java.lang.RuntimeException: java.lang.IllegalArgumen
      tException: Could not download the WSDL 'https://estelam.nibn.net:443/IBANSpecEn
      quiry/IBANSpec?wsdl'.
              at org.springframework.context.support.DefaultLifecycleProcessor.doStart
      (DefaultLifecycleProcessor.java:170)
              at org.springframework.context.support.DefaultLifecycleProcessor.access$
      1(DefaultLifecycleProcessor.java:154)
              at org.springframework.context.support.DefaultLifecycleProcessor$Lifecyc
      leGroup.start(DefaultLifecycleProcessor.java:339)
              at org.springframework.context.support.DefaultLifecycleProcessor.startBe
      ans(DefaultLifecycleProcessor.java:143)
              at org.springframework.context.support.DefaultLifecycleProcessor.start(D
      efaultLifecycleProcessor.java:89)
              at org.springframework.context.support.AbstractApplicationContext.start(
      AbstractApplicationContext.java:1259)
              at com.predic8.membrane.core.Router.init(Router.java:138)
              at com.predic8.membrane.core.RouterCLI.main(RouterCLI.java:38)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
              at java.lang.reflect.Method.invoke(Unknown Source)
              at com.predic8.membrane.core.Starter.main(Starter.java:26)
      Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException: Could
       not download the WSDL 'https://estelam.nibn.net:443/IBANSpecEnquiry/IBANSpec?ws
      dl'.
              at com.predic8.membrane.core.Router.start(Router.java:270)
              at org.springframework.context.support.DefaultLifecycleProcessor.doStart
      (DefaultLifecycleProcessor.java:167)
              ... 12 more
      Caused by: java.lang.IllegalArgumentException: Could not download the WSDL 'http
      s://estelam.nibn.net:443/IBANSpecEnquiry/IBANSpec?wsdl'.
              at com.predic8.membrane.core.rules.SOAPProxy.parseWSDL(SOAPProxy.java:15
      1)
              at com.predic8.membrane.core.rules.SOAPProxy.configure(SOAPProxy.java:19
      4)
              at com.predic8.membrane.core.rules.SOAPProxy.init(SOAPProxy.java:268)
              at com.predic8.membrane.core.rules.AbstractProxy.init(AbstractProxy.java
      :180)
              at com.predic8.membrane.core.Router.init(Router.java:241)
              at com.predic8.membrane.core.Router.start(Router.java:256)
              ... 13 more
      Caused by: java.lang.RuntimeException: com.predic8.membrane.core.resolver.Resour
      ceRetrievalException: com.predic8.membrane.core.transport.http.EOFWhileReadingFi
      rstLineException: null line so far: "§♥☺ ☻☻
      " while retrieving https://estelam.nibn.net:443/IBANSpecEnquiry/IBANSpec?wsdl
              at com.predic8.membrane.core.resolver.ResolverMap$ExternalResolverConver
      ter$1.resolveViaHttp(ResolverMap.java:238)
              at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
              at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
              at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
              at java.lang.reflect.Method.invoke(Unknown Source)
              at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMet
      hodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:272)
              at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(P
      ogoMetaMethodSite.java:52)
              at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent
      (CallSiteArray.java:49)
              at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(Abs
      tractCallSite.java:133)
              at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(Abs
      tractCallSite.java:141)
              at com.predic8.xml.util.ExternalResolver.resolve(ExternalResolver.groovy
      :66)
              at com.predic8.xml.util.ExternalResolver$resolve.call(Unknown Source)
              at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSi
      teArray.java:45)
              at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCa
      llSite.java:108)
              at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCa
      llSite.java:120)
              at com.predic8.soamodel.AbstractParser.getResourceToken(AbstractParser.g
      roovy:45)
              at com.predic8.soamodel.AbstractParser.this$2$getResourceToken(AbstractP
      arser.groovy)
              at com.predic8.soamodel.AbstractParser$this$2$getResourceToken.callCurre                          
         nt(Unknown Source)
              at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent
         (CallSiteArray.java:49)
                 at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(Abs
         tractCallSite.java:133)
        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(Abs
         tractCallSite.java:141)
        at com.predic8.soamodel.AbstractParser.parse(AbstractParser.groovy:34)
        at com.predic8.wsdl.WSDLParser.super$2$parse(WSDLParser.groovy)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:
         90)
        at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:233)
        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:1074)
        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodOnSuper
         N(ScriptBytecodeAdapter.java:128)
        at com.predic8.wsdl.WSDLParser.parse(WSDLParser.groovy:29)
        at com.predic8.membrane.core.rules.SOAPProxy.parseWSDL(SOAPProxy.java:96
         )
        ... 18 more
         Caused by: com.predic8.membrane.core.resolver.ResourceRetrievalException: com.pr
         edic8.membrane.core.transport.http.EOFWhileReadingFirstLineException: null line
         so far: "§♥☺ ☻☻
         " while retrieving https://estelam.nibn.net:443/IBANSpecEnquiry/IBANSpec?wsdl
        at com.predic8.membrane.core.resolver.HTTPSchemaResolver.resolve(HTTPSch
         emaResolver.java:67)
        at com.predic8.membrane.core.resolver.ResolverMap$ExternalResolverConver
         ter$1.resolveViaHttp(ResolverMap.java:236)
        ... 50 more
         Caused by: com.predic8.membrane.core.transport.http.EOFWhileReadingFirstLineExce
         ption: null line so far: "§♥☺ ☻☻
         "
        at com.predic8.membrane.core.http.Response.parseStartLine(Response.java:
         295)
        at com.predic8.membrane.core.http.Response.read(Response.java:312)
        at com.predic8.membrane.core.transport.http.HttpClient.doCall(HttpClient
         .java:252)
        at com.predic8.membrane.core.transport.http.HttpClient.call(HttpClient.j
         ava:157)
        at com.predic8.membrane.core.transport.http.HttpClient.call(HttpClient.j
         ava:124)
        at com.predic8.membrane.core.resolver.HTTPSchemaResolver.resolve(HTTPSch
         emaResolver.java:56)
        ... 51 more
    

    Thank you

    question wontfix 
    opened by ali-rezvani 11
  • Question, How to I can change serversocket port?

    Question, How to I can change serversocket port?

    07:07:44,385 ERROR RouterCLI:50 - Failed to start bean 'router'; nested exception is java.lang.RuntimeException: com.predic8.membrane.core.transport.PortOccupiedException: Opening a serversocket at port 80 failed. Please make sure that the port is not occupied by a different program or change your rule configuration to select another one. org.springframework.context.ApplicationContextException: Failed to start bean 'router'; nested exception is java.lang.RuntimeException: com.predic8.membrane.core.transport.PortOccupiedException: Opening a serversocket at port 80 failed. Please make sure that the port is not occupied by a different program or change your rule configuration to select another one.

    I added

    <serviceProxy port="9001">
        <webSocket/>
        <target host="localhost" port="2001" />
    </serviceProxy>
    
    

    but it doesn't work

    opened by marti1125 8
  • wsdl fails to load if it has no carriage returns

    wsdl fails to load if it has no carriage returns

    xml documents should not need whitespace/carriage returns. I have a large wsdl file that fails i.e. membrane fails to start. It works (i.e. membrane starts) if the wsdl file is prettified though.

    Apologies for the size of the file but small files don't cause a problem. Here's the formatted version:

    <?xml version="1.0" encoding="UTF-8"?>
    <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
                      xmlns:sch3="http://www.capita-software-services.com/scp/base"
                      xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
                      xmlns:tns="http://www.capita-software-services.com/scp/simple"
                      targetNamespace="http://www.capita-software-services.com/scp/simple">
        <wsdl:types>
            <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
                       xmlns="http://www.capita-software-services.com/portal-api"
                       xmlns:cpt="http://www.capita-software-services.com/portal-api" elementFormDefault="unqualified"
                       targetNamespace="http://www.capita-software-services.com/portal-api">
                <xs:annotation>
                    <xs:documentation>Schema Version: 8.0.0.0</xs:documentation>
                    <xs:documentation>Schema Description: Type definitions for
                        use by Secure Bureau Service
                    </xs:documentation>
                </xs:annotation>
                <xs:simpleType name="generalShortString">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="35"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalString">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="50"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalIntermediateString">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="100"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalMediumString">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="255"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalLongString">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="2048"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalShortStringEmpty">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="0"/>
                        <xs:maxLength value="35"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalStringEmpty">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="0"/>
                        <xs:maxLength value="50"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalMediumStringEmpty">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="0"/>
                        <xs:maxLength value="255"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalLongStringEmpty">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="0"/>
                        <xs:maxLength value="2048"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalAmount">
                    <xs:annotation>
                        <xs:documentation>Amount in minor currency
                            units(pence/cents), leading sign
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:int"/>
                </xs:simpleType>
                <xs:simpleType name="generalAmountPositive">
                    <xs:annotation>
                        <xs:documentation>Amount in minor currency
                            units(pence/cents)
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:positiveInteger"/>
                </xs:simpleType>
                <xs:simpleType name="generalAmountNonZero">
                    <xs:annotation>
                        <xs:documentation>Amount in minor currency
                            units(pence/cents), leading sign, zero not allowed
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:int">
                        <xs:pattern value="[\-+]?[0]*[1-9]\d*"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalInteger">
                    <xs:restriction base="xs:int"/>
                </xs:simpleType>
                <xs:simpleType name="generalShort">
                    <xs:restriction base="xs:short">
                        <xs:minInclusive value="1"/>
                        <xs:maxInclusive value="32767"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalDecimal">
                    <xs:restriction base="xs:decimal">
                        <xs:fractionDigits value="4"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalDecimalPositive">
                    <xs:restriction base="generalDecimal">
                        <xs:minExclusive value="0"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalDate">
                    <xs:annotation>
                        <xs:documentation>Use the xml date/time format eg
                            2003-09-26T15:32:00
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:dateTime"/>
                </xs:simpleType>
                <xs:simpleType name="generalDateMMYY">
                    <xs:annotation>
                        <xs:documentation>Date format MMYY</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:pattern value="(([1][0-2])|([0][1-9]))[0-9][0-9]"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalDateMMYYallow0000">
                    <xs:annotation>
                        <xs:documentation>Date format MMYY</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[0][0][0][0]|((([1][0-2])|([0][1-9]))[0-9][0-9])"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalCode">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="5"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="generalBoolean">
                    <xs:restriction base="xs:boolean"/>
                </xs:simpleType>
                <xs:simpleType name="generalSequenceNumber">
                    <xs:restriction base="xs:positiveInteger">
                        <xs:totalDigits value="5"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="systemCode">
                    <xs:annotation>
                        <xs:documentation>ACP - AXIS Common Payments</xs:documentation>
                        <xs:documentation>ACR - AXIS Counter Receipting</xs:documentation>
                        <xs:documentation>ADD - AXIS Direct Debits</xs:documentation>
                        <xs:documentation>AIM - AXIS Income Management</xs:documentation>
                        <xs:documentation>AIP - AXIS Internet Payments</xs:documentation>
                        <xs:documentation>AOS - AXIS On-line Services</xs:documentation>
                        <xs:documentation>API - AXIS Payments Interface</xs:documentation>
                        <xs:documentation>APN - AXIS PAYe.NET</xs:documentation>
                        <xs:documentation>APP - AXIS Payment Portal</xs:documentation>
                        <xs:documentation>ARP - AXIS Remittance</xs:documentation>
                        <xs:documentation>ASR - AXIS Speech Recognition</xs:documentation>
                        <xs:documentation>ATP - AXIS Telephone Payments</xs:documentation>
                        <xs:documentation>ATT - AXIS Touch Tone</xs:documentation>
                        <xs:documentation>DIR - Direct Authorisations from Third
                            Parties
                        </xs:documentation>
                        <xs:documentation>EXT - EXTERNAL SYSTEM</xs:documentation>
                        <xs:documentation>HPAY - AXIS Health PAYe.NET</xs:documentation>
                        <xs:documentation>MAPN - Managed AXIS PAYe.NET</xs:documentation>
                        <xs:documentation>MHPAY - Managed AXIS Health PAYe.NET</xs:documentation>
                        <xs:documentation>MOTO - AXIS Mail Order Telephone
                            Order
                        </xs:documentation>
                        <xs:documentation>PCR - Perception</xs:documentation>
                        <xs:documentation>SBS - Secure Bureau Service</xs:documentation>
                        <xs:documentation>SCM - AXIS SafeCom</xs:documentation>
                        <xs:documentation>SCP - AXIS Stored Card Portal</xs:documentation>
                        <xs:documentation>SGW - AXIS Smart Gateway</xs:documentation>
                        <xs:documentation>SMS - AXIS Short Message Service</xs:documentation>
                        <xs:documentation>THY - Thyron</xs:documentation>
                        <xs:documentation>TVWAP - AXIS DigiTV</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="ACP"/>
                        <xs:enumeration value="ACR"/>
                        <xs:enumeration value="ADD"/>
                        <xs:enumeration value="AIM"/>
                        <xs:enumeration value="AIP"/>
                        <xs:enumeration value="AOS"/>
                        <xs:enumeration value="API"/>
                        <xs:enumeration value="APN"/>
                        <xs:enumeration value="APP"/>
                        <xs:enumeration value="ARP"/>
                        <xs:enumeration value="ASR"/>
                        <xs:enumeration value="ATP"/>
                        <xs:enumeration value="ATT"/>
                        <xs:enumeration value="DIR"/>
                        <xs:enumeration value="EXT"/>
                        <xs:enumeration value="HPAY"/>
                        <xs:enumeration value="MAPN"/>
                        <xs:enumeration value="MHPAY"/>
                        <xs:enumeration value="MOTO"/>
                        <xs:enumeration value="PCR"/>
                        <xs:enumeration value="SCM"/>
                        <xs:enumeration value="SCP"/>
                        <xs:enumeration value="SGW"/>
                        <xs:enumeration value="SMS"/>
                        <xs:enumeration value="THY"/>
                        <xs:enumeration value="TVWAP"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="systemCodeDirect">
                    <xs:annotation>
                        <xs:documentation>DIR - Direct Authorisations from Third
                            Parties
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="DIR"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="siteID">
                    <xs:restriction base="xs:unsignedShort">
                        <xs:maxInclusive value="32767"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="uniqueTranID">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="12"/>
                        <xs:maxLength value="12"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="isoCode">
                    <xs:annotation>
                        <xs:documentation>Three digit ISO code</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[0-9]{3}"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="userName">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="25"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="sourceCode">
                    <xs:restriction base="generalCode"/>
                </xs:simpleType>
                <xs:simpleType name="languageCode">
                    <xs:restriction base="xs:string">
                        <xs:length value="2"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="linkCAN">
                    <xs:restriction base="xs:positiveInteger"/>
                </xs:simpleType>
                <xs:simpleType name="san">
                    <xs:restriction base="xs:positiveInteger"/>
                </xs:simpleType>
                <xs:simpleType name="recordSource">
                    <xs:annotation>
                        <xs:documentation>0 - Holding</xs:documentation>
                        <xs:documentation>1 - History</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="0"/>
                        <xs:enumeration value="1"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="track2Data">
                    <xs:annotation>
                        <xs:documentation>Mandatory if card swiped, otherwise
                            should not be present
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:maxLength value="100"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="cardNumber">
                    <xs:annotation>
                        <xs:documentation>Mandatory on keyed and chip card
                            transactions, should not be present for swiped
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:pattern value="([0-9]{12,19})"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="issueNumber">
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[0-9]?[0-9]"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="keySwipe">
                    <xs:annotation>
                        <xs:documentation>0 - Signed voucher</xs:documentation>
                        <xs:documentation>1 - Mail order/telephone order/CNP</xs:documentation>
                        <xs:documentation>2 - Continuous authority</xs:documentation>
                        <xs:documentation>3 - PIN verified (on-line)</xs:documentation>
                        <xs:documentation>4 - PIN verified (off-line)</xs:documentation>
                        <xs:documentation>5 - Signed voucher (swiped)</xs:documentation>
                        <xs:documentation>6 - Signed voucher (keyed)</xs:documentation>
                        <xs:documentation>7 - Unattended device without PIN</xs:documentation>
                        <xs:documentation>8 - PIN verified transaction
                            (recovered after sale)
                        </xs:documentation>
                        <xs:documentation>9 - Signed voucher (recovered after
                            sale)
                        </xs:documentation>
                        <xs:documentation>G - Secure e-commerce transaction with
                            cardholder certificate
                        </xs:documentation>
                        <xs:documentation>H - Non-authenticated security
                            transaction with SET merchant certificate
                        </xs:documentation>
                        <xs:documentation>J - Non-authenticated security
                            transaction without SET merchant certificate (e.g. SSL)
                        </xs:documentation>
                        <xs:documentation>K - Non-secure transaction</xs:documentation>
                        <xs:documentation>R - Reversal (used in reversal file
                            only)
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="0"/>
                        <xs:enumeration value="1"/>
                        <xs:enumeration value="2"/>
                        <xs:enumeration value="3"/>
                        <xs:enumeration value="4"/>
                        <xs:enumeration value="5"/>
                        <xs:enumeration value="6"/>
                        <xs:enumeration value="7"/>
                        <xs:enumeration value="8"/>
                        <xs:enumeration value="9"/>
                        <xs:enumeration value="G"/>
                        <xs:enumeration value="H"/>
                        <xs:enumeration value="J"/>
                        <xs:enumeration value="K"/>
                        <xs:enumeration value="R"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="cardType">
                    <xs:annotation>
                        <xs:documentation>Mandatory on card transactions</xs:documentation>
                        <xs:documentation>D - Debit Card</xs:documentation>
                        <xs:documentation>C - Credit Card</xs:documentation>
                        <xs:documentation>N - No Auth</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:length value="1"/>
                        <xs:enumeration value="D"/>
                        <xs:enumeration value="C"/>
                        <xs:enumeration value="N"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="merchantNumber">
                    <xs:restriction base="xs:string">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="20"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="cardTranType">
                    <xs:annotation>
                        <xs:documentation>Mandatory on card transactions</xs:documentation>
                        <xs:documentation>09 - Sale, keyed (cardholder not
                            present(CNP), mail order/batch)
                        </xs:documentation>
                        <xs:documentation>10 - Sale, swiped or chip (cardholder
                            present)
                        </xs:documentation>
                        <xs:documentation>20 - Sale, keyed (cardholder present /
                            magstripe fallback only)
                        </xs:documentation>
                        <xs:documentation>B2 - Sale, e-commerce, keyed (CNP)</xs:documentation>
                        <xs:documentation>Z1 - Sale, swiped,
                            voice-authorization
                        </xs:documentation>
                        <xs:documentation>Z2 - Sale, keyed,
                            voice-authorization
                        </xs:documentation>
                        <xs:documentation>Z9 - Sale, keyed, voice-authorization
                            (CNP)
                        </xs:documentation>
                        <xs:documentation>47 - Refund, keyed (CNP, mail
                            order/batch)
                        </xs:documentation>
                        <xs:documentation>58 - Refund, swiped or chip
                            (cardholder present)
                        </xs:documentation>
                        <xs:documentation>61 - Refund, keyed (cardholder present
                            / magstripe fallback only)
                        </xs:documentation>
                        <xs:documentation>B4 - Refund, e-commerce, keyed (CNP)</xs:documentation>
                        <xs:documentation>25 - Sale reversal</xs:documentation>
                        <xs:documentation>86 - Refund reversal</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="09"/>
                        <xs:enumeration value="10"/>
                        <xs:enumeration value="20"/>
                        <xs:enumeration value="B2"/>
                        <xs:enumeration value="Z1"/>
                        <xs:enumeration value="Z2"/>
                        <xs:enumeration value="Z9"/>
                        <xs:enumeration value="47"/>
                        <xs:enumeration value="58"/>
                        <xs:enumeration value="61"/>
                        <xs:enumeration value="B4"/>
                        <xs:enumeration value="25"/>
                        <xs:enumeration value="86"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="eCommerceTerminalType">
                    <xs:annotation>
                        <xs:documentation>For E-commerce transactions</xs:documentation>
                        <xs:documentation>22 - Chip and Pin transaction</xs:documentation>
                        <xs:documentation>25 - Unattended Chip and Pin
                            transaction, controlled by merchant
                        </xs:documentation>
                        <xs:documentation>30 - Secure transaction with
                            cardholder certificate
                        </xs:documentation>
                        <xs:documentation>31 - Non-authenticated security
                            transaction with SET merchant certificate
                        </xs:documentation>
                        <xs:documentation>32 - Non-authenticated security
                            transaction without SET merchant certificate(eg SSL)
                        </xs:documentation>
                        <xs:documentation>33 - No additional information
                            (considered as unsecured)
                        </xs:documentation>
                        <xs:documentation>35 - Unattended Chip and Pin
                            transaction, controlled by cardholder
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:length value="2"/>
                        <xs:enumeration value="22"/>
                        <xs:enumeration value="25"/>
                        <xs:enumeration value="30"/>
                        <xs:enumeration value="31"/>
                        <xs:enumeration value="32"/>
                        <xs:enumeration value="33"/>
                        <xs:enumeration value="35"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="cardSecurityCode">
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[0-9][0-9][0-9]?[0-9]"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="houseNumber">
                    <xs:restriction base="xs:string">
                        <xs:maxLength value="10"/>
                        <xs:minLength value="1"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="postCode">
                    <xs:restriction base="xs:string">
                        <xs:maxLength value="10"/>
                        <xs:minLength value="1"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="securityAttempted">
                    <xs:annotation>
                        <xs:documentation>M - MasterCard Secure</xs:documentation>
                        <xs:documentation>V - Verified By Visa</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="M"/>
                        <xs:enumeration value="V"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="securityResult">
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="Y"/>
                        <xs:enumeration value="A"/>
                        <xs:enumeration value="U"/>
                        <xs:enumeration value="N"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="eci">
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[0-9][0-9]"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="surchargeType">
                    <xs:annotation>
                        <xs:documentation>F - Fixed Amount</xs:documentation>
                        <xs:documentation>N - None</xs:documentation>
                        <xs:documentation>P - Percentage</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:length value="1"/>
                        <xs:enumeration value="F"/>
                        <xs:enumeration value="N"/>
                        <xs:enumeration value="P"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="cardMnemonic">
                    <xs:restriction base="xs:string">
                        <xs:length value="4"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="cardDescription">
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="VISA"/>
                        <xs:enumeration value="MASTERCARD"/>
                        <xs:enumeration value="AMERICAN EXPRESS"/>
                        <xs:enumeration value="LASER"/>
                        <xs:enumeration value="DINERS"/>
                        <xs:enumeration value="JCBC"/>
                        <xs:enumeration value="NONE"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="statusCode">
                    <xs:annotation>
                        <xs:documentation>0 - Operation completed successfully</xs:documentation>
                        <xs:documentation>Non-zero - Operation failed, more
                            details available in description
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:int"/>
                </xs:simpleType>
                <xs:simpleType name="responseCode">
                    <xs:annotation>
                        <xs:documentation>Card Authorisation Response Codes:-</xs:documentation>
                        <xs:documentation>From the underlying application. Some
                            examples:
                        </xs:documentation>
                        <xs:documentation>00 - Transaction Authorized</xs:documentation>
                        <xs:documentation>Non-zero - Transaction Not Authorized,
                            some possible values are given below
                        </xs:documentation>
                        <xs:documentation>02 - Referral B</xs:documentation>
                        <xs:documentation>05 - Declined</xs:documentation>
                        <xs:documentation>30 - Bank validation failed, invalid
                            merchant etc
                        </xs:documentation>
                        <xs:documentation>54 - Expired Card</xs:documentation>
                        <xs:documentation>91 - Comms Fault</xs:documentation>
                        <xs:documentation>92 - Manual Auth</xs:documentation>
                        <xs:documentation>Validate Card Response Codes:-</xs:documentation>
                        <xs:documentation>0 - Request processed successfully</xs:documentation>
                        <xs:documentation>10 - Request failed schema validation
                            exception
                        </xs:documentation>
                        <xs:documentation>20 - Request failed data access
                            exception
                        </xs:documentation>
                        <xs:documentation>30 - Request failed validation
                            exception
                        </xs:documentation>
                        <xs:documentation>90 - Request failed other error</xs:documentation>
                        <xs:documentation>Stored Card Response Codes:-</xs:documentation>
                        <xs:documentation>0 - Request processed successfully</xs:documentation>
                        <xs:documentation>5 - Card not found</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[0-9A-Z][0-9]?"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="maskedCardNumber">
                    <xs:annotation>
                        <xs:documentation>Card number with all but first six and
                            last four digits masked with asterisks
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[0-9]{6}\*+[0-9]{4}"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="responseAVVCVV">
                    <xs:restriction base="xs:string">
                        <xs:pattern value="\d{6}"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="surchargeRate">
                    <xs:annotation>
                        <xs:documentation>Percentage rate on which surcharge is
                            based, not present for fixed rate surcharges
                        </xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:decimal"/>
                </xs:simpleType>
                <xs:simpleType name="cardLastFourDigits">
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[0-9][0-9][0-9][0-9]"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="panEntryMethod">
                    <xs:annotation>
                        <xs:documentation>ECOM - E-Commerce (Default)</xs:documentation>
                        <xs:documentation>CNP - Card Not Present</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="ECOM"/>
                        <xs:enumeration value="CNP"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="portalAction">
                    <xs:annotation>
                        <xs:documentation>authorise (Default)</xs:documentation>
                        <xs:documentation>storeOnly</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="authorise"/>
                        <xs:enumeration value="storeOnly"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="phone">
                    <xs:restriction base="xs:string">
                        <xs:pattern value="|\+[1-9][0-9]{8}[0-9]?[0-9]?[0-9]?[0-9]?[0-9]?[0-9]?"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="email">
                    <xs:restriction base="xs:string">
                        <xs:pattern value="|[A-Za-z0-9._%+\-][email protected][A-Za-z0-9.\-]+\.[A-Za-z]{2,6}"/>
                        <xs:whiteSpace value="replace"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="integrator">
                    <xs:restriction base="xs:positiveInteger"/>
                </xs:simpleType>
                <xs:simpleType name="lineId">
                    <xs:restriction base="xs:token">
                        <xs:minLength value="1"/>
                        <xs:maxLength value="50"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="bacsReference">
                    <xs:restriction base="xs:string">
                        <xs:pattern value="[A-Za-z0-9.\-/&amp; ]{1,18}"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="bankSortCode">
                    <xs:restriction base="xs:token">
                        <xs:pattern value="[0-9]{6}"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="bankAccountNumber">
                    <xs:restriction base="xs:token">
                        <xs:pattern value="[0-9]{8}"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="httpUrl">
                    <xs:restriction base="xs:token">
                        <xs:pattern value="https?://.+"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:annotation>
                    <xs:documentation>Schema Version: 7.4.2.0</xs:documentation>
                    <xs:documentation>Schema Description: Type definitions for
                        use by Common Foundation
                    </xs:documentation>
                </xs:annotation>
                <xs:element name="credentials" type="credentials"/>
                <xs:complexType name="credentials">
                    <xs:sequence>
                        <xs:element name="subject" type="subject"/>
                        <xs:element name="requestIdentification" type="requestIdentification"/>
                        <xs:element name="signature" type="signature"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="subject">
                    <xs:sequence>
                        <xs:element name="subjectType" type="subjectType"/>
                        <xs:element name="identifier" type="xs:int"/>
                        <xs:element minOccurs="0" name="systemCode" nillable="true" type="systemCode"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="requestIdentification">
                    <xs:sequence>
                        <xs:element name="uniqueReference" type="xs:string"/>
                        <xs:element name="timeStamp" type="timeStamp"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="signature">
                    <xs:sequence>
                        <xs:element name="algorithm" type="algorithm"/>
                        <xs:element name="hmacKeyID" type="xs:int"/>
                        <xs:element name="digest" type="xs:string"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:simpleType name="timeStamp">
                    <xs:restriction base="xs:string">
                        <xs:pattern
                                value="(20)\d\d(0[1-9]|1[012])(0[1-9]|[12][0-9]|3[01])([0-1]\d|2[0-3])([0-5]\d)([0-5]\d)"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="algorithm">
                    <xs:annotation>
                        <xs:documentation>Original</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="Original"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="subjectType">
                    <xs:annotation>
                        <xs:documentation>Capita Site</xs:documentation>
                        <xs:documentation>Integrator</xs:documentation>
                        <xs:documentation>Other Security Entity</xs:documentation>
                        <xs:documentation>Secure Bureau Service Site</xs:documentation>
                        <xs:documentation>Capita Portal</xs:documentation>
                    </xs:annotation>
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="CapitaSite"/>
                        <xs:enumeration value="Integrator"/>
                        <xs:enumeration value="OtherSecurityEntity"/>
                        <xs:enumeration value="SecureBureauServiceSite"/>
                        <xs:enumeration value="CapitaPortal"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:element name="scpSimpleInvokeRequest" type="scpSimpleInvokeRequest"/>
                <xs:element name="scpSimpleInvokeResponse" type="scpInvokeResponse"/>
                <xs:element name="scpSimpleQueryRequest" type="scpQueryRequest"/>
                <xs:element name="scpSimpleQueryResponse" type="scpSimpleQueryResponse"/>
                <xs:complexType name="scpSimpleInvokeRequest">
                    <xs:complexContent>
                        <xs:extension base="scpInvokeRequest">
                            <xs:sequence>
                                <xs:element minOccurs="0" name="sale" type="simpleSale"/>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="simpleSale">
                    <xs:complexContent>
                        <xs:extension base="saleBase">
                            <xs:sequence>
                                <xs:element minOccurs="0" name="postageAndPacking" type="postageAndPacking"/>
                                <xs:element minOccurs="0" name="surchargeable" type="surchargeable"/>
                                <xs:element minOccurs="0" name="items">
                                    <xs:complexType>
                                        <xs:sequence>
                                            <xs:element maxOccurs="unbounded" name="item" type="simpleItem"/>
                                        </xs:sequence>
                                    </xs:complexType>
                                </xs:element>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="surchargeable">
                    <xs:sequence>
                        <xs:choice>
                            <xs:element name="applyScpConfig">
                                <xs:complexType/>
                            </xs:element>
                            <xs:element name="surcharge" type="surchargeItemDetails"/>
                        </xs:choice>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="simpleItem">
                    <xs:complexContent>
                        <xs:extension base="itemBase">
                            <xs:sequence>
                                <xs:element minOccurs="0" name="surchargeable" type="xs:boolean"/>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="scpSimpleQueryResponse">
                    <xs:complexContent>
                        <xs:extension base="scpQueryResponse">
                            <xs:sequence>
                                <xs:element minOccurs="0" name="paymentResult" type="simplePaymentResult"/>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="simplePaymentResult">
                    <xs:complexContent>
                        <xs:extension base="paymentResultBase">
                            <xs:choice minOccurs="0">
                                <xs:element name="paymentDetails" type="simplePayment"/>
                                <xs:element name="errorDetails" type="errorDetails"/>
                            </xs:choice>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="simplePayment">
                    <xs:complexContent>
                        <xs:extension base="paymentBase">
                            <xs:sequence>
                                <xs:element name="saleSummary" type="simpleSaleSummary"/>
                                <xs:element minOccurs="0" name="surchargeDetails" type="surchargeDetails"/>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="simpleSaleSummary">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="items">
                            <xs:complexType>
                                <xs:sequence>
                                    <xs:element maxOccurs="unbounded" name="itemSummary" type="simpleItemSummary"/>
                                </xs:sequence>
                            </xs:complexType>
                        </xs:element>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="simpleItemSummary">
                    <xs:complexContent>
                        <xs:extension base="itemSummaryBase"/>
                    </xs:complexContent>
                </xs:complexType>
                <xs:element name="scpVersionRequest" type="scpVersionRequest"/>
                <xs:element name="scpVersionResponse" type="scpVersionResponse"/>
                <xs:complexType name="requestWithCredentials">
                    <xs:sequence>
                        <xs:element ref="credentials"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="scpVersionRequest">
                    <xs:complexContent>
                        <xs:extension base="requestWithCredentials"/>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="scpVersionResponse">
                    <xs:sequence>
                        <xs:element name="version" type="xs:string"/>
                        <xs:element name="schemaVersion" type="xs:string"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="scpInvokeRequest">
                    <xs:complexContent>
                        <xs:extension base="requestWithCredentials">
                            <xs:sequence>
                                <xs:element name="requestType" type="requestType"/>
                                <xs:element name="requestId" type="xs:token"/>
                                <xs:element name="routing" type="routing"/>
                                <xs:element name="panEntryMethod" type="cpt:panEntryMethod"/>
                                <xs:element minOccurs="0" name="additionalInstructions" type="additionalInstructions"/>
                                <xs:element minOccurs="0" name="billing" type="billingDetails"/>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:simpleType name="requestType">
                    <xs:restriction base="xs:token">
                        <xs:enumeration value="payOnly"/>
                        <xs:enumeration value="authoriseOnly"/>
                        <xs:enumeration value="storeOnly"/>
                        <xs:enumeration value="payAndStore"/>
                        <xs:enumeration value="payAndAutoStore"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:complexType name="routing">
                    <xs:sequence>
                        <xs:element name="returnUrl" type="returnUrl"/>
                        <xs:element minOccurs="0" name="backUrl" type="cpt:httpUrl"/>
                        <xs:element minOccurs="0" name="errorUrl" type="cpt:httpUrl"/>
                        <xs:element name="siteId" type="xs:int"/>
                        <xs:element name="scpId" type="xs:int"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:simpleType name="returnUrl">
                    <xs:union memberTypes="cpt:httpUrl scpSpecialUrl"/>
                </xs:simpleType>
                <xs:simpleType name="scpSpecialUrl">
                    <xs:restriction base="xs:token">
                        <xs:enumeration value="scp:close"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:complexType name="additionalInstructions">
                    <xs:all>
                        <xs:element minOccurs="0" name="merchantCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="countryCode" type="cpt:isoCode"/>
                        <xs:element minOccurs="0" name="currencyCode" type="cpt:isoCode"/>
                        <xs:element minOccurs="0" name="acceptedCards" type="acceptedCards"/>
                        <xs:element minOccurs="0" name="language" type="cpt:languageCode"/>
                        <xs:element minOccurs="0" name="stageIndicator" type="stageIndicator"/>
                        <xs:element minOccurs="0" name="responseInterface" type="responseInterface"/>
                        <xs:element minOccurs="0" name="cardholderID" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="integrator" type="xs:positiveInteger"/>
                        <xs:element minOccurs="0" name="styleCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="frameworkCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="systemCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="walletRequest">
                            <xs:complexType/>
                        </xs:element>
                    </xs:all>
                </xs:complexType>
                <xs:complexType name="acceptedCards">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="includes" type="acceptedCardList"/>
                        <xs:element minOccurs="0" name="excludes" type="acceptedCardList"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="acceptedCardList">
                    <xs:sequence>
                        <xs:element maxOccurs="unbounded" name="card" type="acceptedCardType"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="stageIndicator">
                    <xs:sequence>
                        <xs:element name="firstPortalStage" type="stageNumber"/>
                        <xs:element name="totalStages" type="stageNumber"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:simpleType name="stageNumber">
                    <xs:restriction base="xs:byte">
                        <xs:minInclusive value="1"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="responseInterface">
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="scpWebService"/>
                        <xs:enumeration value="commonPaymentsFormPost"/>
                        <xs:enumeration value="xmlFormPost"/>
                        <xs:enumeration value="htmlFormPost"/>
                        <xs:enumeration value="planningFormPost"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:complexType name="billingDetails">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="card" type="card"/>
                        <xs:element minOccurs="0" name="cardHolderDetails" type="cardHolderDetails"/>
                    </xs:sequence>
                    <xs:attribute default="true" name="editable" type="xs:boolean" use="optional"/>
                </xs:complexType>
                <xs:complexType name="card">
                    <xs:sequence>
                        <xs:choice>
                            <xs:element name="cardDetails" type="cardDetails"/>
                            <xs:element name="storedCardKey" type="storedCardKey"/>
                        </xs:choice>
                        <xs:element minOccurs="0" name="paymentGroupCode" type="cpt:generalCode"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="cardDetails">
                    <xs:sequence>
                        <xs:element name="cardNumber" type="cpt:cardNumber"/>
                        <xs:element name="expiryDate" type="cpt:generalDateMMYY"/>
                        <xs:element minOccurs="0" name="startDate" type="cpt:generalDateMMYY"/>
                        <xs:element minOccurs="0" name="issueNumber" type="cpt:issueNumber"/>
                        <xs:element minOccurs="0" name="cardSecurityCode" type="cpt:cardSecurityCode"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="storedCardKey">
                    <xs:sequence>
                        <xs:element name="token" type="xs:string"/>
                        <xs:element name="lastFourDigits" type="cpt:cardLastFourDigits"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="cardHolderDetails">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="cardHolderName" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="address" type="address"/>
                        <xs:element minOccurs="0" name="contact" type="contact"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="address">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="address1" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="address2" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="address3" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="address4" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="county" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="country" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="postcode" type="cpt:postCode"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="contact">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="telephone" type="cpt:phone"/>
                        <xs:element minOccurs="0" name="mobile" type="cpt:phone"/>
                        <xs:element minOccurs="0" name="email" type="cpt:email"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="saleBase">
                    <xs:sequence>
                        <xs:element name="saleSummary" type="summaryData"/>
                        <xs:element minOccurs="0" name="deliveryDetails" type="contactDetails"/>
                        <xs:element minOccurs="0" name="lgSaleDetails" type="lgSaleDetails"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="summaryData">
                    <xs:sequence>
                        <xs:element name="description">
                            <xs:simpleType>
                                <xs:restriction base="xs:string">
                                    <xs:minLength value="1"/>
                                    <xs:maxLength value="100"/>
                                </xs:restriction>
                            </xs:simpleType>
                        </xs:element>
                        <xs:element name="amountInMinorUnits" type="cpt:generalAmount"/>
                        <xs:element minOccurs="0" name="reference" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="displayableReference" type="cpt:generalString"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="contactDetails">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="name" type="threePartName"/>
                        <xs:element minOccurs="0" name="address" type="address"/>
                        <xs:element minOccurs="0" name="contact" type="contact"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="threePartName">
                    <xs:sequence>
                        <xs:element name="surname" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="title" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="forename" type="cpt:generalString"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="lgSaleDetails">
                    <xs:all>
                        <xs:element minOccurs="0" name="areaCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="locationCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="sourceCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="userName" type="cpt:userName"/>
                        <xs:element minOccurs="0" name="userCode" type="cpt:generalCode"/>
                    </xs:all>
                </xs:complexType>
                <xs:complexType name="postageAndPacking">
                    <xs:sequence>
                        <xs:element name="pnpSummary" type="summaryData"/>
                        <xs:element minOccurs="0" name="tax" type="taxItem"/>
                        <xs:element minOccurs="0" name="lgPnpDetails" type="lgPnpDetails"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="taxItem">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="vat" type="vatItem"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="vatItem">
                    <xs:complexContent>
                        <xs:extension base="vatBase">
                            <xs:sequence>
                                <xs:element name="vatAmountInMinorUnits" type="cpt:generalAmount"/>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="vatBase">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="vatCode" type="cpt:generalCode"/>
                        <xs:element name="vatRate" type="cpt:generalDecimal"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="lgPnpDetails">
                    <xs:all>
                        <xs:element minOccurs="0" name="fundCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="pnpCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="pnpOptionCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="pnpOptionDescription" type="cpt:generalString"/>
                    </xs:all>
                </xs:complexType>
                <xs:complexType name="surchargeItemDetails">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="fundCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="reference" type="cpt:generalString"/>
                        <xs:element name="surchargeInfo" type="surchargeInfo"/>
                        <xs:element minOccurs="0" name="tax" type="taxSurcharge"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="surchargeInfo">
                    <xs:sequence>
                        <xs:element maxOccurs="unbounded" name="cardSurchargeRate" type="cardSurchargeRate"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="cardSurchargeRate">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="surchargeCardType" type="acceptedCardType"/>
                        <xs:element name="surchargeBasis" type="surchargeBasis"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="acceptedCardType">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="cardDescription" type="cpt:cardDescription"/>
                        <xs:element minOccurs="0" name="cardType" type="cardType"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="surchargeBasis">
                    <xs:annotation>
                        <xs:documentation>At least one of surchargeFixed and/or
                            surchargeRate
                            is required
                        </xs:documentation>
                    </xs:annotation>
                    <xs:all>
                        <xs:element minOccurs="0" name="surchargeFixed" type="cpt:generalAmountPositive"/>
                        <xs:element minOccurs="0" name="surchargeRate" type="cpt:generalDecimalPositive"/>
                    </xs:all>
                </xs:complexType>
                <xs:complexType name="taxSurcharge">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="vat" type="vatSurcharge"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="vatSurcharge">
                    <xs:complexContent>
                        <xs:extension base="vatBase"/>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="itemBase">
                    <xs:sequence>
                        <xs:element name="itemSummary" type="summaryData"/>
                        <xs:element minOccurs="0" name="tax" type="taxItem"/>
                        <xs:element minOccurs="0" name="quantity" type="cpt:generalShort"/>
                        <xs:element minOccurs="0" name="notificationEmails" type="notificationEmails"/>
                        <xs:element minOccurs="0" name="lgItemDetails" type="lgItemDetails"/>
                        <xs:element minOccurs="0" name="customerInfo" type="customerInfo"/>
                        <xs:element name="lineId" type="cpt:lineId"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="notificationEmails">
                    <xs:sequence>
                        <xs:element maxOccurs="5" name="email" type="cpt:email"/>
                        <xs:element minOccurs="0" name="additionalEmailMessage" type="cpt:generalLongString"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="lgItemDetails">
                    <xs:all>
                        <xs:element minOccurs="0" name="fundCode" type="cpt:generalCode"/>
                        <xs:element minOccurs="0" name="isFundItem" type="xs:boolean"/>
                        <xs:element minOccurs="0" name="additionalReference" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="narrative" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="accountName" type="threePartName"/>
                        <xs:element minOccurs="0" name="accountAddress" type="address"/>
                        <xs:element minOccurs="0" name="contact" type="contact"/>
                    </xs:all>
                </xs:complexType>
                <xs:complexType name="customerInfo">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="customerString1" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="customerString2" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="customerString3" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="customerString4" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="customerString5" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="customerNumber1" type="xs:int"/>
                        <xs:element minOccurs="0" name="customerNumber2" type="xs:int"/>
                        <xs:element minOccurs="0" name="customerNumber3" type="xs:int"/>
                        <xs:element minOccurs="0" name="customerNumber4" type="xs:int"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="bankDetails">
                    <xs:complexContent>
                        <xs:extension base="bacsBankAccount">
                            <xs:sequence>
                                <xs:element minOccurs="0" name="bacsReference" type="cpt:bacsReference"/>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="bacsBankAccount">
                    <xs:sequence>
                        <xs:element name="sortCode" type="cpt:bankSortCode"/>
                        <xs:element name="bacsAccountNumber" type="cpt:bankAccountNumber"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="scpInvokeResponse">
                    <xs:complexContent>
                        <xs:extension base="scpResponse">
                            <xs:sequence>
                                <xs:element name="invokeResult">
                                    <xs:complexType>
                                        <xs:sequence>
                                            <xs:element name="status" type="status"/>
                                            <xs:choice>
                                                <xs:element name="redirectUrl" type="xs:token"/>
                                                <xs:element name="errorDetails" type="errorDetails"/>
                                            </xs:choice>
                                        </xs:sequence>
                                    </xs:complexType>
                                </xs:element>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="scpResponse">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="requestId" type="xs:token"/>
                        <xs:element name="scpReference" type="xs:string"/>
                        <xs:element name="transactionState" type="transactionState"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:simpleType name="transactionState">
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="IN_PROGRESS"/>
                        <xs:enumeration value="COMPLETE"/>
                        <xs:enumeration value="INVALID_REFERENCE"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:simpleType name="status">
                    <xs:restriction base="xs:string">
                        <xs:enumeration value="SUCCESS"/>
                        <xs:enumeration value="INVALID_REQUEST"/>
                        <xs:enumeration value="CARD_DETAILS_REJECTED"/>
                        <xs:enumeration value="CANCELLED"/>
                        <xs:enumeration value="LOGGED_OUT"/>
                        <xs:enumeration value="NOT_ATTEMPTED"/>
                        <xs:enumeration value="ERROR"/>
                    </xs:restriction>
                </xs:simpleType>
                <xs:complexType name="errorDetails">
                    <xs:sequence>
                        <xs:element minOccurs="0" name="errorId" type="xs:string"/>
                        <xs:element minOccurs="0" name="errorMessage" type="xs:string"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="scpQueryRequest">
                    <xs:complexContent>
                        <xs:extension base="requestWithCredentials">
                            <xs:sequence>
                                <xs:element name="siteId" type="xs:int"/>
                                <xs:element name="scpReference" type="xs:string"/>
                            </xs:sequence>
                            <xs:attribute default="false" name="acceptNonCardResponseData" type="xs:boolean"
                                          use="optional"/>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="scpQueryResponse">
                    <xs:complexContent>
                        <xs:extension base="scpResponse">
                            <xs:sequence>
                                <xs:element minOccurs="0" name="storeCardResult" type="storeCardResult"/>
                                <xs:element minOccurs="0" name="emailResult" type="emailResult"/>
                            </xs:sequence>
                        </xs:extension>
                    </xs:complexContent>
                </xs:complexType>
                <xs:complexType name="storeCardResult">
                    <xs:sequence>
                        <xs:element name="status" type="status"/>
                        <xs:choice minOccurs="0">
                            <xs:element name="storedCardDetails" type="storedCardDetails"/>
                            <xs:element name="errorDetails" type="errorDetails"/>
                        </xs:choice>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="storedCardDetails">
                    <xs:sequence>
                        <xs:element name="storedCardKey" type="storedCardKey"/>
                        <xs:element name="cardDescription" type="cpt:cardDescription"/>
                        <xs:element name="cardType" type="cardType"/>
                        <xs:element minOccurs="0" name="expiryDate" type="cpt:generalDateMMYY"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="emailResult">
                    <xs:sequence>
                        <xs:element name="status" type="status"/>
                        <xs:element name="errorDetails" type="errorDetails"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="paymentResultBase">
                    <xs:sequence>
                        <xs:element name="status" type="status"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="paymentBase">
                    <xs:sequence>
                        <xs:element name="paymentHeader" type="paymentHeader"/>
                        <xs:choice>
                            <xs:element name="authDetails" type="authDetails"/>
                            <xs:element name="nonCardPayment" type="nonCardPayment"/>
                        </xs:choice>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="paymentHeader">
                    <xs:sequence>
                        <xs:element name="transactionDate" type="cpt:generalDate"/>
                        <xs:element name="machineCode" type="cpt:generalCode"/>
                        <xs:element name="uniqueTranId">
                            <xs:simpleType>
                                <xs:restriction base="xs:string">
                                    <xs:length value="12"/>
                                </xs:restriction>
                            </xs:simpleType>
                        </xs:element>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="authDetails">
                    <xs:sequence>
                        <xs:element name="authCode" type="cpt:generalString"/>
                        <xs:element name="amountInMinorUnits" type="cpt:generalAmount"/>
                        <xs:element name="maskedCardNumber" type="cpt:maskedCardNumber"/>
                        <xs:element name="cardDescription" type="cpt:cardDescription"/>
                        <xs:element name="cardType" type="cardType"/>
                        <xs:element name="merchantNumber" type="cpt:generalString"/>
                        <xs:element minOccurs="0" name="expiryDate" type="cpt:generalDateMMYY"/>
                        <xs:element minOccurs="0" name="continuousAuditNumber" type="cpt:generalSequenceNumber"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="nonCardPayment">
                    <xs:sequence>
                        <xs:element name="amountInMinorUnits" type="cpt:generalAmount"/>
                        <xs:element minOccurs="0" name="continuousAuditNumber" type="cpt:generalSequenceNumber"/>
                        <xs:element name="paymentType" type="cpt:generalString"/>
                        <xs:element name="paymentProviderReference" type="cpt:generalString"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="itemSummaryBase">
                    <xs:sequence>
                        <xs:element name="lineId" type="cpt:lineId"/>
                        <xs:element name="continuousAuditNumber" type="cpt:generalSequenceNumber"/>
                    </xs:sequence>
                </xs:complexType>
                <xs:complexType name="surchargeDetails">
                    <xs:sequence>
                        <xs:element name="fundCode" type="cpt:generalCode"/>
                        <xs:element name="reference" type="cpt:generalString"/>
                        <xs:element name="amountInMinorUnits" type="cpt:generalAmount"/>
                        <xs:element name="surchargeBasis" type="surchargeBasis"/>
                        <xs:element minOccurs="0" name="continuousAuditNumber" type="cpt:generalSequenceNumber"/>
                        <xs:element name="vatAmountInMinorUnits" type="cpt:generalAmount"/>
                    </xs:sequence>
                </xs:complexType>
            </xs:schema>
        </wsdl:types>
        <wsdl:message name="scpSimpleQueryRequest">
            <wsdl:part element="tns:scpSimpleQueryRequest" name="scpSimpleQueryRequest"/>
        </wsdl:message>
        <wsdl:message name="scpSimpleInvokeRequest">
            <wsdl:part element="tns:scpSimpleInvokeRequest" name="scpSimpleInvokeRequest"/>
        </wsdl:message>
        <wsdl:message name="scpVersionResponse">
            <wsdl:part element="sch3:scpVersionResponse" name="scpVersionResponse"/>
        </wsdl:message>
        <wsdl:message name="scpVersionRequest">
            <wsdl:part element="sch3:scpVersionRequest" name="scpVersionRequest"/>
        </wsdl:message>
        <wsdl:message name="scpSimpleQueryResponse">
            <wsdl:part element="tns:scpSimpleQueryResponse" name="scpSimpleQueryResponse"/>
        </wsdl:message>
        <wsdl:message name="scpSimpleInvokeResponse">
            <wsdl:part element="tns:scpSimpleInvokeResponse" name="scpSimpleInvokeResponse"/>
        </wsdl:message>
        <wsdl:portType name="scp">
            <wsdl:operation name="scpSimpleQuery">
                <wsdl:input message="tns:scpSimpleQueryRequest" name="scpSimpleQueryRequest"/>
                <wsdl:output message="tns:scpSimpleQueryResponse" name="scpSimpleQueryResponse"/>
            </wsdl:operation>
            <wsdl:operation name="scpSimpleInvoke">
                <wsdl:input message="tns:scpSimpleInvokeRequest" name="scpSimpleInvokeRequest"/>
                <wsdl:output message="tns:scpSimpleInvokeResponse" name="scpSimpleInvokeResponse"/>
            </wsdl:operation>
            <wsdl:operation name="scpVersion">
                <wsdl:input message="tns:scpVersionRequest" name="scpVersionRequest"/>
                <wsdl:output message="tns:scpVersionResponse" name="scpVersionResponse"/>
            </wsdl:operation>
        </wsdl:portType>
        <wsdl:binding name="scpSoap11" type="tns:scp">
            <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
            <wsdl:operation name="scpSimpleQuery">
                <soap:operation soapAction=""/>
                <wsdl:input name="scpSimpleQueryRequest">
                    <soap:body use="literal"/>
                </wsdl:input>
                <wsdl:output name="scpSimpleQueryResponse">
                    <soap:body use="literal"/>
                </wsdl:output>
            </wsdl:operation>
            <wsdl:operation name="scpSimpleInvoke">
                <soap:operation soapAction=""/>
                <wsdl:input name="scpSimpleInvokeRequest">
                    <soap:body use="literal"/>
                </wsdl:input>
                <wsdl:output name="scpSimpleInvokeResponse">
                    <soap:body use="literal"/>
                </wsdl:output>
            </wsdl:operation>
            <wsdl:operation name="scpVersion">
                <soap:operation soapAction=""/>
                <wsdl:input name="scpVersionRequest">
                    <soap:body use="literal"/>
                </wsdl:input>
                <wsdl:output name="scpVersionResponse">
                    <soap:body use="literal"/>
                </wsdl:output>
            </wsdl:operation>
        </wsdl:binding>
        <wsdl:service name="scpService">
            <wsdl:port binding="tns:scpSoap11" name="scpSoap11">
                <soap:address location="https://sbsctest.e-paycapita.com:443/scp/scpws"/>
            </wsdl:port>
        </wsdl:service>
    </wsdl:definitions>
    

    And the same file unformatted:

    <?xml version="1.0" encoding="UTF-8"?>
    <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:sch3="http://www.capita-software-services.com/scp/base" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://www.capita-software-services.com/scp/simple" targetNamespace="http://www.capita-software-services.com/scp/simple"><wsdl:types><xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://www.capita-software-services.com/portal-api" xmlns:cpt="http://www.capita-software-services.com/portal-api" elementFormDefault="unqualified" targetNamespace="http://www.capita-software-services.com/portal-api"><xs:annotation><xs:documentation>Schema Version: 8.0.0.0</xs:documentation><xs:documentation>Schema Description: Type definitions for
                    use by Secure Bureau Service</xs:documentation></xs:annotation><xs:simpleType name="generalShortString"><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="35" /></xs:restriction></xs:simpleType><xs:simpleType name="generalString"><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="50" /></xs:restriction></xs:simpleType><xs:simpleType name="generalIntermediateString"><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="100" /></xs:restriction></xs:simpleType><xs:simpleType name="generalMediumString"><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="255" /></xs:restriction></xs:simpleType><xs:simpleType name="generalLongString"><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="2048" /></xs:restriction></xs:simpleType><xs:simpleType name="generalShortStringEmpty"><xs:restriction base="xs:string"><xs:minLength value="0" /><xs:maxLength value="35" /></xs:restriction></xs:simpleType><xs:simpleType name="generalStringEmpty"><xs:restriction base="xs:string"><xs:minLength value="0" /><xs:maxLength value="50" /></xs:restriction></xs:simpleType><xs:simpleType name="generalMediumStringEmpty"><xs:restriction base="xs:string"><xs:minLength value="0" /><xs:maxLength value="255" /></xs:restriction></xs:simpleType><xs:simpleType name="generalLongStringEmpty"><xs:restriction base="xs:string"><xs:minLength value="0" /><xs:maxLength value="2048" /></xs:restriction></xs:simpleType><xs:simpleType name="generalAmount"><xs:annotation><xs:documentation>Amount in minor currency
                        units(pence/cents), leading sign</xs:documentation></xs:annotation><xs:restriction base="xs:int" /></xs:simpleType><xs:simpleType name="generalAmountPositive"><xs:annotation><xs:documentation>Amount in minor currency
                        units(pence/cents)</xs:documentation></xs:annotation><xs:restriction base="xs:positiveInteger" /></xs:simpleType><xs:simpleType name="generalAmountNonZero"><xs:annotation><xs:documentation>Amount in minor currency
                        units(pence/cents), leading sign, zero not allowed</xs:documentation></xs:annotation><xs:restriction base="xs:int"><xs:pattern value="[\-+]?[0]*[1-9]\d*" /></xs:restriction></xs:simpleType><xs:simpleType name="generalInteger"><xs:restriction base="xs:int" /></xs:simpleType><xs:simpleType name="generalShort"><xs:restriction base="xs:short"><xs:minInclusive value="1" /><xs:maxInclusive value="32767" /></xs:restriction></xs:simpleType><xs:simpleType name="generalDecimal"><xs:restriction base="xs:decimal"><xs:fractionDigits value="4" /></xs:restriction></xs:simpleType><xs:simpleType name="generalDecimalPositive"><xs:restriction base="generalDecimal"><xs:minExclusive value="0" /></xs:restriction></xs:simpleType><xs:simpleType name="generalDate"><xs:annotation><xs:documentation>Use the xml date/time format eg
                        2003-09-26T15:32:00</xs:documentation></xs:annotation><xs:restriction base="xs:dateTime" /></xs:simpleType><xs:simpleType name="generalDateMMYY"><xs:annotation><xs:documentation>Date format MMYY</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:pattern value="(([1][0-2])|([0][1-9]))[0-9][0-9]" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="generalDateMMYYallow0000"><xs:annotation><xs:documentation>Date format MMYY</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:pattern value="[0][0][0][0]|((([1][0-2])|([0][1-9]))[0-9][0-9])" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="generalCode"><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="5" /></xs:restriction></xs:simpleType><xs:simpleType name="generalBoolean"><xs:restriction base="xs:boolean" /></xs:simpleType><xs:simpleType name="generalSequenceNumber"><xs:restriction base="xs:positiveInteger"><xs:totalDigits value="5" /></xs:restriction></xs:simpleType><xs:simpleType name="systemCode"><xs:annotation><xs:documentation>ACP - AXIS Common Payments</xs:documentation><xs:documentation>ACR - AXIS Counter Receipting</xs:documentation><xs:documentation>ADD - AXIS Direct Debits</xs:documentation><xs:documentation>AIM - AXIS Income Management</xs:documentation><xs:documentation>AIP - AXIS Internet Payments</xs:documentation><xs:documentation>AOS - AXIS On-line Services</xs:documentation><xs:documentation>API - AXIS Payments Interface</xs:documentation><xs:documentation>APN - AXIS PAYe.NET</xs:documentation><xs:documentation>APP - AXIS Payment Portal</xs:documentation><xs:documentation>ARP - AXIS Remittance</xs:documentation><xs:documentation>ASR - AXIS Speech Recognition</xs:documentation><xs:documentation>ATP - AXIS Telephone Payments</xs:documentation><xs:documentation>ATT - AXIS Touch Tone</xs:documentation><xs:documentation>DIR - Direct Authorisations from Third
                        Parties</xs:documentation><xs:documentation>EXT - EXTERNAL SYSTEM</xs:documentation><xs:documentation>HPAY - AXIS Health PAYe.NET</xs:documentation><xs:documentation>MAPN - Managed AXIS PAYe.NET</xs:documentation><xs:documentation>MHPAY - Managed AXIS Health PAYe.NET</xs:documentation><xs:documentation>MOTO - AXIS Mail Order Telephone
                        Order</xs:documentation><xs:documentation>PCR - Perception</xs:documentation><xs:documentation>SBS - Secure Bureau Service</xs:documentation><xs:documentation>SCM - AXIS SafeCom</xs:documentation><xs:documentation>SCP - AXIS Stored Card Portal</xs:documentation><xs:documentation>SGW - AXIS Smart Gateway</xs:documentation><xs:documentation>SMS - AXIS Short Message Service</xs:documentation><xs:documentation>THY - Thyron</xs:documentation><xs:documentation>TVWAP - AXIS DigiTV</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="ACP" /><xs:enumeration value="ACR" /><xs:enumeration value="ADD" /><xs:enumeration value="AIM" /><xs:enumeration value="AIP" /><xs:enumeration value="AOS" /><xs:enumeration value="API" /><xs:enumeration value="APN" /><xs:enumeration value="APP" /><xs:enumeration value="ARP" /><xs:enumeration value="ASR" /><xs:enumeration value="ATP" /><xs:enumeration value="ATT" /><xs:enumeration value="DIR" /><xs:enumeration value="EXT" /><xs:enumeration value="HPAY" /><xs:enumeration value="MAPN" /><xs:enumeration value="MHPAY" /><xs:enumeration value="MOTO" /><xs:enumeration value="PCR" /><xs:enumeration value="SCM" /><xs:enumeration value="SCP" /><xs:enumeration value="SGW" /><xs:enumeration value="SMS" /><xs:enumeration value="THY" /><xs:enumeration value="TVWAP" /></xs:restriction></xs:simpleType><xs:simpleType name="systemCodeDirect"><xs:annotation><xs:documentation>DIR - Direct Authorisations from Third
                        Parties</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="DIR" /></xs:restriction></xs:simpleType><xs:simpleType name="siteID"><xs:restriction base="xs:unsignedShort"><xs:maxInclusive value="32767" /></xs:restriction></xs:simpleType><xs:simpleType name="uniqueTranID"><xs:restriction base="xs:string"><xs:minLength value="12" /><xs:maxLength value="12" /></xs:restriction></xs:simpleType><xs:simpleType name="isoCode"><xs:annotation><xs:documentation>Three digit ISO code</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:pattern value="[0-9]{3}" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="userName"><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="25" /></xs:restriction></xs:simpleType><xs:simpleType name="sourceCode"><xs:restriction base="generalCode" /></xs:simpleType><xs:simpleType name="languageCode"><xs:restriction base="xs:string"><xs:length value="2" /></xs:restriction></xs:simpleType><xs:simpleType name="linkCAN"><xs:restriction base="xs:positiveInteger" /></xs:simpleType><xs:simpleType name="san"><xs:restriction base="xs:positiveInteger" /></xs:simpleType><xs:simpleType name="recordSource"><xs:annotation><xs:documentation>0 - Holding</xs:documentation><xs:documentation>1 - History</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="0" /><xs:enumeration value="1" /></xs:restriction></xs:simpleType><xs:simpleType name="track2Data"><xs:annotation><xs:documentation>Mandatory if card swiped, otherwise
                        should not be present</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:maxLength value="100" /></xs:restriction></xs:simpleType><xs:simpleType name="cardNumber"><xs:annotation><xs:documentation>Mandatory on keyed and chip card
                        transactions, should not be present for swiped</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:pattern value="([0-9]{12,19})" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="issueNumber"><xs:restriction base="xs:string"><xs:pattern value="[0-9]?[0-9]" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="keySwipe"><xs:annotation><xs:documentation>0 - Signed voucher</xs:documentation><xs:documentation>1 - Mail order/telephone order/CNP</xs:documentation><xs:documentation>2 - Continuous authority</xs:documentation><xs:documentation>3 - PIN verified (on-line)</xs:documentation><xs:documentation>4 - PIN verified (off-line)</xs:documentation><xs:documentation>5 - Signed voucher (swiped)</xs:documentation><xs:documentation>6 - Signed voucher (keyed)</xs:documentation><xs:documentation>7 - Unattended device without PIN</xs:documentation><xs:documentation>8 - PIN verified transaction
                        (recovered after sale)</xs:documentation><xs:documentation>9 - Signed voucher (recovered after
                        sale)</xs:documentation><xs:documentation>G - Secure e-commerce transaction with
                        cardholder certificate</xs:documentation><xs:documentation>H - Non-authenticated security
                        transaction with SET merchant certificate</xs:documentation><xs:documentation>J - Non-authenticated security
                        transaction without SET merchant certificate (e.g. SSL)</xs:documentation><xs:documentation>K - Non-secure transaction</xs:documentation><xs:documentation>R - Reversal (used in reversal file
                        only)</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="0" /><xs:enumeration value="1" /><xs:enumeration value="2" /><xs:enumeration value="3" /><xs:enumeration value="4" /><xs:enumeration value="5" /><xs:enumeration value="6" /><xs:enumeration value="7" /><xs:enumeration value="8" /><xs:enumeration value="9" /><xs:enumeration value="G" /><xs:enumeration value="H" /><xs:enumeration value="J" /><xs:enumeration value="K" /><xs:enumeration value="R" /></xs:restriction></xs:simpleType><xs:simpleType name="cardType"><xs:annotation><xs:documentation>Mandatory on card transactions</xs:documentation><xs:documentation>D - Debit Card</xs:documentation><xs:documentation>C - Credit Card</xs:documentation><xs:documentation>N - No Auth</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:length value="1" /><xs:enumeration value="D" /><xs:enumeration value="C" /><xs:enumeration value="N" /></xs:restriction></xs:simpleType><xs:simpleType name="merchantNumber"><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="20" /></xs:restriction></xs:simpleType><xs:simpleType name="cardTranType"><xs:annotation><xs:documentation>Mandatory on card transactions</xs:documentation><xs:documentation>09 - Sale, keyed (cardholder not
                        present(CNP), mail order/batch)</xs:documentation><xs:documentation>10 - Sale, swiped or chip (cardholder
                        present)</xs:documentation><xs:documentation>20 - Sale, keyed (cardholder present /
                        magstripe fallback only)</xs:documentation><xs:documentation>B2 - Sale, e-commerce, keyed (CNP)</xs:documentation><xs:documentation>Z1 - Sale, swiped,
                        voice-authorization</xs:documentation><xs:documentation>Z2 - Sale, keyed,
                        voice-authorization</xs:documentation><xs:documentation>Z9 - Sale, keyed, voice-authorization
                        (CNP)</xs:documentation><xs:documentation>47 - Refund, keyed (CNP, mail
                        order/batch)</xs:documentation><xs:documentation>58 - Refund, swiped or chip
                        (cardholder present)</xs:documentation><xs:documentation>61 - Refund, keyed (cardholder present
                        / magstripe fallback only)</xs:documentation><xs:documentation>B4 - Refund, e-commerce, keyed (CNP)</xs:documentation><xs:documentation>25 - Sale reversal</xs:documentation><xs:documentation>86 - Refund reversal</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="09" /><xs:enumeration value="10" /><xs:enumeration value="20" /><xs:enumeration value="B2" /><xs:enumeration value="Z1" /><xs:enumeration value="Z2" /><xs:enumeration value="Z9" /><xs:enumeration value="47" /><xs:enumeration value="58" /><xs:enumeration value="61" /><xs:enumeration value="B4" /><xs:enumeration value="25" /><xs:enumeration value="86" /></xs:restriction></xs:simpleType><xs:simpleType name="eCommerceTerminalType"><xs:annotation><xs:documentation>For E-commerce transactions</xs:documentation><xs:documentation>22 - Chip and Pin transaction</xs:documentation><xs:documentation>25 - Unattended Chip and Pin
                        transaction, controlled by merchant</xs:documentation><xs:documentation>30 - Secure transaction with
                        cardholder certificate</xs:documentation><xs:documentation>31 - Non-authenticated security
                        transaction with SET merchant certificate</xs:documentation><xs:documentation>32 - Non-authenticated security
                        transaction without SET merchant certificate(eg SSL)</xs:documentation><xs:documentation>33 - No additional information
                        (considered as unsecured)</xs:documentation><xs:documentation>35 - Unattended Chip and Pin
                        transaction, controlled by cardholder</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:length value="2" /><xs:enumeration value="22" /><xs:enumeration value="25" /><xs:enumeration value="30" /><xs:enumeration value="31" /><xs:enumeration value="32" /><xs:enumeration value="33" /><xs:enumeration value="35" /></xs:restriction></xs:simpleType><xs:simpleType name="cardSecurityCode"><xs:restriction base="xs:string"><xs:pattern value="[0-9][0-9][0-9]?[0-9]" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="houseNumber"><xs:restriction base="xs:string"><xs:maxLength value="10" /><xs:minLength value="1" /></xs:restriction></xs:simpleType><xs:simpleType name="postCode"><xs:restriction base="xs:string"><xs:maxLength value="10" /><xs:minLength value="1" /></xs:restriction></xs:simpleType><xs:simpleType name="securityAttempted"><xs:annotation><xs:documentation>M - MasterCard Secure</xs:documentation><xs:documentation>V - Verified By Visa</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="M" /><xs:enumeration value="V" /></xs:restriction></xs:simpleType><xs:simpleType name="securityResult"><xs:restriction base="xs:string"><xs:enumeration value="Y" /><xs:enumeration value="A" /><xs:enumeration value="U" /><xs:enumeration value="N" /></xs:restriction></xs:simpleType><xs:simpleType name="eci"><xs:restriction base="xs:string"><xs:pattern value="[0-9][0-9]" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="surchargeType"><xs:annotation><xs:documentation>F - Fixed Amount</xs:documentation><xs:documentation>N - None</xs:documentation><xs:documentation>P - Percentage</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:length value="1" /><xs:enumeration value="F" /><xs:enumeration value="N" /><xs:enumeration value="P" /></xs:restriction></xs:simpleType><xs:simpleType name="cardMnemonic"><xs:restriction base="xs:string"><xs:length value="4" /></xs:restriction></xs:simpleType><xs:simpleType name="cardDescription"><xs:restriction base="xs:string"><xs:enumeration value="VISA" /><xs:enumeration value="MASTERCARD" /><xs:enumeration value="AMERICAN EXPRESS" /><xs:enumeration value="LASER" /><xs:enumeration value="DINERS" /><xs:enumeration value="JCBC" /><xs:enumeration value="NONE" /></xs:restriction></xs:simpleType><xs:simpleType name="statusCode"><xs:annotation><xs:documentation>0 - Operation completed successfully</xs:documentation><xs:documentation>Non-zero - Operation failed, more
                        details available in description</xs:documentation></xs:annotation><xs:restriction base="xs:int" /></xs:simpleType><xs:simpleType name="responseCode"><xs:annotation><xs:documentation>Card Authorisation Response Codes:-</xs:documentation><xs:documentation>From the underlying application. Some
                        examples:</xs:documentation><xs:documentation>00 - Transaction Authorized</xs:documentation><xs:documentation>Non-zero - Transaction Not Authorized,
                        some possible values are given below</xs:documentation><xs:documentation>02 - Referral B</xs:documentation><xs:documentation>05 - Declined</xs:documentation><xs:documentation>30 - Bank validation failed, invalid
                        merchant etc</xs:documentation><xs:documentation>54 - Expired Card</xs:documentation><xs:documentation>91 - Comms Fault</xs:documentation><xs:documentation>92 - Manual Auth</xs:documentation><xs:documentation>Validate Card Response Codes:-</xs:documentation><xs:documentation>0 - Request processed successfully</xs:documentation><xs:documentation>10 - Request failed schema validation
                        exception</xs:documentation><xs:documentation>20 - Request failed data access
                        exception</xs:documentation><xs:documentation>30 - Request failed validation
                        exception</xs:documentation><xs:documentation>90 - Request failed other error</xs:documentation><xs:documentation>Stored Card Response Codes:-</xs:documentation><xs:documentation>0 - Request processed successfully</xs:documentation><xs:documentation>5 - Card not found</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:pattern value="[0-9A-Z][0-9]?" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="maskedCardNumber"><xs:annotation><xs:documentation>Card number with all but first six and
                        last four digits masked with asterisks</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:pattern value="[0-9]{6}\*+[0-9]{4}" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="responseAVVCVV"><xs:restriction base="xs:string"><xs:pattern value="\d{6}" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="surchargeRate"><xs:annotation><xs:documentation>Percentage rate on which surcharge is
                        based, not present for fixed rate surcharges</xs:documentation></xs:annotation><xs:restriction base="xs:decimal" /></xs:simpleType><xs:simpleType name="cardLastFourDigits"><xs:restriction base="xs:string"><xs:pattern value="[0-9][0-9][0-9][0-9]" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="panEntryMethod"><xs:annotation><xs:documentation>ECOM - E-Commerce (Default)</xs:documentation><xs:documentation>CNP - Card Not Present</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="ECOM" /><xs:enumeration value="CNP" /></xs:restriction></xs:simpleType><xs:simpleType name="portalAction"><xs:annotation><xs:documentation>authorise (Default)</xs:documentation><xs:documentation>storeOnly</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="authorise" /><xs:enumeration value="storeOnly" /></xs:restriction></xs:simpleType><xs:simpleType name="phone"><xs:restriction base="xs:string"><xs:pattern value="|\+[1-9][0-9]{8}[0-9]?[0-9]?[0-9]?[0-9]?[0-9]?[0-9]?" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="email"><xs:restriction base="xs:string"><xs:pattern value="|[A-Za-z0-9._%+\-][email protected][A-Za-z0-9.\-]+\.[A-Za-z]{2,6}" /><xs:whiteSpace value="replace" /></xs:restriction></xs:simpleType><xs:simpleType name="integrator"><xs:restriction base="xs:positiveInteger" /></xs:simpleType><xs:simpleType name="lineId"><xs:restriction base="xs:token"><xs:minLength value="1" /><xs:maxLength value="50" /></xs:restriction></xs:simpleType><xs:simpleType name="bacsReference"><xs:restriction base="xs:string"><xs:pattern value="[A-Za-z0-9.\-/&amp; ]{1,18}" /></xs:restriction></xs:simpleType><xs:simpleType name="bankSortCode"><xs:restriction base="xs:token"><xs:pattern value="[0-9]{6}" /></xs:restriction></xs:simpleType><xs:simpleType name="bankAccountNumber"><xs:restriction base="xs:token"><xs:pattern value="[0-9]{8}" /></xs:restriction></xs:simpleType><xs:simpleType name="httpUrl"><xs:restriction base="xs:token"><xs:pattern value="https?://.+" /></xs:restriction></xs:simpleType><xs:annotation><xs:documentation>Schema Version: 7.4.2.0</xs:documentation><xs:documentation>Schema Description: Type definitions for
                    use by Common Foundation</xs:documentation></xs:annotation><xs:element name="credentials" type="credentials" /><xs:complexType name="credentials"><xs:sequence><xs:element name="subject" type="subject" /><xs:element name="requestIdentification" type="requestIdentification" /><xs:element name="signature" type="signature" /></xs:sequence></xs:complexType><xs:complexType name="subject"><xs:sequence><xs:element name="subjectType" type="subjectType" /><xs:element name="identifier" type="xs:int" /><xs:element minOccurs="0" name="systemCode" nillable="true" type="systemCode" /></xs:sequence></xs:complexType><xs:complexType name="requestIdentification"><xs:sequence><xs:element name="uniqueReference" type="xs:string" /><xs:element name="timeStamp" type="timeStamp" /></xs:sequence></xs:complexType><xs:complexType name="signature"><xs:sequence><xs:element name="algorithm" type="algorithm" /><xs:element name="hmacKeyID" type="xs:int" /><xs:element name="digest" type="xs:string" /></xs:sequence></xs:complexType><xs:simpleType name="timeStamp"><xs:restriction base="xs:string"><xs:pattern value="(20)\d\d(0[1-9]|1[012])(0[1-9]|[12][0-9]|3[01])([0-1]\d|2[0-3])([0-5]\d)([0-5]\d)" /></xs:restriction></xs:simpleType><xs:simpleType name="algorithm"><xs:annotation><xs:documentation>Original</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="Original" /></xs:restriction></xs:simpleType><xs:simpleType name="subjectType"><xs:annotation><xs:documentation>Capita Site</xs:documentation><xs:documentation>Integrator</xs:documentation><xs:documentation>Other Security Entity</xs:documentation><xs:documentation>Secure Bureau Service Site</xs:documentation><xs:documentation>Capita Portal</xs:documentation></xs:annotation><xs:restriction base="xs:string"><xs:enumeration value="CapitaSite" /><xs:enumeration value="Integrator" /><xs:enumeration value="OtherSecurityEntity" /><xs:enumeration value="SecureBureauServiceSite" /><xs:enumeration value="CapitaPortal" /></xs:restriction></xs:simpleType><xs:element name="scpSimpleInvokeRequest" type="scpSimpleInvokeRequest" /><xs:element name="scpSimpleInvokeResponse" type="scpInvokeResponse" /><xs:element name="scpSimpleQueryRequest" type="scpQueryRequest" /><xs:element name="scpSimpleQueryResponse" type="scpSimpleQueryResponse" /><xs:complexType name="scpSimpleInvokeRequest"><xs:complexContent><xs:extension base="scpInvokeRequest"><xs:sequence><xs:element minOccurs="0" name="sale" type="simpleSale" /></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="simpleSale"><xs:complexContent><xs:extension base="saleBase"><xs:sequence><xs:element minOccurs="0" name="postageAndPacking" type="postageAndPacking" /><xs:element minOccurs="0" name="surchargeable" type="surchargeable" /><xs:element minOccurs="0" name="items"><xs:complexType><xs:sequence><xs:element maxOccurs="unbounded" name="item" type="simpleItem" /></xs:sequence></xs:complexType></xs:element></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="surchargeable"><xs:sequence><xs:choice><xs:element name="applyScpConfig"><xs:complexType /></xs:element><xs:element name="surcharge" type="surchargeItemDetails" /></xs:choice></xs:sequence></xs:complexType><xs:complexType name="simpleItem"><xs:complexContent><xs:extension base="itemBase"><xs:sequence><xs:element minOccurs="0" name="surchargeable" type="xs:boolean" /></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="scpSimpleQueryResponse"><xs:complexContent><xs:extension base="scpQueryResponse"><xs:sequence><xs:element minOccurs="0" name="paymentResult" type="simplePaymentResult" /></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="simplePaymentResult"><xs:complexContent><xs:extension base="paymentResultBase"><xs:choice minOccurs="0"><xs:element name="paymentDetails" type="simplePayment" /><xs:element name="errorDetails" type="errorDetails" /></xs:choice></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="simplePayment"><xs:complexContent><xs:extension base="paymentBase"><xs:sequence><xs:element name="saleSummary" type="simpleSaleSummary" /><xs:element minOccurs="0" name="surchargeDetails" type="surchargeDetails" /></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="simpleSaleSummary"><xs:sequence><xs:element minOccurs="0" name="items"><xs:complexType><xs:sequence><xs:element maxOccurs="unbounded" name="itemSummary" type="simpleItemSummary" /></xs:sequence></xs:complexType></xs:element></xs:sequence></xs:complexType><xs:complexType name="simpleItemSummary"><xs:complexContent><xs:extension base="itemSummaryBase" /></xs:complexContent></xs:complexType><xs:element name="scpVersionRequest" type="scpVersionRequest" /><xs:element name="scpVersionResponse" type="scpVersionResponse" /><xs:complexType name="requestWithCredentials"><xs:sequence><xs:element ref="credentials" /></xs:sequence></xs:complexType><xs:complexType name="scpVersionRequest"><xs:complexContent><xs:extension base="requestWithCredentials" /></xs:complexContent></xs:complexType><xs:complexType name="scpVersionResponse"><xs:sequence><xs:element name="version" type="xs:string" /><xs:element name="schemaVersion" type="xs:string" /></xs:sequence></xs:complexType><xs:complexType name="scpInvokeRequest"><xs:complexContent><xs:extension base="requestWithCredentials"><xs:sequence><xs:element name="requestType" type="requestType" /><xs:element name="requestId" type="xs:token" /><xs:element name="routing" type="routing" /><xs:element name="panEntryMethod" type="cpt:panEntryMethod" /><xs:element minOccurs="0" name="additionalInstructions" type="additionalInstructions" /><xs:element minOccurs="0" name="billing" type="billingDetails" /></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:simpleType name="requestType"><xs:restriction base="xs:token"><xs:enumeration value="payOnly" /><xs:enumeration value="authoriseOnly" /><xs:enumeration value="storeOnly" /><xs:enumeration value="payAndStore" /><xs:enumeration value="payAndAutoStore" /></xs:restriction></xs:simpleType><xs:complexType name="routing"><xs:sequence><xs:element name="returnUrl" type="returnUrl" /><xs:element minOccurs="0" name="backUrl" type="cpt:httpUrl" /><xs:element minOccurs="0" name="errorUrl" type="cpt:httpUrl" /><xs:element name="siteId" type="xs:int" /><xs:element name="scpId" type="xs:int" /></xs:sequence></xs:complexType><xs:simpleType name="returnUrl"><xs:union memberTypes="cpt:httpUrl scpSpecialUrl" /></xs:simpleType><xs:simpleType name="scpSpecialUrl"><xs:restriction base="xs:token"><xs:enumeration value="scp:close" /></xs:restriction></xs:simpleType><xs:complexType name="additionalInstructions"><xs:all><xs:element minOccurs="0" name="merchantCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="countryCode" type="cpt:isoCode" /><xs:element minOccurs="0" name="currencyCode" type="cpt:isoCode" /><xs:element minOccurs="0" name="acceptedCards" type="acceptedCards" /><xs:element minOccurs="0" name="language" type="cpt:languageCode" /><xs:element minOccurs="0" name="stageIndicator" type="stageIndicator" /><xs:element minOccurs="0" name="responseInterface" type="responseInterface" /><xs:element minOccurs="0" name="cardholderID" type="cpt:generalString" /><xs:element minOccurs="0" name="integrator" type="xs:positiveInteger" /><xs:element minOccurs="0" name="styleCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="frameworkCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="systemCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="walletRequest"><xs:complexType /></xs:element></xs:all></xs:complexType><xs:complexType name="acceptedCards"><xs:sequence><xs:element minOccurs="0" name="includes" type="acceptedCardList" /><xs:element minOccurs="0" name="excludes" type="acceptedCardList" /></xs:sequence></xs:complexType><xs:complexType name="acceptedCardList"><xs:sequence><xs:element maxOccurs="unbounded" name="card" type="acceptedCardType" /></xs:sequence></xs:complexType><xs:complexType name="stageIndicator"><xs:sequence><xs:element name="firstPortalStage" type="stageNumber" /><xs:element name="totalStages" type="stageNumber" /></xs:sequence></xs:complexType><xs:simpleType name="stageNumber"><xs:restriction base="xs:byte"><xs:minInclusive value="1" /></xs:restriction></xs:simpleType><xs:simpleType name="responseInterface"><xs:restriction base="xs:string"><xs:enumeration value="scpWebService" /><xs:enumeration value="commonPaymentsFormPost" /><xs:enumeration value="xmlFormPost" /><xs:enumeration value="htmlFormPost" /><xs:enumeration value="planningFormPost" /></xs:restriction></xs:simpleType><xs:complexType name="billingDetails"><xs:sequence><xs:element minOccurs="0" name="card" type="card" /><xs:element minOccurs="0" name="cardHolderDetails" type="cardHolderDetails" /></xs:sequence><xs:attribute default="true" name="editable" type="xs:boolean" use="optional" /></xs:complexType><xs:complexType name="card"><xs:sequence><xs:choice><xs:element name="cardDetails" type="cardDetails" /><xs:element name="storedCardKey" type="storedCardKey" /></xs:choice><xs:element minOccurs="0" name="paymentGroupCode" type="cpt:generalCode" /></xs:sequence></xs:complexType><xs:complexType name="cardDetails"><xs:sequence><xs:element name="cardNumber" type="cpt:cardNumber" /><xs:element name="expiryDate" type="cpt:generalDateMMYY" /><xs:element minOccurs="0" name="startDate" type="cpt:generalDateMMYY" /><xs:element minOccurs="0" name="issueNumber" type="cpt:issueNumber" /><xs:element minOccurs="0" name="cardSecurityCode" type="cpt:cardSecurityCode" /></xs:sequence></xs:complexType><xs:complexType name="storedCardKey"><xs:sequence><xs:element name="token" type="xs:string" /><xs:element name="lastFourDigits" type="cpt:cardLastFourDigits" /></xs:sequence></xs:complexType><xs:complexType name="cardHolderDetails"><xs:sequence><xs:element minOccurs="0" name="cardHolderName" type="cpt:generalString" /><xs:element minOccurs="0" name="address" type="address" /><xs:element minOccurs="0" name="contact" type="contact" /></xs:sequence></xs:complexType><xs:complexType name="address"><xs:sequence><xs:element minOccurs="0" name="address1" type="cpt:generalString" /><xs:element minOccurs="0" name="address2" type="cpt:generalString" /><xs:element minOccurs="0" name="address3" type="cpt:generalString" /><xs:element minOccurs="0" name="address4" type="cpt:generalString" /><xs:element minOccurs="0" name="county" type="cpt:generalString" /><xs:element minOccurs="0" name="country" type="cpt:generalString" /><xs:element minOccurs="0" name="postcode" type="cpt:postCode" /></xs:sequence></xs:complexType><xs:complexType name="contact"><xs:sequence><xs:element minOccurs="0" name="telephone" type="cpt:phone" /><xs:element minOccurs="0" name="mobile" type="cpt:phone" /><xs:element minOccurs="0" name="email" type="cpt:email" /></xs:sequence></xs:complexType><xs:complexType name="saleBase"><xs:sequence><xs:element name="saleSummary" type="summaryData" /><xs:element minOccurs="0" name="deliveryDetails" type="contactDetails" /><xs:element minOccurs="0" name="lgSaleDetails" type="lgSaleDetails" /></xs:sequence></xs:complexType><xs:complexType name="summaryData"><xs:sequence><xs:element name="description"><xs:simpleType><xs:restriction base="xs:string"><xs:minLength value="1" /><xs:maxLength value="100" /></xs:restriction></xs:simpleType></xs:element><xs:element name="amountInMinorUnits" type="cpt:generalAmount" /><xs:element minOccurs="0" name="reference" type="cpt:generalString" /><xs:element minOccurs="0" name="displayableReference" type="cpt:generalString" /></xs:sequence></xs:complexType><xs:complexType name="contactDetails"><xs:sequence><xs:element minOccurs="0" name="name" type="threePartName" /><xs:element minOccurs="0" name="address" type="address" /><xs:element minOccurs="0" name="contact" type="contact" /></xs:sequence></xs:complexType><xs:complexType name="threePartName"><xs:sequence><xs:element name="surname" type="cpt:generalString" /><xs:element minOccurs="0" name="title" type="cpt:generalString" /><xs:element minOccurs="0" name="forename" type="cpt:generalString" /></xs:sequence></xs:complexType><xs:complexType name="lgSaleDetails"><xs:all><xs:element minOccurs="0" name="areaCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="locationCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="sourceCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="userName" type="cpt:userName" /><xs:element minOccurs="0" name="userCode" type="cpt:generalCode" /></xs:all></xs:complexType><xs:complexType name="postageAndPacking"><xs:sequence><xs:element name="pnpSummary" type="summaryData" /><xs:element minOccurs="0" name="tax" type="taxItem" /><xs:element minOccurs="0" name="lgPnpDetails" type="lgPnpDetails" /></xs:sequence></xs:complexType><xs:complexType name="taxItem"><xs:sequence><xs:element minOccurs="0" name="vat" type="vatItem" /></xs:sequence></xs:complexType><xs:complexType name="vatItem"><xs:complexContent><xs:extension base="vatBase"><xs:sequence><xs:element name="vatAmountInMinorUnits" type="cpt:generalAmount" /></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="vatBase"><xs:sequence><xs:element minOccurs="0" name="vatCode" type="cpt:generalCode" /><xs:element name="vatRate" type="cpt:generalDecimal" /></xs:sequence></xs:complexType><xs:complexType name="lgPnpDetails"><xs:all><xs:element minOccurs="0" name="fundCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="pnpCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="pnpOptionCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="pnpOptionDescription" type="cpt:generalString" /></xs:all></xs:complexType><xs:complexType name="surchargeItemDetails"><xs:sequence><xs:element minOccurs="0" name="fundCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="reference" type="cpt:generalString" /><xs:element name="surchargeInfo" type="surchargeInfo" /><xs:element minOccurs="0" name="tax" type="taxSurcharge" /></xs:sequence></xs:complexType><xs:complexType name="surchargeInfo"><xs:sequence><xs:element maxOccurs="unbounded" name="cardSurchargeRate" type="cardSurchargeRate" /></xs:sequence></xs:complexType><xs:complexType name="cardSurchargeRate"><xs:sequence><xs:element minOccurs="0" name="surchargeCardType" type="acceptedCardType" /><xs:element name="surchargeBasis" type="surchargeBasis" /></xs:sequence></xs:complexType><xs:complexType name="acceptedCardType"><xs:sequence><xs:element minOccurs="0" name="cardDescription" type="cpt:cardDescription" /><xs:element minOccurs="0" name="cardType" type="cardType" /></xs:sequence></xs:complexType><xs:complexType name="surchargeBasis"><xs:annotation><xs:documentation>At least one of surchargeFixed and/or
                        surchargeRate
                        is required</xs:documentation></xs:annotation><xs:all><xs:element minOccurs="0" name="surchargeFixed" type="cpt:generalAmountPositive" /><xs:element minOccurs="0" name="surchargeRate" type="cpt:generalDecimalPositive" /></xs:all></xs:complexType><xs:complexType name="taxSurcharge"><xs:sequence><xs:element minOccurs="0" name="vat" type="vatSurcharge" /></xs:sequence></xs:complexType><xs:complexType name="vatSurcharge"><xs:complexContent><xs:extension base="vatBase" /></xs:complexContent></xs:complexType><xs:complexType name="itemBase"><xs:sequence><xs:element name="itemSummary" type="summaryData" /><xs:element minOccurs="0" name="tax" type="taxItem" /><xs:element minOccurs="0" name="quantity" type="cpt:generalShort" /><xs:element minOccurs="0" name="notificationEmails" type="notificationEmails" /><xs:element minOccurs="0" name="lgItemDetails" type="lgItemDetails" /><xs:element minOccurs="0" name="customerInfo" type="customerInfo" /><xs:element name="lineId" type="cpt:lineId" /></xs:sequence></xs:complexType><xs:complexType name="notificationEmails"><xs:sequence><xs:element maxOccurs="5" name="email" type="cpt:email" /><xs:element minOccurs="0" name="additionalEmailMessage" type="cpt:generalLongString" /></xs:sequence></xs:complexType><xs:complexType name="lgItemDetails"><xs:all><xs:element minOccurs="0" name="fundCode" type="cpt:generalCode" /><xs:element minOccurs="0" name="isFundItem" type="xs:boolean" /><xs:element minOccurs="0" name="additionalReference" type="cpt:generalString" /><xs:element minOccurs="0" name="narrative" type="cpt:generalString" /><xs:element minOccurs="0" name="accountName" type="threePartName" /><xs:element minOccurs="0" name="accountAddress" type="address" /><xs:element minOccurs="0" name="contact" type="contact" /></xs:all></xs:complexType><xs:complexType name="customerInfo"><xs:sequence><xs:element minOccurs="0" name="customerString1" type="cpt:generalString" /><xs:element minOccurs="0" name="customerString2" type="cpt:generalString" /><xs:element minOccurs="0" name="customerString3" type="cpt:generalString" /><xs:element minOccurs="0" name="customerString4" type="cpt:generalString" /><xs:element minOccurs="0" name="customerString5" type="cpt:generalString" /><xs:element minOccurs="0" name="customerNumber1" type="xs:int" /><xs:element minOccurs="0" name="customerNumber2" type="xs:int" /><xs:element minOccurs="0" name="customerNumber3" type="xs:int" /><xs:element minOccurs="0" name="customerNumber4" type="xs:int" /></xs:sequence></xs:complexType><xs:complexType name="bankDetails"><xs:complexContent><xs:extension base="bacsBankAccount"><xs:sequence><xs:element minOccurs="0" name="bacsReference" type="cpt:bacsReference" /></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="bacsBankAccount"><xs:sequence><xs:element name="sortCode" type="cpt:bankSortCode" /><xs:element name="bacsAccountNumber" type="cpt:bankAccountNumber" /></xs:sequence></xs:complexType><xs:complexType name="scpInvokeResponse"><xs:complexContent><xs:extension base="scpResponse"><xs:sequence><xs:element name="invokeResult"><xs:complexType><xs:sequence><xs:element name="status" type="status" /><xs:choice><xs:element name="redirectUrl" type="xs:token" /><xs:element name="errorDetails" type="errorDetails" /></xs:choice></xs:sequence></xs:complexType></xs:element></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="scpResponse"><xs:sequence><xs:element minOccurs="0" name="requestId" type="xs:token" /><xs:element name="scpReference" type="xs:string" /><xs:element name="transactionState" type="transactionState" /></xs:sequence></xs:complexType><xs:simpleType name="transactionState"><xs:restriction base="xs:string"><xs:enumeration value="IN_PROGRESS" /><xs:enumeration value="COMPLETE" /><xs:enumeration value="INVALID_REFERENCE" /></xs:restriction></xs:simpleType><xs:simpleType name="status"><xs:restriction base="xs:string"><xs:enumeration value="SUCCESS" /><xs:enumeration value="INVALID_REQUEST" /><xs:enumeration value="CARD_DETAILS_REJECTED" /><xs:enumeration value="CANCELLED" /><xs:enumeration value="LOGGED_OUT" /><xs:enumeration value="NOT_ATTEMPTED" /><xs:enumeration value="ERROR" /></xs:restriction></xs:simpleType><xs:complexType name="errorDetails"><xs:sequence><xs:element minOccurs="0" name="errorId" type="xs:string" /><xs:element minOccurs="0" name="errorMessage" type="xs:string" /></xs:sequence></xs:complexType><xs:complexType name="scpQueryRequest"><xs:complexContent><xs:extension base="requestWithCredentials"><xs:sequence><xs:element name="siteId" type="xs:int" /><xs:element name="scpReference" type="xs:string" /></xs:sequence><xs:attribute default="false" name="acceptNonCardResponseData" type="xs:boolean" use="optional" /></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="scpQueryResponse"><xs:complexContent><xs:extension base="scpResponse"><xs:sequence><xs:element minOccurs="0" name="storeCardResult" type="storeCardResult" /><xs:element minOccurs="0" name="emailResult" type="emailResult" /></xs:sequence></xs:extension></xs:complexContent></xs:complexType><xs:complexType name="storeCardResult"><xs:sequence><xs:element name="status" type="status" /><xs:choice minOccurs="0"><xs:element name="storedCardDetails" type="storedCardDetails" /><xs:element name="errorDetails" type="errorDetails" /></xs:choice></xs:sequence></xs:complexType><xs:complexType name="storedCardDetails"><xs:sequence><xs:element name="storedCardKey" type="storedCardKey" /><xs:element name="cardDescription" type="cpt:cardDescription" /><xs:element name="cardType" type="cardType" /><xs:element minOccurs="0" name="expiryDate" type="cpt:generalDateMMYY" /></xs:sequence></xs:complexType><xs:complexType name="emailResult"><xs:sequence><xs:element name="status" type="status" /><xs:element name="errorDetails" type="errorDetails" /></xs:sequence></xs:complexType><xs:complexType name="paymentResultBase"><xs:sequence><xs:element name="status" type="status" /></xs:sequence></xs:complexType><xs:complexType name="paymentBase"><xs:sequence><xs:element name="paymentHeader" type="paymentHeader" /><xs:choice><xs:element name="authDetails" type="authDetails" /><xs:element name="nonCardPayment" type="nonCardPayment" /></xs:choice></xs:sequence></xs:complexType><xs:complexType name="paymentHeader"><xs:sequence><xs:element name="transactionDate" type="cpt:generalDate" /><xs:element name="machineCode" type="cpt:generalCode" /><xs:element name="uniqueTranId"><xs:simpleType><xs:restriction base="xs:string"><xs:length value="12" /></xs:restriction></xs:simpleType></xs:element></xs:sequence></xs:complexType><xs:complexType name="authDetails"><xs:sequence><xs:element name="authCode" type="cpt:generalString" /><xs:element name="amountInMinorUnits" type="cpt:generalAmount" /><xs:element name="maskedCardNumber" type="cpt:maskedCardNumber" /><xs:element name="cardDescription" type="cpt:cardDescription" /><xs:element name="cardType" type="cardType" /><xs:element name="merchantNumber" type="cpt:generalString" /><xs:element minOccurs="0" name="expiryDate" type="cpt:generalDateMMYY" /><xs:element minOccurs="0" name="continuousAuditNumber" type="cpt:generalSequenceNumber" /></xs:sequence></xs:complexType><xs:complexType name="nonCardPayment"><xs:sequence><xs:element name="amountInMinorUnits" type="cpt:generalAmount" /><xs:element minOccurs="0" name="continuousAuditNumber" type="cpt:generalSequenceNumber" /><xs:element name="paymentType" type="cpt:generalString" /><xs:element name="paymentProviderReference" type="cpt:generalString" /></xs:sequence></xs:complexType><xs:complexType name="itemSummaryBase"><xs:sequence><xs:element name="lineId" type="cpt:lineId" /><xs:element name="continuousAuditNumber" type="cpt:generalSequenceNumber" /></xs:sequence></xs:complexType><xs:complexType name="surchargeDetails"><xs:sequence><xs:element name="fundCode" type="cpt:generalCode" /><xs:element name="reference" type="cpt:generalString" /><xs:element name="amountInMinorUnits" type="cpt:generalAmount" /><xs:element name="surchargeBasis" type="surchargeBasis" /><xs:element minOccurs="0" name="continuousAuditNumber" type="cpt:generalSequenceNumber" /><xs:element name="vatAmountInMinorUnits" type="cpt:generalAmount" /></xs:sequence></xs:complexType></xs:schema></wsdl:types><wsdl:message name="scpSimpleQueryRequest"><wsdl:part element="tns:scpSimpleQueryRequest" name="scpSimpleQueryRequest" /></wsdl:message><wsdl:message name="scpSimpleInvokeRequest"><wsdl:part element="tns:scpSimpleInvokeRequest" name="scpSimpleInvokeRequest" /></wsdl:message><wsdl:message name="scpVersionResponse"><wsdl:part element="sch3:scpVersionResponse" name="scpVersionResponse" /></wsdl:message><wsdl:message name="scpVersionRequest"><wsdl:part element="sch3:scpVersionRequest" name="scpVersionRequest" /></wsdl:message><wsdl:message name="scpSimpleQueryResponse"><wsdl:part element="tns:scpSimpleQueryResponse" name="scpSimpleQueryResponse" /></wsdl:message><wsdl:message name="scpSimpleInvokeResponse"><wsdl:part element="tns:scpSimpleInvokeResponse" name="scpSimpleInvokeResponse" /></wsdl:message><wsdl:portType name="scp"><wsdl:operation name="scpSimpleQuery"><wsdl:input message="tns:scpSimpleQueryRequest" name="scpSimpleQueryRequest" /><wsdl:output message="tns:scpSimpleQueryResponse" name="scpSimpleQueryResponse" /></wsdl:operation><wsdl:operation name="scpSimpleInvoke"><wsdl:input message="tns:scpSimpleInvokeRequest" name="scpSimpleInvokeRequest" /><wsdl:output message="tns:scpSimpleInvokeResponse" name="scpSimpleInvokeResponse" /></wsdl:operation><wsdl:operation name="scpVersion"><wsdl:input message="tns:scpVersionRequest" name="scpVersionRequest" /><wsdl:output message="tns:scpVersionResponse" name="scpVersionResponse" /></wsdl:operation></wsdl:portType><wsdl:binding name="scpSoap11" type="tns:scp"><soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" /><wsdl:operation name="scpSimpleQuery"><soap:operation soapAction="" /><wsdl:input name="scpSimpleQueryRequest"><soap:body use="literal" /></wsdl:input><wsdl:output name="scpSimpleQueryResponse"><soap:body use="literal" /></wsdl:output></wsdl:operation><wsdl:operation name="scpSimpleInvoke"><soap:operation soapAction="" /><wsdl:input name="scpSimpleInvokeRequest"><soap:body use="literal" /></wsdl:input><wsdl:output name="scpSimpleInvokeResponse"><soap:body use="literal" /></wsdl:output></wsdl:operation><wsdl:operation name="scpVersion"><soap:operation soapAction="" /><wsdl:input name="scpVersionRequest"><soap:body use="literal" /></wsdl:input><wsdl:output name="scpVersionResponse"><soap:body use="literal" /></wsdl:output></wsdl:operation></wsdl:binding><wsdl:service name="scpService"><wsdl:port binding="tns:scpSoap11" name="scpSoap11"><soap:address location="https://sbsctest.e-paycapita.com:443/scp/scpws" /></wsdl:port></wsdl:service></wsdl:definitions>
    
    Prio-2 bug 
    opened by longsonr 8
  • Feature: smart node selection (load-balancing/failover) by monitoring failures

    Feature: smart node selection (load-balancing/failover) by monitoring failures

    The README of this GitHub project currently lists these 4 bullets under "What is Membrane":

    • a Service Virtualization layer,
    • an API Gateway,
    • a synchronous ESB for HTTP based Integration,
    • a Security Proxy.

    The 2 most important features for me are not listed: load-balancing and failover. As of now the built-in functionality is pretty basic.

    This feature request is for smarter handling. I'm going to contribute a DispatchingStrategy that monitors service failures and acts accordingly to them.

    opened by fabiankessler 7
  • SwaggerProxy does not resolve some URLs

    SwaggerProxy does not resolve some URLs

    works fine. But:

    throws a FileNotFound Exception

    See the Mail Report from Brian below:

    I'm trying to proxy a toy swagger file using membrane but I keep getting the error pasted below. I was wondering if you had any idea what I'm doing wrong. The url to the swagger.json file is definitely valid. My proxies.xml file is attached Also, an unrelated question, does membrane support yaml formatted swagger files or does it only support json?

    The error: Membrane Router running... 20:25:39,211 INFO TrackingFileSystemXmlApplicationContext:583 - Refreshing Membrane Service Proxy's Spring Context 20:25:39,291 INFO XmlBeanDefinitionReader:317 - Loading XML bean definitions from URL [file:/home/bmason/Projects/membrane/membrane-service-proxy-4.6.2/conf/proxies.xml] 20:25:40,263 INFO DefaultLifecycleProcessor:345 - Starting beans in phase 0 org.springframework.context.ApplicationContextException: Failed to start bean 'router'; nested exception is java.lang.RuntimeException: com.predic8.membrane.core.resolver.ResourceRetrievalException: java.io.FileNotFoundException: swagger.json (No such file or directory) while retrieving swagger.json at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:176) at org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:50) at org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:350) at org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:149) at org.springframework.context.support.DefaultLifecycleProcessor.start(DefaultLifecycleProcessor.java:92) at org.springframework.context.support.AbstractApplicationContext.start(AbstractApplicationContext.java:1305) at com.predic8.membrane.core.Router.init(Router.java:146) at com.predic8.membrane.core.RouterCLI.main(RouterCLI.java:42) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.predic8.membrane.core.Starter.main(Starter.java:26) Caused by: java.lang.RuntimeException: com.predic8.membrane.core.resolver.ResourceRetrievalException: java.io.FileNotFoundException: swagger.json (No such file or directory) while retrieving swagger.json at com.predic8.membrane.core.Router.start(Router.java:285) at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:173) ... 12 more Caused by: com.predic8.membrane.core.resolver.ResourceRetrievalException: java.io.FileNotFoundException: swagger.json (No such file or directory) while retrieving swagger.json at com.predic8.membrane.core.resolver.FileSchemaResolver.resolve(FileSchemaResolver.java:75) at com.predic8.membrane.core.resolver.ResolverMap.resolve(ResolverMap.java:181) at com.predic8.membrane.core.interceptor.swagger.SwaggerRewriterInterceptor.init(SwaggerRewriterInterceptor.java:80) at com.predic8.membrane.core.interceptor.AbstractInterceptor.init(AbstractInterceptor.java:105) at com.predic8.membrane.core.rules.AbstractProxy.init(AbstractProxy.java:171) at com.predic8.membrane.core.Router.init(Router.java:256) at com.predic8.membrane.core.Router.start(Router.java:270) ... 13 more Caused by: java.io.FileNotFoundException: swagger.json (No such file or directory) at java.io.FileInputStream.open0(Native Method) at java.io.FileInputStream.open(FileInputStream.java:195) at java.io.FileInputStream.(FileInputStream.java:138) at com.predic8.membrane.core.resolver.FileSchemaResolver.resolve(FileSchemaResolver.java:73) ... 19 more

    bug 
    opened by predic8 7
  • Exception with FileExchangeStore after upgrading to Membrane v4.7.1

    Exception with FileExchangeStore after upgrading to Membrane v4.7.1

    Hi,

    We recently upgraded Membrane Service Proxy to version 4.7.1 and started having issues with web services which were working fine before. The only workaround we found to make it work again is to disable file exchange store in those services. We get the following error when service is called with file echange store enabled:

    [2020-08-03 13:56:12,279] DEBUG HttpClient:186 - try # 0 to http://report-test.xxxx.xxx:80/rest/
    [2020-08-03 13:56:12,279] DEBUG ConnectionManager:145 - connection requested for report-test.xxxx.xx:80
    [2020-08-03 13:56:12,279] DEBUG ConnectionManager:147 - Number of connections in pool: 2
    [2020-08-03 13:56:12,280] DEBUG Connection:111 - Opened connection on localPort: 46356
    [2020-08-03 13:56:12,280] DEBUG ChunkedBody:123 - writeNotReadChunked
    [2020-08-03 13:56:42,314] ERROR FileExchangeStore:124 - java.net.SocketTimeoutException: Read timed out
    java.net.SocketTimeoutException: Read timed out
            at java.net.SocketInputStream.socketRead0(Native Method)
            at java.net.SocketInputStream.socketRead(SocketInputStream.java:116)
            at java.net.SocketInputStream.read(SocketInputStream.java:171)
            at java.net.SocketInputStream.read(SocketInputStream.java:141)
            at java.io.BufferedInputStream.fill(BufferedInputStream.java:246)
            at java.io.BufferedInputStream.read(BufferedInputStream.java:265)
            at com.predic8.membrane.core.util.HttpUtil.readChunkSize(HttpUtil.java:87)
            at com.predic8.membrane.core.http.ChunkedBody$1.readNextChunk(ChunkedBody.java:99)
            at com.predic8.membrane.core.http.BodyInputStream.advanceToNextPosition(BodyInputStream.java:72)
            at com.predic8.membrane.core.http.BodyInputStream.read(BodyInputStream.java:111)
            at java.io.InputStream.read(InputStream.java:101)
            at com.predic8.membrane.core.util.ByteUtil.readStream(ByteUtil.java:71)
            at com.predic8.membrane.core.http.ChunkedBody.read(ChunkedBody.java:47)
            at com.predic8.membrane.core.http.AbstractBody.getContent(AbstractBody.java:100)
            at com.predic8.membrane.core.exchangestore.FileExchangeStore.writeFile(FileExchangeStore.java:177)
            at com.predic8.membrane.core.exchangestore.FileExchangeStore.snapInternal(FileExchangeStore.java:116)
            at com.predic8.membrane.core.exchangestore.FileExchangeStore.access$000(FileExchangeStore.java:52)
            at com.predic8.membrane.core.exchangestore.FileExchangeStore$1.bodyComplete(FileExchangeStore.java:88)
            at com.predic8.membrane.core.http.AbstractBody.markAsRead(AbstractBody.java:74)
            at com.predic8.membrane.core.http.ChunkedBody.markAsRead(ChunkedBody.java:60)
            at com.predic8.membrane.core.http.ChunkedBody.writeNotRead(ChunkedBody.java:135)
            at com.predic8.membrane.core.http.AbstractBody.write(AbstractBody.java:124)
            at com.predic8.membrane.core.http.ChunkedBody.write(ChunkedBody.java:55)
            at com.predic8.membrane.core.http.Message.write(Message.java:233)
            at com.predic8.membrane.core.transport.http.HttpClient.doCall(HttpClient.java:360)
            at com.predic8.membrane.core.transport.http.HttpClient.call(HttpClient.java:216)
            at com.predic8.membrane.core.interceptor.HTTPClientInterceptor.handleRequest(HTTPClientInterceptor.java:60)
            at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeRequestHandlers(InterceptorFlowController.java:106)
            at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:71)
            at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:70)
            at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:234)
            at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:119)
            at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
            at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
            at java.lang.Thread.run(Thread.java:748)
    [2020-08-03 13:56:42,318] DEBUG Response:376 - empty body created
    [2020-08-03 13:56:42,318] DEBUG InterceptorFlowController:126 - Invoking response handler: WSDL Rewriting Interceptor on exchange: [time:Aug 3, 2020,requestURI:/rest/]
    [2020-08-03 13:56:42,318] DEBUG RelocatingInterceptor:45 - WSDL Rewriting Interceptor HTTP method wasn't GET: No relocating done!
    

    Request headers

    Content-Type	application/json
    Accept	*/*
    User-Agent	Apache-CXF/3.2.6
    Cache-Control	no-cache
    Pragma	no-cache
    Host	report-test.xxxx.xxx:80
    Connection	keep-alive
    Transfer-Encoding	chunked
    X-Forwarded-For	xxx.xxx.xxx.xxx
    X-Forwarded-Proto	http
    X-Forwarded-Host	somehost.xxx.xx
    

    Request content

    {
        "bucketName": "expat",
        "objectName": "xxx.xxx-xx__E68_ex_lettre_etr_autre_20200803134639_1596462399846.pdf",
        "reportTemplateName": "EX_LETTRE_ETR_AUTRE",
        "reportLocale": "FR",
        "reportType": "pdf",
        "reportParameters": {
            "P_LOGO": "CIAM"
        },
        "data": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<Document>....<\/Document>"
    }
    
    opened by jRom42 7
  • webServer loads files completely into memory

    webServer loads files completely into memory

    and this fails, if the file is larger than the heap size

    bug 
    opened by rrayst 6
  • Add doc for JWT Auth Interceptor

    Add doc for JWT Auth Interceptor

    opened by xorpherion 0
  • support Kubernetes Secret/ConfigMap lookup through resolver ('location' attribute)

    support Kubernetes Secret/ConfigMap lookup through resolver ('location' attribute)

    support Kubernetes Secret/ConfigMap lookup through resolver ('location' attribute)

    issue:

    • how to notify resource changes?
    opened by rrayst 0
  • Set Header Interceptor

    Set Header Interceptor

    You can set header using groovy but it might comfortable to have an dedicated interceptor:

    <header name="foo" value="42"/>
    

    It should be possible to use an expression language inside the value field. Something like:

    <header name="foo" value="${exc.request.headers['Bar']}"/>
    

    or

    Do we have alread an Expression Language, Should we use Groovy or and a language?

    Prio-2 enhancement 
    opened by predic8 0
  • OAuth2AuthorizationServer2Interceptor: TODOs for feature parity

    OAuth2AuthorizationServer2Interceptor: TODOs for feature parity

    • Issue non spec tokens
    • relative paths
    • "claims" Request Parameter of openid connect
    • scope construction from claims should be valid
    • token generator bean support
    • use LoginDialog instead of LoginDialog2
    • disable grants
    opened by xorpherion 0
  • Enhancement Delayed start for OpenID Provider

    Enhancement Delayed start for OpenID Provider

    Hello, We have made a few derivations on our copy from the upstream. We want to share them with you so if you find them useful you can also benefit from the code changes.

    This is the 4th of 4 changes.

    Motivation: Hosting the Open ID provider and another router may cause startup ordering issues. If Open ID provider can be started after the router this is solved.

    opened by precoder 3
  • Add reporting plugins to pom.xml

    Add reporting plugins to pom.xml

    Please add reporting plugins to pom.xml to update dependency versions properly.

    Add dependency-updates-report for reporting project dependencies which have newer versions available. Add OWASP dependency-check for reporting any vulnerable components in the project dependencies.

    
    	<reporting>
    		<plugins>
    		
    		    ...
    
    			<!-- OWASP dependency-check -->
                <plugin>
                    <groupId>org.owasp</groupId>
                    <artifactId>dependency-check-maven</artifactId>
                    <version>4.0.0</version>
                    <reportSets>
                        <reportSet>
                            <reports>
                                <report>aggregate</report>
                            </reports>
                        </reportSet>
                    </reportSets>
                </plugin>
    			
    			<!-- Updates Reports -->
    			<plugin>
    				<groupId>org.codehaus.mojo</groupId>
    				<artifactId>versions-maven-plugin</artifactId>
    				<configuration>
    					<rulesUri>file://${basedir}/maven-version-rules.xml</rulesUri>
    				</configuration>
    				<reportSets>
    					<reportSet>
    						<reports>
    							<report>dependency-updates-report</report>
    							<report>plugin-updates-report</report>
    						</reports>
    					</reportSet>
    				</reportSets>
    			</plugin>
    
    
    opened by LarsTor 0
  • Memory Leak with Groovy header manipulation

    Memory Leak with Groovy header manipulation

    We have an issue with membrane where apparently a memory leak with groovy causes some internal classloader hashmap to increase in size over time, causing membrane to eat up all cpu without actually doing anything. I have a heap dump here but I fail to really understand what is causing this. Anybody else witnessed this?

    If you can tell me a place where I can upload a heapdump of this size I'll gladly provide it. The accompanying configuration will follow tomorrow, Membrane in use is 4.6.1 or 4.6.2 (honestly can't tell, will check tomorrow)

    opened by DJGummikuh 1
  • OAuth2Resource: Sending token in request (without use of OAuth2Resource) breaks refreshing (only vague description available)

    OAuth2Resource: Sending token in request (without use of OAuth2Resource) breaks refreshing (only vague description available)

    INFO | jvm 1 | 2018/02/14 15:50:43 | 15:50:43,188 WARN AbstractHttpHandler:89 - An exception occured while handling a request: INFO | jvm 1 | 2018/02/14 15:50:43 | java.lang.NullPointerException INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.interceptor.oauth2.OAuth2ResourceInterceptor.refreshingOfAccessTokenIsNeeded(OAuth2ResourceInterceptor.java:316) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.interceptor.oauth2.OAuth2ResourceInterceptor.handleRequestInternal(OAuth2ResourceInterceptor.java:248) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.interceptor.oauth2.OAuth2ResourceInterceptor.handleRequest(OAuth2ResourceInterceptor.java:191) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeRequestHandlers(InterceptorFlowController.java:106) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.interceptor.UserFeatureInterceptor.handleRequest(UserFeatureInterceptor.java:43) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeRequestHandlers(InterceptorFlowController.java:106) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:71) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:70) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:234) INFO | jvm 1 | 2018/02/14 15:50:43 | at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:119) INFO | jvm 1 | 2018/02/14 15:50:43 | at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) INFO | jvm 1 | 2018/02/14 15:50:43 | at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) INFO | jvm 1 | 2018/02/14 15:50:43 | at java.lang.Thread.run(Thread.java:745)

    external client negotiates a token on its own and sends the token to a resource that is protected by oauth2resource -> this takes the "no session, authorization header available" path

    opened by xorpherion 0
  • Documentation on using rest2soap-json

    Documentation on using rest2soap-json

    Hi I have been trying to make the rest2soap-json example work with another more complex SOAP API. I find it difficult to configure the xsl files with respect to parsing data from JSON body of the request.

    It is stated here that the body is directly converted to XML in case appropriate Content-Type header is set on the request, but do we need to set the requestXSLT attribute in the proxies.xml? If yes, what would the xsl file look like?

    As of now, I get the following error when I try to leave the requestXSLT attribute blank in the proxies.xml file.

    javax.xml.transform.TransformerException: javax.xml.transform.TransformerException: com.sun.org.apache.xml.internal.utils.WrappedRuntimeException: Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:95)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:77)
    	at com.predic8.membrane.core.interceptor.rest.REST2SOAPInterceptor.handleResponse(REST2SOAPInterceptor.java:191)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeResponseHandlers(InterceptorFlowController.java:128)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:79)
    	at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:70)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:234)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:119)
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.lang.Thread.run(Unknown Source)
    Caused by: javax.xml.transform.TransformerException: com.sun.org.apache.xml.internal.utils.WrappedRuntimeException: Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.getDOM(Unknown Source)
    	... 13 more
    Caused by: com.sun.org.apache.xml.internal.utils.WrappedRuntimeException: Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	... 14 more
    ---------
    javax.xml.transform.TransformerException: com.sun.org.apache.xml.internal.utils.WrappedRuntimeException: Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.getDOM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:95)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:77)
    	at com.predic8.membrane.core.interceptor.rest.REST2SOAPInterceptor.handleResponse(REST2SOAPInterceptor.java:191)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeResponseHandlers(InterceptorFlowController.java:128)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:79)
    	at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:70)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:234)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:119)
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.lang.Thread.run(Unknown Source)
    Caused by: com.sun.org.apache.xml.internal.utils.WrappedRuntimeException: Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	... 14 more
    ---------
    com.sun.org.apache.xml.internal.utils.WrappedRuntimeException: Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.getDOM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:95)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:77)
    	at com.predic8.membrane.core.interceptor.rest.REST2SOAPInterceptor.handleResponse(REST2SOAPInterceptor.java:191)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeResponseHandlers(InterceptorFlowController.java:128)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:79)
    	at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:70)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:234)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:119)
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.lang.Thread.run(Unknown Source)
    ---------
    org.xml.sax.SAXParseException; lineNumber: 28; columnNumber: 65; Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
    	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanAttributeValue(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanAttribute(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    	at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
    	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.getDOM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:95)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:77)
    	at com.predic8.membrane.core.interceptor.rest.REST2SOAPInterceptor.handleResponse(REST2SOAPInterceptor.java:191)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeResponseHandlers(InterceptorFlowController.java:128)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:79)
    	at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:70)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:234)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:119)
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.lang.Thread.run(Unknown Source)
    ---------
    com.sun.org.apache.xml.internal.utils.WrappedRuntimeException: Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.getDOM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:95)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:77)
    	at com.predic8.membrane.core.interceptor.rest.REST2SOAPInterceptor.handleResponse(REST2SOAPInterceptor.java:191)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeResponseHandlers(InterceptorFlowController.java:128)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:79)
    	at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:70)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:234)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:119)
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.lang.Thread.run(Unknown Source)
    ---------
    org.xml.sax.SAXParseException; lineNumber: 28; columnNumber: 65; Open quote is expected for attribute "width" associated with an  element type  "hr".
    	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
    	at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanAttributeValue(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanAttribute(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)
    	at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
    	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    	at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)
    	at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)
    	at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.dom.XSLTCDTMManager.getDTM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.getDOM(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(Unknown Source)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:95)
    	at com.predic8.membrane.core.interceptor.xslt.XSLTTransformer.transform(XSLTTransformer.java:77)
    	at com.predic8.membrane.core.interceptor.rest.REST2SOAPInterceptor.handleResponse(REST2SOAPInterceptor.java:191)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeResponseHandlers(InterceptorFlowController.java:128)
    	at com.predic8.membrane.core.interceptor.InterceptorFlowController.invokeHandlers(InterceptorFlowController.java:79)
    	at com.predic8.membrane.core.transport.http.AbstractHttpHandler.invokeHandlers(AbstractHttpHandler.java:70)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.process(HttpServerHandler.java:234)
    	at com.predic8.membrane.core.transport.http.HttpServerHandler.run(HttpServerHandler.java:119)
    	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    	at java.lang.Thread.run(Unknown Source)
    

    And no, I did not have any element called width or hr in the proxies.xml or get2proxy.xsl files.

    It would be very helpful if you could add a basic example of parsing the body as well like how you did for the URI.

    Thanks, Shyam

    opened by shyamsathyanathan 3
Releases(v4.8.0)
API gateway for REST and SOAP written in Java.

API gateway for REST and SOAP written in Java.

predic8 GmbH 353 Apr 26, 2021
A Java library that implements a ByteChannel interface over SSLEngine, enabling easy-to-use (socket-like) TLS for Java applications.

TLS Channel TLS Channel is a library that implements a ByteChannel interface over a TLS (Transport Layer Security) connection. It delegates all crypto

Mariano Barrios 113 Mar 1, 2021
TCP/UDP client/server library for Java, based on Kryo

KryoNet can be downloaded on the releases page. Please use the KryoNet discussion group for support. Overview KryoNet is a Java library that provides

Esoteric Software 1.6k Mar 12, 2021
LINE 3k Mar 12, 2021
Fibers and actors for web development

COMSAT Scalable, Concurrent Web Apps Getting started Add the following Maven/Gradle dependencies: Feature Artifact Servlet integration for defining fi

Parallel Universe 586 Feb 23, 2021
jRT measures the response time of a java application to socket-based requests

jRT Version: 0.0.1 jRT is a instrumentation tool that logs and records networking I/O operations "response times" (applicaion response time if be corr

null 44 Feb 5, 2020
An annotation-based Java library for creating Thrift serializable types and services.

Drift Drift is an easy-to-use, annotation-based Java library for creating Thrift clients and serializable types. The client library is similar to JAX-

null 177 Mar 3, 2021
Apache Dubbo is a high-performance, java based, open source RPC framework.

Apache Dubbo Project Apache Dubbo is a high-performance, Java-based open-source RPC framework. Please visit official site for quick start and document

The Apache Software Foundation 34.8k Mar 13, 2021
Pcap editing and replay tools for *NIX and Windows - Users please download source from

Tcpreplay Tcpreplay is a suite of GPLv3 licensed utilities for UNIX (and Win32 under Cygwin) operating systems for editing and replaying network traff

AppNeta, Inc. 745 Mar 10, 2021
The Java gRPC implementation. HTTP/2 based RPC

gRPC-Java - An RPC library and framework gRPC-Java works with JDK 7. gRPC-Java clients are supported on Android API levels 16 and up (Jelly Bean and l

grpc 8.5k Mar 13, 2021
TCP/IP packet demultiplexer. Download from:

TCPFLOW 1.5.0 Downloads directory: http://digitalcorpora.org/downloads/tcpflow/ Installation Most common GNU/Linux distributions ship tcpflow in their

Simson L. Garfinkel 1.2k May 8, 2021
A Java library for capturing, crafting, and sending packets.

Japanese Logos Pcap4J Pcap4J is a Java library for capturing, crafting and sending packets. Pcap4J wraps a native packet capture library (libpcap, Win

Kaito Yamada 854 Mar 13, 2021
ssh, scp and sftp for java

sshj - SSHv2 library for Java To get started, have a look at one of the examples. Hopefully you will find the API pleasant to work with :) Getting SSH

Jeroen van Erp 1.8k Mar 12, 2021
Socket.IO server implemented on Java. Realtime java framework

Netty-socketio Overview This project is an open-source Java implementation of Socket.IO server. Based on Netty server framework. Checkout Demo project

Nikita Koksharov 5.2k Mar 14, 2021