Fix forgotten digest

This commit is contained in:
Govindass
2020-05-27 15:10:26 +03:00
parent acdd2c2fdc
commit e740e2642e
4 changed files with 15 additions and 6 deletions

View File

@@ -61,6 +61,8 @@ public class AddonPlugin extends JavaPlugin {
} catch (NoSuchAlgorithmException e) {
e.printStackTrace();
}
assert sha != null;
key = sha.digest(key);
key = Arrays.copyOf(key, 16);
SecretKeySpec encryptionKey = new SecretKeySpec(key, "AES");