Payments in compliance with Content Security Policy (CSP)

Content Security Policy (CSP) is a security standard used in web browsers to protect against malicious attacks, including cross-site scripting (XSS) and data injection attacks. When complying with CSP, you define which content sources are trusted, and the browser blocks access to any sources not on the allowlist. If the payment UI is opened in an iframe, 3-D Secure verification fails due to CSP restrictions.

To ensure a secure and seamless payment flow, pass true in the settings.ui.is_three_ds_independent_windows parameter when getting a token. In this case, the payment UI will display an intermediate payment step, and the 3-D Secure verification will open in a new browser tab. The intermediate step is required to verify the security of the payment step and proceed to 3-D Secure verification from an iframe.

Payment flow compliant with CSP in the browser:

  1. The user opens the payment UI to make a payment.
  2. The user enters their payment details and clicks Pay.
  1. The intermediate step opens, and the user clicks Pay one more time.
  1. The user is redirected to a new browser tab to pass the 3-D Secure verification.
  2. The user is redirected to the successful payment status page.
Was this article helpful?
Thank you!
Is there anything we can improve? Message
We’re sorry to hear that
Please explain why this article wasn’t helpful to you. Message
Thank you for your feedback!
We’ll review your message and use it to help us improve your experience.
Last updated: December 12, 2025

Found a typo or other text error? Select the text and press Ctrl+Enter.

Report a problem
We always review our content. Your feedback helps us improve it.
Provide an email so we can follow up
Thank you for your feedback!
We couldn't send your feedback
Try again later or contact us at doc_feedback@xsolla.com.