Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (Get-LocalUser).Name | Out-File C:localusers.txt
- ForEach ($User in Get-Content C:localusers.txt)
- {
- If ($User -match "administrator" -or "kahuna")
- {
- Write-Host True
- }
- Else
- {
- Write-Host False
- }
- }
- If ($User -match "administrator" -or $User -match "kahuna")
- If (($User -match "administrator") -or ($User -match "kahuna"))
- If (($true) -or ($false))
Add Comment
Please, Sign In to add comment