Skip to content

[Bug] Two Windows WAM tests will fail if NativeInterop > 0.18.1 #5346

@fengga

Description

@fengga

Library version used

4.72.1

.NET version

net8.0

Scenario

PublicClient - desktop app

Is this a new or an existing app?

None

Issue description and reproduction steps

If use NativeInterop > 0.18.1, like 0.18.2 or 0.19.1

<MSALRuntimeNativeInteropVersion>0.18.1</MSALRuntimeNativeInteropVersion>

Open LibsAndSamples.sln and run NET Core tests:
WamUsernamePasswordPopTokenEnforcedWithCaOnInValidResourceAsync

fails with error:

Error Code: 3399549011
Error Message: ApiContractViolation
WAM Error Message: Account and credential in the same request. Not supported.
Internal Error Code: 557973642

The failure is inside MSALRuntime with tag_7q6ck: https://office.visualstudio.com/OneAuth/_git/OneAuth?path=/msal/source/windows/broker/AADTokenRequest.cpp&version=GBmaster&_a=contents&line=139&lineStyle=plain&lineEnd=139&lineStartColumn=1&lineEndColumn=51

Error inside WAM:
ERROR_ADAL_ACCOUNT_AND_CREDENTIAL | Account and credential in the same request. Not supported.

Also fails in the pipeline with the same errors:

https://identitydivision.visualstudio.com/IDDP/_build/results?buildId=1493308&view=logs&j=b518b04f-6c84-5938-67f2-8f2b5bcbaf6d&t=f2a8f620-7cb1-5cbf-b47f-4878452b8c1e&l=566

https://identitydivision.visualstudio.com/IDDP/_build/results?buildId=1493308&view=logs&j=b518b04f-6c84-5938-67f2-8f2b5bcbaf6d&t=f2a8f620-7cb1-5cbf-b47f-4878452b8c1e&l=590

Relevant code snippets

Expected behavior

No response

Identity provider

Microsoft Entra ID (Work and School accounts and Personal Microsoft accounts)

Regression

NativeInterop version 0.18.1 works

Solution and workarounds

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions