With PowerShell 7 preview, the get-credential cmdlet does not show the "GUI" interface like Windows PowerShell versions did. In a completely GUI application, with no command window interface, has anyone come up with a GUI workaround to prompt for credentials securely that the get-credential GUI normally would have provided?
Thanks
NK
Get-Credential and PowerShell 7 preview
Forum rules
Do not post any licensing information in this forum.
Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
Do not post any licensing information in this forum.
Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
- mxtrinidad
- Posts: 399
- Last visit: Tue May 16, 2023 6:52 am
Re: Get-Credential and PowerShell 7 preview
First, Get-Credential in PowerShell 6.2.3 (Core) and PowerShell 7 Preview versions use .NET Core framework which has no windows forms. This was meant this way to allow cross-platform compatibility. Windows components are used only with the Full .NET Framework.
Windows component is not supported in PowerShell 7. So, for now there are no workaround for the Get-Credential in GUI form in PowerShell 7.
I recommend to file a feedback suggestion at the Microsoft Github PowerShell repository at the following link: https://github.com/PowerShell/PowerShell/issues
Windows component is not supported in PowerShell 7. So, for now there are no workaround for the Get-Credential in GUI form in PowerShell 7.
I recommend to file a feedback suggestion at the Microsoft Github PowerShell repository at the following link: https://github.com/PowerShell/PowerShell/issues
Re: Get-Credential and PowerShell 7 preview
Thanks. I am able to run Windows forms with PowerShell 7 as PowerShell 7 is built on .NET Core 3 which supports Windows form. However a few things like Out-Gridview and Get-Credential, which have GUI components to them, do not work.
NK
NK
- mxtrinidad
- Posts: 399
- Last visit: Tue May 16, 2023 6:52 am
Re: Get-Credential and PowerShell 7 preview
"... By using the .NET Core 3.0 SDK component Windows Desktop, you can port your Windows Forms and Windows Presentation Foundation (WPF) applications. " https://docs.microsoft.com/en-us/dotnet ... t-core-3-0
Yes! But it doesn't mean existing Windows PowerShell cmdlets "Out-Gridview", "Get-Credential", and even the "Get-Help -ShowWindow".
Now, to start, I can tell you that Microsoft is experimenting with open source Avalonia (WPF-based) Framework to bring back the cmdlet Out-Gridview.
Install the following module from the PowerShell Gallery: Microsoft.PowerShell.GraphicalTools
It won't surprise me if they start working on getting the Get-Credential back using Avalonia Framework.
You can always go to their Github repository and submit a feedback about it.
Yes! But it doesn't mean existing Windows PowerShell cmdlets "Out-Gridview", "Get-Credential", and even the "Get-Help -ShowWindow".
Now, to start, I can tell you that Microsoft is experimenting with open source Avalonia (WPF-based) Framework to bring back the cmdlet Out-Gridview.
Install the following module from the PowerShell Gallery: Microsoft.PowerShell.GraphicalTools
It won't surprise me if they start working on getting the Get-Credential back using Avalonia Framework.
You can always go to their Github repository and submit a feedback about it.