the background is like this. A software bought by the company was installed on xp, but now it has to be migrated to a new server. If there is a problem with the migration, you need to enter the registration code after installation. The company that made this software has closed down before, and there are no documents. After reading the code, I don"t know how to encrypt it
.//
// Source code recreated from a .class file by IntelliJ IDEA
// (powered by Fernflower decompiler)
//
package com.cwebs.common.util;
import java.io.BufferedReader;
import java.io.File;
import java.io.FileReader;
import java.util.Date;
public class MachineCode {
private static String expiredString;
static {
try {
System.load(MachineCode.class.getResource("/").getFile() + "HDSID.properties");
} catch (Exception var13) {
System.out.println("HDSID.dll ");
}
File f = new File(MachineCode.class.getResource("/").getFile() + "license.dat");
expiredString = null;
if (f != null && f.exists()) {
BufferedReader reader = null;
try {
reader = new BufferedReader(new FileReader(f));
expiredString = reader.readLine();
reader.close();
} catch (Exception var12) {
;
} finally {
if (reader != null) {
try {
reader.close();
} catch (Exception var11) {
;
}
}
}
}
}
public MachineCode() {
}
public static native String getHDSID();
public static native String getCPUSID();
public static native String getSID();
public static native String getDecryptionStr(String var0);
public static String getMachineCode() {
try {
return getHDSID();
} catch (Exception var1) {
System.out.println("");
return null;
}
}
public static boolean chcode(String deStr, String souStr) {
if (deStr != null && !deStr.equals("") && souStr != null && !souStr.equals("")) {
String _destr = getDecryptionStr(deStr);
if (_destr.length() > souStr.length()) {
_destr = _destr.substring(0, souStr.length());
}
return _destr.equals(souStr);
} else {
return false;
}
}
public static Date getExpired() {
String tempString = null;
if (expiredString != null) {
try {
DESPlus des = new DESPlus(getMachineCode());
tempString = des.decrypt(expiredString);
} catch (Exception var2) {
tempString = "1977-04-17";
}
} else {
tempString = "1977-04-17";
}
return C_Date.strTodate(tempString, "yyyy-MM-dd");
}
public static void main(String[] args) {
try {
DESPlus des = new DESPlus("B1B1AC094568C763DB");
System.out.println(des.encrypt("2013-12-30"));
} catch (Exception var2) {
;
}
}
}
license.dat opens content like this
1e8155d85ed62cc87ea60962dd2bc858
HDSID.properties is something like this
does anyone know how to encrypt it? install vcredit.exe software before deploying the configuration