You are developing a Single Page Application (SPA) using React and MSAL.js . The application must authenticate users using the Microsoft Identity Platform and call a downstream secured Microsoft Graph API. You register the application in the Microsoft Entra admin center. Under the Authentication blade, you add a redirect URI of `http://localhost:3000` but configure the platform type as Web instead of Single-page application. During testing, users can successfully sign in and the application receives an authorization code. However, when the application attempts to exchange the authorization code for an access token, the token endpoint returns an error. You need to resolve the error and ensure that the application can successfully acquire access tokens. Which of the following actions should you perform?
- AIn the app registration, enable the Implicit Grant flow by checking both Access tokens and ID tokens.
- In the app registration, change the redirect URI platform type from Web to Single-page application.Cevap
- CIn the app registration, generate a client secret and configure the React application to use this secret in the token request.
- DConfigure the React application to use a system-assigned managed identity to authenticate directly against the Microsoft Graph API.