Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $users = Get-Content users.txt
- foreach ($u in $users) {
- Write-Host $u
- $username = ('domain\' + $u)
- $password = 'password'
- $cred = New-Object System.Management.Automation.PSCredential -ArgumentList @($username,(ConvertTo-SecureString -String $password -AsPlainText -Force))
- Start-Process "C:\asd\fd.exe" -LoadUserProfile -Credential $cred
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement