Problem/Motivation
Keeps failing after 3d secure authentication redirect
Steps to reproduce
Customers have got to the point of going through the 3d secure authentication and the authentication being accepted but the redirects back to the site 3dSecureBack/184. with an error message.
The website encountered an unexpected error. Please try again later.
The error that is produced within the error log is
Location
https://www.qmj.co.uk/3dSecureBack/185
Referrer
https://tsys.arcot.com/
Message
Error: Call to undefined function Drupal\commerce_sage\Controller\getPaymentConfigurations() in Drupal\commerce_sage\Controller\CommerceSage->Secure3DBack() (line 17 of /srv/qmj.co.uk/public/mystore/web/modules/contrib/commerce_sage/src/Controller/CommerceSage.php)
#0 [internal function]: Drupal\commerce_sage\Controller\CommerceSage->Secure3DBack()
#1 /srv/qmj.co.uk/public/mystore/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(123): call_user_func_array()
#2 /srv/qmj.co.uk/public/mystore/web/core/lib/Drupal/Core/Render/Renderer.php(564): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}()
#3 /srv/qmj.co.uk/public/mystore/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(124): Drupal\Core\Render\Renderer->executeInRenderContext()
#4 /srv/qmj.co.uk/public/mystore/web/core/lib/Drupal/Core/EventSubscriber/EarlyRenderingControllerWrapperSubscriber.php(97): Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext()
And
Location
https://www.qmj.co.uk/3dSecureBack/186
Referrer
https://secure5.arcot.com/
Message
Array ( [cres] => eyJ0aHJlZURTU2VydmVyVHJhbnNJRCI6IjNlMTBlN2Y4LWQzMDMtNGRjYS1iNDA5LTMxYzdhOWI1Njg4NSIsImFjc1RyYW5zSUQiOiIyZDhiMjE4NC0xNTAwLTQ3NjEtYWYzMC1kY2M2NmI2ZmQ2MGYiLCJtZXNzYWdlVHlwZSI6IkNSZXMiLCJtZXNzYWdlVmVyc2lvbiI6IjIuMS4wIiwidHJhbnNTdGF0dXMiOiJZIn0 [threeDSSessionData] => MjdFN0FFNzAtMzZEQi0wQjU0LUQ4RTAtNzMxOTE5RDlGRDM0 )
I have raised with with SagePay and they have said the following.
f the customer can see the 3D secure page, then it will likely be an issue with how the ThreeDSNotificationURL is posting the threeDSSessionData and cRes to the 3D Secure Callback URL.
The?threeDSSessionData?must be BASE64 URL encoded with no padding, and is limited 1024 bytes in length, please can you ensure your “threeDSSessionData” is sent to this specification?
CRes: This is Base64 URL encoded data that is sent to the vendors ThreeDSNotificationURL.
Further information on the PI ACS URL redirection can be found on the following URL:
https://developer-eu.elavon.com/docs/opayo/3d-secure-authentication
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes