diff --git a/src/System.Management.Automation/engine/remoting/commands/CustomShellCommands.cs b/src/System.Management.Automation/engine/remoting/commands/CustomShellCommands.cs index fcfeb43844..6d59d474f3 100644 --- a/src/System.Management.Automation/engine/remoting/commands/CustomShellCommands.cs +++ b/src/System.Management.Automation/engine/remoting/commands/CustomShellCommands.cs @@ -5223,6 +5223,8 @@ Enable-PSRemoting -force $args[0] -queryForRegisterDefault $args[1] -captionForR /// protected override void EndProcessing() { + WriteWarning(RemotingErrorIdStrings.PSCoreRemotingEnableWarning); + // gather -WhatIf, -Confirm parameter data and pass it to the script block bool whatIf = false; // confirm is always true to start with @@ -5426,6 +5428,7 @@ Disable-PSRemoting -force:$args[0] -queryForSet $args[1] -captionForSet $args[2] /// protected override void EndProcessing() { + WriteWarning(RemotingErrorIdStrings.PSCoreRemotingDisableWarning); WriteWarning(StringUtil.Format(RemotingErrorIdStrings.DcsWarningMessage)); WriteVerbose(StringUtil.Format(RemotingErrorIdStrings.EcsScriptMessageV, disablePSRemotingFormat)); diff --git a/src/System.Management.Automation/resources/RemotingErrorIdStrings.resx b/src/System.Management.Automation/resources/RemotingErrorIdStrings.resx index e2a231edf5..74c120bf35 100644 --- a/src/System.Management.Automation/resources/RemotingErrorIdStrings.resx +++ b/src/System.Management.Automation/resources/RemotingErrorIdStrings.resx @@ -1,17 +1,17 @@ - @@ -655,7 +655,7 @@ Session configuration "{0}" is not a PowerShell-based shell. - + Session configuration "{0}" is a PowerShell Core-based shell. Please use PowerShell Core to modify it. @@ -1114,8 +1114,8 @@ All WinRM sessions connected to PowerShell session configurations, such as Micro {0} authentication requires an explicit user name and password. Specify the user name and password by using the -Credential parameter and try the command again. - - Basic authentication is not supported over HTTP on Unix. + + Basic authentication is not supported over HTTP on Unix. Cannot find a scheduled job with name {0}. @@ -1662,10 +1662,10 @@ All WinRM sessions connected to PowerShell session configurations, such as Micro PowerShell Core does not support WOW64. The binary must match the architecture of the processor. - Unable to install plugin {0} to directory {1}. + Unable to install plugin {0} to directory {1}. - The WinRM plugin DLL {0} is missing for PowerShell. Please run Enable-PSRemoting and then retry this command. + The WinRM plugin DLL {0} is missing for PowerShell. Please run Enable-PSRemoting and then retry this command. This parameter set requires WSMan, and no supported WSMan client library was found. WSMan is either not installed or unavailable for this system. @@ -1686,4 +1686,11 @@ All WinRM sessions connected to PowerShell session configurations, such as Micro HTTPS on Unix does not currently support CA or CN checks. Use the PSSessionOption -SkipCACheck and -SkipCNCheck if you are certain you trust the server you are connecting to and the network in between. + + PowerShell remoting has been disabled only for PowerShell Core configurations and does not affect Windows PowerShell remoting configurations. Run this cmdlet in Windows PowerShell to affect all PowerShell remoting configurations. + + + + PowerShell remoting has been enabled only for PowerShell Core configurations and does not affect Windows PowerShell remoting configurations. Run this cmdlet in Windows PowerShell to affect all PowerShell remoting configurations. +