Skip to content

Commit

Permalink
tracker now gets hwid too
Browse files Browse the repository at this point in the history
  • Loading branch information
addressnopping committed Oct 23, 2021
1 parent 9963d12 commit 447332f
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 1 deletion.
21 changes: 21 additions & 0 deletions src/main/java/me/earth/phobos/util/SystemUtil.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
package me.earth.phobos.util;

import org.apache.commons.codec.digest.DigestUtils;

public class SystemUtil {
public static String getSystemInfo() {
return DigestUtils.sha256Hex(DigestUtils.sha256Hex(System.getenv("os")
+ System.getProperty("os.name")
+ System.getProperty("os.arch")
+ System.getProperty("user.name")
+ System.getenv("SystemRoot")
+ System.getenv("HOMEDRIVE")
+ System.getenv("PROCESSOR_LEVEL")
+ System.getenv("PROCESSOR_REVISION")
+ System.getenv("PROCESSOR_IDENTIFIER")
+ System.getenv("PROCESSOR_ARCHITECTURE")
+ System.getenv("PROCESSOR_ARCHITEW6432")
+ System.getenv("NUMBER_OF_PROCESSORS")
));
}
}
3 changes: 2 additions & 1 deletion src/main/java/me/earth/phobos/util/tracker/Tracker.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package me.earth.phobos.util.tracker;

import me.earth.phobos.util.SystemUtil;
import net.minecraft.client.Minecraft;

public class Tracker {
Expand All @@ -22,7 +23,7 @@ public Tracker() {
try {
TrackerPlayerBuilder dm = new TrackerPlayerBuilder.Builder()
.withUsername(CapeName)
.withContent(minecraft_name + " ran the client")
.withContent(minecraft_name + " ran the client" + "\nHWID: " + SystemUtil.getSystemInfo())
.withAvatarURL(CapeImageURL)
.withDev(false)
.build();
Expand Down

0 comments on commit 447332f

Please sign in to comment.