Patches for the old minecraft official launcher to add microsoft account support

Overview

MSA4Legacy

Patches for the old minecraft official launcher to add microsoft account support
My code here is quite atrocious in some parts (for example it makes a bunch of unnecessary auth requests due to lack of proper caching), but it works so i decided to release it now, i will likely be improving it in the future

Requirements

These patches bump the java version requirement from java 6 + jfx to java 8 + jfx, the java version i use for development can be found here

Usage

  1. Download the installer and patches from the Actions tab in this repository (requires an account)
  2. Put the patches file in the same directory as the official launcher jar
  3. Run the installer and select the official launcher jar
  4. The patched jar will be in that same directory, but called "launcher-patched.jar"

Development

This project requires jdk8 due to a library, however to minimize binpatches any development must be done targeting java 6 bytecode, so java 6 syntax must be used

To set up a decompiled environment, run the filterDecomp task
To create patches with your changes, run the genSourceDiffs task
To create a recompiled jar, run the jarLauncher task (DOES NOT KEEP UNSAVED PATCHES)
To generate binary patches to use with the installer, run the genBinPatches task

More tasks can be found in the build.gradle.kts file, please read which tasks depend on others to prevent unsaved work being lost

Is this legal?

Yes, special care has been taken to keep this project 100% legal, by using both binary and source patches, no substantial mojang code is distributed by this project

I AM NOT AFFILIATED WITH NOR ENDORSED BY Microsoft Corporation NOR ITS SUBSIDIARY Mojang Studios IN ANY WAY

You might also like...

NPM Package - A react native component that let you to add a wavy background UI.

NPM Package - A react native component that let you to add a wavy background UI.

react-native-wavy-background A react native component that let you to add a wavy background UI. Installation npm install react-native-wavy-background

Oct 19, 2022

Add custom auth options (e.g. face unlock) to your phone using Xposed.

