@echo off
ipconfig /all >"%USERPROFILE%"\Desktop\ipconfig.txt
:: Saves ip settings
netsh interface ip delete arpcache
ipconfig /flushdns
ipconfig /release *
ipconfig /renew *
ipconfig /registerdns
nbtstat -RR
netsh winsock show catalog >"%USERPROFILE%"\Desktop\lsp.txt
::saves log of current settings
netsh winsock reset catalog
::resets Winsock
netsh winsock show catalog >>"%USERPROFILE%"\Desktop\lsp.txt
:: winsock after rest
netsh int ip reset >"%USERPROFILE%"\Desktop\tcpreset.txt
:: reset TCP stack
netsh dump >"%USERPROFILE%"\Desktop\netshout.txt
exit
exit