unkwntech

Untitled

Sep 30th, 2013
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $Adapter = ""
  2. #Take down all the Adapters
  3. foreach($a in Get-NetAdapter)
  4. {
  5.     $Adapter += "," + $a.Name ;
  6.     Disable-NetAdapter -Name $a.Name;
  7. }
  8.  
  9. #Reset Adaptors settings
  10. netsh int ip reset C:\netsh.log.txt
  11. netsh winsock reset
  12.  
  13. #empty ARP tables
  14. arp -d *
  15.  
  16. #flush DNS
  17. ipconfig /flushdns
  18.  
  19. #bring Adapter back up
  20. foreach($a in $Adapter.SubString(1).Split(","))
  21. {
  22.     Enable-NetAdapter -Name $a;
  23. }
Advertisement
Add Comment
Please, Sign In to add comment