-
Notifications
You must be signed in to change notification settings - Fork 3.9k
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
Connect-AzAccount fails on Mac #13714
Comments
Thanks for reporting. We will look into it. |
Hi @APIWT - can you access your keychain? Is it locked perhaps? Could you try the following: Open Keychain access using Spotlight search. |
@bgavrilMS Same error :( Btw, it wasn't locked. I did try locking it and unlocking it. |
Scratching my head here. This is the Apple documentation for this error... very informing.. |
@APIWT - can you manually add an entry to the login keychain? Try a password. |
Also this shows a similar issue: https://github.com/keybase/go-keychain/issues/32 with a potential workaround. |
Yeahhhh classic Apple documentation. Not very telling. Yeah I can manually add items to keychain no problem. |
@APIWT , could you confirm this issue is resolved? |
@dingmeng-xue The issue is not resolved. Same error. |
I have the same issue. Any solution or workaround available yet? |
Same issue. Can not login thru pwsh on Mac; although the login is successful on browser with Device Code; back on PowerShell throws up the error! |
Just a gentle bump on this issue. Do you have any advice? |
Seems to be working now :)
…On Thu, Jan 14, 2021 at 1:12 AM Anthony Iacono ***@***.***> wrote:
@APIWT <https://github.com/APIWT> , could you confirm this issue is
resolved?
Just a gentle bump on this issue. Do you have any advice?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#13714 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASI6PVYXQ2WON2NBHP3BTLSZXZQ3ANCNFSM4UVMSXIQ>
.
|
Confirmed also working now from my side! |
@dingmeng-xue did you find a workaround or a fix for this issue? I was thinking of updating the KeyChain access layer with different (non-deprecated) APIs, but it's a lot of work and no guarantee it is going to work. Seem that some of issues simply went away? |
@bgavrilMS Just a heads up, the issue has not gone away on our side. We are basically temporarily running the PowerShell Az stuff inside a docker container until there is a fix. Not ideal but it works. |
@bgavrilMS , what's the root cause around it? |
@dingmeng-xue - I do not know, since the error only happens on some machines. I know Git Cred Manager on Mac use updated APIs for secure storage and they have not seen this issue. Otherwise, I can write a small app to test the KeyChain similar to how PowerShell would... |
Sam issue still broken: PSVersion 7.1.1 |
Yes, unfortunately, this is broken again!
Only thing that is working is a Service Principal login!
Can this be fixed quickly?
Regards,
Monojit
…On Fri, Jan 29, 2021 at 3:07 AM Steve M ***@***.***> wrote:
Sam issue still broken:
Name Value
------------------------------
PSVersion 7.1.1
PSEdition Core
GitCommitId 7.1.1
OS Darwin 18.7.0 Darwin Kernel Version 18.7.0: Tue Nov 10 00:07:31 PST
2020; root:xnu-4903.278.51~1/RELEA…
Platform Unix
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#13714 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASI6PVMHGCC3U6HMUVOFKLS4HKH7ANCNFSM4UVMSXIQ>
.
|
Any update on this?
On Sun, Jan 31, 2021 at 2:55 AM Monojit Datta <datta.monojit@gmail.com>
wrote:
… Yes, unfortunately, this is broken again!
Only thing that is working is a Service Principal login!
Can this be fixed quickly?
Regards,
Monojit
On Fri, Jan 29, 2021 at 3:07 AM Steve M ***@***.***> wrote:
> Sam issue still broken:
> Name Value
> ------------------------------
>
> PSVersion 7.1.1
> PSEdition Core
> GitCommitId 7.1.1
> OS Darwin 18.7.0 Darwin Kernel Version 18.7.0: Tue Nov 10 00:07:31 PST
> 2020; root:xnu-4903.278.51~1/RELEA…
> Platform Unix
> PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
> PSRemotingProtocolVersion 2.3
> SerializationVersion 1.1.0.1
> WSManStackVersion 3.0
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <#13714 (comment)>,
> or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AASI6PVMHGCC3U6HMUVOFKLS4HKH7ANCNFSM4UVMSXIQ>
> .
>
|
We are working on the issue. |
This is a complete blocker for me now :(
as I can not login with Device Code and since I am on PS Core, it is not
allowing me to login with my creds also!!!
…On Thu, Feb 4, 2021 at 10:23 PM Damien Caro ***@***.***> wrote:
We are working on the issue.
Thanks for your patience as we are investigating this issue and its
dependencies.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#13714 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASI6PQSNMBFMZQ7TFB6ABLS5LGHJANCNFSM4UVMSXIQ>
.
|
@monojit18 if you cannot use |
Not sure how to degrade a Module version in Powershell!
I tried updating the module though Update-Module -Name Az; No luck :(
…On Fri, Feb 5, 2021 at 9:52 PM Damien Caro ***@***.***> wrote:
@monojit18 <https://github.com/monojit18> if you cannot use Connect-AzAccount
-UseDeviceAuthentication can you consider using a previous version of Az
that was working for you while we are addressing this issue?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#13714 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASI6PQREXQX7OTX6H2C5I3S5QLMDANCNFSM4UVMSXIQ>
.
|
@monojit18 I suggest that you follow the documentation here to completely uninstall the Az Module: https://docs.microsoft.com/en-us/powershell/azure/uninstall-az-ps?view=azps-5.4.0 then install Az 4.8.0 with the following command: |
@bgavrilMS has upgraded MSAL library to fix the issue. Could @APIWT or @monojit18 please help to verify whether the issue has been fixed with latest MSAL library on Mac? The steps to apply upgraded MSAL lib:
|
Team,
Sorry for the delayed reply.
I can confirm that this is working from both Mac and Linux boxes...so no
blocker. Thanks for all the help!👍
Regards,
Monojit
…On Fri, Feb 19, 2021 at 8:07 PM erich-wang ***@***.***> wrote:
@bgavrilMS <https://github.com/bgavrilMS> has upgraded MSAL library to
fix the issue. Could @APIWT <https://github.com/APIWT> or @monojit18
<https://github.com/monojit18> please help to verify whether the issue
has been fixed with latest MSAL library on Mac? The steps to apply upgraded
MSAL lib:
1. Make sure you have installed Az.Accounts 2.2.x, the latest version
is 2.2.5
2. Run Clear-AzContext
3. Restart pwsh
4. Download upgraded MSAL libraries from below link:
https://erich20diag.blob.core.windows.net/erich/Microsoft.Identity.Client.Extensions.Msal.dll
https://erich20diag.blob.core.windows.net/erich/Microsoft.Identity.Client.dll
5. Copy the above two libs to override the ones under Az.Accounts, the
destination folder should be like /Users/*yourname*
/.local/share/powershell/Modules/Az.Accounts/*2.2.x*/NetCoreAssemblies/,
you need replace with real value for *bold part* in the path.
6. Try Connect-AzAccount to see if issue remains.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#13714 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASI6PXO2WDCNZATYR656KTS7ZZQXANCNFSM4UVMSXIQ>
.
|
@monojit18 I have been debugging this exact issue for a few days now and it is being a major blocker for me. I have tried the MSAL library update as well and that doesn't seem to fix the issue on my machine. Could you please let me know the version of PWSH and Az module (Az.Accounts as well) that you're using? Any help is appreciated. @dcaro Please find below the stack trace of this exception that I'm facing. TargetSite : System.Exception FailWrapAndThrow(System.Exception) TargetSite : Void VerifyPersistence() |
Close the issue as @monojit18 confirmed that the issue be resolved. Please feel free to open another issue if you still see the issue, thanks. |
Description
Using the
Connect-AzAccount
command fails on my Mac machine. I have tried to delete bothmsal.cache
and all the keychain entries. The browser flow and device code flow fail instantly with the following stacktrace (see debug info below).Steps to reproduce
Connect-AzAccount
Environment data
Module versions
Debug output
Error output
The text was updated successfully, but these errors were encountered: