If you download the new version of Minecraft.exe
or Minecraft.msi
it will install a minimal working Java in the directory of the Launcher. By default, the game will prefer this to any other java installation.
This means that you can add [Minecraft]/runtime/jre-ABC/DEF/bin/javaw.exe
to the block list of your firewall, instead of blocking the default port (25565).
- Open "Windows Firewall with Advanced Security" as an Administrator
- Click on "Outbound rules" in the left pane
- In the right pane, click "New rule..."
- In the wizard, set it to program and locate the
javaw.exe
mentioned above.
- Set it to "Block all connections".
- Optional: Repeat step 2-5 for
java.exe
.
Blocking javaw.exe
affects the game itself. Any attempt to join a server will cause a java.net.SocketException: Permission denied
, even though the launcher won't say "Play Offline".
Blocking java.exe
will prevent the launcher from accessing minecraft.net
, so you will not be able to install new versions if you simply run Minecraft_Launcher.exe
, which uses the blocked java. You can easily subvert this by running [Minecraft]/game/launcher.jar
manually.
However, this is not really needed, and a simpler solution is using Windows UAC. Specifically, go to %appdata%/.minecraft
. Right click on versions
> Properties > Security > Edit. Select your kid's account and check "Deny" for "Write". Repeat his for launcher_profiles.json
. This will prevent your kids from downloading new versions, or modifying the existing ones. Furthermore, any changes to profiles with revert once the launcher closes.
A note on security: This method only works as long as the restricted user doesn't know how to run the game using a different java installation.
route add 23.21.227.220 127.0.0.1 -p
, followed by running Minecraft, followed byroute delete 23.21.227.220
, and link that for your kids. This assumes them not willing and able to tamper with it, though. It's also an ugly hack, rather than a real solution, and the command prompt will stay open until they close Minecraft.