Menu

Split Authentication

Split Authentication allows you to separate the authentication and authorisation process. This gives you full control, meaning you can do your own checks before submitting the payment for authorisation.

This guide allows you to integrate to Cardinal through Worldpay. Use Cardinal's own JavaScript for Device Data Collect and Challenge pages, as well as making use of Cardinal's own test system. You must have a Secure Test Cardinal profile before you can use this method of integration. For more information, contact your Implementation Manager.

Note:

  • You must be setup for 3DS Flex and the Secure Test connection to Cardinal, before using it. For more information, contact your Relationship Manager or Implementation Manager.
  • This service can only be used with adirect integration.
  • Ensure the <orderCode> used in your authentication request is different to the one in the authorisation request.

Split Authentication Flow

Challenge flow for Split Authentication

Device Data Collection (DDC)

JWT creation

All requests to Cardinal Commerce from the shopper's browser must be authenticated using a JSON Web Token (JWT). Providing this gives the shopper's browser access to resources to complete DDC and Challenges. You must create all JWT's on your server and not in the browser. This is because the JWT MAC Key, used in JWT creation, must only be known to you, Worldpay and Cardinal Commerce.

Best practice: We strongly recommend that you use a third-party library to create the JWT in its entirety.

JWT structure

JWT's consist of three parts (Header, Body and MAC). They are described below:

Header

The purpose of the header is to identify that the body is a JWT and to specify the message authentication algorithm. This is used to create the Message Authentication Code (MAC). The following algorithms are supported:

  • HS256 (HMAC with SHA256)
  • HS512 (HMAC with SHA512)

Example Header:

Copied!
{
  "typ":"JWT",
  "alg":"HS256"
}

Body

A JSON object that contains the claims (name-value pairs) being sent from one party to another. The body must only contain the claims below, adding additional claims results in 400 Bad Request response.

Claim NameM/ODescription
jtiMJWT Id - A unique identifier for this JWT. This field must be set to a random UUID each time a JWT is generated.
iatMIssued At - The epoch time (in seconds - 10 digits) of when the JWT was generated. Valid for two hours.
issMIssuer - An identifier for who is issuing the JWT. Once boarded to Cardinal in Secure Test, you can find these details in the Test version of the MAI. You'll need to use the Production credentails for Production.
expOExpiration - The numeric epoch time (in seconds - 10 digits) that the JWT should be considered expired. Anything over two hours in the future is ignored.
OrgUnitIdMOrganisational Unit Id - An identity associated with your account. Once boarded to Cardinal in Secure Test, you can find this in the Test version of the MAI. You'll need to use the Production credentails for Production.

Example Body:

Copied!
{
  "jti": "69adc185-1748-4525-9ef9-43f259a1c2d6",
  "iat": 1548838855,
  "iss": "5bd9e0e4444dce153428c940",
  "exp": 1548838900,
  "OrgUnitId": "5bd9b55e4444761ac0af1c80"
}

MAC

A base64url encoded hash value of the header and payload combined with a JWT MAC Key. This is used to verify that the contents of the JWT have not been tampered with. Authentication codes are verified by the consumer by recreating the MAC from the JWT header, body and JWT MAC Key.

AttributeDescription
JWT MAC KeyPass this as a string and not a number. Once boarded to Cardinal in Secure Test, you can find this in the Test version of the MAI. You'll need to use the Production credentails for Production.

DDC initiation

DDC requires you to change your website to run JavaScript from Cardinal Commerce on your page. The JavaScript runs on the shopper's browser to collect device data as part of the authentication process regardless whether 3DS1 or 3DS2 is used.

Place an invisible iframe on your page. Create a form in the iframe using the POST method with action="https://centinelapistag.cardinalcommerce.com/V1/Cruise/Collect". Include the field JWT and Bin as described below. Do not submit this form until the card can no longer be changed.

FieldDescription
JWTThe authentication token, as describedabove.
BinThe card number (PAN). Minimum of first six digits.

Note: We strongly recommend providing the first nine digits of the PAN. This will allow the issuer's Method URL to run, which may increase authentication success. This ensures you're capturing both six and eight digit BIN ranges, after the eight digit BINs are introduced in March 2022.
Fortokenisationuse the value of <bin>.

