Skip to content
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

Issue 506 Problem with API Module #528

Merged

Conversation

Kevin-Andrew
Copy link
Contributor

When attempting to invoke the basic Connect-Safeguard command, one could get the following error, depending on your environment (Windows and PowerShell version):

Metadata file 'System.Security.Cryptography.dll' could not be found.
safeguard-ps.psm1:82

I believe, when running under Windows with PowerShell 5.1, it's using just the regular .NET Framework, so no explicit reference to System.Security.Cryptography.dll is needed. Unlike with PowerShell Core.

After fixing that problem, we immediately ran into another error that may again be a difference between PowerShell and PowerShell Core.

Unexpected character '$'
string accessTokenUri = $"https://{_appli...

It seems the C# string interpolation is not supported, at least in this version of PowerShell. So we'll just use the old string.Format() method.

When attempting to invoke the basic `Connect-Safeguard` command, one could get the following error, depending on your environment (Windows and PowerShell version):
> Metadata file 'System.Security.Cryptography.dll' could not be found.
safeguard-ps.psm1:82

I believe, when running under Windows with PowerShell 5.1, it's using just the regular .NET Framework, so no explicit reference to `System.Security.Cryptography.dll` is needed. Unlike with PowerShell Core.

After fixing that problem, we immediately ran into another error that may again be a difference between PowerShell and PowerShell Core.
> Unexpected character '$'
string accessTokenUri = $"https://{_appli...

It seems the C# string interpolation is not supported, at least in this version of PowerShell. So we'll just use the old `string.Format()` method.
@Kevin-Andrew
Copy link
Contributor Author

See #506.

@Kevin-Andrew
Copy link
Contributor Author

@JeffHarkavy

@JeffHarkavy JeffHarkavy merged commit b72cdfd into OneIdentity:master Sep 16, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants