Click to See Complete Forum and Search --> : Encryption data, migrate code from java to C#


polszewski
October 9th, 2008, 03:53 AM
Hi

I have some problems to migrate a one piece of code from java to c#. Help me please!

...
private Cipher authCipher;
private SecretKeyFactory desEdeKeyFactory;
...

SecretKey kEnc = desEdeKeyFactory.generateSecret(new DESedeKeySpec(kenc));

authCipher.init(Cipher.ENCRYPT_MODE, kEnc);

byte[] e1 = authCipher.doFinal(reorderBlocks(rndIfdIcc));
...

polszewski
October 9th, 2008, 07:49 AM
so, can you tell me what's happen here:

SecretKey kEnc = desEdeKeyFactory.generateSecret(new DESedeKeySpec(kenc));