urgent help please!! decrypting a string recived from external device
i'm using 3des, with ECB mode and PKCS5 padding to encrypt and decrypt a string with a secret Key.
i get an encypted string from external device (remote pc). this string is represented with an array of 16 bytes.
i pass this array directly to the method decypt.doFinal, but i get a badPaddingException :Given final block not properly padded
at com.sun.crypto.provider.SunJCE_h.b(DashoA12275)
at com.sun.crypto.provider.SunJCE_h.b(DashoA12275)
at com.sun.crypto.provider.DESedeCipher.engineDoFinal(DashoA12275)
at javax.crypto.Cipher.doFinal(DashoA12275)
i tried to simulate this problem in my PC, so i encrypt a string and i pass the result (array of 16 bytes) to decrypt.doFinal and it's OK.
when i pass directly an array of 16 bytes the exception is thrown!!
does anyone have an idea please?

