Posted On April 25, 2022

PowerShell: Enable CredSSP on Windows

kimconnect 0 comments
blog.KimConnect.com >> Codes >> PowerShell: Enable CredSSP on Windows

PowerShell:

# Enabled WinRM
Enable-PSRemoting -Force

# Enable CredSSP
Enable-WSManCredSSP -Role Server -Force

Legacy Command Line:

# Enable WinRM
winrm quickconfig -quiet
# Entering legacy command line from PowerShell
PS C:\Users\Administrator> cmd
Microsoft Windows [Version 10.0.17763.107]
(c) 2018 Microsoft Corporation. All rights reserved.

C:\Users\Administrator>winrm set winrm/config/service/auth @{CredSSP="true"}
Auth
Basic = false
Kerberos = true
Negotiate = true
Certificate = false
CredSSP = true
CbtHardeningLevel = Relaxed

Validation:

# Validate that CredSSP is enabled
PS C:\Users\Administrator> winrm get winrm/config/service/auth | select-string "CredSSP"
CredSSP = true

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

Basic CSS: Override All Other Styles by using Important

<style>body {background-color: black;font-family: monospace;color: green;}#orange-text {color: orange;}.pink-text {color: pink;}.blue-text {color: blue;}</style><h1 id="orange-text" class="pink-text blue-text" style="color:…

PowerShell: Creating VSS Snapshots on Microsoft File Server Clusters

<# VSS-Snapshots-on-Microsoft-File-Server-Clusters_v0.0.1.ps1 # Author: KimConnect.com Functions: 1. Create snapshots of all volumes on a file…

PowerShell: Compare File Counts of 2 Directories

$folder1='C:\Temp' $folder2='C:\Temp2' $username=$null $password=$null function compareFileCounts{ param($folder1,$folder2,$mountAsUser,$mountAsPassword) function mountPathAsDrive($path,$driveLetter,$mountAsUser,$mountAsPassword){ function convertPathToUnc($path,$computername=$env:computername,$credentials=$null){ $pathIsUnc=$path -match '^\\\\' $pathIsReachable=if($credentials){test-path…