Thanks nikoley,

i implemented DES algorithm to encrypt a String it worked fine in that
but while encrypting a file i have to ask user an Encryption key so at
that time i am asking for a key and then i am converting it to byte
array. but this SecretFactory not working this time can you explain
and if possible can you edit this text by using a raw key?

Thanks a lot.

On 12/27/11, Nikolay Elenkov <[email protected]> wrote:
> On Tue, Dec 27, 2011 at 3:11 PM, chander <[email protected]> wrote:
>
>> Exception is :    java.security.NoSuchAlgorithmException :
>> SecretKeyFactory AES implementation not found.
>>
>>
>> Please help and rectify the code or if possible give a working code
>> for File encryption using AES. i don't know why this implementation is
>> not there.
>
> Posting the same question twice in different threads is rarely useful.
>
> Assuming that byteKey is the raw key, you can construct a secret key
> like this (SecretKey is just a marker interface):
>
> SecretKey secretKey = new SecretKeySpec(byteKey, "AES");
>
> You don't need a SecretKeyFactory.
>
> --
> You received this message because you are subscribed to the Google
> Groups "Android Developers" group.
> To post to this group, send email to [email protected]
> To unsubscribe from this group, send email to
> [email protected]
> For more options, visit this group at
> http://groups.google.com/group/android-developers?hl=en


-- 
Chandra Mohan Mourya

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to