CsWinRT icon indicating copy to clipboard operation
CsWinRT copied to clipboard

PasswordVault access not returning credentials

Open baaaaif opened this issue 3 years ago • 0 comments

Describe the bug PasswordVault access not returning PasswordCredential added by the main app

I'm migrating a UWP app to the WAS. The app uses a OOP background task which i migrated following the BGTaskComponent example. In the BG-Task i'm trying to retrieve a PasswordCredential (Windows.Security.Credentials) which was added by the main app. Unfortunately the BG-Task ist not able to retrieve the credentials. It seems like it behaves like a indepentent app in context of the PasswordVault. Same scenario was working with UWPs runtime component / background task

To Reproduce PasswordVaultTest.zip

  1. Run the attached minimum repro example
  2. click the button
  3. use VS to trigger the background task
  4. set a breakpoint to the credential list or watch the trace

Expected behavior WinRT Host is working with the same context like UWPs background task was doing. PasswordVault is able to retrieve credentials added by the main app

Version Info CSWinRT 1.4.1 and older WindowsAppSDK 1.0.0

baaaaif avatar Dec 07 '21 12:12 baaaaif