Connect-MgGraph on 2.41 crashes when making a connection with cert, fixes when using 2.39 or lower
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 48/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Ativa
- Stack de tecnologia
- csharp, powershell
- Domínio
- api, authentication
Direção de pesquisa
Start by reproducing the reported Connect-MgGraph certificate-authentication failure with Graph.Authentication 2.41.1, then compare it with 2.39, which the report says works. Investigate the RefreshCacheAsync implementation mismatch named in the exception; done means the certificate connection succeeds on 2.41.1 without downgrading.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Describe the bug
When using the following code with version 2.39 (or lower) of Graph.authentication, it will work.
Connect-MgGraph -ClientId $ClientID
-TenantId $TenantID -Certificate $cert
-NoWelcome
fresh device with 2.4.1 will crash with this error. work around is to install 2.39 or lower and use this graph.authentication.
Method 'RefreshCacheAsync' in type 'Microsoft.Graph.PowerShell.Authentication.Core.TokenCache.InMemoryTokenCacheOptions' from assembly 'Microsoft.Graph.Authentication.Core, Version=2.41.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' does not have an implementation.
Expected behavior
I expect it to connect and work.
How to reproduce
Create a certificate and load it. This is used by an api registration with only https://graph.microsoft.com/DeviceManagementServiceConfig.ReadWrite.All
Connect-MgGraph -ClientId $ClientID
-TenantId $TenantID -Certificate $cert
-NoWelcome
upon using this connection command it will crash
SDK Version
No response
Latest version known to work for scenario above?
No response
Known Workarounds
downgrade and load Graph.authentication 2.39 or lower
Debug output
Click to expand log
```</details>
### Configuration
_No response_
### Other information
_No response_
- Linguagem predominante
- C#
- Estrelas
- 902
- Forks
- 233
- Merge médio
- 1d 20h
- PRs com merge (30d)
- 30
Preparar o ambiente
- Inclui um Dockerfile ou arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de microsoftgraph/msgraph-sdk-powershell
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 84/100
microsoftgraph/msgraph-sdk-powershell#3752 ·
Mantenedores costumam responder em até 1 dia
-
status:waiting-for-triage type:bug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 22/100
microsoftgraph/msgraph-sdk-powershell#3822 ·
Mantenedores costumam responder em até 1 dia
-
Microsoft.Graph.Authentication dependency Microsoft.Graph.Authentication.Loader.dll is unsignedAbertastatus:waiting-for-triage type:bug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
microsoftgraph/msgraph-sdk-powershell#3819 ·
Mantenedores costumam responder em até 1 dia
-
status:waiting-for-triage type:feature
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 45/100
microsoftgraph/msgraph-sdk-powershell#3806 · 3 comentários · 3 reações ·
Mantenedores costumam responder em até 1 dia
-
Microsoft.Graph.Authentication fails after removal and re-import in the same PowerShell sessionAbertastatus:waiting-for-triage type:bug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 25/100
microsoftgraph/msgraph-sdk-powershell#3805 · 3 comentários ·
Mantenedores costumam responder em até 1 dia
Todas as issues de microsoftgraph/msgraph-sdk-powershell
Issues semelhantes
-
[i18n] 安装实例完成后的成功提示未正确本地化Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 62/100
PCL-Community/PCL-CE#3658 ·
Mantenedores costumam responder em até 1 dia
-
Deploy & Patch-issues opprettes ikke: create-pnd-issues.yml har feilet hver uke siden 2025-09-08Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 62/100
Altinn/altinn-auth#4359 ·
Mantenedores costumam responder em até 1 dia
-
アプリ: チャット 優先: 中 提案
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
yksr-melt/Meltype#243 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
Workflows: a workflow stored with null conditions is skipped with an exception instead of runAbertabug core
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
Mantenedores costumam responder em até 1 dia
-
type/automation type/tech-debt
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 72/100
Mantenedores costumam responder em até 1 dia