Hello @JJ-Fullmer , hope all is well.
First of all, thanks for creating that Powershell module for FOG to be used via Powershell.
I have a question in regards to the script I’ve been using for a while. In it has the API for both the user and the FOG server.
I want to be more secure in the sense of not putting the API in the script. I tried Microsoft’s module Secret Management and I can store both api keys under 2 different secrets. Here is the link from Microsoft: https://learn.microsoft.com/en-us/powershell/utility-modules/secretmanagement/get-started/using-secretstore?view=ps-modules
But when I try to retrieve the secrets, I get the 403 forbidden message.
Powershell variables for the both api keys for example: f8dcc28c-aef3-45c7-a765-1719c30df353-image.png
Error message: 3cce1c57-e18b-4b3b-965b-aed75980c21c-image.png
It will only work if I add -asplaintext for example:
94f64f07-9835-4fac-8265-cda63d9de679-image.png
It won’t take the System.Security.SecureString
I double checked to make sure I’m using the correct fog and user api keys, but no dice.
Is there a way to secure these API keys instead of putting them directly in the Powershell script and also not doing the command -asplaintext?
If anyone has suggestions, please let me know.