You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Following is optional, Google requires encryption needs to be AES/GCM/NoPadding, Following is updated encryption logic using AES/GCM/NoPadding, at present plugin works for both old encryption method (AES/CBC/PKCS5Padding) as well as for new method AES/GCM/NoPadding.
54
+
55
+
Following is example code encryption using AES/GCM/NoPadding to connect to PNFPB plugin REST API
56
+
57
+
'''JAVA
58
+
/*** NEW method of encrypting using AES GCM Nopadding - 2024 */
59
+
SecureRandom secureRandom = new SecureRandom();
60
+
byte[] iv = new byte[16]; // GCM mode typically uses a 12-byte IV
61
+
secureRandom.nextBytes(iv);
62
+
IvParameterSpec ivSpec = new IvParameterSpec(iv);
63
+
// Create an AES key from the secret
64
+
SecretKeySpec secretKey = new SecretKeySpec(secret.getBytes(), "AES");
0 commit comments