我正在尝试生成一个机器密钥放在我的网络配置中,但它说它无法识别。我已经阅读了以下问题并使用相同的命令但没有成功生成机器密钥。请检查我在做什么:
I am trying to generate a machine key to place in my web configs, but its saying it is not recognized. I have already read the following question and use the same commands without success Generate Machine Key. Please check what am i doing:
我拿了 Powershell脚本,然后执行以下命令:
I took the Powershell Script from microsoft site, then executed the commands below:
PS C:\> C:\Users\myuser\Desktop\Docs\KeyGeneration\machinekey.ps1然后
PS C:\> Generate-MachineKey -validationAlgorithm SHA1它说:
The term 'Generate-MachineKey' is not recognized as the name of a cmdlet, function, script file推荐答案
尝试点源脚本的运行,在脚本之前放置一个句点然后放一个空格
Try "dot sourcing" the running of the script, by placing a period and then a space before the script
PS C:>。 C:\ Users \ myuser \Desktop \Docs \KeyGeneration\machinekey.ps1
PS C:> . C:\Users\myuser\Desktop\Docs\KeyGeneration\machinekey.ps1
更多推荐
使用电源Shell生成机器密钥
发布评论