Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cors error #25

Open
Mastan12789 opened this issue Jul 18, 2023 · 6 comments
Open

Cors error #25

Mastan12789 opened this issue Jul 18, 2023 · 6 comments

Comments

@Mastan12789
Copy link

Description

Getting cors error while using duo universal prompt using .net core with react

===========

return new RedirectResult(prontuari);

==========

after this line we are getting cors error in .net core

@AaronAtDuo
Copy link
Contributor

@Mastan12789 I think it's likely you're running into the same issue as duosecurity/duo_universal_python#1. Are you trying to use the SDK from a SPA-like application where you handle the login via XHR requests and not http POSTs?

@Mastan12789
Copy link
Author

Mastan12789 commented Jul 18, 2023

@AaronAtDuo yes we are also following same .
Login via xhr request using react and Dotnet core api

@AaronAtDuo
Copy link
Contributor

@Mastan12789 I don't think anyone has ever been able to get that flow to work with the Duo Universal Prompt. The prompt is expecting to get the user via a redirected browser, and to POST the browser back to some server-side application.

So I don't think this SDK as-is will be suitable for your application. https://duo.com/docs/oauthapi describes the API that this SDK uses, so perhaps you'll be able to find a solution by accessing the API directly.

@Mastan12789
Copy link
Author

@AaronAtDuo Using oauthapi how to get the DuoUniversal prompt ?

@Mastan12789
Copy link
Author

@AaronAtDuo after redirect uri from mvc app we are getting below error

{“error” : “invalid_client”, “error_description”: “The provided client_assertion was invalid.”}

May I know the reason?

@AaronAtDuo
Copy link
Contributor

@Mastan12789 unfortunately there's multiple possible causes of that error. It's the "catch-all" error when no specific cause of failure is identified.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants