You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Got error executing the script.
The problem is during this call at line 93: New-AzureADApplicationKeyCredential
For some reason using this method "-EndDate $cert.GetExpirationDateString()" return the error described as if the EndDate retrieved were after the effective certificate end date.
I solved this issue using "$cert.NotAfter" instead "$cert.GetExpirationDateString()".
I modified also the start date, using "$cert.NotBefore".
Describe the bug
Got error executing the script.
The problem is during this call at line 93: New-AzureADApplicationKeyCredential
For some reason using this method "-EndDate $cert.GetExpirationDateString()" return the error described as if the EndDate retrieved were after the effective certificate end date.
I solved this issue using "$cert.NotAfter" instead "$cert.GetExpirationDateString()".
I modified also the start date, using "$cert.NotBefore".
Line 93 could be:
New-AzureADApplicationKeyCredential -ObjectId $app.ObjectId -CustomKeyIdentifier $base64Thumbprint -Type AsymmetricX509Cert -Usage Verify -Value $base64Value -StartDate $cert.NotBefore -EndDate $cert.NotAfter | Out-Null
To Reproduce
Steps to reproduce the behavior:
Screenshots
The text was updated successfully, but these errors were encountered: