javax.crypto Questions

7

Solved

I am trying to implement password based encryption algorithm, but I get this exception: javax.crypto.BadPaddingException: Given final block not properly padded What might be the problem? Here...
Verisimilar asked 8/11, 2011 at 11:45

2

Solved

I generate 128bit AES/CBC/PKCS5Padding key using Java javax.crypto API. Here is the algorithm that I use: public static String encryptAES(String data, String secretKey) { try { byte[] secretKeys...
Vassili asked 21/5, 2016 at 22:42

1

Solved

I am looking for settings/parameters of CryptoKit which will allow me to share data between iOS App and a Java Application. The flow would be something like below: - Use CryptoKit to encrypt a text...
Beware asked 3/1, 2020 at 10:56

5

Solved

I am getting a Cipher implementation with Cipher.getInstance(String algorithm). I am under the impression that the available algorithm names that I may pass differ based on what libraries which are...
Shyamal asked 17/2, 2012 at 18:31

3

Solved

When I compile a class using javax.crypto.Mac I get this error message? package javax.crypto does not exist I can fix it by including jre/lib/jce.jar in my compile classpath. Why is jce.jar n...
Prurigo asked 18/2, 2013 at 11:40

1

Solved

Was trying to run the Junit tests Below is for the Password decryption using org.jasypt.encryption.pbe.StandardPBEStringEncryptor > Caused by: org.jasypt.exceptions.EncryptionInitializatio...
Fletafletch asked 1/9, 2017 at 4:55

2

Solved

I've been successfully using javax.crypto.Cipher.getInstance("DESede/CBC/NoPadding") to Authenticate with DESFire cards on Android (following the example here: https://mcmap.net/q/1193038/-des-send...

1

Solved

I'm trying to convert below java code into nodejs. public static String encrypt(String accessToken) throws Exception { Cipher cipher = Cipher.getInstance("AES"); String merchantKey = "1111111111...
Subhuman asked 13/7, 2016 at 12:50

2

Solved

In the Java crypto libraries, there are two different representations of a key - Key and KeySpec. The docs imply there's a difference between the two - a KeySpec is 'transparent' (whatever that mea...
Bunting asked 1/3, 2016 at 17:37

1

I have to encrypt an string using bash script in the same way I encrypt using javax.crypto.Cipher. At java I use AES-256 with the key "0123456789". But When I use openssl I had to convert "01234567...
Dog asked 14/8, 2015 at 21:8

2

Solved

I am migrating some server-side Java code to a new NodeJS server. I am looking for an equivalent method call in Javascript to Java's Cipher.doFinal(byte[]) Note that I can't use NodeJS Buffers beca...
Benevento asked 6/7, 2014 at 4:4

2

Solved

I'm working on a Java authentication subsystem that specs the storage of passwords in the DB as PBKDF2-generated hashes, and I'm now trying to decide whether I should use SHA1 or SHA512 as PRF. I w...
Simonette asked 13/10, 2013 at 18:9

1

Solved

I have the following Clojure code: (ns myproject.hmac-sha256 (:import (javax.crypto Mac) (javax.crypto.spec SecretKeySpec))) (defn secretKeyInst [key mac] (SecretKeySpec. (.getBytes key) (.get...
Gowrie asked 15/3, 2013 at 23:36

3

Solved

I'm using this code snippet to encrypt/decrypt data in my app's database: http://www.androidsnippets.com/encryptdecrypt-strings It appears that the javax.crypto.KeyGenerator.generateKey() operati...
Overcrop asked 11/6, 2011 at 13:38
1

© 2022 - 2024 — McMap. All rights reserved.