Ich folge diesem Tutorial:
https://learn.microsoft.com/en-us/entra ... ode]string[] scopes = new string[] { "user.read" };
var app = PublicClientApplicationBuilder.Create("YOUR_CLIENT_ID")
.WithDefaultRedirectUri()
.Build();
var accounts = await app.GetAccountsAsync();
AuthenticationResult result;
try
{
result = await app.AcquireTokenSilent(scopes, accounts.FirstOrDefault())
.ExecuteAsync();
}
catch (MsalUiRequiredException)
{
result = await app.AcquireTokenInteractive(scopes).ExecuteAsync();
}
< /code>
Ich erhalte diesen Fehler jedoch: < /p>
{
"error": "invalid_client",
"error_description": "AADSTS7000218: The request body must contain the following parameter: \u0027client_assertion\u0027 or \u0027client_secret\u0027.,
"error_codes": [
7000218
],
"error_uri": "https://login.microsoftonline.com/error ... 03d7000218"
}
< /code>
Ich habe unter anderem versucht, < /p>
öffentlichen Kundenflows < /p>
< /blockquote>
in meiner App zulassen, funktioniert jedoch nicht. Ich bin verwirrt; Ich sollte kein Geheimnis benötigen. < /P>
Hier ist mein Manifest: < /p>
{
"id": "id",
"acceptMappedClaims": null,
"accessTokenAcceptedVersion": 2,
"addIns": [],
"allowPublicClient": true,
"appId": "id",
"appRoles": [],
"oauth2AllowUrlPathMatching": false,
"createdDateTime": "Date",
"description": null,
"certification": null,
"disabledByMicrosoftStatus": null,
"groupMembershipClaims": null,
"identifierUris": [],
"informationalUrls": {
"termsOfService": null,
"support": null,
"privacy": null,
"marketing": null
},
"keyCredentials": [],
"knownClientApplications": [],
"logoUrl": null,
"logoutUrl": null,
"name": "scannerbox. Uploader",
"notes": null,
"oauth2AllowIdTokenImplicitFlow": false,
"oauth2AllowImplicitFlow": false,
"oauth2Permissions": [],
"oauth2RequirePostResponse": false,
"optionalClaims": null,
"orgRestrictions": [],
"parentalControlSettings": {
"countriesBlockedForMinors": [],
"legalAgeGroupRule": "Allow"
},
"passwordCredentials": [],
"preAuthorizedApplications": [],
"publisherDomain": "domain",
"replyUrlsWithType": [
{
"url": "https://login.microsoftonline.com/commo ... tiveclient",
"type": "Web"
}
],
"requiredResourceAccess": [
{
//things...
}
],
"samlMetadataUrl": null,
"signInUrl": null,
"signInAudience": "AzureADandPersonalMicrosoftAccount",
"tags": [],
"tokenEncryptionKeyId": null
}
[/code]
MSALException: AADSTS7000218 Der Anforderungsgremium muss den folgenden Parameter enthalten: client_assertion \ u0027 od ⇐ C#
-
- Similar Topics
- Replies
- Views
- Last post