Skip to content

Commit 4de8af2

Browse files
committed
Fix an issue in a third party library used to compute machine codes
1 parent 487a07e commit 4de8af2

File tree

3 files changed

+4
-2
lines changed

3 files changed

+4
-2
lines changed

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
<dependency>
2828
<groupId>com.github.oshi</groupId>
2929
<artifactId>oshi-core</artifactId>
30-
<version>LATEST</version>
30+
<version>5.3.0</version>
3131
</dependency>
3232
<dependency>
3333
<groupId>commons-codec</groupId>

src/main/java/io/cryptolens/methods/Helpers.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -319,7 +319,7 @@ private static String getRawDeviceID()
319319

320320
String vendor = operatingSystem.getManufacturer();
321321
String processorSerialNumber = computerSystem.getSerialNumber();
322-
String processorIdentifier = centralProcessor.getIdentifier();
322+
String processorIdentifier = centralProcessor.getProcessorIdentifier().getIdentifier();
323323
int processors = centralProcessor.getLogicalProcessorCount();
324324

325325
return vendor +

src/main/java/io/cryptolens/methods/Key.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,11 @@ public static LicenseKey Activate (String token, String RSAPubKey, ActivateModel
6969
Map<String,String> extraParams = new HashMap<>();
7070

7171
// force sign and the new protocol (only in activate)
72+
// modelVersion=3 docs: https://app.cryptolens.io/docs/api/v3/Activate?modelVersion=3
7273
extraParams.put("Sign", "true");
7374
extraParams.put("SignMethod", "1");
7475
extraParams.put("token", token);
76+
//extraParams.put("ModelVersion", "3");
7577

7678
ActivateResult result = HelperMethods.SendRequestToWebAPI("key/activate", model, extraParams, ActivateResult.class, error);
7779

0 commit comments

Comments
 (0)