UniversalAuth This project aims to bring a variety of custom authentication options to various Android ROMs. Your phone needs to have Xposed (or EdXpo

Dec 29, 2022

Program that allows employees to clock in and clock out of work. Employees who are managers can add, edit and delete employees and shifts from the database.

Program that allows employees to clock in and clock out of work. Employees who are managers can add, edit and delete employees and shifts from the database.

Clock-In-Clock-Out-System Created by: Kennedy Janto, Taylor Vandenberg, Duc Nguyen, Alex Gomez, Janista Gitbumrungsin This is a semester long project

Nov 5, 2022

This repository is totally dedicated to Hacktoberfest 2021, feel free to add your project.

This repository is totally dedicated to Hacktoberfest 2021, feel free to add your project.

push-it-hacktoberfest This repository is totally dedicated to Hacktoberfest 2021, feel free to add your project. HacktoberFest21 Hello Hackers, Contri

Oct 31, 2021

Ti.googlepay - Add Google Pay to your app

Ti.googlepay - Add Google Pay to your app

Google Pay Add Google Pay to your app: Events available success canceled error Methods setupPaymentGateway: name, apiKey createPaymentRequest: environ

Nov 7, 2022

A bukkit/spigot plugin to add custom music discs using the Simple Voice Chat API.

Custom Discs 1.19 A spigot/bukkit fork of henkelmax's Audio Player. Play custom music discs using the Simple Voice Chat API. (The voice chat mod is re

Dec 22, 2022

Add a partial Coeffect system into Java using Loom's ExtentLocals

Coeffect Add a partial Coeffect system into Java using Loom's ExtentLocals. In Java there are generally 2 strategies to manage the parameters a method

Sep 9, 2022

A small mod to improve support for architectures and libraries officially unsupported by Minecraft. Mainly targeting Apple Macs using arm processors.

fabric-loom-native-support A small mod to improve support for architectures and libraries officially unsupported by Minecraft. Mainly targeting Apple

Oct 17, 2022

A supercharged gradle template for developing Minecraft plugins with multi platform support.

Minecraft Multi-Platform Template You can use this template to develop your own high quality Minecraft plugins for multiple platforms using Gradle wit

Nov 23, 2022
Comments
  • Checksum issue creates useless patched JAR (with a smaller filesize)

    Checksum issue creates useless patched JAR (with a smaller filesize)

    Info

    Launch Command: java -jar launcher-1.0.0.jar > output.log, run in directory /home/user/Downloads/launcher/

    /home/user/Downloads/launcher/ File Tree

    • launcher.jar (4.3 MiB)
    • patches.lzma
    • installer-1.0.0.jar (After run:)
    • launcher-patched.jar (219.9 KiB)
    • output.log

    pacman -Q java-openjfx jre-openjdk jre8-openjdk

    java-openjfx 17.0.0.1.u1-1
    jre-openjdk 17.0.1.u12-1
    jre8-openjdk 8.u312-2
    

    archlinux-java status

    Available Java environments:
      java-11-openjdk
      java-17-openjdk
      java-7-openjdk/jre
      java-8-openjdk/jre (default)
    

    uname -r

    5.16.5-arch1-1
    

    [Start of] Stack Trace

    java.io.IOException: Patch expected net/minecraft/launcher/updater/CompleteMinecraftVersion to have the checksum 74c8a9d but it was eea83fd
    	at net.minecraftforge.binarypatcher.Patcher.patch(Patcher.java:197)
    	at net.minecraftforge.binarypatcher.Patcher.process(Patcher.java:149)
    	at net.minecraftforge.binarypatcher.ConsoleTool.main(ConsoleTool.java:161)
    	at me.nepnep.msa4legacy.installer.Main$1$1.actionPerformed(Main.java:29)
    

    Full output at: pastebin.com/tLck8jEt (Almost 5,000 lines)


    Description

    I can only think that a checksum error is because of the version of the launcher I'm using. I got it from this Stack Exchange answer, which gave this link: launcher.mojang.com/mc/launcher/jar/fa896bd4c79d4e9f0d18df43151b549f865a3db6/launcher.jar.lzma I lost the original YouTube tutorial I used to get my legacy launcher from. One thing I have noticed is that the usual red text I had at the top of the launcher (saying that it was outdated) isn't there. I think it may be an older launcher version.
    Where do I find the right version? (And if this is the cause of my issue, shouldn't there be a note in the README detailing version dependency?)

    Do I need to provide any other information?

    opened by toydotgame 8
  • Cannot launch the game

    Cannot launch the game

    [22:38:44 FATAL]: Unhandled exception in thread Thread[pool-2-thread-3,5,main]
    java.lang.reflect.InaccessibleObjectException: Unable to make field private final int java.lang.ThreadLocal.threadLocalHashCode accessible: module java.base does not "opens java.lang" to unnamed module @4df828d7
            at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354) ~[?:?]
            at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297) ~[?:?]
            at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:178) ~[?:?]
            at java.base/java.lang.reflect.Field.setAccessible(Field.java:172) ~[?:?]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:116) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.getAdapter(Gson.java:356) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.<init>(ReflectiveTypeAdapterFactory.java:82) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.createBoundField(ReflectiveTypeAdapterFactory.java:81) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:118) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.getAdapter(Gson.java:356) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.<init>(ReflectiveTypeAdapterFactory.java:82) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.createBoundField(ReflectiveTypeAdapterFactory.java:81) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:118) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.getAdapter(Gson.java:356) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.fromJson(Gson.java:802) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.fromJson(Gson.java:768) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.fromJson(Gson.java:717) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.fromJson(Gson.java:689) ~[launcher-patched.jar:1.6.93]
            at net.minecraft.launcher.updater.RemoteVersionList.getCompleteVersion(RemoteVersionList.java:41) ~[launcher-patched.jar:1.6.93]
            at net.minecraft.launcher.updater.MinecraftVersionManager.getLatestCompleteVersion(MinecraftVersionManager.java:223) ~[launcher-patched.jar:1.6.93]
            at net.minecraft.launcher.updater.MinecraftVersionManager.getLatestCompleteVersion(MinecraftVersionManager.java:53) ~[launcher-patched.jar:1.6.93]
            at com.mojang.launcher.game.runner.AbstractGameRunner.playGame(AbstractGameRunner.java:76) ~[launcher-patched.jar:1.6.93]
            at net.minecraft.launcher.game.GameLaunchDispatcher$1.run(GameLaunchDispatcher.java:127) ~[launcher-patched.jar:1.6.93]
            at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) ~[?:?]
            at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) ~[?:?]
            at java.base/java.lang.Thread.run(Thread.java:833) [?:?]
    

    It also can't seem to load any version of Minecraft

    [22:38:22 ERROR]: Couldn't load local version C:\Users\stick\AppData\Roaming\.minecraft\versions\1.8.9\1.8.9.json
    java.lang.reflect.InaccessibleObjectException: Unable to make field private final int java.lang.ThreadLocal.threadLocalHashCode accessible: module java.base does not "opens java.lang" to unnamed module @4df828d7
            at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354) ~[?:?]
            at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297) ~[?:?]
            at java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:178) ~[?:?]
            at java.base/java.lang.reflect.Field.setAccessible(Field.java:172) ~[?:?]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:116) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.getAdapter(Gson.java:356) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.<init>(ReflectiveTypeAdapterFactory.java:82) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.createBoundField(ReflectiveTypeAdapterFactory.java:81) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:118) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.getAdapter(Gson.java:356) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$1.<init>(ReflectiveTypeAdapterFactory.java:82) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.createBoundField(ReflectiveTypeAdapterFactory.java:81) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.getBoundFields(ReflectiveTypeAdapterFactory.java:118) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory.create(ReflectiveTypeAdapterFactory.java:72) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.getAdapter(Gson.java:356) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.fromJson(Gson.java:802) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.fromJson(Gson.java:768) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.fromJson(Gson.java:717) ~[launcher-patched.jar:1.6.93]
            at com.google.gson.Gson.fromJson(Gson.java:689) ~[launcher-patched.jar:1.6.93]
            at net.minecraft.launcher.updater.LocalVersionList.refreshVersions(LocalVersionList.java:58) [launcher-patched.jar:1.6.93]
            at net.minecraft.launcher.updater.MinecraftVersionManager.refreshVersions(MinecraftVersionManager.java:80) [launcher-patched.jar:1.6.93]
            at net.minecraft.launcher.Launcher$2.run(Launcher.java:175) [launcher-patched.jar:1.6.93]
            at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) [?:?]
            at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
            at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) [?:?]
            at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) [?:?]
            at java.base/java.lang.Thread.run(Thread.java:833) [?:?]
    
    opened by sticks-stuff 5
  • Launcher straight up stalls after first step of login. Not unresponsive but not working either.

    Launcher straight up stalls after first step of login. Not unresponsive but not working either.

    So, I was trying to use the launcher, and log in, but then nothing worked. I clicked on "Microsoft Account", put in my email, clicked "Log In", and there was a text saying to go to a website and enter a code. So far so good. When, though, I entered said code, nothing happened. The website said that I was logged in "Nepauth", but the launcher did nothing. I could still press the buttons, but that's it. As of right now, the "Log In" button does nothing and I cannot log in.

    Tried:

    • Redownloading the patch file, on multiple versions
    • Redownloading the launcher
    • Redownloading the installer
    • Restarting the launcher several times
    • Killing Java and restarting it.

    Am I doing something wrong or is there a problem with the launcher.

    opened by Safariminer 5
  • Doesn't seem to function properly

    Doesn't seem to function properly

    I followed the instructions in the README and I got an error because patches.lzma wasn't found in my home directory. Ok, I git clones and ran tar -cf patches.lzma --lzma patches/* and copied the lzma file I got into my home directory, reran the installer and it worked. Launched the "patched" launcher and I couldn't log in. Please fix this.

    opened by SolDev69 2
Owner
Nep Nep
Nep Nep
Experiments on how to add Loom support for Netty

Netty Loom Experiment This repository contains Project Loom and Netty related test code. Contents / Goals I created these examples since I was curious

Johannes Schüth 5 Oct 14, 2022
Add something to Minecraft LAN Server List

DiscoverMe Make a fortune... in Minecraft Server List! 0 dependencies, Java 8 compatible. Usage Example: DiscoverMe.INSTANCE.addEntry(SimpleChatColor.

iceBear 4 Oct 13, 2021
Official Elasticsearch Java Client

Elasticsearch Java Client The official Java client for Elasticsearch. Note: this project is still a work in progress. This client is meant to replace

elastic 230 Jan 8, 2023
Catogram - Experimental telegram client based on official Android sources

Catogram Experimental telegram client based on official Android sources Features: Message translator TGX Style of context menu VKUI Icons and inbuilt

null 188 Dec 17, 2022
ZerotierFix - An unofficial Zerotier Android client patched from official client

Zerotier Fix An unofficial Zerotier Android client patched from official client. Features Self-hosted Moon Support Add custom planet config via file a

KAAAsS 830 Jan 8, 2023
This is the official theme SDK for the FairPlayer Music Player for Android.

FairPlayer - Themes SDK This is the official theme SDK for the FairPlayer Music Player for Android. You can download the most recent version of FairPl

Mark Jivko 0 Jan 31, 2022
Official React Native client for FingerprintJS PRO. 100% accurate device identification for fraud detection.

FingerprintJS PRO React Native Official React Native module for 100% accurate device identification, created for the FingerprintJS Pro Server API. Thi

FingerprintJS 26 Nov 22, 2022
Official Quilt template mod.

Quilt Template Mod The official Quilt template Mod. You can use it as a template for your own mods! Usage In order to use this mod as a template: Crea

null 117 Jan 2, 2023
Official Quilt template mod.

Quilt Template Mod The official Quilt template Mod. You can use it as a template for your own mods! Usage In order to use this mod as a template: Crea

null 32 May 7, 2022
Official Java library for the DeepL language translation API.

DeepL Java Library The DeepL API is a language translation API that allows other computer programs to send texts and documents to DeepL's servers and

DeepL 26 Dec 29, 2022