jce

InvalidKeyException Illegal key size

我的梦境 提交于 2019-11-26 01:26:29
问题 I have a test which runs great on my development MacBook Pro, but fails to run in continuous integration TeamCity server. The error is following: java.security.InvalidKeyException: Illegal key size at javax.crypto.Cipher.a(DashoA13*..) at javax.crypto.Cipher.init(DashoA13*..) at javax.crypto.Cipher.init(DashoA13*..) Both development box and TeamCity uses Java 1.6 and I use BouncyCastle library for the need of special AES encryption. The code is following: private byte[] aesEncryptedInfo

How to avoid installing “Unlimited Strength” JCE policy files when deploying an application?

血红的双手。 提交于 2019-11-26 01:23:17
问题 I have an app that uses 256-bit AES encryption which is not supported by Java out of the box. I know to get this to function correctly I install the JCE unlimited strength jars in the security folder. This is fine for me being the developer, I can install them. My question is since this app will be distributed, end users most likely will not have these policy files installed. Having the end user download these just to make the app function is not an attractive solution. Is there a way to make

Trust Store vs Key Store - creating with keytool

喜你入骨 提交于 2019-11-25 22:43:08
问题 I understand that the keystore would usually hold private/public keys and the trust store only public keys (and represents the list of trusted parties you intend to communicate with). Well, that\'s my first assumption, so if that\'s not correct, I probably haven\'t started very well... I was interested though in understanding how / when you distinguish the stores when using keytool. So, far I\'ve created a keystore using keytool -import -alias bob -file bob.crt -keystore keystore.ks which