Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @echo off
- REM XBOX App Teredo Fix by JeffersonGER v1.0 03.10.2018
- REM SETTINGS:
- REM 0 = No / 1 = Yes
- set DoRestartAfterScript=1
- set StateOfDecay2PortCheck=0
- set KEY_NAME=HKLM\System\CurrentControlSet\Services\Tcpip6\Parameters
- set VALUE_NAME=DisabledComponents
- set hostsfile=C:\WINDOWS\system32\drivers\etc\hosts
- set hostsurl=win10.ipv6.microsoft.com
- set opendns_address_string="Address:"
- REM DO NOT EDIT THE COMING LINES!
- REM DO NOT EDIT THE COMING LINES!
- REM DO NOT EDIT THE COMING LINES!
- REM DO NOT EDIT THE COMING LINES!
- net.exe session 1>nul 2>nul || (echo This script requires elevated rights. & pause & exit /b 1)
- color 4f
- REM echo Enable Telnet for Portcheck, please wait... ( Takes a few seconds! )
- REM dism /online /Enable-Feature /FeatureName:TelnetClient 1>nul 2>nul
- cls
- set scripaddregentrystatus="Skipped add Regedit - Because value already exists"
- set scripaddhostsurlstatus="Skipped add Hosts URL - Because value already exists"
- echo.
- echo "Please close all programs because after this Setup the Computer will be restarted!"
- echo.
- pause
- cls
- echo Please wait for a few seconds, Teredofix is in progress...
- ipconfig /flushdns 1>nul 2>nul
- sc stop iphlpsvc 1>nul 2>nul
- sc stop IKEEXT 1>nul 2>nul
- sc stop XblAuthManager 1>nul 2>nul
- sc stop XboxNetApiSvc 1>nul 2>nul
- netsh int Teredo set state disable 1>nul 2>nul
- for /F "usebackq tokens=3" %%A in (`reg query "%KEY_NAME%" /v "%VALUE_NAME%" 2^>nul ^| find "%VALUE_NAME%"`) do (
- goto scripregadd
- )
- :regadd
- reg add %KEY_NAME% /v %VALUE_NAME% /t REG_DWORD /d 0x0 /f 1>nul 2>nul
- set scripaddregentrystatus="Added Regedit Entry"
- :scripregadd
- netsh int teredo set state servername=win10.ipv6.microsoft.com 1>nul 2>nul
- netsh int teredo set state type=enterpriseclient 1>nul 2>nul
- netsh int teredo set state clientport=default 1>nul 2>nul
- find "%hostsurl%" "%hostsfile%" > nul & if errorlevel 1 (
- echo %hostsurl% >> %hostsfile%
- set scripaddhostsurlstatus="Added Hosts URL"
- ) else (
- goto scripaddhostsurl)
- :scripaddhostsurl
- netsh advfirewall set currentprofile firewallpolicy blockinbound,allowoutbound 1>nul 2>nul
- sc config iphlpsvc start=delayed-auto 1>nul 2>nul
- sc config IKEEXT start=delayed-auto 1>nul 2>nul
- sc config XblAuthManager start=delayed-auto 1>nul 2>nul
- sc config XboxNetApiSvc start=delayed-auto 1>nul 2>nul
- sc start iphlpsvc 1>nul 2>nul
- sc start IKEEXT 1>nul 2>nul
- sc start XblAuthManager 1>nul 2>nul
- sc start XboxNetApiSvc 1>nul 2>nul
- cls
- echo Please wait for a few seconds, Teredofix is in progress...
- ping 127.0.0.1 /n 5 > nul 2>&1
- cls
- echo.
- echo Now check the IP Adresses!
- echo.
- netsh int Teredo show state
- echo.
- echo.
- echo "Please check if one of these IPv4 Addresses matched to ("Local Mapping"):"
- ipconfig /all | findstr IPv4
- pause
- echo.
- echo "Please check if one of these Addresses matched to ("External NAT Mapping"):"
- for /f "usebackq tokens=2 delims=:" %%f in (`nslookup myip.opendns.com resolver1.opendns.com ^| findstr /c:%opendns_address_string%`) do (
- set extip=%%f
- )
- echo %extip%
- echo.
- echo.
- echo -------------------------------------------------------------------------
- echo Regedit Status: %scripaddregentrystatus%
- echo Hosts Status: %scripaddhostsurlstatus%
- if %DoRestartAfterScript%==1 ( echo Computerrestart is enabled! )
- echo -------------------------------------------------------------------------
- echo.
- echo.
- pause
- if %StateOfDecay2PortCheck%==1 (
- cls
- echo.
- echo Check externals Ports open:
- powershell -command "& {&'Test-NetConnection' 127.0.0.1 -Port 3074 -InformationLevel Quiet}"
- powershell -command "& {&'Test-NetConnection' 127.0.0.1 -Port 88 -InformationLevel Quiet}"
- powershell -command "& {&'Test-NetConnection' 127.0.0.1 -Port 500 -InformationLevel Quiet}"
- powershell -command "& {&'Test-NetConnection' 127.0.0.1 -Port 3074 -InformationLevel Quiet}"
- powershell -command "& {&'Test-NetConnection' 127.0.0.1 -Port 3544 -InformationLevel Quiet}"
- powershell -command "& {&'Test-NetConnection' 127.0.0.1 -Port 4500 -InformationLevel Quiet}"
- pause
- )
- if %DoRestartAfterScript%==1 (
- shutdown /g /t 0
- ) else (
- exit /b 1
- )
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement