Reputation: 1174
It's little tricky situation to explain but would try my best to explain the problem. First of all it is happening only on Firefox, Chrome and Edge working as expected.
I have a web check-out form where payment gateway fields are displaying inside the iframe. Iframe does come with the <form></form>
tag which has the post action to submit credit card details to the payment provider when "Submit Order" is clicked.
On click of the submit button payment gateway providers submits the Iframe, and returns the results through the "Callback" function which is my action controller attached to this Iframe.
The issue is when I submit the main "check-out" form on Firefox it resets the every cached property in the session to null. All works fine as expected on Chrome/Edge but Firefox having this consistent behavior. I am quite sure the Iframe postback causing this issue but unable to find the fix for the same.
Any ideas?
Upvotes: 0
Views: 132
Reputation: 1174
Adding following property in web.config fix the problem
<system.web>
<sessionState cookieSameSite="None"/>
This way third party Iframe sessions starts working.
Before you do this change, it's better to read this https://learn.microsoft.com/en-us/aspnet/samesite/system-web-samesite
Upvotes: 0