I am using Laravel 5.8 and authorizenet/authorizenet: ^2.0
I am requesting a hosted form using a paymentFormToken and getting back the proper iFrame content and I am able to make a payment to a customer and create a payment profile etc.
My issue is I get no response to the iframe. I can see the response from api.ashx and it has all of the info I need, however it doesn't hit the window.CommunicationHandler.
I am getting the following error message:
Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://dockmaster.geigerent.com') does not match the recipient window's origin ('https://test.authorize.net').
Not sure if that is part of the problem.
I added headers as middleware like this:
public function handle($request, Closure $next)
{
$response = $next($request);
$response->headers->set('Content-Security-Policy', "frame-ancestors 'self' dockmaster.geigerent.com *.authorize.net");
return $response;
}
But it has no effect on the above error.
Not sure what I am doing wrong here, I have been beating my head against this keyboard for some time now. Can someone help?
07-16-2019 12:14 PM