Here's an example of one way to do it:

Copied!
<iframe height="1" width="1" style="display: none;">
  <!-- This is a Cardinal Commerce URL in live. -->
  <form id="collectionForm" method="POST" action="https://centinelapistag.cardinalcommerce.com/V1/Cruise/Collect">
    <input type="hidden" name="Bin" value="4000000000001000" />
    <input type="hidden" name="JWT" value="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJqdGkiOiI2OWFkYzE4NS0xNzQ4LTQ1MjUtOWVmOS00M2YyNTlhMWMyZDYiLCJpYXQiOjE1NDg4Mzg4NTUsImlzcyI6IjViZDllMGU0NDQ0ZGNlMTUzNDI4Yzk0MCIsIk9yZ1VuaXRJZCI6IjViZDliNTVlNDQ0NDc2MWFjMGFmMWM4MCJ9.qTyYn4rItMMNdnh6ouqW6ZmcCNzaG9JI_GdWGIaq6rY" />
  </form>
  <script>
    window.onload = function() {
      document.getElementById('collectionForm').submit();
    }
  </script>
</iframe>

DDC Outcome

You are notified via a JavaScript postMessage that DDC has been completed. Your website must listen for this notification which will contain the following fields:

NameValue
MessageTypeprofile.completed
SessionIdUUID, not present or undefined
Statustrue or false

There are three possible scenarios:

StatusAction
trueSend SessionId as dfReferenceId in initial payment request.
falseSessionId will be empty. Either retry DDC or send empty dfReferenceId which will downgrade authentication to 3DS1.
No callbackEither retry DDC or send empty dfReferenceId which will downgrade authentication to 3DS1.

Example postMessage:

Copied!
{
    "MessageType": "profile.completed",
    "SessionId": "d3197c02-6f63-4ab2-801c-83633d097e32",
    "Status": true
}

Here's some example JavaScript code for reference:

Copied!
window.addEventListener("message", function(event) {
   //This is a Cardinal Commerce URL in live.
   if (event.origin === "https://centinelapistag.cardinalcommerce.com") {
       var data = JSON.parse(event.data);
       console.warn('Merchant received a message:', data);
       if (data !== undefined && data.Status) {
           // Extract the value of SessionId for onward processing.
       }
   }
}, false);

Extract the SessionId, if returned, and retain it for use in your initial payment request.

Authenticate request

The first Split Authentication request is an enrolment check. This request inquires if the shopper and issuer are enrolled for 3DS. For 3DS2 the issuers can authenticate the shopper without a challenge, given the shopper and issuer support 3DS2. This means the cardholder could be authenticated after the first request. Therefore, the authenticate request can invoke different outcomes.

Structure your first authenticate request the same way as the3DS Flexinitial payment request. However, to indicate your request is for Split Authentication you must supply the action attribute in paymentDetails with a value of AUTHENTICATE (<paymentDetails action="AUTHENTICATE">).

Note: We recommend providing an orderCode of less than 50 characters for 3DS Flex requests. Where the orderCode is longer than 50 characters, we will truncate it for downstream processing. This adjusted orderCode is only be used in Cardinal's systems.
This doesn't impact the orderCode that is stored internally, the orderCode that is returned to you, or the orderCode that is visible in the Merchant Admin Interface (MAI).

Supply the following additional sections in your authenticate request:

  1. additional3DSData (Mandatory)
  2. riskData (Recommended to increase chances of a frictionless flow)

Specifying Additional 3DS Data

<additional3DSData> has 3 different attributes:

AttributesDescription
dfReferenceIdThe SessionId returned in the JavaScript postMessage after DDC is complete.
challengePreferencePossible Values:
  • noPreference - You have no preference whether a challenge should be performed. This is the default.
  • noChallengeRequested - You prefer that no challenge should be performed.
  • challengeRequested - You prefer that a challenge should be performed.
  • challengeMandated - There are local or regional mandates that mean that a challenge must be performed.

Note: The interpretation of this field will vary from issuer to issuer. Worldpay cannot guarantee any particular behaviour as a result of you setting this field.

challengeWindowSizeChallenge window size the issuer should use to display the challenge. Possible Values:
  • fullPage
  • 250x400
  • 390x400 (default)
  • 500x600
  • 600x400

Here is an example for <additional3DSData>:

Copied!
<order>
  ....

  <additional3DSData
    dfReferenceId="1f1154b7-620d-4654-801b-893b5bb22db1"
    challengeWindowSize="390x400"
    challengePreference="challengeMandated"/>
</order>

Adding Risk Data

Provide additional information in the <riskData> element to increase the chances that the shopper won't be challenged. <riskData> contains three child elements:

Complete initial Authenticate example:

Copied!
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE paymentService PUBLIC "-//Worldpay//DTD Worldpay PaymentService v1//EN"
  "http://dtd.worldpay.com/paymentService_v1.dtd">
<paymentService version="1.4" merchantCode="YOUR_MERCHANT_CODE">
  <submit>
    <order orderCode="YOUR_ORDER_CODE"> 
      <description>YOUR DESCRIPTION</description>
      <amount value="2000" currencyCode="EUR" exponent="2"/>
      <orderContent>
        <![CDATA[]]>
      </orderContent>
      <paymentDetails action="AUTHENTICATE">
        <CARD-SSL>
          <cardNumber>4000000000000002</cardNumber> <!-- Use a Cardinal PAN for the Secure Test connection to Cardinal -->
          <expiryDate>
            <date month="01" year="2020"/>
          </expiryDate>
          <cardHolderName>AUTHORISED</cardHolderName> <!-- Any value can be provided in cardHolderName for authentication -->
          <cvc>123</cvc>
          <cardAddress>
            <address>
              <address1>Worldpay</address1>
              <address2>270-289 The Science Park</address2>
              <address3>Milton Road</address3>
              <postalCode>CB4 0WE</postalCode>
              <city>Cambridge</city>
              <countryCode>GB</countryCode>
              <telephoneNumber>+12222345678</telephoneNumber><!-- No spaces, no hyphens. Country code 1 to 3 characters e.g."12", subscriber code 15 characters max e.g. "222345678". Maps to mobilePhone at Cardinal -->
            </address>
          </cardAddress>
        </CARD-SSL>
        <session shopperIPAddress="127.0.0.1" id="SESSION_ID"/> <!--Session id must be unique -->
      </paymentDetails>
      <shopper>
        <shopperEmailAddress>jshopper@myprovider.com</shopperEmailAddress>
        <browser>
          <acceptHeader>text/html</acceptHeader>
          <userAgentHeader>Mozilla/5.0 ...</userAgentHeader>
        </browser>
      </shopper>
      <!-- Optional Risk Data -->
      <riskData>
        <authenticationRiskData authenticationMethod="localAccount">
          <authenticationTimestamp><date second="01" minute="02" hour="03" dayOfMonth="01" month="06" year="2019"/></authenticationTimestamp>
        </authenticationRiskData>
        <shopperAccountRiskData
          transactionsAttemptedLastDay="1"
          transactionsAttemptedLastYear="100"
          purchasesCompletedLastSixMonths="50"
          addCardAttemptsLastDay="1"
          previousSuspiciousActivity="true"
          shippingNameMatchesAccountName="true"
          shopperAccountAgeIndicator="lessThanThirtyDays"
          shopperAccountChangeIndicator="lessThanThirtyDays"
          shopperAccountPasswordChangeIndicator="noChange"
          shopperAccountShippingAddressUsageIndicator="thisTransaction"
          shopperAccountPaymentAccountIndicator="lessThanThirtyDays">          
          <shopperAccountCreationDate><date dayOfMonth="01" month="02" year="2003"/></shopperAccountCreationDate>
          <shopperAccountModificationDate><date dayOfMonth="02" month="03" year="2004"/></shopperAccountModificationDate>
          <shopperAccountPasswordChangeDate><date dayOfMonth="03" month="04" year="2005"/></shopperAccountPasswordChangeDate>
          <shopperAccountShippingAddressFirstUseDate><date dayOfMonth="04" month="05" year="2006"/></shopperAccountShippingAddressFirstUseDate> 
          <shopperAccountPaymentAccountFirstUseDate><date dayOfMonth="05" month="06" year="2007"/></shopperAccountPaymentAccountFirstUseDate>
        </shopperAccountRiskData>
        <transactionRiskData
          shippingMethod="shipToBillingAddress"
          deliveryTimeframe="overnightShipping"
          deliveryEmailAddress="sp@worldpay.com"
          reorderingPreviousPurchases="true"
          preOrderPurchase="false"
          giftCardCount="1">
        <transactionRiskDataGiftCardAmount><amount value="1" currencyCode="EUR" exponent="2"/></transactionRiskDataGiftCardAmount>
          <transactionRiskDataPreOrderDate><date dayOfMonth="06" month="07" year="2008"/></transactionRiskDataPreOrderDate>
        </transactionRiskData>
      </riskData>
      <!-- Additional 3DS data that you must provide to us -->
      <additional3DSData
        dfReferenceId="1f1154b7-620d-4654-801b-893b5bb22db1"
        challengeWindowSize="390x400"
        challengePreference="challengeMandated"/>
    </order>
  </submit>
</paymentService>

Authenticate Response

The authenticate response is a final response, which could be returned if there is a frictionless 3DS2 response, or if the cardholder isn't enrolled for 3DS.

Below are three example responses:

Copied!
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE paymentService PUBLIC "-//WorldPay//DTD WorldPay PaymentService v1//EN"
   "http://dtd.worldpay.com/paymentService_v1.dtd">
<paymentService version="1.4" merchantCode="YOUR_MERCHANT_CODE">
   <reply>
      <orderStatus orderCode='YOUR_ORDER_CODE'>
         <authenticateResponse>
            <threeDSOutcome>
               <threeDSVersion>1.0.2</threeDSVersion>
               <enrolled>N</enrolled>
               <eci>06</eci>
            </threeDSOutcome>
         </authenticateResponse>
      </orderStatus>
   </reply>
</paymentService>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE paymentService PUBLIC "-//WorldPay//DTD WorldPay PaymentService v1//EN"
      "http://dtd.worldpay.com/paymentService_v1.dtd">
<paymentService version="1.4" merchantCode="YOUR_MERCHANT_CODE">
   <reply>
      <orderStatus orderCode='YOUR_ORDER_CODE'>
         <authenticateResponse>
            <threeDSOutcome>
               <threeDSVersion>1.0.2</threeDSVersion>
               <authenticationStatus>Y</authenticationStatus>
               <signatureVerification>Y</signatureVerification>
               <eci>05</eci>
               <xid>z9UKb06xLziZMOXBEmWSVA1kwG0=</xid>
               <cavv>MTIzNDU2Nzg5MDEyMzQ1Njc4OTA=</cavv>
            </threeDSOutcome>
         </authenticateResponse>
      </orderStatus>
   </reply>
</paymentService>
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE paymentService PUBLIC "-//WorldPay//DTD WorldPay PaymentService v1//EN"
      "http://dtd.worldpay.com/paymentService_v1.dtd">
<paymentService version="1.4" merchantCode="YOUR_MERCHANT_CODE">
   <reply>
      <orderStatus orderCode='YOUR_ORDER_CODE'>
         <authenticateResponse>
            <threeDSOutcome>
               <threeDSVersion>2.1.0</threeDSVersion>
               <enrolled>Y</enrolled>
               <authenticationStatus>Y</authenticationStatus>
               <signatureVerification>Y</signatureVerification>
               <cavv>MAAAAAAAAAAAAAAAAAAAAAAAAAA=</cavv>
               <eci>05</eci>
               <dsTransactionId>c5b808e7-1de1-4069-a17b-f70d3b3b1645</dsTransactionId>
            </threeDSOutcome>
         </authenticateResponse>
      </orderStatus>
   </reply>
</paymentService>

Challenge Response

In most cases, however, you are required to present a challenge to the shopper. The information to complete this is returned in the <challengeRequired> response.

3DS1 example:

Copied!
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE paymentService PUBLIC "-//WorldPay//DTD WorldPay PaymentService v1//EN"
      "http://dtd.worldpay.com/paymentService v1.dtd">
<paymentService version="1.4" merchantCode="YOUR_MERCHANT_CODE">
	<reply>
		<orderStatus orderCode='YOUR_ORDER_CODE'>
			<challengeRequired>
				<threeDSChallengeDetails>
					<threeDSVersion>2.1.0</threeDSVersion>
					<transactionId3DS>rUT8fLKDviHXr8aUn3l1</transactionId3DS>
					<acsURL><![CDATA[https://merchantacsstag.cardinalcommerce.com/MerchantACSWeb/...]]></acsURL> <!-- This will be a longer URL in test -->
					<payload>P.25de9db33221a55eedc6ac352b927a8c3a08d747643c592dd8f8ab7d3...</payload>
				</threeDSChallengeDetails>
			</challengeRequired>
		</orderStatus>
	</reply>
</paymentService>

You receive 3DS related data you need for the next step. These are sent as child elements of <threeDSChallengeDetails>:

ElementRequiredFormatDescription
<threeDSVersion>YAN(10)This field contains the 3DS version that was used to process the transaction.

Possible Values:
  • 1.0.2
  • 2.1.0
  • 2.2.0

Note: Required for Mastercard Identity Check transactions in Authorisation.

<acsURL>YAN(2048)The fully qualified URL to redirect the shopper to complete authentication.

Note: Only available if the shopper is enrolled.

<transactionId3DS>YAN(20)Authentication transaction identifier. This value identifies the transaction within the Worldpay system. Pass the value in the challenge request.
<payload>YAN(2048)The encoded payer authentication request.

Extract the information from the XML response and pass it back to the shopper browser to present the challenge page.

Present the 3DS Challenge

Create a challenge JWT on your server that is passed to the browser. Refer toCreating JWTsif you need to.

The challenge JWT contains more fields than the DDC one:

Claim NameDescription
jtiJWT Id - A unique identifier for this JWT. This field must be set to a random UUID each time a JWT is generated
iatIssued At - The epoch time (in seconds - 10 digits) of when the JWT was generated. Valid for 2 hours
issIssuer - An identifier of who is issuing the JWT. Once boarded to Cardinal in Secure Test, you can find these details in the Test version of the MAI. You'll need to use the Production credentails for Production
OrgUnitIdOrganisational Unit Id is an identity associated with your account. Once boarded to Cardinal in Secure Test, you can find these details in the Test version of the MAI. You'll need to use the Production credentails for Production
ReturnUrlThe URL on your website that is invoked when the challenge is complete, see below
PayloadJSON container for extra data required for a challenge
Payload.ACSUrlThe value of the <acsURL> element from the challengeRequired response
Payload.PayloadThe value of the <payload> element from the challengeRequired response
Payload.TransactionIdThe value of the <transactionId3DS> element from the challengeRequired response
ObjectifyPayloadSee below

Here's a full example of a challenge JWT:

Copied!
{
    "jti": "54438b3a-bb53-12cd-8643-1536be73ff35",
    "iat": 3856729482,
    "iss": "5bd9e0e4444dce153428c940",
    "OrgUnitId": "5bd9b55e4444761ac0af1c80",
    "ReturnUrl": "https://merchant.example.com/threedschallengecomplete",
    "Payload": {
        "ACSUrl": "https://merchantacsstag.cardinalcommerce.com/MerchantACSWeb/...",
        "Payload": "P.25de9db33221a55eedc6ac352b927a8c3a08d747643c592dd8f8ab7d3...",
        "TransactionId": "sRMPWCQoQrEiVxehTnu0"
    },
    "ObjectifyPayload": true
}

Request Challenge Page

Create an iframe with an automatic form post to https://centinelapistag.cardinalcommerce.com/V2/Cruise/StepUp, on the page you redirect the shopper to. The size of this iframe depends on whether you provided a challengeWindowSize and whether a 3DS1 or a 3DS2 process flow is being followed:

  • For <threeDSVersion> value of 1, the size must be 390x400
  • For <threeDSVersion> value of 2, match the value supplied in the authenticate request. For more details of the support challenge Windows sizes seehere.

Example of the challenge iframe:

Create an iframe with an automatic form post to https://centinelapistag.cardinalcommerce.com/V2/Cruise/StepUp, on the page you redirect the shopper to. This is required unless you have supplied a challengeWindowSize of "fullPage". The size of the iframe depends on threeDSVersion:

  • For threeDSVersion value of 1, the size must be 390x400.
  • For threeDSVersion value of 2, match the value of challengeWindowSize supplied in the authenticate request. For more details of the support challenge windows sizes seehere.

Example 3DS2 challenge iframe:

Copied!
<iframe height="250" width="400">
  <!-- This is a Cardinal Commerce URL in live -->
  <form id= "challengeForm" method= "POST" action="https://centinelapistag.cardinalcommerce.com/V2/Cruise/StepUp">
    <input type="hidden" name="JWT" value= "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJqdGkiOiI1NDQzOGIzYS1iYjUzLTEyY2QtODY0My0xNTM2YmU3M2ZmMzUiLCJpYXQiOiIzODU2NzI5NDgyIiwiaXNzIjoiNWJkOWUwZTQ0NDRkY2UxNTM0MjhjOTQwIiwiT3JnVW5pdElkIjoiNWJkOWI1NWU0NDQ0NzYxYWMwYWYxYzgwIiwiUmV0dXJuVXJsIjoiaHR0cDovL21lcmNoYW50LmV4YW1wbGUuY29tL3RocmVlZHNjaGFsbGVuZ2Vjb21wbGV0ZSIsIlBheWxvYWQiOnsiQUNTVXJsIjoiaHR0cHM6Ly9hY3MuZXhhbXBsZS5jb20vM2RzMi9jaGFsbGVuZ2U_aWQ9MTIzNDU2Nzg5IiwiUGF5bG9hZCI6IlZHaHBjeUJwY3lCaElHSmhjMlVnTmpRZ1pXNWpiMlJsWkNCbGVHRnRjR3hsSUc5bUlHRWdNMFJUSUNKd1lYbHNiMkZrSWc9PSIsIlRyYW5zYWN0aW9uSWQiOiJzUk1QV0NRb1FyRWlWeGVoVG51MCJ9LCJPYmplY3RpZnlQYXlsb2FkIjp0cnVlfQ.3Dqjr5MuEC9AG7uvsJCft94-d70NmgR94zIeru8fAYE" />
    <input type="hidden" name="MD" value="1234567890" />
  </form>
  <script>
    window.onload = function() {
      // Auto submit form on page load
      document.getElementById('challengeForm').submit();
    }
  </script>
</iframe>
FieldM/ODescription
actionMandatoryWorldpay provides a static Challenge URL when you go live. The test value is: https://centinelapistag.cardinalcommerce.com/V2/Cruise/StepUp.
JWTMandatoryThe challenge JWT that you generated on the server side.
MDOptionalMerchant Data. This is returned as a parameter to the ReturnUrl.

Challenge Request Data

Submit the second request once the challenge is complete. The response from Worldpay will contain the authentication data.

ElementRequiredDescription
<transactionId3DS>YCardinal-generated transaction identifier. This value links the request message to the lookup message.

Example XML

Copied!
<!DOCTYPE paymentService PUBLIC "-//WorldPay//DTD WorldPay PaymentService v1//EN" 
  "http://dtd.worldpay.com/paymentService_v1.dtd">
<paymentService version="1.4" merchantCode="YOUR_MERCHANT_CODE">
    <submit>
        <challenge orderCode="YOUR_ORDER_CODE">
            <transactionId3DS>qzjqQWjJn8R859kLn7Zi</transactionId3DS>
        </challenge>
    </submit>
</paymentService>

Once you submit this request, Worldpay will receive the authentication outcome and return this to you in the authenticate response.

Merchant next steps

The <authenticationStatus> field tells you all you need to know about what next steps you need to take.

Authentication Status valueNext steps
YProceed to authorisation using the information received in the <threeDSOutcome> response.
NDo not proceed to authorisation. You can ask for an alternative form of payment.
UYou can retry authentication, or submit for authorisation (without liability shift).
AYou can submit authorisation using the information received in the <threeDSOutcome> response.
RDo not proceed to authorisation. You can ask for an alternative form of payment.
BYou can proceed to authorisation using the information received in the <threeDSOutcome> response.

Note: Ensure you include the fields you receive in the <threeDSOutcome> response in your External MPI request. This can include: threeDSVersion, xid, cavv, dsTransactionId, eci.

Errors

We will return WPG errors if something goes wrong.

Error CodeDescriptionScenario
13Connection error.The connection timed out.
13Authentication error.An error was returned by our authentication provider.
13Authentication not enabled.You're not set up to use 3DS in Secure Test or Production.
13Merchant not set up in live.Your merchant code is not configured to use Split Authentication.

Split Authentication error example

Copied!
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE paymentService PUBLIC "-//WorldPay//DTD WorldPay PaymentService v1//EN" 
      "http://dtd.WorldPay.com/paymentService_v1.dtd">
<paymentService version="1.4" merchantCode="YOUR_MERCHANT_CODE">
  <reply>
    <orderStatus orderCode="YOUR_ORDER_CODE">
      <error code="13">
        <![CDATA[Authentication error.]]>
      </error>
    </orderStatus>
  </reply>
</paymentService>

Next

Once you have received the authentication outcome, you can now submit the payment for authorisation using theExternal MPI API.

Testing

How it works

In Production, you will interact with both Cardinal Commerce and Worldpay. For Secure Test, we have built simulators to allow you to integrate to Worldpay, when you're ready to go live, you must make a few changes to point your connection to both Cardinal and Worldpay.

1. Create a JWT with static values

Once boarded to Cardinal in Secure Test, you can find your details in the Test section of the MAI This will include your:

  • OrgUnitId - This is the Org Unit ID in the MAI.
  • iss - This is the API ID in the MAI.
  • JWT MAC Key - This is the API Key in the MAI.

Use these values to test theJWT creation. All other claims must be present and not empty but can otherwise take any value.

2. DDC test URLs

Run the JavaScript tosubmit the Device Datato the URL of the Cardinal simulator:

https://centinelapistag.cardinalcommerce.com/V1/Cruise/Collect

3. Create the initialauthenticate request

Use the below magic values and test card numbers to create your initial authenticate XML.

Test card numbers

Insert the below values in the <cardNumber> field to simulate the test cases described in column one.

3DS1

The following test cases have been added. These can be found in Cardinal's documentationhere.

Test CaseVisaMastercardJCBAmerican Express
Test Case 1: Successful Authentication400000000000000252000000000000073520000000000922340000000003961
Test Case 2: Failed Signature400000000000001052000000000000153520000000002811340000000006022
Test Case 3: Failed Authentication400000000000002852000000000000233520000000009931340000000000033
Test Case 4: Attempts/Non-Participating400000000000010152000000000009083520000000004767340000000003391
Test Case 5: Timeout400000000000004452000000000000493520000000001284340000000008309
Test Case 6: Not Enrolled400000000000005152000000000000563520000000006903340000000008135
Test Case 7: Unavailable400000000000006952000000000000643520000000002423340000000007780
Test Case 8: Merchant Not Active400000000000007752000000000000723520000000006549340000000008416
Test Case 9: cmpi_lookup error400000000000008552000000000000803520000000002175340000000006337
Test Case 10: cmpi_authenticate error400000000000009352000000000000983520000000006861340000000009299
Test Case 11: Authentication Unavailable400000000000003652000000000000313520000000005780340000000000116
Test Case 12: Bypassed AuthenticationNA52009900000000093500990000000001340099000000001

3DS2

The following test cases have been added. These can be found in Cardinal's documentationhere. Note: For 3DS2, we only support the following payment methods

  • Visa
  • Mastercard
  • American Express
If you provide PANs for the other payment methods found in Cardinal's documentation, the payment might be refused or processed as unauthenticated eCommerce.
Test CaseVisaMastercardAmerican Express
Test Case 1: Successful Frictionless Authentication40000000000010005200000000001005340000000001007
Test Case 2: Failed Frictionless Authentication40000000000010185200000000001013340000000001015
Test Case 3: Attempts Stand-In Frictionless Authentication40000000000010265200000000001021340000000001023
Test Case 4: Unavailable Frictionless Authentication from the Issuer40000000000010345200000000001039340000000001031
Test Case 5: Rejected Frictionless Authentication by the Issuer40000000000010425200000000001047340000000001049
Test Case 6: Authentication Not Available on Lookup40000000000010595200000000001054340000000001056
Test Case 7: Error on Lookup40000000000010675200000000001062340000000001064
Test Case 8: Timeout on cmpi_lookup Transaction40000000000010755200000000001070340000000001072
Test Case 9: Bypassed Authentication40000000000010835200000000001088340000000001080
Test Case 10: Successful Step Up Authentication40000000000010915200000000001096340000000001098
Test Case 11: Failed Step Up Authentication40000000000011095200000000001104340000000001106
Test Case 12: Step Up Authentication is Unavailable40000000000011175200000000001112340000000001114
Test Case 13: Error on Authentication40000000000011255200000000001120340000000001122

Test Case Scenarios

3DS1

Test CaseScenario SimulationAuthentication Outcome
Test Case 1: Successful AuthenticationSuccessful challengeAuthentication Status = Y
Test Case 2: Failed SignatureSuccessful challenge but invalid signatureAuthentication Status = Y

Signature Verification = N
Test Case 3: Failed AuthenticationChallenge failedAuthentication Status = N
Test Case 4: Attempts/Non-ParticipatingCard not enrolled in 3DS1Authentication Status = A
Test Case 5: TimeoutTimeoutAuthentication Error
Test Case 6: Not EnrolledCard not enrolled in 3DS1Enrolled = N
Test Case 7: UnavailableAuthentication unavailableEnrolled = U
Test Case 8: Merchant Not ActiveMerchant not configured in Cardinal's systemAuthentication Error
Test Case 9: cmpi_lookup errorError received on Cardinal responseAuthentication Error
Test Case 10: cmpi_authenticate errorError received on Cardinal responseAuthentication Error
Test Case 11: Authentication UnavailableAuthentication unavailableAuthentication Status = U
Test Case 12: Bypassed AuthenticationMerchant using Cardinal rules to bypass 3DSEnrolled = B

3DS2

Test CaseScenario SimulationAuthentication Outcome
Test Case 1: Successful Frictionless AuthenticationFrictionless authentication successfulAuthentication Status = U
Test Case 2: Failed Frictionless AuthenticationFrictionless authentication failedAuthentication Status = N
Test Case 3: Attempts Stand-In Frictionless AuthenticationAuthentication on behalf of Card SchemeAuthentication Status = A
Test Case 4: Unavailable Frictionless Authentication from the IssuerFrictionless authentication rejectedAuthentication Status = U
Test Case 5: Rejected Frictionless Authentication by the IssuerFrictionless authentication unavailableAuthentication Status = R
Test Case 6: Authentication Not Available on LookupAuthentication unavailableEnrolled = U
Test Case 7: Error on LookupError response received from CardinalAuthentication Error
Test Case 8: Timeout on cmpi_lookup TransactionNo response from CardinalAuthentication Error
Test Case 9: Bypassed AuthenticationMerchant using Cardinal rules to bypass 3DSEnrolled = B
Test Case 10: Successful Step Up AuthenticationSuccessful challengeAuthentication Status = Y
Test Case 11: Failed Step Up AuthenticationFailed challengeAuthentication Status = N
Test Case 12: Step Up Authentication is UnavailableAuthentication unavailableAuthentication Status = U
Test Case 13: Error on AuthenticationError response received from CardinalAuthentication Error

Note: Ensure you are sending the dfReferenceId attribute in yourauthenticate request. Extract the value for this from the SessionId that is returned by the Worldpay simulator.

4. Challenge

If you have decided to use a magic value that invokes achallengeyou will need to create another JWT. Use the same static values as inStep 1.

Use the below URL to POST your challenge JWT in an iframe:

https://centinelapistag.cardinalcommerce.com/V2/Cruise/StepUp

The Cardinal simulator POSTs back a standard response to the iframe. You are presented with a Cardinal Issuer page which allows you to enter a one-time password (OTP) which is visible on the page. Enter the password and click 'okay' to be redirected to your ReturnUrl.

5. Challenge request request

Provide the <transactionId3DS> after the challenge has been completed. The value for this is returned in the first response of your challenge request. This is then passed to Cardinal who return the authentication outcome to us. Worldpay retruns this outcome to you.

Trigger yourchallenge requestincluding the <transactionId3DS> returned to you in the response. Worldpay then sends the authentciation outcome in the challenge response to you.

Authorisation

When using Split Authentication, submit the authorisation using our External MPI. To test this, check out theExternal MPIdocumentation for more information.

About this guide

To see the latest changes made to this guide please clickhere.